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

Add profiler auto instrumentation #1534

Merged
merged 42 commits into from
Nov 4, 2021

Conversation

russcam
Copy link
Contributor

@russcam russcam commented Oct 25, 2021

This commit adds profiler auto instrumentation to the
Elastic APM .NET agent solution.

Profiler auto instrumentation uses the CLR profiling APIs
to instrument methods of interest at runtime, by signalling
to the runtime to load an unmanaged profiler into the process
using profiling environment variables.

The approach comprises:

  1. A CLR profiler written in Rust
  2. Supporting managed assemblies containing methods
    that will be inserted into rewritten IL and called, to start
    and end transactions and spans.

Initial integrations are available for common ADO.NET providers
and Kafka, with more to follow in the future.

The profiler auto instrumentation approach is currently
an alpha release, as indicated by the version number
in src/elastic_apm_profiler/Cargo.toml.

Closes #1522

This commit adds profiler auto instrumentation to the
Elastic APM .NET agent solution.

Profiler auto instrumentation uses the CLR profiling APIs
to instrument methods of interest at runtime, by signalling
to the runtime to load an unmanaged profiler into the process
using profiling environment variables.

The approach comprises:

1. A CLR profiler written in Rust
2. Supporting managed assemblies containing methods
that will be inserted into rewritten IL and called, to start
and end transactions and spans.

Initial integrations are available for common ADO.NET providers
and Kafka, with more to follow in the future.

The profiler auto instrumentation approach is currently
an alpha release, as indicated by the version number
in src/elastic_apm_profiler/Cargo.toml.

Closes elastic#1522
@russcam russcam added enhancement New feature or request 8.0-candidate labels Oct 25, 2021
@russcam russcam added this to the 8.0 milestone Oct 25, 2021
@apmmachine
Copy link
Contributor

apmmachine commented Oct 25, 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 preview

Expand to view the summary

Build stats

  • Start Time: 2021-11-03T06:52:25.251+0000

  • Duration: 85 min 19 sec

  • Commit: 477899c

Test stats 🧪

Test Results
Failed 0
Passed 8358
Skipped 7
Total 8365

Steps errors 4

Expand to view the steps failures

Restore files previously stashed
  • Took 8 min 7 sec . View more details here
  • Description: source
Delete workspace when build is done
  • Took 0 min 0 sec . View more details here
  • Description: [2021-11-03T07:08:59.297Z] apm-ci-immutable-windows-2019-1635922555886673206 was marked offline: Con
Restore files previously stashed
  • Took 8 min 56 sec . View more details here
  • Description: source
Delete workspace when build is done
  • Took 0 min 0 sec . View more details here
  • Description: [2021-11-03T07:09:33.541Z] apm-ci-immutable-windows-2019-1635922555807640431 was marked offline: Con

🤖 GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

  • run benchmark tests : Run the benchmark test.

@russcam
Copy link
Contributor Author

russcam commented Nov 2, 2021

/test

@russcam
Copy link
Contributor Author

russcam commented Nov 3, 2021

/test

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.

Profiler auto instrumentation
4 participants