-
Notifications
You must be signed in to change notification settings - Fork 117
[RabbitMQ] bytecode instrumentation for versions 6.*.* - initial #3533
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
Merged
zacharycmontoya
merged 15 commits into
open-telemetry:main
from
lachmatt:rabbitmq6-bytecode-instrumentation
Aug 6, 2024
Merged
Changes from 8 commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
3c15497
rabbitmq6 bytecode instrumentation
lachmatt 511ec9e
format fixes
lachmatt 1509574
casing fix
lachmatt 0b1d97f
PR feedback
lachmatt 25dba6c
Merge branch 'main' into rabbitmq6-bytecode-instrumentation
lachmatt eb5610c
Merge branch 'main' into rabbitmq6-bytecode-instrumentation
lachmatt 0568a33
Merge branch 'main' into rabbitmq6-bytecode-instrumentation
Kielek 1101b83
Merge branch 'main' into rabbitmq6-bytecode-instrumentation
Kielek 8da1a77
Merge branch 'main' into rabbitmq6-bytecode-instrumentation
lachmatt 93bf093
fix changelog after merge
lachmatt 12e2ce8
revert redundant changelog change
lachmatt dae32c2
pr feedback
lachmatt bd900d1
fix after rename
lachmatt 972fd82
Merge branch 'main' into rabbitmq6-bytecode-instrumentation
Kielek 90e7196
Merge branch 'main' into rabbitmq6-bytecode-instrumentation
lachmatt File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -50,6 +50,7 @@ PROCESSRUNTIME | |
proto | ||
protobuf | ||
protos | ||
RABBITMQ | ||
Serilog | ||
spdlog | ||
SQLCLIENT | ||
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
OpenTelemetry.AutoInstrumentation.Instrumentations.RabbitMq6.Integrations.AsyncEventingBasicConsumerIntegration | ||
OpenTelemetry.AutoInstrumentation.Instrumentations.RabbitMq6.Integrations.EventingBasicConsumerIntegration | ||
OpenTelemetry.AutoInstrumentation.Instrumentations.RabbitMq6.Integrations.ModelBaseBasicGetIntegration | ||
OpenTelemetry.AutoInstrumentation.Instrumentations.RabbitMq6.Integrations.ModelBasicPublishIntegration |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
OpenTelemetry.AutoInstrumentation.Instrumentations.RabbitMq6.Integrations.AsyncEventingBasicConsumerIntegration | ||
OpenTelemetry.AutoInstrumentation.Instrumentations.RabbitMq6.Integrations.EventingBasicConsumerIntegration | ||
OpenTelemetry.AutoInstrumentation.Instrumentations.RabbitMq6.Integrations.ModelBaseBasicGetIntegration | ||
OpenTelemetry.AutoInstrumentation.Instrumentations.RabbitMq6.Integrations.ModelBasicPublishIntegration |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 30 additions & 0 deletions
30
...OpenTelemetry.AutoInstrumentation/Instrumentations/RabbitMq6/DuckTypes/IBasicGetResult.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
// Copyright The OpenTelemetry Authors | ||
// SPDX-License-Identifier: Apache-2.0 | ||
|
||
using OpenTelemetry.AutoInstrumentation.DuckTyping; | ||
|
||
namespace OpenTelemetry.AutoInstrumentation.Instrumentations.RabbitMq6.DuckTypes; | ||
|
||
// wraps https://github.com/rabbitmq/rabbitmq-dotnet-client/blob/a50334f2acb09fd16dc9cbd20ad1c6dd093d1d64/projects/RabbitMQ.Client/client/api/BasicGetResult.cs | ||
internal interface IBasicGetResult : IDuckType | ||
{ | ||
public string? Exchange { get; set; } | ||
|
||
public string? RoutingKey { get; set; } | ||
|
||
public IBasicProperties? BasicProperties { get; set; } | ||
|
||
public ulong DeliveryTag { get; set; } | ||
|
||
public IBody Body { get; set; } | ||
} | ||
|
||
// wraps https://github.com/rabbitmq/rabbitmq-dotnet-client/blob/a50334f2acb09fd16dc9cbd20ad1c6dd093d1d64/projects/RabbitMQ.Client/client/api/IBasicProperties.cs | ||
internal interface IBasicProperties : IDuckType | ||
{ | ||
IDictionary<string, object>? Headers { get; set; } | ||
|
||
string? CorrelationId { get; set; } | ||
|
||
string? MessageId { get; set; } | ||
} |
11 changes: 11 additions & 0 deletions
11
src/OpenTelemetry.AutoInstrumentation/Instrumentations/RabbitMq6/DuckTypes/IBody.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
// Copyright The OpenTelemetry Authors | ||
// SPDX-License-Identifier: Apache-2.0 | ||
|
||
using OpenTelemetry.AutoInstrumentation.DuckTyping; | ||
|
||
namespace OpenTelemetry.AutoInstrumentation.Instrumentations.RabbitMq6.DuckTypes; | ||
|
||
internal interface IBody : IDuckType | ||
{ | ||
public int Length { get; } | ||
} |
21 changes: 21 additions & 0 deletions
21
src/OpenTelemetry.AutoInstrumentation/Instrumentations/RabbitMq6/IntegrationConstants.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
// Copyright The OpenTelemetry Authors | ||
// SPDX-License-Identifier: Apache-2.0 | ||
|
||
namespace OpenTelemetry.AutoInstrumentation.Instrumentations.RabbitMq6; | ||
|
||
internal static class IntegrationConstants | ||
{ | ||
public const string RabbitMqByteCodeIntegrationName = "RabbitMq6"; | ||
public const string RabbitMqAssemblyName = "RabbitMQ.Client"; | ||
public const string ModelBaseTypeName = "RabbitMQ.Client.Impl.ModelBase"; | ||
public const string EventingBasicConsumerTypeName = "RabbitMQ.Client.Events.EventingBasicConsumer"; | ||
public const string AsyncEventingBasicConsumerTypeName = "RabbitMQ.Client.Events.AsyncEventingBasicConsumer"; | ||
public const string ModelGeneratedTypeName = "RabbitMQ.Client.Framing.Impl.Model"; | ||
public const string BasicGetResultTypeName = "RabbitMQ.Client.BasicGetResult"; | ||
public const string BasicPropertiesInterfaceTypeName = "RabbitMQ.Client.IBasicProperties"; | ||
public const string BasicGetMethodName = "BasicGet"; | ||
public const string HandleBasicDeliverMethodName = "HandleBasicDeliver"; | ||
public const string BasicPublishMethodName = "_Private_BasicPublish"; | ||
public const string MinSupportedVersion = "6.0.0"; | ||
public const string MaxSupportedVersion = "6.*.*"; | ||
} |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.