Documentation
¶
Index ¶
- type Postgres
- func (db *Postgres) Close()
- func (db *Postgres) DeleteNode(ctx context.Context, req *scheduler.Node) (*scheduler.DeleteNodeResponse, error)
- func (db *Postgres) GetNode(ctx context.Context, req *scheduler.GetNodeRequest) (*scheduler.Node, error)
- func (db *Postgres) GetTask(ctx context.Context, req *tes.GetTaskRequest) (*tes.Task, error)
- func (db *Postgres) Init() error
- func (db *Postgres) ListNodes(ctx context.Context, req *scheduler.ListNodesRequest) (*scheduler.ListNodesResponse, error)
- func (db *Postgres) ListTasks(ctx context.Context, req *tes.ListTasksRequest) (*tes.ListTasksResponse, error)
- func (db *Postgres) PutNode(ctx context.Context, node *scheduler.Node) (*scheduler.PutNodeResponse, error)
- func (db *Postgres) ReadQueue(n int) []*tes.Task
- func (db *Postgres) WriteEvent(ctx context.Context, req *events.Event) error
- type TaskCore
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Postgres ¶
type Postgres struct {
scheduler.UnimplementedSchedulerServiceServer
// contains filtered or unexported fields
}
Postgres provides a PostgreSQL database server backend.
func (*Postgres) DeleteNode ¶
func (db *Postgres) DeleteNode(ctx context.Context, req *scheduler.Node) (*scheduler.DeleteNodeResponse, error)
DeleteNode deletes a node
func (*Postgres) GetNode ¶
func (db *Postgres) GetNode(ctx context.Context, req *scheduler.GetNodeRequest) (*scheduler.Node, error)
GetNode gets a node
func (*Postgres) ListNodes ¶
func (db *Postgres) ListNodes(ctx context.Context, req *scheduler.ListNodesRequest) (*scheduler.ListNodesResponse, error)
ListNodes is an API endpoint that returns a list of nodes.
func (*Postgres) ListTasks ¶
func (db *Postgres) ListTasks(ctx context.Context, req *tes.ListTasksRequest) (*tes.ListTasksResponse, error)
ListTasks returns a list of tasks.
func (*Postgres) PutNode ¶
func (db *Postgres) PutNode(ctx context.Context, node *scheduler.Node) (*scheduler.PutNodeResponse, error)
PutNode is an RPC endpoint that is used by nodes to send heartbeats and status updates.
Click to show internal directories.
Click to hide internal directories.