Documentation ¶
Index ¶
- func NewResultWithContextTracer(ctx context.Context, result neo4j.ResultWithContext, tracer trace.Tracer) neo4j.ResultWithContext
- type BookmarkManagerTracer
- type DriverWithContextTracer
- func (n *DriverWithContextTracer) ExecuteQueryBookmarkManager() neo4j.BookmarkManager
- func (n *DriverWithContextTracer) GetServerInfo(ctx context.Context) (_ neo4j.ServerInfo, err error)
- func (n *DriverWithContextTracer) NewSession(ctx context.Context, config neo4j.SessionConfig) neo4j.SessionWithContext
- func (n *DriverWithContextTracer) VerifyAuthentication(ctx context.Context, auth *neo4j.AuthToken) (err error)
- func (n *DriverWithContextTracer) VerifyConnectivity(ctx context.Context) (err error)
- type ExplicitTransactionTracer
- func (t *ExplicitTransactionTracer) Close(ctx context.Context) (err error)
- func (t *ExplicitTransactionTracer) Commit(ctx context.Context) (err error)
- func (t *ExplicitTransactionTracer) Rollback(ctx context.Context) (err error)
- func (t *ExplicitTransactionTracer) Run(ctx context.Context, cypher string, params map[string]any) (_ neo4j.ResultWithContext, err error)
- type ManagedTransactionTracer
- type Neo4jTracer
- type Option
- type ResultWithContextTracer
- func (r *ResultWithContextTracer) Collect(ctx context.Context) (_ []*neo4j.Record, err error)
- func (r *ResultWithContextTracer) Consume(ctx context.Context) (_ neo4j.ResultSummary, err error)
- func (r *ResultWithContextTracer) Next(ctx context.Context) bool
- func (r *ResultWithContextTracer) NextRecord(ctx context.Context, record **neo4j.Record) bool
- func (r *ResultWithContextTracer) Peek(ctx context.Context) bool
- func (r *ResultWithContextTracer) PeekRecord(ctx context.Context, record **neo4j.Record) bool
- func (r *ResultWithContextTracer) Single(ctx context.Context) (_ *neo4j.Record, err error)
- type SessionWithContextTracer
- func (s *SessionWithContextTracer) BeginTransaction(ctx context.Context, configurers ...func(config *neo4j.TransactionConfig)) (neo4j.ExplicitTransaction, error)
- func (s *SessionWithContextTracer) ExecuteRead(ctx context.Context, work neo4j.ManagedTransactionWork, ...) (_ any, err error)
- func (s *SessionWithContextTracer) ExecuteWrite(ctx context.Context, work neo4j.ManagedTransactionWork, ...) (_ any, err error)
- func (s *SessionWithContextTracer) Run(ctx context.Context, cypher string, params map[string]any, ...) (_ neo4j.ResultWithContext, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewResultWithContextTracer ¶ added in v0.0.5
func NewResultWithContextTracer(ctx context.Context, result neo4j.ResultWithContext, tracer trace.Tracer) neo4j.ResultWithContext
Types ¶
type BookmarkManagerTracer ¶
type BookmarkManagerTracer struct { // Actual neo4j BookmarkManager neo4j.BookmarkManager // contains filtered or unexported fields }
BookmarkManagerTracer wraps a neo4j.BookmarkManager object so the calls can be traced with open telemetry distributed tracing
func (*BookmarkManagerTracer) GetBookmarks ¶
GetBookmarks calls neo4j.BookmarkManager.GetBookmarks and trace the call
func (*BookmarkManagerTracer) UpdateBookmarks ¶
func (b *BookmarkManagerTracer) UpdateBookmarks(ctx context.Context, previousBookmarks, newBookmarks neo4j.Bookmarks) (err error)
UpdateBookmarks calls neo4j.BookmarkManager.UpdateBookmarks and trace the call
type DriverWithContextTracer ¶
type DriverWithContextTracer struct { neo4j.DriverWithContext // contains filtered or unexported fields }
func (*DriverWithContextTracer) ExecuteQueryBookmarkManager ¶
func (n *DriverWithContextTracer) ExecuteQueryBookmarkManager() neo4j.BookmarkManager
ExecuteQueryBookmarkManager calls neo4j.DriverWithContext.ExecuteQueryBookmarkManager and wraps the resulting neo4j.BookmarkManager with a tracing object
func (*DriverWithContextTracer) GetServerInfo ¶
func (n *DriverWithContextTracer) GetServerInfo(ctx context.Context) (_ neo4j.ServerInfo, err error)
GetServerInfo calls neo4j.GetServerInfo.VerifyConnectivity and trace the call
func (*DriverWithContextTracer) NewSession ¶
func (n *DriverWithContextTracer) NewSession(ctx context.Context, config neo4j.SessionConfig) neo4j.SessionWithContext
NewSession calls neo4j.DriverWithContext.NewSession and wraps the resulting neo4j.SessionWithContext with a tracing object
func (*DriverWithContextTracer) VerifyAuthentication ¶
func (n *DriverWithContextTracer) VerifyAuthentication(ctx context.Context, auth *neo4j.AuthToken) (err error)
VerifyAuthentication calls neo4j.DriverWithContext.VerifyAuthentication and trace the call
func (*DriverWithContextTracer) VerifyConnectivity ¶
func (n *DriverWithContextTracer) VerifyConnectivity(ctx context.Context) (err error)
VerifyConnectivity calls neo4j.DriverWithContext.VerifyConnectivity and trace the call
type ExplicitTransactionTracer ¶
type ExplicitTransactionTracer struct { neo4j.ExplicitTransaction // contains filtered or unexported fields }
ExplicitTransactionTracer wraps a neo4j.ExplicitTransaction object so the calls can be traced with open telemetry distributed tracing
func NewExplicitTransactionTracer ¶
func NewExplicitTransactionTracer(ctx context.Context, tx neo4j.ExplicitTransaction, txSpan trace.Span, tracer trace.Tracer) *ExplicitTransactionTracer
NewExplicitTransactionTracer returns a new ExplicitTransactionTracer that wraps a neo4j.ExplicitTransaction with correct tracing details
func (*ExplicitTransactionTracer) Close ¶
func (t *ExplicitTransactionTracer) Close(ctx context.Context) (err error)
Close calls neo4j.ExplicitTransaction.Close and trace the call
func (*ExplicitTransactionTracer) Commit ¶
func (t *ExplicitTransactionTracer) Commit(ctx context.Context) (err error)
Commit calls neo4j.ExplicitTransaction.Commit and trace the call
type ManagedTransactionTracer ¶
type ManagedTransactionTracer struct { neo4j.ManagedTransaction // contains filtered or unexported fields }
ManagedTransactionTracer wraps a neo4j.ManagedTransaction object so the calls can be traced with open telemetry distributed tracing
func NewManagedTransactionTracer ¶
func NewManagedTransactionTracer(ctx context.Context, tx neo4j.ManagedTransaction, tracer trace.Tracer) *ManagedTransactionTracer
NewManagedTransactionTracer returns a new ManagedTransactionTracer that wraps a neo4j.ManagedTransaction with correct tracing details
type Neo4jTracer ¶
type Neo4jTracer struct {
// contains filtered or unexported fields
}
Neo4jTracer wraps a neo4j.Tracer object so the calls can be traced with open telemetry distributed tracing
func NewNeo4jTracer ¶
func NewNeo4jTracer(opts ...Option) *Neo4jTracer
NewNeo4jTracer creates an object that will wrap neo4j drivers with a tracing object
func (*Neo4jTracer) NewDriverWithContext ¶
func (t *Neo4jTracer) NewDriverWithContext(target string, auth auth.TokenManager, configurers ...func(config2 *neo4j.Config)) (_ neo4j.DriverWithContext, err error)
NewDriverWithContext is the entry point to the neo4j driver to create an instance of a neo4j.DriverWithContext that is wrapped by a tracing object More information about the arguments can be found in the underlying neo4j driver call neo4j.NewDriverWithContext
type Option ¶
type Option interface {
// contains filtered or unexported methods
}
func WithTracerProvider ¶
func WithTracerProvider(tp trace.TracerProvider) Option
WithTracerProvider specifies a tracer provider to use for creating a tracer. If none is specified, the global provider is used.
type ResultWithContextTracer ¶ added in v0.0.5
type ResultWithContextTracer struct { neo4j.ResultWithContext // contains filtered or unexported fields }
func (*ResultWithContextTracer) Consume ¶ added in v0.0.5
func (r *ResultWithContextTracer) Consume(ctx context.Context) (_ neo4j.ResultSummary, err error)
func (*ResultWithContextTracer) Next ¶ added in v0.0.5
func (r *ResultWithContextTracer) Next(ctx context.Context) bool
func (*ResultWithContextTracer) NextRecord ¶ added in v0.0.5
func (*ResultWithContextTracer) Peek ¶ added in v0.0.5
func (r *ResultWithContextTracer) Peek(ctx context.Context) bool
func (*ResultWithContextTracer) PeekRecord ¶ added in v0.0.5
type SessionWithContextTracer ¶
type SessionWithContextTracer struct { neo4j.SessionWithContext // contains filtered or unexported fields }
SessionWithContextTracer wraps a neo4j.SessionWithContext object so the calls can be traced with open telemetry distributed tracing
func (*SessionWithContextTracer) BeginTransaction ¶
func (s *SessionWithContextTracer) BeginTransaction(ctx context.Context, configurers ...func(config *neo4j.TransactionConfig)) (neo4j.ExplicitTransaction, error)
BeginTransaction calls neo4j.SessionWithContext.BeginTransaction and trace the call
func (*SessionWithContextTracer) ExecuteRead ¶
func (s *SessionWithContextTracer) ExecuteRead(ctx context.Context, work neo4j.ManagedTransactionWork, configurers ...func(config *neo4j.TransactionConfig)) (_ any, err error)
ExecuteRead calls neo4j.SessionWithContext.ExecuteRead and trace the call. The neo4j.ManagedTransaction object that is passed to the work function will be wrapped with a tracer.
func (*SessionWithContextTracer) ExecuteWrite ¶
func (s *SessionWithContextTracer) ExecuteWrite(ctx context.Context, work neo4j.ManagedTransactionWork, configurers ...func(config *neo4j.TransactionConfig)) (_ any, err error)
ExecuteWrite calls neo4j.SessionWithContext.ExecuteWrite and trace the call. The neo4j.ManagedTransaction object that is passed to the work function will be wrapped with a tracer.
func (*SessionWithContextTracer) Run ¶
func (s *SessionWithContextTracer) Run(ctx context.Context, cypher string, params map[string]any, configurers ...func(config *neo4j.TransactionConfig)) (_ neo4j.ResultWithContext, err error)
Run calls neo4j.SessionWithContext.Run and trace the call