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

module/apmgrpc: record underlying HTTP/2 context #904

Merged
merged 4 commits into from
Apr 19, 2021

Conversation

axw
Copy link
Member

@axw axw commented Feb 20, 2021

Record underlying HTTP/2 context:

  • URL using :authority for host, presence of TLS auth info for scheme, and full method name for path.
  • gRPC metadata as HTTP request headers
  • peer IP for remote address in transactions

Closes #900

@elastic-apm-tech elastic-apm-tech added this to In Progress in APM-Agents (OLD) Feb 20, 2021
@apmmachine
Copy link
Collaborator

apmmachine commented Feb 20, 2021

💔 Build 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: Branch indexing

  • Start Time: 2021-03-15T17:20:20.038+0000

  • Duration: 11 min 39 sec

  • Commit: caa6417

Test stats 🧪

Test Results
Failed 0
Passed 6630
Skipped 208
Total 6838

Trends 🧪

Image of Build Times

Image of Tests

Steps errors 7

Expand to view the steps failures

Build
  • Took 2 min 36 sec . View more details on here
  • Description: ./scripts/jenkins/build.sh
Build
  • Took 0 min 2 sec . View more details on here
  • Description: ./scripts/jenkins/build.sh
Build
  • Took 0 min 2 sec . View more details on here
  • Description: ./scripts/jenkins/build.sh
Build
  • Took 2 min 52 sec . View more details on here
  • Description: ./scripts/jenkins/build.sh
Build
  • Took 0 min 2 sec . View more details on here
  • Description: ./scripts/jenkins/build.sh
Build
  • Took 0 min 2 sec . View more details on here
  • Description: ./scripts/jenkins/build.sh
Error signal
  • Took 0 min 0 sec . View more details on here
  • Description: hudson.AbortException: script returned exit code 2

Log output

Expand to view the last 100 lines of log output

[2021-03-15T17:30:55.489Z] === RUN   TestFilesystemContextSetterFileNotFound
[2021-03-15T17:30:55.489Z] --- PASS: TestFilesystemContextSetterFileNotFound (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestLibraryPackage
[2021-03-15T17:30:55.489Z] --- PASS: TestLibraryPackage (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestStacktrace
[2021-03-15T17:30:55.489Z] --- PASS: TestStacktrace (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestSplitFunctionName
[2021-03-15T17:30:55.489Z] --- PASS: TestSplitFunctionName (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestSplitFunctionNameUnescape
[2021-03-15T17:30:55.489Z] --- PASS: TestSplitFunctionNameUnescape (0.00s)
[2021-03-15T17:30:55.489Z] PASS
[2021-03-15T17:30:55.489Z] ok  	go.elastic.co/apm/stacktrace	0.011s
[2021-03-15T17:30:55.489Z] === RUN   TestInitDefault
[2021-03-15T17:30:55.489Z] --- PASS: TestInitDefault (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestInitDefaultDiscard
[2021-03-15T17:30:55.489Z] --- PASS: TestInitDefaultDiscard (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestInitDefaultError
[2021-03-15T17:30:55.489Z] --- PASS: TestInitDefaultError (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestNewHTTPTransportDefaultURL
[2021-03-15T17:30:55.489Z] --- PASS: TestNewHTTPTransportDefaultURL (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportUserAgent
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportUserAgent (0.01s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportSecretToken
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportSecretToken (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportEnvSecretToken
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportEnvSecretToken (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportAPIKey
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportAPIKey (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportEnvAPIKey
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportEnvAPIKey (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportNoAuthorization
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportNoAuthorization (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportTLS
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportTLS (0.04s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportEnvVerifyServerCert
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportEnvVerifyServerCert (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPError
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPError (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportContent
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportContent (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportServerTimeout
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportServerTimeout (0.05s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportServerFailover
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportServerFailover (0.01s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportV2NotFound
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportV2NotFound (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportServerCert
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportServerCert (0.01s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportServerCertInvalid
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportServerCertInvalid (0.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportWatchConfig
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportWatchConfig (1.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportWatchConfigQueryParams
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportWatchConfigQueryParams/name_only
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportWatchConfigQueryParams/name_and_env
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportWatchConfigQueryParams/name_empty
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportWatchConfigQueryParams/both_empty
[2021-03-15T17:30:55.489Z] --- PASS: TestHTTPTransportWatchConfigQueryParams (4.01s)
[2021-03-15T17:30:55.489Z]     --- PASS: TestHTTPTransportWatchConfigQueryParams/name_only (1.00s)
[2021-03-15T17:30:55.489Z]     --- PASS: TestHTTPTransportWatchConfigQueryParams/name_and_env (1.00s)
[2021-03-15T17:30:55.489Z]     --- PASS: TestHTTPTransportWatchConfigQueryParams/name_empty (1.00s)
[2021-03-15T17:30:55.489Z]     --- PASS: TestHTTPTransportWatchConfigQueryParams/both_empty (1.00s)
[2021-03-15T17:30:55.489Z] === RUN   TestHTTPTransportWatchConfigContextCancelled
[2021-03-15T17:30:55.490Z] --- PASS: TestHTTPTransportWatchConfigContextCancelled (0.00s)
[2021-03-15T17:30:55.490Z] === RUN   TestNewHTTPTransportTrailingSlash
[2021-03-15T17:30:55.490Z] --- PASS: TestNewHTTPTransportTrailingSlash (0.00s)
[2021-03-15T17:30:55.490Z] === RUN   TestHTTPTransportSendProfile
[2021-03-15T17:30:55.490Z] --- PASS: TestHTTPTransportSendProfile (0.00s)
[2021-03-15T17:30:55.490Z] PASS
[2021-03-15T17:30:55.490Z] ok  	go.elastic.co/apm/transport	5.170s
[2021-03-15T17:30:55.490Z] ?   	go.elastic.co/apm/transport/transporttest	[no test files]
[2021-03-15T17:30:55.490Z] + status=0
[2021-03-15T17:30:55.490Z] + go get -v -u github.com/jstemmer/go-junit-report
[2021-03-15T17:30:55.490Z] go: downloading github.com/jstemmer/go-junit-report v0.9.1
[2021-03-15T17:30:55.490Z] github.com/jstemmer/go-junit-report/parser
[2021-03-15T17:30:55.490Z] github.com/jstemmer/go-junit-report/formatter
[2021-03-15T17:30:55.490Z] github.com/jstemmer/go-junit-report
[2021-03-15T17:30:55.490Z] go get: added github.com/jstemmer/go-junit-report v0.9.1
[2021-03-15T17:30:55.490Z] + go-junit-report
[2021-03-15T17:30:55.490Z] + exit 0
[2021-03-15T17:30:55.548Z] Recording test results
[2021-03-15T17:30:56.219Z] [Checks API] No suitable checks publisher found.
[2021-03-15T17:30:57.289Z] Stage "Coverage" skipped due to earlier failure(s)
[2021-03-15T17:30:57.324Z] Stage "Benchmark" skipped due to earlier failure(s)
[2021-03-15T17:30:57.395Z] Stage "More OS" skipped due to earlier failure(s)
[2021-03-15T17:30:57.430Z] Stage "Windows" skipped due to earlier failure(s)
[2021-03-15T17:30:57.432Z] Stage "OSX" skipped due to earlier failure(s)
[2021-03-15T17:30:57.459Z] Failed in branch Windows
[2021-03-15T17:30:57.460Z] Failed in branch OSX
[2021-03-15T17:30:57.510Z] Stage "Integration Tests" skipped due to earlier failure(s)
[2021-03-15T17:30:57.543Z] Stage "Release" skipped due to earlier failure(s)
[2021-03-15T17:30:57.560Z] Stage "Release" skipped due to earlier failure(s)
[2021-03-15T17:30:57.595Z] Stage "Release" skipped due to earlier failure(s)
[2021-03-15T17:30:57.893Z] Running on Jenkins in /var/lib/jenkins/workspace/agent-go_apm-agent-go-mbp_PR-904
[2021-03-15T17:30:57.991Z] [INFO] getVaultSecret: Getting secrets
[2021-03-15T17:30:58.152Z] Masking supported pattern matches of $VAULT_ADDR or $VAULT_ROLE_ID or $VAULT_SECRET_ID
[2021-03-15T17:30:58.828Z] + chmod 755 generate-build-data.sh
[2021-03-15T17:30:58.828Z] + ./generate-build-data.sh https://apm-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/apm-agent-go/apm-agent-go-mbp/PR-904/ https://apm-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/apm-agent-go/apm-agent-go-mbp/PR-904/runs/4 FAILURE 638529
[2021-03-15T17:30:59.079Z] INFO: curl https://apm-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/apm-agent-go/apm-agent-go-mbp/PR-904/runs/4/steps/?limit=10000 -o steps-info.json
[2021-03-15T17:30:59.630Z] INFO: curl https://apm-ci.elastic.co/blue/rest/organizations/jenkins/pipelines/apm-agent-go/apm-agent-go-mbp/PR-904/runs/4/tests/?status=FAILED -o tests-errors.json

@apmmachine
Copy link
Collaborator

apmmachine commented Mar 17, 2021

💚 Build Succeeded

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 #904 updated

  • Start Time: 2021-04-19T07:21:47.732+0000

  • Duration: 26 min 35 sec

  • Commit: 5eab7f4

Test stats 🧪

Test Results
Failed 0
Passed 10184
Skipped 266
Total 10450

Trends 🧪

Image of Build Times

Image of Tests

Record underlying HTTP/2 request metadata:
 - URL using :authority for host, presence of TLS
   auth info for scheme, and full method name for path.
 - gRPC metadata as HTTP request headers
 - peer IP for remote address in transactions
@axw axw marked this pull request as ready for review April 14, 2021 06:37
@axw axw requested a review from a team April 14, 2021 06:37
Copy link
Contributor

@stuartnelson3 stuartnelson3 left a comment

Choose a reason for hiding this comment

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

looks good!

@axw axw merged commit 0b9c641 into elastic:master Apr 19, 2021
APM-Agents (OLD) automation moved this from In Progress to Done Apr 19, 2021
@axw axw deleted the apmgrpc-http-context branch April 19, 2021 08:20
stuartnelson3 pushed a commit that referenced this pull request Jul 30, 2021
* module/apmgrpc: record underlying HTTP/2 context

Record underlying HTTP/2 request metadata:
 - URL using :authority for host, presence of TLS
   auth info for scheme, and full method name for path.
 - gRPC metadata as HTTP request headers
 - peer IP for remote address in transactions

* Update changelog
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Development

Successfully merging this pull request may close these issues.

Add Support for storing HTTP Headers (Req & Resp) for gRPC calls
3 participants