Documentation
¶
Index ¶
- type ContainerRequest
- type Inventory
- func (inv *Inventory) CheckRequests()
- func (i *Inventory) GetItem(key string) (cntOut types.ContainerJSON, err error)
- func (i *Inventory) HandleRequest(req ContainerRequest) (err error)
- func (i *Inventory) ServeRequest(req ContainerRequest)
- func (i *Inventory) SetItem(key string, item types.ContainerJSON) (err error)
- type Plugin
- type Response
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ContainerRequest ¶
type ContainerRequest struct {
IssuedAt time.Time
Source string
Timeout time.Duration
Name string
ID string
IP string
Back chan Response
}
func NewContainerRequest ¶
func NewContainerRequest(src string, to time.Duration) ContainerRequest
func NewIDContainerRequest ¶
func NewIDContainerRequest(src, id string) ContainerRequest
func NewIPContainerRequest ¶
func NewIPContainerRequest(src, ip string) ContainerRequest
func NewNameContainerRequest ¶
func NewNameContainerRequest(src, name string) ContainerRequest
func (ContainerRequest) Equal ¶
func (this ContainerRequest) Equal(other types.ContainerJSON) bool
func (*ContainerRequest) TimedOut ¶
func (cr *ContainerRequest) TimedOut() bool
type Inventory ¶
type Inventory struct {
Version string
Data map[string]types.ContainerJSON
PendingRequests []ContainerRequest
// contains filtered or unexported fields
}
func NewInventory ¶
func NewInventory() Inventory
func (*Inventory) CheckRequests ¶
func (inv *Inventory) CheckRequests()
CheckRequests iterates over all requests and responses if the request can be fulfilled
func (*Inventory) GetItem ¶
func (i *Inventory) GetItem(key string) (cntOut types.ContainerJSON, err error)
func (*Inventory) HandleRequest ¶
func (i *Inventory) HandleRequest(req ContainerRequest) (err error)
func (*Inventory) ServeRequest ¶
func (i *Inventory) ServeRequest(req ContainerRequest)
type Response ¶
type Response struct {
Container types.ContainerJSON
Error error
}
func NewFAILResponse ¶
func NewOKResponse ¶
func NewOKResponse(cnt types.ContainerJSON) Response
Click to show internal directories.
Click to hide internal directories.