EasyCaching icon indicating copy to clipboard operation
EasyCaching copied to clipboard

Use easycaching with elastic apm agent dotnet

Open billhong-just opened this issue 2 years ago • 4 comments

Description

Hi, I want to use elastic/apm-agent-dotnet to trace the commands sent to Redis.
Here is a sample code from elastic official document:

// using Elastic.Apm.StackExchange.Redis;

var connection = await ConnectionMultiplexer.ConnectAsync("<redis connection>");
connection.UseElasticApm();

Do I have any chance to get the connection from easycaching or provide a delegate to easycaching?

References

  • https://www.elastic.co/guide/en/apm/agent/dotnet/1.x/setup-stackexchange-redis.html

billhong-just avatar Feb 24 '23 08:02 billhong-just

@billhong-just Thanks for your interest in this project.

EasyCaching does not support this one now, I will take a look how to support more APM system.

catcherwong avatar Feb 26 '23 11:02 catcherwong

@catcherwong Thanks for your quick answer.

Perhaps there could be an event called OnConnected,user can register this event, get the connection and something else when it is established then do what they want.

billhong-just avatar Feb 27 '23 03:02 billhong-just

@billhong-just Could you submit a PR for your idea?

catcherwong avatar Mar 06 '23 00:03 catcherwong

@catcherwong

Thanks, I will take a look how to make a PR for my idea. Do you have any contributing guidelines or suggestions? 👋

billhong-just avatar Mar 06 '23 01:03 billhong-just