Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewRouter ¶
NewRouter initializes a new router with registered routes redirected to appropriate handler functions
func ToContainerInstance ¶
func ToContainerInstance(versionedInstance storetypes.VersionedContainerInstance) (models.ContainerInstance, error)
ToContainerInstance translates a container instance represented by the internal structure (storetypes.VersionedContainerInstance) to it's external representation (models.ContainerInstance)
func ToTask ¶
func ToTask(versionedTask storetypes.VersionedTask) (models.Task, error)
ToTask translates a task represented by the internal structure (storetypes.VersionedTask) to it's external representation (models.Task)
Types ¶
type APIs ¶
type APIs struct { TaskApis TaskAPIs ContainerInstanceApis ContainerInstanceAPIs }
type ContainerInstanceAPIs ¶
type ContainerInstanceAPIs struct {
// contains filtered or unexported fields
}
ContainerInstanceAPIs encapsulates the backend datastore with which the container instance APIs interact
func NewContainerInstanceAPIs ¶
func NewContainerInstanceAPIs(instanceStore store.ContainerInstanceStore) ContainerInstanceAPIs
NewContainerInstanceAPIs initializes the ContainerInstanceAPIs struct
func (ContainerInstanceAPIs) GetInstance ¶
func (instanceAPIs ContainerInstanceAPIs) GetInstance(w http.ResponseWriter, r *http.Request)
GetInstance gets a container instance using the cluster name to which the instance belongs to and the instance ARN
func (ContainerInstanceAPIs) ListInstances ¶
func (instanceAPIs ContainerInstanceAPIs) ListInstances(w http.ResponseWriter, r *http.Request)
ListInstances lists all container instances across all clusters after applying filters, if any
func (ContainerInstanceAPIs) StreamInstances ¶
func (instanceAPIs ContainerInstanceAPIs) StreamInstances(w http.ResponseWriter, r *http.Request)
StreamInstances streams container instances that change (status, resources, etc.) across all clusters
type TaskAPIs ¶
type TaskAPIs struct {
// contains filtered or unexported fields
}
TaskAPIs encapsulates the backend datastore with which the task APIs interact
func NewTaskAPIs ¶
NewTaskAPIs initializes the TaskAPIs struct
func (TaskAPIs) GetTask ¶
func (taskAPIs TaskAPIs) GetTask(w http.ResponseWriter, r *http.Request)
GetTask gets a task using the cluster name to which the task belongs to and the task ARN
func (TaskAPIs) ListTasks ¶
func (taskAPIs TaskAPIs) ListTasks(w http.ResponseWriter, r *http.Request)
ListTasks lists all tasks across all clusters after applying filters, if any
func (TaskAPIs) StreamTasks ¶
func (taskAPIs TaskAPIs) StreamTasks(w http.ResponseWriter, r *http.Request)
StreamTasks streams tasks that change (status etc.) across all clusters