Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[google_workspace] Add httpjson system tests and remove log input #1130

Merged
merged 1 commit into from
Jun 17, 2021

Conversation

marc-gr
Copy link
Contributor

@marc-gr marc-gr commented Jun 16, 2021

What does this PR do?

  • Removes log input only used for system tests
  • Adds System tests for the httpjson input.

Checklist

  • I have reviewed tips for building integrations and this pull request is aligned with them.
  • I have verified that all data streams collect metrics or logs.
  • I have added an entry to my package's changelog.yml file.
  • If I'm introducing a new feature, I have modified the Kibana version constraint in my package's manifest.yml file to point to the latest Elastic stack release (e.g. ^7.13.0).

Related issues

@elasticmachine
Copy link

Pinging @elastic/security-external-integrations (Team:Security-External Integrations)

@marc-gr marc-gr force-pushed the googleworkspace_system-tests branch from 385241a to 15f576e Compare June 16, 2021 12:51
@elasticmachine
Copy link

elasticmachine commented Jun 16, 2021

💔 Tests Failed

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview

Expand to view the summary

Build stats

  • Build Cause: Pull request #1130 updated

  • Start Time: 2021-06-16T15:13:01.783+0000

  • Duration: 74 min 58 sec

  • Commit: 899aa1f

Test stats 🧪

Test Results
Failed 6
Passed 0
Skipped 0
Total 6

Trends 🧪

Image of Build Times

Image of Tests

Test errors 6

Expand to view the tests failures

system test: default – google_workspace.groups
  • no error details
  • Expand to view the stacktrace

     could not find hits in logs-google_workspace.groups-ep data stream 
    

system test: default – google_workspace.login
  • no error details
  • Expand to view the stacktrace

     could not find hits in logs-google_workspace.login-ep data stream 
    

system test: default – google_workspace.saml
  • no error details
  • Expand to view the stacktrace

     could not find hits in logs-google_workspace.saml-ep data stream 
    

system test: default – google_workspace.user_accounts
  • no error details
  • Expand to view the stacktrace

     could not find hits in logs-google_workspace.user_accounts-ep data stream 
    

system test: default – google_workspace.admin
  • no error details
  • Expand to view the stacktrace

     could not find hits in logs-google_workspace.admin-ep data stream 
    

system test: default – google_workspace.drive
  • no error details
  • Expand to view the stacktrace

     could not find hits in logs-google_workspace.drive-ep data stream 
    

Steps errors 1

Expand to view the steps failures

Test integration: google_workspace
  • Took 64 min 25 sec . View more details on here
  • Description: eval "$(../../build/elastic-package stack shellinit)" ../../build/elastic-package test -v --report-format xUnit --report-output file

Log output

Expand to view the last 100 lines of log output

[2021-06-16T16:25:51.906Z] 2021/06/16 16:25:51 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:25:52.845Z] 2021/06/16 16:25:52 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:25:53.782Z] 2021/06/16 16:25:53 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:25:54.719Z] 2021/06/16 16:25:54 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:25:56.111Z] 2021/06/16 16:25:55 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:25:57.048Z] 2021/06/16 16:25:56 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:25:57.987Z] 2021/06/16 16:25:57 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:25:58.925Z] 2021/06/16 16:25:58 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:25:59.867Z] 2021/06/16 16:25:59 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:26:00.806Z] 2021/06/16 16:26:00 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:26:01.744Z] 2021/06/16 16:26:01 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:26:03.126Z] 2021/06/16 16:26:02 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:26:04.067Z] 2021/06/16 16:26:03 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:26:05.007Z] 2021/06/16 16:26:04 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:26:05.947Z] 2021/06/16 16:26:05 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:26:06.886Z] 2021/06/16 16:26:06 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:26:07.829Z] 2021/06/16 16:26:07 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:26:08.770Z] 2021/06/16 16:26:08 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:26:10.153Z] 2021/06/16 16:26:09 DEBUG found 0 hits in logs-google_workspace.user_accounts-ep data stream
[2021-06-16T16:26:11.095Z] 2021/06/16 16:26:10 DEBUG reassigning original policy back to agent...
[2021-06-16T16:26:11.095Z] 2021/06/16 16:26:10 DEBUG PUT http://127.0.0.1:5601/api/fleet/agents/11071bab-efab-4ed6-85e9-d9ee40e6c6ee/reassign
[2021-06-16T16:26:12.036Z] 2021/06/16 16:26:11 DEBUG GET http://127.0.0.1:5601/api/fleet/agents/11071bab-efab-4ed6-85e9-d9ee40e6c6ee
[2021-06-16T16:26:12.036Z] 2021/06/16 16:26:11 DEBUG Wait until the policy (ID: 8ecd48c0-ceb6-11eb-a9a3-c7dbb5717c54, revision: 1) is assigned to the agent (ID: 11071bab-efab-4ed6-85e9-d9ee40e6c6ee)...
[2021-06-16T16:26:13.949Z] 2021/06/16 16:26:13 DEBUG GET http://127.0.0.1:5601/api/fleet/agents/11071bab-efab-4ed6-85e9-d9ee40e6c6ee
[2021-06-16T16:26:13.949Z] 2021/06/16 16:26:13 DEBUG Wait until the policy (ID: 8ecd48c0-ceb6-11eb-a9a3-c7dbb5717c54, revision: 1) is assigned to the agent (ID: 11071bab-efab-4ed6-85e9-d9ee40e6c6ee)...
[2021-06-16T16:26:16.005Z] 2021/06/16 16:26:15 DEBUG GET http://127.0.0.1:5601/api/fleet/agents/11071bab-efab-4ed6-85e9-d9ee40e6c6ee
[2021-06-16T16:26:16.006Z] 2021/06/16 16:26:15 DEBUG Wait until the policy (ID: 8ecd48c0-ceb6-11eb-a9a3-c7dbb5717c54, revision: 1) is assigned to the agent (ID: 11071bab-efab-4ed6-85e9-d9ee40e6c6ee)...
[2021-06-16T16:26:18.544Z] 2021/06/16 16:26:17 DEBUG GET http://127.0.0.1:5601/api/fleet/agents/11071bab-efab-4ed6-85e9-d9ee40e6c6ee
[2021-06-16T16:26:18.545Z] 2021/06/16 16:26:17 DEBUG Policy revision assigned to the agent (ID: 11071bab-efab-4ed6-85e9-d9ee40e6c6ee)...
[2021-06-16T16:26:18.545Z] 2021/06/16 16:26:17 DEBUG deleting test policy...
[2021-06-16T16:26:18.545Z] 2021/06/16 16:26:17 DEBUG POST http://127.0.0.1:5601/api/fleet/agent_policies/delete
[2021-06-16T16:26:22.740Z] 2021/06/16 16:26:21 DEBUG tearing down service...
[2021-06-16T16:26:22.740Z] 2021/06/16 16:26:21 DEBUG tearing down service using docker compose runner
[2021-06-16T16:26:22.740Z] 2021/06/16 16:26:21 DEBUG running command: /usr/local/bin/docker-compose -f /var/lib/jenkins/workspace/est-manager_integrations_PR-1130/src/github.com/elastic/integrations/packages/google_workspace/_dev/deploy/docker/docker-compose.yml -p elastic-package-service down
[2021-06-16T16:26:22.740Z] Stopping elastic-package-service_google_workspace_1 ... 
[2021-06-16T16:26:22.740Z] Stopping elastic-package-service_creds_1            ... 
[2021-06-16T16:26:36.342Z] 
Stopping elastic-package-service_google_workspace_1 ... done

Stopping elastic-package-service_creds_1            ... done
Removing elastic-package-service_google_workspace_1 ... 
[2021-06-16T16:26:36.342Z] Removing elastic-package-service_creds_1            ... 
[2021-06-16T16:26:36.342Z] 
Removing elastic-package-service_google_workspace_1 ... done

Removing elastic-package-service_creds_1            ... done
Removing network elastic-package-service_default
[2021-06-16T16:26:36.342Z] 2021/06/16 16:26:34 DEBUG deleting data in data stream...
[2021-06-16T16:26:36.342Z] Error: one or more test cases failed
[2021-06-16T16:26:36.401Z] Running in /var/lib/jenkins/workspace/est-manager_integrations_PR-1130/src/github.com/elastic/integrations
[2021-06-16T16:26:36.416Z] Archiving artifacts
[2021-06-16T16:26:36.635Z] Recording test results
[2021-06-16T16:26:37.125Z] [Checks API] No suitable checks publisher found.
[2021-06-16T16:26:37.445Z] + build/elastic-package stack dump -v --output build/elastic-stack-dump/latest/google_workspace
[2021-06-16T16:26:37.445Z] 2021/06/16 16:26:37  WARN CommitHash is undefined, in both /var/lib/jenkins/workspace/est-manager_integrations_PR-1130/.elastic-package/version and the compiled binary, config may be out of date.
[2021-06-16T16:26:37.445Z] 2021/06/16 16:26:37 DEBUG Enable verbose logging
[2021-06-16T16:26:37.445Z] 2021/06/16 16:26:37 DEBUG Dump Elastic stack data
[2021-06-16T16:26:37.445Z] 2021/06/16 16:26:37 DEBUG Dump stack logs
[2021-06-16T16:26:37.445Z] 2021/06/16 16:26:37 DEBUG Recreate the output location (path: build/elastic-stack-dump/latest/google_workspace)
[2021-06-16T16:26:37.445Z] 2021/06/16 16:26:37 DEBUG Dump stack logs for elasticsearch
[2021-06-16T16:26:37.445Z] 2021/06/16 16:26:37 DEBUG running command: /usr/local/bin/docker-compose -f /var/lib/jenkins/workspace/est-manager_integrations_PR-1130/.elastic-package/profiles/default/stack/snapshot.yml -p elastic-package-stack logs elasticsearch
[2021-06-16T16:26:38.384Z] 2021/06/16 16:26:38 DEBUG Dump stack logs for elastic-agent
[2021-06-16T16:26:38.384Z] 2021/06/16 16:26:38 DEBUG running command: /usr/local/bin/docker-compose -f /var/lib/jenkins/workspace/est-manager_integrations_PR-1130/.elastic-package/profiles/default/stack/snapshot.yml -p elastic-package-stack logs elastic-agent
[2021-06-16T16:26:39.324Z] 2021/06/16 16:26:39 DEBUG Dump stack logs for fleet-server
[2021-06-16T16:26:39.324Z] 2021/06/16 16:26:39 DEBUG running command: /usr/local/bin/docker-compose -f /var/lib/jenkins/workspace/est-manager_integrations_PR-1130/.elastic-package/profiles/default/stack/snapshot.yml -p elastic-package-stack logs fleet-server
[2021-06-16T16:26:40.264Z] 2021/06/16 16:26:39 DEBUG Dump stack logs for kibana
[2021-06-16T16:26:40.264Z] 2021/06/16 16:26:39 DEBUG running command: /usr/local/bin/docker-compose -f /var/lib/jenkins/workspace/est-manager_integrations_PR-1130/.elastic-package/profiles/default/stack/snapshot.yml -p elastic-package-stack logs kibana
[2021-06-16T16:26:41.204Z] 2021/06/16 16:26:41 DEBUG Dump stack logs for package-registry
[2021-06-16T16:26:41.204Z] 2021/06/16 16:26:41 DEBUG running command: /usr/local/bin/docker-compose -f /var/lib/jenkins/workspace/est-manager_integrations_PR-1130/.elastic-package/profiles/default/stack/snapshot.yml -p elastic-package-stack logs package-registry
[2021-06-16T16:26:42.585Z] Path to stack dump: build/elastic-stack-dump/latest/google_workspace
[2021-06-16T16:26:42.585Z] Done
[2021-06-16T16:26:42.605Z] Archiving artifacts
[2021-06-16T16:26:42.985Z] + build/elastic-package stack down -v
[2021-06-16T16:26:42.985Z] 2021/06/16 16:26:42  WARN CommitHash is undefined, in both /var/lib/jenkins/workspace/est-manager_integrations_PR-1130/.elastic-package/version and the compiled binary, config may be out of date.
[2021-06-16T16:26:42.985Z] 2021/06/16 16:26:42 DEBUG Enable verbose logging
[2021-06-16T16:26:42.985Z] Take down the Elastic stack
[2021-06-16T16:26:42.985Z] 2021/06/16 16:26:42 DEBUG running command: /usr/local/bin/docker-compose -f /var/lib/jenkins/workspace/est-manager_integrations_PR-1130/.elastic-package/profiles/default/stack/snapshot.yml -p elastic-package-stack down
[2021-06-16T16:26:43.558Z] The ELASTICSEARCH_IMAGE_REF variable is not set. Defaulting to a blank string.
[2021-06-16T16:26:43.558Z] The KIBANA_IMAGE_REF variable is not set. Defaulting to a blank string.
[2021-06-16T16:26:43.558Z] The STACK_PATH variable is not set. Defaulting to a blank string.
[2021-06-16T16:26:43.558Z] The PROFILE_NAME variable is not set. Defaulting to a blank string.
[2021-06-16T16:26:43.558Z] The ELASTIC_AGENT_IMAGE_REF variable is not set. Defaulting to a blank string.
[2021-06-16T16:26:43.558Z] Stopping elastic-package-stack_elastic-agent_1    ... 
[2021-06-16T16:26:43.558Z] Stopping elastic-package-stack_fleet-server_1     ... 
[2021-06-16T16:26:43.558Z] Stopping elastic-package-stack_kibana_1           ... 
[2021-06-16T16:26:43.558Z] Stopping elastic-package-stack_package-registry_1 ... 
[2021-06-16T16:26:43.559Z] Stopping elastic-package-stack_elasticsearch_1    ... 
[2021-06-16T16:26:58.622Z] 
Stopping elastic-package-stack_elastic-agent_1    ... done

Stopping elastic-package-stack_fleet-server_1     ... done

Stopping elastic-package-stack_kibana_1           ... done

Stopping elastic-package-stack_package-registry_1 ... done

Stopping elastic-package-stack_elasticsearch_1    ... done
Removing elastic-package-stack_elastic-agent_is_ready_1    ... 
[2021-06-16T16:26:58.622Z] Removing elastic-package-stack_fleet-server_is_ready_1     ... 
[2021-06-16T16:26:58.622Z] Removing elastic-package-stack_elastic-agent_1             ... 
[2021-06-16T16:26:58.622Z] Removing elastic-package-stack_kibana_is_ready_1           ... 
[2021-06-16T16:26:58.622Z] Removing elastic-package-stack_fleet-server_1              ... 
[2021-06-16T16:26:58.622Z] Removing elastic-package-stack_kibana_1                    ... 
[2021-06-16T16:26:58.623Z] Removing elastic-package-stack_elasticsearch_is_ready_1    ... 
[2021-06-16T16:26:58.623Z] Removing elastic-package-stack_package-registry_is_ready_1 ... 
[2021-06-16T16:26:58.623Z] Removing elastic-package-stack_package-registry_1          ... 
[2021-06-16T16:26:58.623Z] Removing elastic-package-stack_elasticsearch_1             ... 
[2021-06-16T16:26:58.623Z] 
Removing elastic-package-stack_kibana_is_ready_1           ... done

Removing elastic-package-stack_package-registry_is_ready_1 ... done

Removing elastic-package-stack_fleet-server_is_ready_1     ... done

Removing elastic-package-stack_package-registry_1          ... done

Removing elastic-package-stack_kibana_1                    ... done

Removing elastic-package-stack_elastic-agent_is_ready_1    ... done

Removing elastic-package-stack_elasticsearch_is_ready_1    ... done

Removing elastic-package-stack_elasticsearch_1             ... done

Removing elastic-package-stack_elastic-agent_1             ... done

Removing elastic-package-stack_fleet-server_1              ... done
Removing network elastic-package-stack_default
[2021-06-16T16:26:58.623Z] Done
[2021-06-16T16:26:58.657Z] Failed in branch google_workspace
[2021-06-16T16:26:58.899Z] Running on Jenkins in /var/lib/jenkins/workspace/est-manager_integrations_PR-1130
[2021-06-16T16:26:58.932Z] [INFO] getVaultSecret: Getting secrets
[2021-06-16T16:26:58.966Z] Masking supported pattern matches of $VAULT_ADDR or $VAULT_ROLE_ID or $VAULT_SECRET_ID
[2021-06-16T16:26:59.572Z] + chmod 755 generate-build-data.sh
[2021-06-16T16:26:59.572Z] + ./generate-build-data.sh https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Ingest-manager/integrations/PR-1130/ https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Ingest-manager/integrations/PR-1130/runs/8 FAILURE 4437529
[2021-06-16T16:26:59.572Z] INFO: curl https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Ingest-manager/integrations/PR-1130/runs/8/steps/?limit=10000 -o steps-info.json
[2021-06-16T16:26:59.822Z] INFO: curl https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Ingest-manager/integrations/PR-1130/runs/8/tests/?status=FAILED -o tests-errors.json
[2021-06-16T16:26:59.822Z] INFO: curl https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Ingest-manager/integrations/PR-1130/runs/8/log/ -o pipeline-log.txt

@marc-gr marc-gr force-pushed the googleworkspace_system-tests branch 6 times, most recently from 34fe5ee to 899aa1f Compare June 16, 2021 15:12
@marc-gr marc-gr force-pushed the googleworkspace_system-tests branch from 899aa1f to f774895 Compare June 16, 2021 15:22
Copy link
Member

@P1llus P1llus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@P1llus P1llus merged commit 40e648a into elastic:master Jun 17, 2021
P1llus added a commit that referenced this pull request Jun 17, 2021
james-elastic pushed a commit to james-elastic/integrations that referenced this pull request Jun 30, 2021
eyalkraft pushed a commit to build-security/integrations that referenced this pull request Mar 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants