Documentation ¶
Index ¶
- Constants
- type InternalTracer
- func (t *InternalTracer) Extract(format interface{}, carrier interface{}) (opentracing.SpanContext, error)
- func (t *InternalTracer) Inject(sm opentracing.SpanContext, format interface{}, carrier interface{}) error
- func (t *InternalTracer) StartSpan(operationName string, opts ...opentracing.StartSpanOption) opentracing.Span
- type NoopSpan
- func (s *NoopSpan) BaggageItem(restrictedKey string) string
- func (s *NoopSpan) Context() opentracing.SpanContext
- func (s *NoopSpan) Finish()
- func (s *NoopSpan) FinishWithOptions(opts opentracing.FinishOptions)
- func (s *NoopSpan) Log(data opentracing.LogData)
- func (s *NoopSpan) LogEvent(event string)
- func (s *NoopSpan) LogEventWithPayload(event string, payload interface{})
- func (s *NoopSpan) LogFields(fields ...log.Field)
- func (s *NoopSpan) LogKV(alternatingKeyValues ...interface{})
- func (s *NoopSpan) SetBaggageItem(restrictedKey, value string) opentracing.Span
- func (s *NoopSpan) SetOperationName(operationName string) opentracing.Span
- func (s *NoopSpan) SetTag(key string, value interface{}) opentracing.Span
- func (s *NoopSpan) Tracer() opentracing.Tracer
- type NoopSpanContext
- type NoopTracer
- func (t *NoopTracer) Done() <-chan struct{}
- func (t *NoopTracer) FinishSpan(entityID flow.Identifier, spanName SpanName)
- func (t *NoopTracer) GetSpan(entityID flow.Identifier, spanName SpanName) (opentracing.Span, bool)
- func (t *NoopTracer) Ready() <-chan struct{}
- func (t *NoopTracer) RecordSpanFromParent(span opentracing.Span, operationName SpanName, duration time.Duration, ...)
- func (t *NoopTracer) StartSpan(entityID flow.Identifier, spanName SpanName, ...) opentracing.Span
- func (t *NoopTracer) StartSpanFromContext(ctx context.Context, operationName SpanName, ...) (opentracing.Span, context.Context)
- func (t *NoopTracer) StartSpanFromParent(span opentracing.Span, operationName SpanName, ...) opentracing.Span
- func (t *NoopTracer) WithSpanFromContext(ctx context.Context, operationName SpanName, f func(), ...)
- type OpenTracer
- func (t *OpenTracer) Done() <-chan struct{}
- func (t *OpenTracer) FinishSpan(entityID flow.Identifier, spanName SpanName)
- func (t *OpenTracer) GetSpan(entityID flow.Identifier, spanName SpanName) (opentracing.Span, bool)
- func (t *OpenTracer) Ready() <-chan struct{}
- func (t *OpenTracer) RecordSpanFromParent(span opentracing.Span, operationName SpanName, duration time.Duration, ...)
- func (t *OpenTracer) StartSpan(entityID flow.Identifier, spanName SpanName, ...) opentracing.Span
- func (t *OpenTracer) StartSpanFromContext(ctx context.Context, operationName SpanName, ...) (opentracing.Span, context.Context)
- func (t *OpenTracer) StartSpanFromParent(span opentracing.Span, operationName SpanName, ...) opentracing.Span
- func (t *OpenTracer) WithSpanFromContext(ctx context.Context, operationName SpanName, f func(), ...)
- type SpanName
Constants ¶
const ( EXEParseDurationTag = "runtime.parseTransactionDuration" EXECheckDurationTag = "runtime.checkTransactionDuration" EXEInterpretDurationTag = "runtime.interpretTransactionDuration" EXEValueEncodingDurationTag = "runtime.encodingValueDuration" EXEValueDecodingDurationTag = "runtime.decodingValueDuration" )
Tag names
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type InternalTracer ¶
type InternalTracer struct {
// contains filtered or unexported fields
}
func (*InternalTracer) Extract ¶
func (t *InternalTracer) Extract(format interface{}, carrier interface{}) (opentracing.SpanContext, error)
func (*InternalTracer) Inject ¶
func (t *InternalTracer) Inject(sm opentracing.SpanContext, format interface{}, carrier interface{}) error
func (*InternalTracer) StartSpan ¶
func (t *InternalTracer) StartSpan(operationName string, opts ...opentracing.StartSpanOption) opentracing.Span
type NoopSpan ¶
type NoopSpan struct {
// contains filtered or unexported fields
}
func (*NoopSpan) BaggageItem ¶
func (*NoopSpan) FinishWithOptions ¶
func (s *NoopSpan) FinishWithOptions(opts opentracing.FinishOptions)
func (*NoopSpan) LogEventWithPayload ¶
func (*NoopSpan) SetBaggageItem ¶
func (*NoopSpan) SetOperationName ¶
type NoopSpanContext ¶
type NoopSpanContext struct{}
func (*NoopSpanContext) ForeachBaggageItem ¶
func (c *NoopSpanContext) ForeachBaggageItem(handler func(k, v string) bool)
type NoopTracer ¶
type NoopTracer struct {
// contains filtered or unexported fields
}
NoopTracer is the implementation of the Tracer interface
func (*NoopTracer) Done ¶
func (t *NoopTracer) Done() <-chan struct{}
Done returns a channel that will close when shutdown is complete.
func (*NoopTracer) FinishSpan ¶
func (t *NoopTracer) FinishSpan(entityID flow.Identifier, spanName SpanName)
FinishSpan finishes a span started with the passed in flow identifier
func (*NoopTracer) GetSpan ¶
func (t *NoopTracer) GetSpan(entityID flow.Identifier, spanName SpanName) (opentracing.Span, bool)
GetSpan will get the span started with the passed in flow identifier
func (*NoopTracer) Ready ¶
func (t *NoopTracer) Ready() <-chan struct{}
Ready returns a channel that will close when the network stack is ready.
func (*NoopTracer) RecordSpanFromParent ¶ added in v0.14.5
func (t *NoopTracer) RecordSpanFromParent( span opentracing.Span, operationName SpanName, duration time.Duration, logs []opentracing.LogRecord, opts ...opentracing.StartSpanOption, )
func (*NoopTracer) StartSpan ¶
func (t *NoopTracer) StartSpan(entityID flow.Identifier, spanName SpanName, opts ...opentracing.StartSpanOption, ) opentracing.Span
StartSpan starts a span using the flow identifier as a key into the span map
func (*NoopTracer) StartSpanFromContext ¶
func (*NoopTracer) StartSpanFromParent ¶
func (t *NoopTracer) StartSpanFromParent( span opentracing.Span, operationName SpanName, opts ...opentracing.StartSpanOption, ) opentracing.Span
func (*NoopTracer) WithSpanFromContext ¶ added in v0.15.0
func (t *NoopTracer) WithSpanFromContext(ctx context.Context, operationName SpanName, f func(), opts ...opentracing.StartSpanOption)
type OpenTracer ¶
type OpenTracer struct { opentracing.Tracer // contains filtered or unexported fields }
OpenTracer is the implementation of the Tracer interface
func NewTracer ¶
func NewTracer(log zerolog.Logger, serviceName string) (*OpenTracer, error)
NewTracer creates a new tracer.
func (*OpenTracer) Done ¶
func (t *OpenTracer) Done() <-chan struct{}
Done returns a channel that will close when shutdown is complete.
func (*OpenTracer) FinishSpan ¶
func (t *OpenTracer) FinishSpan(entityID flow.Identifier, spanName SpanName)
FinishSpan finishes a span started with the passed in flow identifier
func (*OpenTracer) GetSpan ¶
func (t *OpenTracer) GetSpan(entityID flow.Identifier, spanName SpanName) (opentracing.Span, bool)
GetSpan will get the span started with the passed in flow identifier
func (*OpenTracer) Ready ¶
func (t *OpenTracer) Ready() <-chan struct{}
Ready returns a channel that will close when the network stack is ready.
func (*OpenTracer) RecordSpanFromParent ¶ added in v0.14.5
func (t *OpenTracer) RecordSpanFromParent( span opentracing.Span, operationName SpanName, duration time.Duration, logs []opentracing.LogRecord, opts ...opentracing.StartSpanOption, )
func (*OpenTracer) StartSpan ¶
func (t *OpenTracer) StartSpan(entityID flow.Identifier, spanName SpanName, opts ...opentracing.StartSpanOption) opentracing.Span
StartSpan starts a span using the flow identifier as a key into the span map
func (*OpenTracer) StartSpanFromContext ¶
func (*OpenTracer) StartSpanFromParent ¶
func (t *OpenTracer) StartSpanFromParent( span opentracing.Span, operationName SpanName, opts ...opentracing.StartSpanOption, ) opentracing.Span
func (*OpenTracer) WithSpanFromContext ¶ added in v0.15.0
func (t *OpenTracer) WithSpanFromContext(ctx context.Context, operationName SpanName, f func(), opts ...opentracing.StartSpanOption)
WithSpanFromContext encapsulates executing a function within an span, i.e., it starts a span with the specified SpanName from the context, executes the function f, and finishes the span once the function returns.
type SpanName ¶
type SpanName string
const ( // State // mutator.Extend - full payload check ProtoStateMutatorExtend SpanName = "common.state.proto.mutator.extend" ProtoStateMutatorExtendCheckHeader SpanName = "common.state.proto.mutator.extend.checkHeader" ProtoStateMutatorExtendCheckGuarantees SpanName = "common.state.proto.mutator.extend.checkGuarantees" ProtoStateMutatorExtendCheckSeals SpanName = "common.state.proto.mutator.extend.checkSeals" ProtoStateMutatorExtendCheckReceipts SpanName = "common.state.proto.mutator.extend.checkReceipts" ProtoStateMutatorExtendDBInsert SpanName = "common.state.proto.mutator.extend.dbInsert" // mutator.HeaderExtend - header-only check ProtoStateMutatorHeaderExtend SpanName = "common.state.proto.mutator.headerExtend" ProtoStateMutatorHeaderExtendGetLastSealed SpanName = "common.state.proto.mutator.headerExtend.lastSealed" // mutator.Finalize ProtoStateMutatorFinalize SpanName = "common.state.proto.mutator.finalize" CONProcessCollection SpanName = "con.processCollection" CONProcessBlock SpanName = "con.processBlock" // Hotstuff CONHotFinalizeCollection SpanName = "con.hotstuff.finalizeCollection" CONHotFinalizeBlock SpanName = "con.hotstuff.finalizeBlock" // Ingestion CONIngOnCollectionGuarantee SpanName = "con.ingestion.onCollectionGuarantee" // Propagation CONPropOnGuarantee SpanName = "con.propagation.onGuarantee" // Provider CONProvOnBlockProposal SpanName = "con.provider.onBlockProposal" // Compliance CONCompBroadcastProposalWithDelay SpanName = "con.compliance.BroadcastProposalWithDelay" CONCompOnBlockProposal SpanName = "con.compliance.onBlockProposal" CONCompOnBlockProposalProcessRecursive SpanName = "con.compliance.onBlockProposal.processBlockProposal.recursive" CONCompOnBlockProposalProcessSingle SpanName = "con.compliance.onBlockProposal.processBlockProposal.single" // Matching CONMatchCheckSealing SpanName = "con.matching.checkSealing" CONMatchCheckSealingSealableResults SpanName = "con.matching.checkSealing.sealableResults" CONMatchCheckSealingClearPools SpanName = "con.matching.checkSealing.clearPools" CONMatchCheckSealingRequestPendingReceipts SpanName = "con.matching.checkSealing.requestPendingReceipts" CONMatchCheckSealingRequestPendingApprovals SpanName = "con.matching.checkSealing.requestPendingApprovals" CONMatchOnReceipt SpanName = "con.matching.onReceipt" CONMatchOnReceiptVal SpanName = "con.matching.onReceipt.validation" CONMatchOnApproval SpanName = "con.matching.onApproval" // Builder CONBuildOn SpanName = "con.builder" CONBuildOnCreatePayloadGuarantees SpanName = "con.builder.createPayload.guarantees" CONBuildOnCreatePayloadSeals SpanName = "con.builder.createPayload.seals" CONBuildOnCreatePayloadReceipts SpanName = "con.builder.createPayload.receipts" CONBuildOnCreateHeader SpanName = "con.builder.createHeader" CONBuildOnDBInsert SpanName = "con.builder.dbInsert" // Builder COLBuildOn SpanName = "col.builder" COLBuildOnSetup SpanName = "col.builder.setup" COLBuildOnUnfinalizedLookup SpanName = "col.builder.unfinalizedLookup" COLBuildOnFinalizedLookup SpanName = "col.builder.finalizedLookup" COLBuildOnCreatePayload SpanName = "col.builder.createPayload" COLBuildOnCreateHeader SpanName = "col.builder.createHeader" COLBuildOnDBInsert SpanName = "col.builder.dbInsert" // Cluster State COLClusterStateMutatorExtend SpanName = "col.state.mutator.extend" COLClusterStateMutatorExtendSetup SpanName = "col.state.mutator.extend.setup" COLClusterStateMutatorExtendCheckAncestry SpanName = "col.state.mutator.extend.ancestry" COLClusterStateMutatorExtendCheckTransactionsValid SpanName = "col.state.mutator.extend.transactions.validity" COLClusterStateMutatorExtendCheckTransactionsDupes SpanName = "col.state.mutator.extend.transactions.dupes" COLClusterStateMutatorExtendDBInsert SpanName = "col.state.mutator.extend.dbInsert" EXEExecuteBlock SpanName = "exe.ingestion.executeBlock" EXESaveExecutionResults SpanName = "exe.ingestion.saveExecutionResults" EXESaveExecutionReceipt SpanName = "exe.ingestion.saveExecutionReceipt" EXESaveTransactionResults SpanName = "exe.ingestion.saveTransactionResults" EXESaveTransactionEvents SpanName = "exe.ingestion.saveTransactionEvents" EXEBroadcastExecutionReceipt SpanName = "exe.provider.broadcastExecutionReceipt" EXEComputeBlock SpanName = "exe.computer.computeBlock" EXEComputeCollection SpanName = "exe.computer.computeCollection" EXEComputeSystemCollection SpanName = "exe.computer.computeSystemCollection" EXEComputeTransaction SpanName = "exe.computer.computeTransaction" EXEMergeTransactionView SpanName = "exe.computer.mergeTransactionView" EXECommitDelta SpanName = "exe.state.commitDelta" EXEGenerateChunkDataPacks SpanName = "exe.state.generateChunkDataPacks" EXEGetRegisters SpanName = "exe.state.getRegisters" EXEGetRegistersWithProofs SpanName = "exe.state.getRegistersWithProofs" EXEPersistStateCommitment SpanName = "exe.state.persistStateCommitment" EXEPersistEvents SpanName = "exe.state.persistEvents" EXEPersistChunkDataPack SpanName = "exe.state.persistChunkDataPack" EXEGetExecutionResultID SpanName = "exe.state.getExecutionResultID" EXEPersistExecutionResult SpanName = "exe.state.persistExecutionResult" EXEUpdateHighestExecutedBlockIfHigher SpanName = "exe.state.updateHighestExecutedBlockIfHigher" EXEGetHighestExecutedBlockID SpanName = "exe.state.getHighestExecutedBlockID" // Verification node // // assigner engine VERProcessFinalizedBlock SpanName = "ver.processFinalizedBlock" // children of VERProcessFinalizedBlock VERAssignerHandleFinalizedBlock SpanName = "ver.assigner.handleFinalizedBlock" VERAssignerHandleExecutionReceipt SpanName = "ver.assigner.handleExecutionReceipt" VERAssignerChunkAssignment SpanName = "ver.assigner.chunkAssignment" VERAssignerProcessChunk SpanName = "ver.assigner.processChunk" VERProcessExecutionReceipt SpanName = "ver.processExecutionReceipt" // children of VERProcessExecutionReceipt VERFindHandleExecutionReceipt SpanName = "ver.find.handleExecutionReceipt" VERFindOnFinalizedBlock SpanName = "ver.finder.OnFinalizedBlock" VERFindCheckCachedReceipts SpanName = "ver.finder.checkCachedReceipts" VERFindCheckPendingReceipts SpanName = "ver.finder.checkPendingReceipts" VERFindCheckReadyReceipts SpanName = "ver.finder.checkReadyReceipts" VERFindProcessResult SpanName = "ver.finder.processResult" VERFindOnResultProcessed SpanName = "ver.finder.onResultProcessed" VERProcessExecutionResult SpanName = "ver.processExecutionResult" // children of VERProcessExecutionResult VERMatchHandleExecutionResult SpanName = "ver.match.handleExecutionResult" VERMatchHandleChunkDataPack SpanName = "ver.match.handleChunkDataPack" VERMatchMyChunkAssignments SpanName = "ver.match.myChunkAssignments" VERVerVerifyWithMetrics SpanName = "ver.verify.verifyWithMetrics" VERVerChunkVerify SpanName = "ver.verify.ChunkVerifier.Verify" VERVerGenerateResultApproval SpanName = "ver.verify.GenerateResultApproval" // Flow Virtual Machine FVMVerifyTransaction SpanName = "fvm.verifyTransaction" FVMSeqNumCheckTransaction SpanName = "fvm.seqNumCheckTransaction" FVMExecuteTransaction SpanName = "fvm.executeTransaction" FVMDeductTransactionFees SpanName = "fvm.deductTransactionFees" FVMFrozenAccountCheckTransaction SpanName = "fvm.frozenAccountCheckTransaction" FVMEnvHash SpanName = "fvm.env.Hash" FVMEnvValueExists SpanName = "fvm.env.valueExists" FVMEnvGetValue SpanName = "fvm.env.getValue" FVMEnvSetValue SpanName = "fvm.env.setValue" FVMEnvGetStorageUsed SpanName = "fvm.env.getStorageUsed" FVMEnvGetStorageCapacity SpanName = "fvm.env.getStorageCapacity" FVMEnvGetAccountBalance SpanName = "fvm.env.getAccountBalance" FVMEnvResolveLocation SpanName = "fvm.env.resolveLocation" FVMEnvGetCode SpanName = "fvm.env.getCode" FVMEnvGetProgram SpanName = "fvm.env.getCachedProgram" FVMEnvSetProgram SpanName = "fvm.env.cacheProgram" FVMEnvProgramLog SpanName = "fvm.env.programLog" FVMEnvEmitEvent SpanName = "fvm.env.emitEvent" FVMEnvGenerateUUID SpanName = "fvm.env.generateUUID" FVMEnvDecodeArgument SpanName = "fvm.env.decodeArgument" FVMEnvVerifySignature SpanName = "fvm.env.verifySignature" FVMEnvGetCurrentBlockHeight SpanName = "fvm.env.getCurrentBlockHeight" FVMEnvUnsafeRandom SpanName = "fvm.env.unsafeRandom" FVMEnvGetBlockAtHeight SpanName = "fvm.env.getBlockAtHeight" FVMEnvCreateAccount SpanName = "fvm.env.createAccount" FVMEnvAddAccountKey SpanName = "fvm.env.addAccountKey" FVMEnvGetAccountKey SpanName = "fvm.env.getAccountKey" FVMEnvRemoveAccountKey SpanName = "fvm.env.removeAccountKey" FVMEnvUpdateAccountContractCode SpanName = "fvm.env.updateAccountContractCode" FVMEnvGetAccountContractCode SpanName = "fvm.env.getAccountContractCode" FVMEnvRemoveAccountContractCode SpanName = "fvm.env.removeAccountContractCode" FVMEnvGetSigningAccounts SpanName = "fvm.env.getSigningAccounts" FVMCadenceParseProgram SpanName = "fvm.cadence.parseProgram" FVMCadenceCheckProgram SpanName = "fvm.cadence.checkProgram" FVMCadenceInterpretProgram SpanName = "fvm.cadence.interpretProgram" FVMCadenceEncodeValue SpanName = "fvm.cadence.encodeValue" FVMCadenceDecodeValue SpanName = "fvm.cadence.decodeValue" )
Span names