Documentation ¶
Index ¶
- func OpenSpannerClient(ctx context.Context, name string) (*spanner.Client, error)
- type Database
- func (db *Database) Apply(ctx context.Context, ms []*spanner.Mutation, ...) error
- func (db *Database) Close()
- func (db *Database) Query(ctx context.Context, statement spanner.Statement, collection, query string) *spanner.RowIterator
- func (db *Database) Read(ctx context.Context, table string, keys spanner.KeySet, columns []string, ...) *spanner.RowIterator
- func (db *Database) ReadOnlyTransaction() *spanner.ReadOnlyTransaction
- func (db *Database) ReadRow(ctx context.Context, table string, key spanner.Key, columns []string, ...) (*spanner.Row, error)
- func (db *Database) ReadUsingIndex(ctx context.Context, table, index string, keys spanner.KeySet, ...) *spanner.RowIterator
- func (db *Database) ReadWriteTransaction(ctx context.Context, ...) (time.Time, error)
- type Logger
- func (logger *Logger) Debug(v ...interface{})
- func (logger *Logger) Debugf(format string, v ...interface{})
- func (logger *Logger) Error(v ...interface{})
- func (logger *Logger) Errorf(format string, v ...interface{})
- func (logger *Logger) Info(v ...interface{})
- func (logger *Logger) Infof(format string, v ...interface{})
- func (logger *Logger) Panicln(v ...interface{})
- type LoggerClient
- type Transaction
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Database ¶
type Database struct {
// contains filtered or unexported fields
}
func WrapDatabase ¶
func WrapDatabase(client *spanner.Client, transaction newrelic.Transaction) *Database
func (*Database) ReadOnlyTransaction ¶
func (db *Database) ReadOnlyTransaction() *spanner.ReadOnlyTransaction
func (*Database) ReadUsingIndex ¶
type LoggerClient ¶
type LoggerClient struct{}
func NewLoggerClient ¶
func NewLoggerClient() *LoggerClient
type Transaction ¶
type Transaction interface { ReadUsingIndex(context.Context, string, string, spanner.KeySet, []string) *spanner.RowIterator Read(context.Context, string, spanner.KeySet, []string) *spanner.RowIterator ReadRow(context.Context, string, spanner.Key, []string) (*spanner.Row, error) Query(context.Context, spanner.Statement) *spanner.RowIterator }
Click to show internal directories.
Click to hide internal directories.