package trace
import "github.com/ydb-platform/ydb-go-sdk/v3/trace"
Index ¶
- func ClearContext(x interface{}) interface{}
- func DriverOnClose(t Driver, c *context.Context) func(error)
- func DriverOnClusterGet(t Driver, c *context.Context) func(endpoint endpointInfo, _ error)
- func DriverOnClusterInsert(t Driver, c *context.Context, endpoint endpointInfo) func(state ConnState)
- func DriverOnClusterRemove(t Driver, c *context.Context, endpoint endpointInfo) func(state ConnState)
- func DriverOnClusterUpdate(t Driver, c *context.Context, endpoint endpointInfo) func(state ConnState)
- func DriverOnConnInvoke(t Driver, c *context.Context, endpoint endpointInfo, m Method) func(_ error, issues []Issue, opID string, state ConnState)
- func DriverOnConnNewStream(t Driver, c *context.Context, endpoint endpointInfo, m Method) func(error) func(state ConnState, _ error)
- func DriverOnConnRelease(t Driver, c *context.Context, endpoint endpointInfo) func(lock int)
- func DriverOnConnStateChange(t Driver, c *context.Context, endpoint endpointInfo, state ConnState) func(state ConnState)
- func DriverOnConnTake(t Driver, c *context.Context, endpoint endpointInfo) func(lock int, _ error)
- func DriverOnDiscovery(t Driver, c *context.Context, address string) func(location string, endpoints []string, _ error)
- func DriverOnGetCredentials(t Driver, c *context.Context) func(tokenOk bool, _ error)
- func DriverOnInit(t Driver, c *context.Context, endpoint string, database string, secure bool) func(error)
- func DriverOnNetClose(t Driver, address string) func(error)
- func DriverOnNetDial(t Driver, c *context.Context, address string) func(error)
- func DriverOnNetRead(t Driver, address string, buffer int) func(received int, _ error)
- func DriverOnNetWrite(t Driver, address string, bytes int) func(sent int, _ error)
- func DriverOnPessimizeNode(t Driver, c *context.Context, endpoint endpointInfo, state ConnState, cause error) func(state ConnState)
- func RetryOnRetry(t Retry, c context.Context) func(_ context.Context, latency time.Duration, err error)
- func Stub(x interface{}, f func(name string, args ...interface{}))
- func TableOnPoolClose(t Table, c *context.Context) func(error)
- func TableOnPoolDo(t Table, c *context.Context, idempotent bool) func(error) func(attempts int, _ error)
- func TableOnPoolDoTx(t Table, c *context.Context, idempotent bool) func(error) func(attempts int, _ error)
- func TableOnPoolGet(t Table, c *context.Context) func(session sessionInfo, attempts int, _ error)
- func TableOnPoolInit(t Table, c *context.Context) func(limit int, keepAliveMinSize int)
- func TableOnPoolPut(t Table, c *context.Context, session sessionInfo) func(error)
- func TableOnPoolSessionClose(t Table, c *context.Context, session sessionInfo) func()
- func TableOnPoolSessionNew(t Table, c *context.Context) func(session sessionInfo, _ error)
- func TableOnPoolTake(t Table, c *context.Context, session sessionInfo) func() func(took bool, _ error)
- func TableOnPoolWait(t Table, c *context.Context) func(session sessionInfo, _ error)
- func TableOnSessionDelete(t Table, c *context.Context, session sessionInfo) func(error)
- func TableOnSessionKeepAlive(t Table, c *context.Context, session sessionInfo) func(error)
- func TableOnSessionNew(t Table, c *context.Context) func(session sessionInfo, _ error)
- func TableOnSessionQueryExecute(t Table, c *context.Context, session sessionInfo, query dataQuery, parameters queryParameters) func(tx transactionInfo, prepared bool, result result, _ error)
- func TableOnSessionQueryPrepare(t Table, c *context.Context, session sessionInfo, query string) func(result dataQuery, _ error)
- func TableOnSessionQueryStreamExecute(t Table, c *context.Context, session sessionInfo, query dataQuery, parameters queryParameters) func(error)
- func TableOnSessionQueryStreamRead(t Table, c *context.Context, session sessionInfo) func(error)
- func TableOnSessionTransactionBegin(t Table, c *context.Context, session sessionInfo) func(tx transactionInfo, _ error)
- func TableOnSessionTransactionCommit(t Table, c *context.Context, session sessionInfo, tx transactionInfo) func(error)
- func TableOnSessionTransactionRollback(t Table, c *context.Context, session sessionInfo, tx transactionInfo) func(error)
- func WithDriver(ctx context.Context, t Driver) context.Context
- func WithRetry(ctx context.Context, t Retry) context.Context
- func WithTable(ctx context.Context, t Table) context.Context
- type CloseDoneInfo
- type CloseStartInfo
- type ClusterGetDoneInfo
- type ClusterGetStartInfo
- type ClusterInsertDoneInfo
- type ClusterInsertStartInfo
- type ClusterRemoveDoneInfo
- type ClusterRemoveStartInfo
- type ClusterUpdateDoneInfo
- type ClusterUpdateStartInfo
- type ConnInvokeDoneInfo
- type ConnInvokeStartInfo
- type ConnNewStreamDoneInfo
- type ConnNewStreamRecvInfo
- type ConnNewStreamStartInfo
- type ConnReleaseDoneInfo
- type ConnReleaseStartInfo
- type ConnState
- type ConnStateChangeDoneInfo
- type ConnStateChangeStartInfo
- type ConnTakeDoneInfo
- type ConnTakeStartInfo
- type Details
- func DetailsFromString(s string) (d Details)
- func DetailsFromStrings(ss []string) (d Details)
- func (d Details) String() string
- func (d Details) Strings() (ss []string)
- type DiscoveryDoneInfo
- type DiscoveryStartInfo
- type Driver
- type ExecuteDataQueryStartInfo
- type FieldStubber
- type GetCredentialsDoneInfo
- type GetCredentialsStartInfo
- type InitDoneInfo
- type InitStartInfo
- type Issue
- type KeepAliveDoneInfo
- type KeepAliveStartInfo
- type Method
- func (m Method) Name() (s string)
- func (m Method) Service() (s string)
- func (m Method) Split() (service, method string)
- type NetCloseDoneInfo
- type NetCloseStartInfo
- type NetDialDoneInfo
- type NetDialStartInfo
- type NetReadDoneInfo
- type NetReadStartInfo
- type NetWriteDoneInfo
- type NetWriteStartInfo
- type PessimizeNodeDoneInfo
- type PessimizeNodeStartInfo
- type PoolCloseDoneInfo
- type PoolCloseStartInfo
- type PoolDoDoneInfo
- type PoolDoInternalInfo
- type PoolDoStartInfo
- type PoolDoTxDoneInfo
- type PoolDoTxInternalInfo
- type PoolDoTxStartInfo
- type PoolGetDoneInfo
- type PoolGetStartInfo
- type PoolInitDoneInfo
- type PoolInitStartInfo
- type PoolPutDoneInfo
- type PoolPutStartInfo
- type PoolSessionCloseDoneInfo
- type PoolSessionCloseStartInfo
- type PoolSessionNewDoneInfo
- type PoolSessionNewStartInfo
- type PoolTakeDoneInfo
- type PoolTakeStartInfo
- type PoolTakeWaitInfo
- type PoolWaitDoneInfo
- type PoolWaitStartInfo
- type PrepareDataQueryDoneInfo
- type Retry
- type RetryLoopDoneInfo
- type RetryLoopStartInfo
- type SessionDeleteDoneInfo
- type SessionDeleteStartInfo
- type SessionNewDoneInfo
- type SessionNewStartInfo
- type SessionQueryPrepareDoneInfo
- type SessionQueryPrepareStartInfo
- type SessionQueryStreamExecuteDoneInfo
- type SessionQueryStreamExecuteStartInfo
- type SessionQueryStreamReadDoneInfo
- type SessionQueryStreamReadStartInfo
- type SessionTransactionBeginDoneInfo
- type SessionTransactionBeginStartInfo
- type SessionTransactionCommitDoneInfo
- type SessionTransactionCommitStartInfo
- type SessionTransactionRollbackDoneInfo
- type SessionTransactionRollbackStartInfo
- type Table
Functions ¶
func ClearContext ¶
func ClearContext(x interface{}) interface{}
func DriverOnClose ¶
func DriverOnClusterGet ¶
func DriverOnClusterInsert ¶
func DriverOnClusterInsert(t Driver, c *context.Context, endpoint endpointInfo) func(state ConnState)
func DriverOnClusterRemove ¶
func DriverOnClusterRemove(t Driver, c *context.Context, endpoint endpointInfo) func(state ConnState)
func DriverOnClusterUpdate ¶
func DriverOnClusterUpdate(t Driver, c *context.Context, endpoint endpointInfo) func(state ConnState)
func DriverOnConnInvoke ¶
func DriverOnConnInvoke(t Driver, c *context.Context, endpoint endpointInfo, m Method) func(_ error, issues []Issue, opID string, state ConnState)
func DriverOnConnNewStream ¶
func DriverOnConnNewStream(t Driver, c *context.Context, endpoint endpointInfo, m Method) func(error) func(state ConnState, _ error)
func DriverOnConnRelease ¶
func DriverOnConnStateChange ¶
func DriverOnConnStateChange(t Driver, c *context.Context, endpoint endpointInfo, state ConnState) func(state ConnState)
func DriverOnConnTake ¶
func DriverOnDiscovery ¶
func DriverOnDiscovery(t Driver, c *context.Context, address string) func(location string, endpoints []string, _ error)
func DriverOnGetCredentials ¶
func DriverOnInit ¶
func DriverOnInit(t Driver, c *context.Context, endpoint string, database string, secure bool) func(error)
func DriverOnNetClose ¶
func DriverOnNetDial ¶
func DriverOnNetRead ¶
func DriverOnNetWrite ¶
func DriverOnPessimizeNode ¶
func DriverOnPessimizeNode(t Driver, c *context.Context, endpoint endpointInfo, state ConnState, cause error) func(state ConnState)
func RetryOnRetry ¶
func RetryOnRetry(t Retry, c context.Context) func(_ context.Context, latency time.Duration, err error)
func Stub ¶
func Stub(x interface{}, f func(name string, args ...interface{}))
Stub is a helper function that stubs all functional fields of x with given f.
func TableOnPoolClose ¶
func TableOnPoolDo ¶
func TableOnPoolDo(t Table, c *context.Context, idempotent bool) func(error) func(attempts int, _ error)
func TableOnPoolDoTx ¶
func TableOnPoolDoTx(t Table, c *context.Context, idempotent bool) func(error) func(attempts int, _ error)
func TableOnPoolGet ¶
func TableOnPoolInit ¶
func TableOnPoolPut ¶
func TableOnPoolSessionClose ¶
func TableOnPoolSessionNew ¶
func TableOnPoolTake ¶
func TableOnPoolTake(t Table, c *context.Context, session sessionInfo) func() func(took bool, _ error)
func TableOnPoolWait ¶
func TableOnSessionDelete ¶
func TableOnSessionKeepAlive ¶
func TableOnSessionNew ¶
func TableOnSessionQueryExecute ¶
func TableOnSessionQueryExecute(t Table, c *context.Context, session sessionInfo, query dataQuery, parameters queryParameters) func(tx transactionInfo, prepared bool, result result, _ error)
func TableOnSessionQueryPrepare ¶
func TableOnSessionQueryPrepare(t Table, c *context.Context, session sessionInfo, query string) func(result dataQuery, _ error)
func TableOnSessionQueryStreamExecute ¶
func TableOnSessionQueryStreamExecute(t Table, c *context.Context, session sessionInfo, query dataQuery, parameters queryParameters) func(error)
func TableOnSessionQueryStreamRead ¶
func TableOnSessionTransactionBegin ¶
func TableOnSessionTransactionBegin(t Table, c *context.Context, session sessionInfo) func(tx transactionInfo, _ error)
func TableOnSessionTransactionCommit ¶
func TableOnSessionTransactionCommit(t Table, c *context.Context, session sessionInfo, tx transactionInfo) func(error)
func TableOnSessionTransactionRollback ¶
func TableOnSessionTransactionRollback(t Table, c *context.Context, session sessionInfo, tx transactionInfo) func(error)
func WithDriver ¶
WithDriver returns deadline which has associated Driver with it.
func WithRetry ¶
WithRetry returns deadline which has associated Retry with it.
func WithTable ¶
WithTable returns deadline which has associated Trace with it.
Types ¶
type CloseDoneInfo ¶
type CloseDoneInfo struct { Error error }
type CloseStartInfo ¶
type CloseStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context }
type ClusterGetDoneInfo ¶
type ClusterGetDoneInfo struct { Endpoint endpointInfo Error error }
type ClusterGetStartInfo ¶
type ClusterGetStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context }
type ClusterInsertDoneInfo ¶
type ClusterInsertDoneInfo struct { State ConnState }
type ClusterInsertStartInfo ¶
type ClusterInsertStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Endpoint endpointInfo }
type ClusterRemoveDoneInfo ¶
type ClusterRemoveDoneInfo struct { State ConnState }
type ClusterRemoveStartInfo ¶
type ClusterRemoveStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Endpoint endpointInfo }
type ClusterUpdateDoneInfo ¶
type ClusterUpdateDoneInfo struct { State ConnState }
type ClusterUpdateStartInfo ¶
type ClusterUpdateStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Endpoint endpointInfo }
type ConnInvokeDoneInfo ¶
type ConnInvokeStartInfo ¶
type ConnInvokeStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Endpoint endpointInfo Method Method }
type ConnNewStreamDoneInfo ¶
type ConnNewStreamRecvInfo ¶
type ConnNewStreamRecvInfo struct { Error error }
type ConnNewStreamStartInfo ¶
type ConnNewStreamStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Endpoint endpointInfo Method Method }
type ConnReleaseDoneInfo ¶
type ConnReleaseDoneInfo struct { Lock int }
type ConnReleaseStartInfo ¶
type ConnReleaseStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Endpoint endpointInfo }
type ConnState ¶
type ConnStateChangeDoneInfo ¶
type ConnStateChangeDoneInfo struct { State ConnState }
type ConnStateChangeStartInfo ¶
type ConnStateChangeStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Endpoint endpointInfo State ConnState }
type ConnTakeDoneInfo ¶
type ConnTakeStartInfo ¶
type ConnTakeStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Endpoint endpointInfo }
type Details ¶
type Details uint64
const ( DriverSystemEvents Details = 1 << iota // 1 DriverClusterEvents // 2 DriverNetEvents // 4 DriverCoreEvents // 8 DriverCredentialsEvents // 16 DriverDiscoveryEvents // 32 TableSessionLifeCycleEvents // 64 TableSessionQueryInvokeEvents // 128 TableSessionQueryStreamEvents // 256 TableSessionTransactionEvents // 512 TablePoolLifeCycleEvents // 1024 TablePoolRetryEvents // 2048 TablePoolSessionLifeCycleEvents // 4096 TablePoolAPIEvents // 8192 DriverConnEvents = DriverNetEvents | DriverCoreEvents // 12 TableSessionQueryEvents = TableSessionQueryInvokeEvents | TableSessionQueryStreamEvents // 384 TableSessionEvents = TableSessionLifeCycleEvents | TableSessionQueryEvents | TableSessionTransactionEvents // 960 TablePoolEvents = TablePoolLifeCycleEvents | TablePoolRetryEvents | TablePoolSessionLifeCycleEvents | TablePoolAPIEvents // 15360 DetailsAll = ^Details(0) // 18446744073709551615 )
func DetailsFromString ¶
func DetailsFromStrings ¶
func (Details) String ¶
func (Details) Strings ¶
type DiscoveryDoneInfo ¶
type DiscoveryStartInfo ¶
type DiscoveryStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Address string }
type Driver ¶
type Driver struct { // Driver runtime events OnInit func(InitStartInfo) func(InitDoneInfo) OnClose func(CloseStartInfo) func(CloseDoneInfo) // Network events OnNetRead func(NetReadStartInfo) func(NetReadDoneInfo) OnNetWrite func(NetWriteStartInfo) func(NetWriteDoneInfo) OnNetDial func(NetDialStartInfo) func(NetDialDoneInfo) OnNetClose func(NetCloseStartInfo) func(NetCloseDoneInfo) // Conn events OnConnStateChange func(ConnStateChangeStartInfo) func(ConnStateChangeDoneInfo) OnConnInvoke func(ConnInvokeStartInfo) func(ConnInvokeDoneInfo) OnConnNewStream func(ConnNewStreamStartInfo) func(ConnNewStreamRecvInfo) func(ConnNewStreamDoneInfo) OnConnTake func(ConnTakeStartInfo) func(ConnTakeDoneInfo) OnConnRelease func(ConnReleaseStartInfo) func(ConnReleaseDoneInfo) // Cluster events OnClusterGet func(ClusterGetStartInfo) func(ClusterGetDoneInfo) OnClusterInsert func(ClusterInsertStartInfo) func(ClusterInsertDoneInfo) OnClusterUpdate func(ClusterUpdateStartInfo) func(ClusterUpdateDoneInfo) OnClusterRemove func(ClusterRemoveStartInfo) func(ClusterRemoveDoneInfo) OnPessimizeNode func(PessimizeNodeStartInfo) func(PessimizeNodeDoneInfo) // Credentials events OnGetCredentials func(GetCredentialsStartInfo) func(GetCredentialsDoneInfo) // Discovery events OnDiscovery func(DiscoveryStartInfo) func(DiscoveryDoneInfo) }
func ContextDriver ¶
ContextDriver returns Driver associated with ctx. If there is no Driver associated with ctx then zero value of Driver is returned.
func (Driver) Compose ¶
Compose returns a new Driver which has functional fields composed both from t and x.
type ExecuteDataQueryStartInfo ¶
type ExecuteDataQueryStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Session sessionInfo Query dataQuery Parameters queryParameters }
type FieldStubber ¶
type FieldStubber struct { // OnStub is an optional callback that is called when field getting // stubbed. OnStub func(name string) // OnCall is an optional callback that will be called for each stubbed // field getting called. OnCall func(name string, args ...interface{}) }
FieldStubber contains options of filling all struct functional fields.
func (FieldStubber) Stub ¶
func (f FieldStubber) Stub(x reflect.Value)
Stub fills in given x struct.
type GetCredentialsDoneInfo ¶
type GetCredentialsStartInfo ¶
type GetCredentialsStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context }
type InitDoneInfo ¶
type InitDoneInfo struct { Error error }
type InitStartInfo ¶
type InitStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Endpoint string Database string Secure bool }
type Issue ¶
Issue interface
type KeepAliveDoneInfo ¶
type KeepAliveDoneInfo struct { Error error }
type KeepAliveStartInfo ¶
type KeepAliveStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Session sessionInfo }
type Method ¶
type Method string
Method represents rpc method.
func (Method) Name ¶
Name returns the rpc method name.
func (Method) Service ¶
Service returns the rpc service name.
func (Method) Split ¶
Split returns service name and method.
type NetCloseDoneInfo ¶
type NetCloseDoneInfo struct { Error error }
type NetCloseStartInfo ¶
type NetCloseStartInfo struct { Address string }
type NetDialDoneInfo ¶
type NetDialDoneInfo struct { Error error }
type NetDialStartInfo ¶
type NetDialStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Address string }
type NetReadDoneInfo ¶
type NetReadStartInfo ¶
type NetWriteDoneInfo ¶
type NetWriteStartInfo ¶
type PessimizeNodeDoneInfo ¶
type PessimizeNodeDoneInfo struct { State ConnState }
type PessimizeNodeStartInfo ¶
type PessimizeNodeStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Endpoint endpointInfo State ConnState Cause error }
type PoolCloseDoneInfo ¶
type PoolCloseDoneInfo struct { Error error }
type PoolCloseStartInfo ¶
type PoolCloseStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context }
type PoolDoDoneInfo ¶
type PoolDoInternalInfo ¶
type PoolDoInternalInfo struct { Error error }
type PoolDoStartInfo ¶
type PoolDoStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Idempotent bool }
type PoolDoTxDoneInfo ¶
type PoolDoTxInternalInfo ¶
type PoolDoTxInternalInfo struct { Error error }
type PoolDoTxStartInfo ¶
type PoolDoTxStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Idempotent bool }
type PoolGetDoneInfo ¶
type PoolGetStartInfo ¶
type PoolGetStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context }
type PoolInitDoneInfo ¶
type PoolInitStartInfo ¶
type PoolInitStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context }
type PoolPutDoneInfo ¶
type PoolPutDoneInfo struct { Error error }
type PoolPutStartInfo ¶
type PoolPutStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Session sessionInfo }
type PoolSessionCloseDoneInfo ¶
type PoolSessionCloseDoneInfo struct{}
type PoolSessionCloseStartInfo ¶
type PoolSessionCloseStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Session sessionInfo }
type PoolSessionNewDoneInfo ¶
type PoolSessionNewDoneInfo struct { Session sessionInfo Error error }
type PoolSessionNewStartInfo ¶
type PoolSessionNewStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context }
type PoolTakeDoneInfo ¶
type PoolTakeStartInfo ¶
type PoolTakeStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Session sessionInfo }
type PoolTakeWaitInfo ¶
type PoolTakeWaitInfo struct{}
type PoolWaitDoneInfo ¶
type PoolWaitDoneInfo struct { Session sessionInfo Error error }
PoolWaitDoneInfo means a wait iteration inside Get call is done Warning: Session and Error may be nil at the same time. This means that a wait iteration donned without any significant resultErr
type PoolWaitStartInfo ¶
type PoolWaitStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context }
type PrepareDataQueryDoneInfo ¶
type PrepareDataQueryDoneInfo struct { Result dataQuery Error error }
type Retry ¶
type Retry struct { OnRetry func(RetryLoopStartInfo) func(RetryLoopDoneInfo) }
func ContextRetry ¶
ContextRetry returns Retry associated with ctx. If there is no Retry associated with ctx then zero value of Retry is returned.
func (Retry) Compose ¶
Compose returns a new Retry which has functional fields composed both from t and x.
type RetryLoopDoneInfo ¶
type RetryLoopStartInfo ¶
type SessionDeleteDoneInfo ¶
type SessionDeleteDoneInfo struct { Error error }
type SessionDeleteStartInfo ¶
type SessionDeleteStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Session sessionInfo }
type SessionNewDoneInfo ¶
type SessionNewDoneInfo struct { Session sessionInfo Error error }
type SessionNewStartInfo ¶
type SessionNewStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context }
type SessionQueryPrepareDoneInfo ¶
type SessionQueryPrepareDoneInfo struct { Tx transactionInfo Prepared bool Result result Error error }
type SessionQueryPrepareStartInfo ¶
type SessionQueryPrepareStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Session sessionInfo Query string }
type SessionQueryStreamExecuteDoneInfo ¶
type SessionQueryStreamExecuteDoneInfo struct { Error error }
type SessionQueryStreamExecuteStartInfo ¶
type SessionQueryStreamExecuteStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Session sessionInfo Query dataQuery Parameters queryParameters }
type SessionQueryStreamReadDoneInfo ¶
type SessionQueryStreamReadDoneInfo struct { Error error }
type SessionQueryStreamReadStartInfo ¶
type SessionQueryStreamReadStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Session sessionInfo }
type SessionTransactionBeginDoneInfo ¶
type SessionTransactionBeginDoneInfo struct { Tx transactionInfo Error error }
type SessionTransactionBeginStartInfo ¶
type SessionTransactionBeginStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Session sessionInfo }
type SessionTransactionCommitDoneInfo ¶
type SessionTransactionCommitDoneInfo struct { Error error }
type SessionTransactionCommitStartInfo ¶
type SessionTransactionCommitStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Session sessionInfo Tx transactionInfo }
type SessionTransactionRollbackDoneInfo ¶
type SessionTransactionRollbackDoneInfo struct { Error error }
type SessionTransactionRollbackStartInfo ¶
type SessionTransactionRollbackStartInfo struct { // Context make available context in trace callback function. // Pointer to context provide replacement of context in trace callback function. // Warning: concurrent access to pointer on client side must be excluded. // Safe replacement of context are provided only inside callback function Context *context.Context Session sessionInfo Tx transactionInfo }
type Table ¶
type Table struct { // Session events OnSessionNew func(SessionNewStartInfo) func(SessionNewDoneInfo) OnSessionDelete func(SessionDeleteStartInfo) func(SessionDeleteDoneInfo) OnSessionKeepAlive func(KeepAliveStartInfo) func(KeepAliveDoneInfo) // Query events OnSessionQueryPrepare func(SessionQueryPrepareStartInfo) func(PrepareDataQueryDoneInfo) OnSessionQueryExecute func(ExecuteDataQueryStartInfo) func(SessionQueryPrepareDoneInfo) // Stream events OnSessionQueryStreamExecute func(SessionQueryStreamExecuteStartInfo) func(SessionQueryStreamExecuteDoneInfo) OnSessionQueryStreamRead func(SessionQueryStreamReadStartInfo) func(SessionQueryStreamReadDoneInfo) // Transaction events OnSessionTransactionBegin func(SessionTransactionBeginStartInfo) func(SessionTransactionBeginDoneInfo) OnSessionTransactionCommit func(SessionTransactionCommitStartInfo) func(SessionTransactionCommitDoneInfo) OnSessionTransactionRollback func(SessionTransactionRollbackStartInfo) func(SessionTransactionRollbackDoneInfo) // Pool events OnPoolInit func(PoolInitStartInfo) func(PoolInitDoneInfo) OnPoolClose func(PoolCloseStartInfo) func(PoolCloseDoneInfo) OnPoolDo func(PoolDoStartInfo) func(info PoolDoInternalInfo) func(PoolDoDoneInfo) OnPoolDoTx func(PoolDoTxStartInfo) func(info PoolDoTxInternalInfo) func(PoolDoTxDoneInfo) // Pool session lifecycle events OnPoolSessionNew func(PoolSessionNewStartInfo) func(PoolSessionNewDoneInfo) OnPoolSessionClose func(PoolSessionCloseStartInfo) func(PoolSessionCloseDoneInfo) // Pool common API events OnPoolPut func(PoolPutStartInfo) func(PoolPutDoneInfo) // Pool native API events OnPoolGet func(PoolGetStartInfo) func(PoolGetDoneInfo) OnPoolWait func(PoolWaitStartInfo) func(PoolWaitDoneInfo) // Pool ydbsql API events OnPoolTake func(PoolTakeStartInfo) func(PoolTakeWaitInfo) func(PoolTakeDoneInfo) }
Table contains options for tracing table client activity.
func ContextTable ¶
ContextTable returns Table associated with ctx. If there is no Table associated with ctx then zero value of Trace is returned.
func (Table) Compose ¶
Compose returns a new Table which has functional fields composed both from t and x.
Source Files ¶
context.go details.go driver.go driver_gtrace.go retry.go retry_gtrace.go table.go table_gtrace.go traceutil.go
- Version
- v3.8.6
- Published
- Feb 4, 2022
- Platform
- windows/amd64
- Imports
- 5 packages
- Last checked
- 2 seconds ago –
Tools for package owners.