Documentation ¶
Index ¶
Constants ¶
View Source
const ( StateIdle = iota StatePrepared StateUpdated StateFailed )
UM states.
View Source
const ( StatusInstalled = iota StatusInstalling StatusError )
Component statuses.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CertificateProvider ¶
type CertificateProvider interface { GetNodeID() (string, error) GetCertificate(certType string) (certURL, ketURL string, err error) }
CertificateProvider interface to get certificate.
type Client ¶
Client UM client instance.
func New ¶
func New(cfg *config.Config, messageHandler MessageHandler, certProvider CertificateProvider, cryptocontext *cryptutils.CryptoContext, insecure bool, ) (client *Client, err error)
New creates new UM client.
type ComponentStatus ¶
type ComponentStatus int32
ComponentStatus component status.
func (ComponentStatus) String ¶
func (status ComponentStatus) String() string
type ComponentStatusInfo ¶
type ComponentStatusInfo struct { ID string Type string Version string Status ComponentStatus Error string }
ComponentStatusInfo component status info.
type ComponentUpdateInfo ¶
type ComponentUpdateInfo struct { ID string Type string Version string Annotations json.RawMessage URL string Sha256 []byte Size uint64 }
ComponentUpdateInfo component update info.
type MessageHandler ¶
type MessageHandler interface { // Registered indicates the client registered on the server Registered() // PrepareUpdate prepares update PrepareUpdate(components []ComponentUpdateInfo) // StartUpdate starts update StartUpdate() // ApplyUpdate applies update ApplyUpdate() // RevertUpdate reverts update RevertUpdate() // StatusChannel returns status channel StatusChannel() (channel <-chan Status) }
MessageHandler incoming messages handler.
type Status ¶
type Status struct { State UMState Components []ComponentStatusInfo Error string }
Status update manager status.
Click to show internal directories.
Click to hide internal directories.