Documentation
¶
Index ¶
- type Controller
- func (this *Controller) CountInstances(jwt jwt.Token, search string, includeGenerated bool) (count int64, err error, errCode int)
- func (this *Controller) CreateInstance(instance model.Instance, jwt jwt.Token) (result model.Instance, err error, code int)
- func (this *Controller) DeleteInstance(id string, jwt jwt.Token) (err error, errCode int)
- func (this *Controller) EnsureAllInstancesDeployed() (err error)
- func (this *Controller) ListInstances(jwt jwt.Token, limit int64, offset int64, sort string, asc bool, search string, ...) (results []model.Instance, err error, errCode int)
- func (this *Controller) ReadInstance(id string, jwt jwt.Token) (result model.Instance, err error, errCode int)
- func (this *Controller) SetInstance(instance model.Instance, jwt jwt.Token) (err error, code int)
- type Database
- type DeploymentClient
- type Driver
- type KafkaAdmin
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Controller ¶
type Controller struct {
// contains filtered or unexported fields
}
func New ¶
func New(config config.Config, db Database, deploymentClient DeploymentClient, kafkaAdmin KafkaAdmin, perm permV2Client.Client) *Controller
func (*Controller) CountInstances ¶
func (*Controller) CreateInstance ¶
func (*Controller) DeleteInstance ¶
func (*Controller) EnsureAllInstancesDeployed ¶
func (this *Controller) EnsureAllInstancesDeployed() (err error)
func (*Controller) ListInstances ¶
func (*Controller) ReadInstance ¶
func (*Controller) SetInstance ¶
type Database ¶
type Database interface { ListInstances(ctx context.Context, limit int64, offset int64, sort string, jwt jwt.Token, asc bool, search string, includeGenerated bool) (result []model.Instance, err error) GetInstance(ctx context.Context, id string, jwt jwt.Token) (instance model.Instance, exists bool, err error) CreateInstance(ctx context.Context, instance model.Instance, jwt jwt.Token) error SetInstance(ctx context.Context, instance model.Instance, jwt jwt.Token) error RemoveInstance(ctx context.Context, id string, jwt jwt.Token) error CountInstances(ctx context.Context, jwt jwt.Token, search string, includeGenerated bool) (count int64, err error) }
type DeploymentClient ¶
type DeploymentClient interface { CreateContainer(name string, image string, env map[string]string, restart bool, userid string, importTypeId string) (id string, err error) UpdateContainer(id string, name string, image string, env map[string]string, restart bool, userid string, importTypeId string) (newId string, err error) RemoveContainer(id string) (err error) ContainerExists(id string) (exists bool, err error) }
Click to show internal directories.
Click to hide internal directories.