Skip to content

Commit 695f1a0

Browse files
authored
!trace #80 adjust overloads on tracing instrument startSpan (#81)
1 parent 284912e commit 695f1a0

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

Sources/Instrumentation/Tracing/TracingInstrument.swift

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ public protocol TracingInstrument: Instrument {
2222
/// - operationName: The name of the operation being traced. This may be a handler function, database call, ...
2323
/// - context: The `BaggageContext` within to start the new `Span`.
2424
/// - kind: The `SpanKind` of the new `Span`.
25-
/// - timestamp: The `DispatchTime` at which to start the new `Span`.
25+
/// - timestamp: The `DispatchTime` at which to start the new `Span`. Passing `nil` leaves the timestamp capture to the underlying tracing instrument.
2626
func startSpan(
2727
named operationName: String,
2828
context: BaggageContext,
@@ -38,11 +38,10 @@ extension TracingInstrument {
3838
/// - operationName: The name of the operation being traced. This may be a handler function, database call, ...
3939
/// - context: The `BaggageContext` within to start the new `Span`.
4040
/// - kind: The `SpanKind` of the `Span` to be created. Defaults to `.internal`.
41-
/// - timestamp: The `DispatchTime` at which to start the new `Span`. Defaults to `nil`.
41+
/// - timestamp: The `DispatchTime` at which to start the new `Span`. Defaults to `nil`, meaning the timestamp capture is left up to the underlying tracing instrument.
4242
public func startSpan(
4343
named operationName: String,
4444
context: BaggageContext,
45-
ofKind kind: SpanKind = .internal,
4645
at timestamp: DispatchTime? = nil
4746
) -> Span {
4847
self.startSpan(named: operationName, context: context, ofKind: .internal, at: nil)

0 commit comments

Comments
 (0)