Documentation ¶
Index ¶
- type GetJobsQuery
- type OwnerQuery
- type PostgresStore
- func (d *PostgresStore) CheckAPIKey(ctx context.Context, apiKey string) (*types.ApiKey, error)
- func (d *PostgresStore) CreateAPIKey(ctx context.Context, owner OwnerQuery, name string) (string, error)
- func (d *PostgresStore) CreateBalanceTransfer(ctx context.Context, transfer types.BalanceTransfer) error
- func (d *PostgresStore) CreateJob(ctx context.Context, job types.Job) error
- func (d *PostgresStore) DeleteAPIKey(ctx context.Context, apiKey types.ApiKey) error
- func (d *PostgresStore) GetAPIKeys(ctx context.Context, query OwnerQuery) ([]*types.ApiKey, error)
- func (d *PostgresStore) GetBalanceTransfers(ctx context.Context, query OwnerQuery) ([]*types.BalanceTransfer, error)
- func (d *PostgresStore) GetJob(ctx context.Context, queryID string) (*types.Job, error)
- func (d *PostgresStore) GetJobs(ctx context.Context, query GetJobsQuery) ([]*types.Job, error)
- func (d *PostgresStore) GetMigrations() (*migrate.Migrate, error)
- func (d *PostgresStore) MigrateDown() error
- func (d *PostgresStore) MigrateUp() error
- func (d *PostgresStore) UpdateJob(ctx context.Context, id string, state string, status string, ...) error
- type Store
- type StoreOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GetJobsQuery ¶
type OwnerQuery ¶
type PostgresStore ¶
type PostgresStore struct {
// contains filtered or unexported fields
}
func NewPostgresStore ¶
func NewPostgresStore( options StoreOptions, ) (*PostgresStore, error)
func (*PostgresStore) CheckAPIKey ¶
func (*PostgresStore) CreateAPIKey ¶
func (d *PostgresStore) CreateAPIKey(ctx context.Context, owner OwnerQuery, name string) (string, error)
func (*PostgresStore) CreateBalanceTransfer ¶
func (d *PostgresStore) CreateBalanceTransfer( ctx context.Context, transfer types.BalanceTransfer, ) error
func (*PostgresStore) DeleteAPIKey ¶
func (*PostgresStore) GetAPIKeys ¶
func (d *PostgresStore) GetAPIKeys(ctx context.Context, query OwnerQuery) ([]*types.ApiKey, error)
func (*PostgresStore) GetBalanceTransfers ¶
func (d *PostgresStore) GetBalanceTransfers( ctx context.Context, query OwnerQuery, ) ([]*types.BalanceTransfer, error)
func (*PostgresStore) GetJobs ¶
func (d *PostgresStore) GetJobs( ctx context.Context, query GetJobsQuery, ) ([]*types.Job, error)
func (*PostgresStore) GetMigrations ¶
func (d *PostgresStore) GetMigrations() (*migrate.Migrate, error)
func (*PostgresStore) MigrateDown ¶
func (d *PostgresStore) MigrateDown() error
func (*PostgresStore) MigrateUp ¶
func (d *PostgresStore) MigrateUp() error
type Store ¶
type Store interface { GetJob(ctx context.Context, queryID string) (*types.Job, error) GetJobs(ctx context.Context, query GetJobsQuery) ([]*types.Job, error) CreateJob(ctx context.Context, job types.Job) error UpdateJob(ctx context.Context, id string, state string, status string, data types.JobData) error GetBalanceTransfers(ctx context.Context, query OwnerQuery) ([]*types.BalanceTransfer, error) CreateBalanceTransfer(ctx context.Context, balanceTransfer types.BalanceTransfer) error CreateAPIKey(ctx context.Context, owner OwnerQuery, name string) (string, error) GetAPIKeys(ctx context.Context, query OwnerQuery) ([]*types.ApiKey, error) DeleteAPIKey(ctx context.Context, apiKey types.ApiKey) error CheckAPIKey(ctx context.Context, apiKey string) (*types.ApiKey, error) }
Click to show internal directories.
Click to hide internal directories.