Versions in this module Expand all Collapse all v0 v0.9.0 Jun 15, 2015 Changes in this version + var ErrTxAlreadyStarted = errors.New("transaction already started") + func Init(app, key string) + func NewRequestTx(name string, url string) *tx + func NewTx(name string) *tx + func RecordMetrics(interval time.Duration) + func RecordMetricsWithRecorder(r Recorder) + func WithTx(ctx context.Context, t Tx) context.Context + type NRTxReporter struct + func (r *NRTxReporter) ReportError(txnID int64, exceptionType, errorMessage, stackTrace, stackFrameDelim string) (int, error) + type NRTxTracer struct + func (t *NRTxTracer) BeginDatastoreSegment(txnID, parentID int64, table, operation, sql, rollupName string) (int64, error) + func (t *NRTxTracer) BeginExternalSegment(txnID, parentID int64, host, name string) (int64, error) + func (t *NRTxTracer) BeginGenericSegment(txnID, parentID int64, name string) (int64, error) + func (t *NRTxTracer) BeginTransaction() (int64, error) + func (t *NRTxTracer) EndSegment(txnID, parentID int64) error + func (t *NRTxTracer) EndTransaction(txnID int64) error + func (t *NRTxTracer) SetTransactionName(txnID int64, name string) error + func (t *NRTxTracer) SetTransactionRequestURL(txnID int64, url string) error + type Recorder interface + Interval func() time.Duration + Record func() error + type SegmentStack struct + func NewSegmentStack() *SegmentStack + func (s *SegmentStack) Len() int + func (s *SegmentStack) Peek() int64 + func (s *SegmentStack) Pop() (int64, bool) + func (s *SegmentStack) Push(id int64) + type Tx interface + End func() error + EndSegment func() error + ReportError func(exceptionType, errorMessage, stackTrace, stackFrameDelim string) error + Start func() error + StartDatastore func(table, operation, sql, rollupName string) error + StartExternal func(host, name string) error + StartGeneric func(name string) error + func FromContext(ctx context.Context) (Tx, bool) + type TxReporter interface + ReportError func(txnID int64, exceptionType, errorMessage, stackTrace, stackFrameDelim string) (int, error) + type TxTracer interface + BeginDatastoreSegment func(txnID int64, parentID int64, table string, operation string, sql string, ...) (int64, error) + BeginExternalSegment func(txnID int64, parentID int64, host string, name string) (int64, error) + BeginGenericSegment func(txnID int64, parentID int64, name string) (int64, error) + BeginTransaction func() (int64, error) + EndSegment func(txnID int64, parentID int64) error + EndTransaction func(txnID int64) error + SetTransactionName func(txnID int64, name string) error + SetTransactionRequestURL func(txnID int64, url string) error