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

Cherry-pick #21070 to 7.9: Add vendoring to Google Cloud Functions again #21079

Merged
merged 4 commits into from
Sep 14, 2020

Conversation

kvch
Copy link
Contributor

@kvch kvch commented Sep 14, 2020

Cherry-pick of PR #21070 to 7.9 branch. Original message:

What does this PR do?

This PR adds the vendor folder back the Cloud Functions of Functionbeat, so they can be used on GCP. This PR basically reverts the removal of the vendor builder functionality.

Why is it important?

The functions are currently broken, as there is no go.mod file and vendor folder. However, we cannot use go modules, because the Golang environment on GCP runs go version 1.13. Thus, we have to fall back to vendoring.

Checklist

  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
    - [ ] I have made corresponding changes to the documentation
    - [ ] I have made corresponding change to the default configuration files
    - [ ] I have added tests that prove my fix is effective or that my feature works
  • I have added an entry in CHANGELOG.next.asciidoc or CHANGELOG-developer.next.asciidoc.

Related issues

Closes #20830

kvch and others added 4 commits August 31, 2020 14:00
## What does this PR do?

This PR adds the vendor folder back the Cloud Functions of Functionbeat, so they can be used on GCP. This PR basically reverts the removal of the vendor builder functionality.

## Why is it important?

The functions are currently broken, as there is no go.mod file and vendor folder. However, we cannot use go modules, because the Golang environment on GCP runs go version 1.13. Thus, we have to fall back to vendoring.

## Checklist

- [x] My code follows the style guidelines of this project
- [x] I have commented my code, particularly in hard-to-understand areas
~~- [ ] I have made corresponding changes to the documentation~~
~~- [ ] I have made corresponding change to the default configuration files~~
~~- [ ] I have added tests that prove my fix is effective or that my feature works~~
- [x] I have added an entry in `CHANGELOG.next.asciidoc` or `CHANGELOG-developer.next.asciidoc`.

## Related issues

Closes elastic#20830

(cherry picked from commit 50ea11a)
@kvch kvch added [zube]: In Review backport Team:Services (Deprecated) Label for the former Integrations-Services team labels Sep 14, 2020
@botelastic botelastic bot added the needs_team Indicates that the issue/PR needs a Team:* label label Sep 14, 2020
@elasticmachine
Copy link
Collaborator

Pinging @elastic/integrations-services (Team:Services)

@botelastic botelastic bot removed the needs_team Indicates that the issue/PR needs a Team:* label label Sep 14, 2020
@kvch kvch merged commit 6148cbf into elastic:7.9 Sep 14, 2020
@elasticmachine
Copy link
Collaborator

💔 Tests Failed

Pipeline View Test View Changes Artifacts preview

Expand to view the summary

Build stats

  • Build Cause: [Pull request #21079 opened]

  • Start Time: 2020-09-14T15:33:53.661+0000

  • Duration: 73 min 48 sec

Test stats 🧪

Test Results
Failed 2
Passed 19282
Skipped 1836
Total 21120

Test errors

Expand to view the tests failures

  • Name: Build and Test / Libbeat / Libbeat oss / TestOutputReload – pipeline

    • Age: 1
    • Duration: 67.05
    • Error Details: Failed
  • Name: Build and Test / Libbeat / Libbeat oss / TestOutputReload/network_client – pipeline

    • Age: 1
    • Duration: 37.94
    • Error Details: Failed

Steps errors

Expand to view the steps failures

  • Name: Mage build test

    • Description: mage build test

    • Duration: 21 min 21 sec

    • Start Time: 2020-09-14T15:57:20.948+0000

    • log

  • Name: Make test

    • Description: make -C generator/_templates/beat test

    • Duration: 3 min 3 sec

    • Start Time: 2020-09-14T16:13:44.931+0000

    • log

  • Name: Make test

    • Description: make -C generator/_templates/beat test

    • Duration: 5 min 24 sec

    • Start Time: 2020-09-14T16:22:59.678+0000

    • log

  • Name: Recursively delete the current directory from the workspace

    • Description: script returned exit code 2

    • Duration: 0 min 21 sec

    • Start Time: 2020-09-14T16:30:12.465+0000

    • log

Log output

Expand to view the last 100 lines of log output

[2020-09-14T16:45:58.110Z] + tar -xpf source.tgz
[2020-09-14T16:46:08.457Z] + rm source.tgz
[2020-09-14T16:46:08.489Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats
[2020-09-14T16:46:08.539Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Lint
[2020-09-14T16:46:08.702Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Winlogbeat-oss
[2020-09-14T16:46:08.888Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Elastic-Agent-x-pack
[2020-09-14T16:46:09.053Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Auditbeat-crosscompile
[2020-09-14T16:46:09.225Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/dockerlogbeat
[2020-09-14T16:46:09.409Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Generators-Metricbeat-Linux
[2020-09-14T16:46:09.583Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Journalbeat
[2020-09-14T16:46:09.747Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Functionbeat-x-pack
[2020-09-14T16:46:09.908Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Elastic-Agent-x-pack-Windows
[2020-09-14T16:46:10.072Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Packetbeat-Linux
[2020-09-14T16:46:10.243Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-OSS-Unit-tests
[2020-09-14T16:46:10.411Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Heartbeat-oss
[2020-09-14T16:46:10.586Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Auditbeat-oss-Windows
[2020-09-14T16:46:10.761Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Auditbeat-x-pack
[2020-09-14T16:46:10.938Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-crosscompile
[2020-09-14T16:46:11.113Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Heartbeat-Windows
[2020-09-14T16:46:11.292Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Auditbeat-oss-Linux
[2020-09-14T16:46:11.467Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Auditbeat-x-pack-Windows
[2020-09-14T16:46:11.643Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Winlogbeat-Windows-x-pack
[2020-09-14T16:46:11.820Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Packetbeat-Windows
[2020-09-14T16:46:11.997Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Libbeat-x-pack
[2020-09-14T16:46:12.178Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Filebeat-Windows
[2020-09-14T16:46:12.353Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Elastic-Agent-Mac-OS-X
[2020-09-14T16:46:12.528Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Winlogbeat-Windows
[2020-09-14T16:46:12.708Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Filebeat-x-pack-Windows
[2020-09-14T16:46:12.886Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Functionbeat-Windows
[2020-09-14T16:46:13.066Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Auditbeat-oss-Mac-OS-X
[2020-09-14T16:46:13.238Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Filebeat-x-pack-Mac-OS-X
[2020-09-14T16:46:13.409Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Auditbeat-x-pack-Mac-OS-X
[2020-09-14T16:46:13.714Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-x-pack-Windows
[2020-09-14T16:46:13.899Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-Windows
[2020-09-14T16:46:14.078Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Generators-Beat-Linux
[2020-09-14T16:46:14.269Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Heartbeat-Mac-OS-X
[2020-09-14T16:46:14.444Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Filebeat-Mac-OS-X
[2020-09-14T16:46:14.621Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Libbeat-oss
[2020-09-14T16:46:14.802Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Generators-Metricbeat-Mac-OS-X
[2020-09-14T16:46:14.986Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Packetbeat-Mac-OS-X
[2020-09-14T16:46:15.176Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-Mac-OS-X
[2020-09-14T16:46:15.364Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-x-pack-Mac-OS-X
[2020-09-14T16:46:15.544Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Functionbeat-Mac-OS-X-x-pack
[2020-09-14T16:46:15.723Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Filebeat-x-pack
[2020-09-14T16:46:15.906Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Filebeat-oss
[2020-09-14T16:46:16.083Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Generators-Beat-Mac-OS-X
[2020-09-14T16:46:16.259Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-OSS-Integration-tests
[2020-09-14T16:46:16.425Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-Python-integration-tests
[2020-09-14T16:46:16.598Z] Running in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-x-pack
[2020-09-14T16:46:17.129Z] + cat
[2020-09-14T16:46:17.129Z] + /usr/local/bin/runbld ./runbld-script --job-name elastic+beats+pull-request
[2020-09-14T16:46:17.129Z] Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF8
[2020-09-14T16:46:23.720Z] runbld>>> runbld started
[2020-09-14T16:46:23.720Z] runbld>>> 1.6.12/f45d832f2ba0aa2722ab4ec1fda8ad140f027f8b
[2020-09-14T16:46:24.658Z] runbld>>> The following profiles matched the job 'elastic+beats+pull-request' in order of occurrence in the config (last value wins).
[2020-09-14T16:46:24.658Z] runbld>>> Matches in the system config:
[2020-09-14T16:46:24.658Z] runbld>>> - Matched ^elastic\+beats
[2020-09-14T16:46:24.658Z] runbld>>> - Matched ^elastic\+beats\+pull-request
[2020-09-14T16:46:26.040Z] runbld>>> Debug logging enabled.
[2020-09-14T16:46:26.040Z] runbld>>> Storing result
[2020-09-14T16:46:26.040Z] runbld>>> Store result: created {:total 2, :successful 2, :failed 0} 1
[2020-09-14T16:46:26.040Z] runbld>>> BUILD: https://c150076387b5421f9154dfbf536e5c60.us-west1.gcp.cloud.es.io:9243/build-1597739501209/t/20200914164625-5ED74CAA
[2020-09-14T16:46:26.040Z] runbld>>> Adding system facts.
[2020-09-14T16:46:26.981Z] runbld>>> Adding vcs info for the latest commit:  b4d55e6ea770cc7f24ad45213f38348838c60000
[2020-09-14T16:46:26.981Z] runbld>>> >>>>>>>>>>>> SCRIPT EXECUTION BEGIN >>>>>>>>>>>>
[2020-09-14T16:46:26.981Z] runbld>>> Adding /usr/lib/jvm/java-8-openjdk-amd64/bin to the path.
[2020-09-14T16:46:27.240Z] Processing JUnit reports with runbld...
[2020-09-14T16:46:27.240Z] + echo 'Processing JUnit reports with runbld...'
[2020-09-14T16:46:27.498Z] runbld>>> <<<<<<<<<<<< SCRIPT EXECUTION END <<<<<<<<<<<<
[2020-09-14T16:46:27.498Z] runbld>>> DURATION: 17ms
[2020-09-14T16:46:27.498Z] runbld>>> STDOUT: 40 bytes
[2020-09-14T16:46:27.498Z] runbld>>> STDERR: 49 bytes
[2020-09-14T16:46:27.498Z] runbld>>> WRAPPED PROCESS: SUCCESS (0)
[2020-09-14T16:46:27.498Z] runbld>>> Searching for build metadata in /var/lib/jenkins/workspace/Beats_beats_PR-21079
[2020-09-14T16:46:28.878Z] runbld>>> Storing build metadata: 
[2020-09-14T16:46:28.878Z] runbld>>> Adding test report.
[2020-09-14T16:46:28.878Z] runbld>>> Searching for junit test output files with the pattern: TEST-.*\.xml$ in: /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats
[2020-09-14T16:46:29.447Z] runbld>>> Found 139 test output files
[2020-09-14T16:46:30.831Z] runbld>>> No testsuite node found in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-OSS-Integration-tests/metricbeat/build/TEST-go-integration-graphite.xml
[2020-09-14T16:46:30.831Z] runbld>>> No testsuite node found in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-OSS-Integration-tests/metricbeat/build/TEST-go-integration-windows.xml
[2020-09-14T16:46:31.090Z] runbld>>> No testsuite node found in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-x-pack/x-pack/metricbeat/build/TEST-go-integration-activemq.xml
[2020-09-14T16:46:31.091Z] runbld>>> No testsuite node found in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-x-pack/x-pack/metricbeat/build/TEST-go-integration-iis.xml
[2020-09-14T16:46:31.091Z] runbld>>> No testsuite node found in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-x-pack/x-pack/metricbeat/build/TEST-go-integration-istio.xml
[2020-09-14T16:46:31.091Z] runbld>>> No testsuite node found in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-x-pack/x-pack/metricbeat/build/TEST-go-integration-openmetrics.xml
[2020-09-14T16:46:31.091Z] runbld>>> No testsuite node found in /var/lib/jenkins/workspace/Beats_beats_PR-21079/src/github.com/elastic/beats/Metricbeat-x-pack/x-pack/metricbeat/build/TEST-go-integration-tomcat.xml
[2020-09-14T16:46:32.999Z] runbld>>> Test output logs contained: Errors: 0 Failures: 2 Tests: 20969 Skipped: 1555
[2020-09-14T16:46:33.260Z] runbld>>> Storing result
[2020-09-14T16:46:33.260Z] runbld>>> FAILURES: 2
[2020-09-14T16:46:33.829Z] runbld>>> Store result: updated {:total 2, :successful 2, :failed 0} 2
[2020-09-14T16:46:33.829Z] runbld>>> BUILD: https://c150076387b5421f9154dfbf536e5c60.us-west1.gcp.cloud.es.io:9243/build-1597739501209/t/20200914164625-5ED74CAA
[2020-09-14T16:46:33.829Z] runbld>>> Email notification disabled by environment variable.
[2020-09-14T16:46:33.829Z] runbld>>> Slack notification disabled by environment variable.
[2020-09-14T16:46:40.276Z] Running on worker-1244230 in /var/lib/jenkins/workspace/Beats_beats_PR-21079
[2020-09-14T16:46:40.417Z] [INFO] getVaultSecret: Getting secrets
[2020-09-14T16:46:40.507Z] Masking supported pattern matches of $VAULT_ADDR or $VAULT_ROLE_ID or $VAULT_SECRET_ID
[2020-09-14T16:46:42.865Z] + chmod 755 generate-build-data.sh
[2020-09-14T16:46:42.865Z] + ./generate-build-data.sh https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Beats/beats/PR-21079/ https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Beats/beats/PR-21079/runs/1 FAILURE 4367768
[2020-09-14T16:46:42.865Z] INFO: curl https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Beats/beats/PR-21079/runs/1/steps/?limit=10000 -o steps-info.json
[2020-09-14T16:46:47.079Z] INFO: curl https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Beats/beats/PR-21079/runs/1/tests/?status=FAILED -o tests-errors.json
[2020-09-14T16:46:47.790Z] INFO: curl https://beats-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/Beats/beats/PR-21079/runs/1/log/ -o pipeline-log.txt

@zube zube bot removed the [zube]: Done label Dec 14, 2020
leweafan pushed a commit to leweafan/beats that referenced this pull request Apr 28, 2023
…ions again (elastic#21079)

* Add Known issues section with an issue about Functionbeat

* Add vendoring to Google Cloud Functions again (elastic#21070)

## What does this PR do?

This PR adds the vendor folder back the Cloud Functions of Functionbeat, so they can be used on GCP. This PR basically reverts the removal of the vendor builder functionality.

## Why is it important?

The functions are currently broken, as there is no go.mod file and vendor folder. However, we cannot use go modules, because the Golang environment on GCP runs go version 1.13. Thus, we have to fall back to vendoring.

## Checklist

- [x] My code follows the style guidelines of this project
- [x] I have commented my code, particularly in hard-to-understand areas
~~- [ ] I have made corresponding changes to the documentation~~
~~- [ ] I have made corresponding change to the default configuration files~~
~~- [ ] I have added tests that prove my fix is effective or that my feature works~~
- [x] I have added an entry in `CHANGELOG.next.asciidoc` or `CHANGELOG-developer.next.asciidoc`.

## Related issues

Closes elastic#20830

(cherry picked from commit 7c6df99)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport Team:Services (Deprecated) Label for the former Integrations-Services team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants