juju: github.com/juju/juju/api/migrationmaster Index | Files

package migrationmaster

import "github.com/juju/juju/api/migrationmaster"


Package Files


type Client Uses

type Client struct {
    // contains filtered or unexported fields

Client describes the client side API for the MigrationMaster facade (used by the migrationmaster worker).

func NewClient Uses

func NewClient(caller base.APICaller, newWatcher NewWatcherFunc) *Client

NewClient returns a new Client based on an existing API connection.

func (*Client) Export Uses

func (c *Client) Export() (migration.SerializedModel, error)

Export returns a serialized representation of the model associated with the API connection. The charms used by the model are also returned.

func (*Client) MigrationStatus Uses

func (c *Client) MigrationStatus() (migration.MigrationStatus, error)

MigrationStatus returns the details and progress of the latest model migration.

func (*Client) MinionReports Uses

func (c *Client) MinionReports() (migration.MinionReports, error)

MinionReports returns details of the reports made by migration minions to the controller for the current migration phase.

func (*Client) ModelInfo Uses

func (c *Client) ModelInfo() (migration.ModelInfo, error)

ModelInfo return basic information about the model to migrated.

func (*Client) OpenResource Uses

func (c *Client) OpenResource(application, name string) (io.ReadCloser, error)

OpenResource downloads the named resource for an application.

func (*Client) Prechecks Uses

func (c *Client) Prechecks() error

Prechecks verifies that the source controller and model are healthy and able to participate in a migration.

func (*Client) ProcessRelations Uses

func (c *Client) ProcessRelations(controllerAlias string) error

ProcessRelations runs a series of processes to ensure that the relations of a given model are correct after a migrated model.

func (*Client) Reap Uses

func (c *Client) Reap() error

Reap removes the documents for the model associated with the API connection.

func (*Client) SetPhase Uses

func (c *Client) SetPhase(phase migration.Phase) error

SetPhase updates the phase of the currently active model migration.

func (*Client) SetStatusMessage Uses

func (c *Client) SetStatusMessage(message string) error

SetStatusMessage sets a human readable message regarding the progress of a migration.

func (*Client) StreamModelLog Uses

func (c *Client) StreamModelLog(start time.Time) (<-chan common.LogMessage, error)

StreamModelLog takes a starting time and returns a channel that will yield the logs on or after that time - these are the logs that need to be transferred to the target after the migration is successful.

func (*Client) Watch Uses

func (c *Client) Watch() (watcher.NotifyWatcher, error)

Watch returns a watcher which reports when a migration is active for the model associated with the API connection.

func (*Client) WatchMinionReports Uses

func (c *Client) WatchMinionReports() (watcher.NotifyWatcher, error)

WatchMinionReports returns a watcher which reports when a migration minion has made a report for the current migration phase.

type NewWatcherFunc Uses

type NewWatcherFunc func(base.APICaller, params.NotifyWatchResult) watcher.NotifyWatcher

NewWatcherFunc exists to let us unit test Facade without patching.

Package migrationmaster imports 17 packages (graph) and is imported by 24 packages. Updated 2020-04-25. Refresh now. Tools for package owners.