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

[serverless] Create EventBridge Instrumentation and Inject Trace Context #6096

Merged
merged 24 commits into from
Oct 15, 2024
Merged
Show file tree
Hide file tree
Changes from 11 commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
08b134f
Create skeleton for EventBridge instrumentation
nhulston Sep 26, 2024
5469c4f
Inject trace context into EventBridge
nhulston Sep 26, 2024
d05eb4c
Add unit tests
nhulston Sep 26, 2024
5ccd8b7
Add integration tests
nhulston Sep 27, 2024
134d1dd
Autogenerated files
nhulston Sep 27, 2024
9480a8c
Merge branch 'master' into nicholas.hulston/eventbridge-inject-trace-…
nhulston Sep 30, 2024
2311275
Update snapshot; code review changes.
nhulston Oct 1, 2024
e77b7c7
Update docker-compose for `events` on localstack
bouwkast Oct 1, 2024
e110595
Add NetFramework snapshots
bouwkast Oct 1, 2024
8ad4b1d
Code review changes
nhulston Oct 2, 2024
3f780ba
Merge remote-tracking branch 'origin/nicholas.hulston/eventbridge-inj…
nhulston Oct 2, 2024
a2d0cd7
Add log
nhulston Oct 3, 2024
286c1e7
Update `docker-compose` for `events` for localstack for arm64
nhulston Oct 3, 2024
c949f7e
Merge branch 'master' into nicholas.hulston/eventbridge-inject-trace-…
nhulston Oct 3, 2024
9900a0d
* Rename `eventbusname` tag to `rulename`
nhulston Oct 7, 2024
b84d6ff
Merge branch 'master' into nicholas.hulston/eventbridge-inject-trace-…
nhulston Oct 7, 2024
311a8c6
Add size limit check
nhulston Oct 8, 2024
60349dd
Merge branch 'master' into nicholas.hulston/eventbridge-inject-trace-…
nhulston Oct 8, 2024
1515526
Merge branch 'master' into nicholas.hulston/eventbridge-inject-trace-…
nhulston Oct 9, 2024
c04872a
Change log level; add comments
nhulston Oct 11, 2024
09bb7cb
Merge remote-tracking branch 'origin/nicholas.hulston/eventbridge-inj…
nhulston Oct 11, 2024
57cf577
Add nullability annotations to AwsEventBridgeTags.cs
nhulston Oct 11, 2024
9f09e40
Merge branch 'master' into nicholas.hulston/eventbridge-inject-trace-…
nhulston Oct 11, 2024
c01b3a5
Merge branch 'master' into nicholas.hulston/eventbridge-inject-trace-…
nhulston Oct 15, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .nuke/build.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -330,6 +330,7 @@
"CheckTestResultForProfilerWithSanitizer",
"Clean",
"CleanObjFiles",
"CleanTestLogs",
nhulston marked this conversation as resolved.
Show resolved Hide resolved
"CloseMilestone",
"CompareBenchmarksResults",
"CompareCodeCoverageReports",
Expand Down Expand Up @@ -552,6 +553,7 @@
"CheckTestResultForProfilerWithSanitizer",
"Clean",
"CleanObjFiles",
"CleanTestLogs",
"CloseMilestone",
"CompareBenchmarksResults",
"CompareCodeCoverageReports",
Expand Down
6 changes: 6 additions & 0 deletions Datadog.Trace.sln
Original file line number Diff line number Diff line change
Expand Up @@ -589,6 +589,8 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Generated", "Generated", "{
tracer\build\PackageVersionsLatestSpecific.g.props = tracer\build\PackageVersionsLatestSpecific.g.props
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Samples.AWS.EventBridge", "tracer\test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj", "{D6155F26-8245-4B66-8944-79C3DF9F9DA3}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -1409,6 +1411,10 @@ Global
{2CA0D70C-DFC1-458A-871B-328AB6E87E3A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{2CA0D70C-DFC1-458A-871B-328AB6E87E3A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{2CA0D70C-DFC1-458A-871B-328AB6E87E3A}.Release|Any CPU.Build.0 = Release|Any CPU
{D6155F26-8245-4B66-8944-79C3DF9F9DA3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D6155F26-8245-4B66-8944-79C3DF9F9DA3}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D6155F26-8245-4B66-8944-79C3DF9F9DA3}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D6155F26-8245-4B66-8944-79C3DF9F9DA3}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ services:
localstack:
image: localstack/localstack
environment:
- SERVICES=sns,sqs,kinesis,dynamodb
- SERVICES=sns,sqs,kinesis,dynamodb,events
- DEBUG=1
- DATA_DIR=/tmp/localstack/data
- DEFAULT_REGION=us-east-1
Expand Down
18 changes: 18 additions & 0 deletions tracer/build/PackageVersionsGeneratorDefinitions.json
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,24 @@
}
]
},
{
"IntegrationName": "AwsEventBridge",
"SampleProjectName": "Samples.AWS.EventBridge",
"NugetPackageSearchName": "AWSSDK.EventBridge",
"MinVersion": "3.3.100",
"MaxVersionExclusive": "4.0.0",
"SpecificVersions": [
"3.3.*",
"3.5.*",
"3.7.*"
],
"VersionConditions": [
{
"MaxVersionExclusive": "3.3.0",
"IncludeOnlyTargetFrameworks": ["net462"]
}
]
},
{
"IntegrationName": "MongoDB",
"SampleProjectName": "Samples.MongoDB",
Expand Down
42 changes: 42 additions & 0 deletions tracer/build/PackageVersionsLatestMajors.g.props
Original file line number Diff line number Diff line change
Expand Up @@ -222,6 +222,48 @@ NOTE: This code was generated by the GeneratePackageVersions tool. To safely
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.SimpleNotificationService</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.7.401.25;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>netcoreapp2.1</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.7.401.25;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>netcoreapp3.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.7.401.25;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>netcoreapp3.1</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.7.401.25;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net5.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.7.401.25;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net6.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.7.401.25;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net7.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.7.401.25;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net8.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.MongoDB\Samples.MongoDB.csproj">
<Properties>ApiVersion=2.29.0;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net462</TargetFramework>
Expand Down
126 changes: 126 additions & 0 deletions tracer/build/PackageVersionsLatestMinors.g.props
Original file line number Diff line number Diff line change
Expand Up @@ -756,6 +756,132 @@ NOTE: This code was generated by the GeneratePackageVersions tool. To safely
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.SimpleNotificationService</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.3.102.16;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>netcoreapp2.1</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.5.6.5;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>netcoreapp2.1</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.7.401.25;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>netcoreapp2.1</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.3.102.16;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>netcoreapp3.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.5.6.5;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>netcoreapp3.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.7.401.25;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>netcoreapp3.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.3.102.16;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>netcoreapp3.1</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.5.6.5;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>netcoreapp3.1</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.7.401.25;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>netcoreapp3.1</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.3.102.16;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net5.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.5.6.5;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net5.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.7.401.25;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net5.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.3.102.16;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net6.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.5.6.5;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net6.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.7.401.25;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net6.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.3.102.16;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net7.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.5.6.5;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net7.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.7.401.25;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net7.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.3.102.16;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net8.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.5.6.5;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net8.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.AWS.EventBridge\Samples.AWS.EventBridge.csproj">
<Properties>ApiVersion=3.7.401.25;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net8.0</TargetFramework>
<RequiresDockerDependency>All</RequiresDockerDependency>
<SampleName>Samples.AWS.EventBridge</SampleName>
</PackageVersionSample>
<PackageVersionSample Include="test\test-applications\integrations\Samples.MongoDB\Samples.MongoDB.csproj">
<Properties>ApiVersion=2.0.2;RestoreRecursive=false;BuildProjectReferences=false</Properties>
<TargetFramework>net462</TargetFramework>
Expand Down
Loading
Loading