Skip to content

Commit

Permalink
Add OpCode for activity started and stop in OpenTelemetry-Sdk eventso…
Browse files Browse the repository at this point in the history
…urce
  • Loading branch information
xiaomi7732 committed Jan 3, 2025
1 parent 6100452 commit 259b53b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/OpenTelemetry/Internal/OpenTelemetrySdkEventSource.cs
Original file line number Diff line number Diff line change
Expand Up @@ -185,13 +185,13 @@ public void ObservableInstrumentCallbackException(string exception)
this.WriteEvent(16, exception);
}

[Event(24, Message = "Activity started. Name = '{0}', Id = '{1}'.", Level = EventLevel.Verbose)]
[Event(24, Message = "Activity started. Name = '{0}', Id = '{1}'.", Level = EventLevel.Verbose, Opcode = EventOpcode.Start)]
public void ActivityStarted(string name, string id)
{
this.WriteEvent(24, name, id);
}

[Event(25, Message = "Activity stopped. Name = '{0}', Id = '{1}'.", Level = EventLevel.Verbose)]
[Event(25, Message = "Activity stopped. Name = '{0}', Id = '{1}'.", Level = EventLevel.Verbose, Opcode = EventOpcode.Stop)]
public void ActivityStopped(string name, string? id)
{
this.WriteEvent(25, name, id);
Expand Down

0 comments on commit 259b53b

Please sign in to comment.