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

package remoterelations

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

Index

Package Files

remoterelations.go

type Client Uses

type Client struct {
    // contains filtered or unexported fields
}

Client provides access to the remoterelations api facade.

func NewClient Uses

func NewClient(caller base.APICaller) *Client

NewClient creates a new client-side RemoteRelations facade.

func (*Client) ConsumeRemoteRelationChange Uses

func (c *Client) ConsumeRemoteRelationChange(change params.RemoteRelationChangeEvent) error

ConsumeRemoteRelationChange consumes a change to settings originating from the remote/offering side of a relation.

func (*Client) ControllerAPIInfoForModel Uses

func (c *Client) ControllerAPIInfoForModel(modelUUID string) (*api.Info, error)

ControllerAPIInfoForModel retrieves the controller API info for the specified model.

func (*Client) ExportEntities Uses

func (c *Client) ExportEntities(tags []names.Tag) ([]params.TokenResult, error)

ExportEntities allocates unique, remote entity IDs for the given entities in the local model.

func (*Client) GetToken Uses

func (c *Client) GetToken(tag names.Tag) (string, error)

GetToken returns the token associated with the entity with the given tag for the specified model.

func (*Client) ImportRemoteEntity Uses

func (c *Client) ImportRemoteEntity(entity names.Tag, token string) error

ImportRemoteEntity adds an entity to the remote entities collection with the specified opaque token.

func (*Client) RelationUnitSettings Uses

func (c *Client) RelationUnitSettings(relationUnits []params.RelationUnit) ([]params.SettingsResult, error)

RelationUnitSettings returns the relation unit settings for the given relation units in the local model.

func (*Client) Relations Uses

func (c *Client) Relations(keys []string) ([]params.RemoteRelationResult, error)

Relations returns information about the cross-model relations with the specified keys in the local model.

func (*Client) RemoteApplications Uses

func (c *Client) RemoteApplications(applications []string) ([]params.RemoteApplicationResult, error)

RemoteApplications returns the current state of the remote applications with the specified names in the local model.

func (*Client) SaveMacaroon Uses

func (c *Client) SaveMacaroon(entity names.Tag, mac *macaroon.Macaroon) error

SaveMacaroon saves the macaroon for the entity.

func (*Client) SetRemoteApplicationStatus Uses

func (c *Client) SetRemoteApplicationStatus(applicationName string, status status.Status, message string) error

SetRemoteApplicationStatus sets the status for the specified remote application.

func (*Client) WatchLocalRelationUnits Uses

func (c *Client) WatchLocalRelationUnits(relationKey string) (watcher.RelationUnitsWatcher, error)

WatchLocalRelationUnits returns a watcher that notifies of changes to the local units in the relation with the given key.

func (*Client) WatchRemoteApplicationRelations Uses

func (c *Client) WatchRemoteApplicationRelations(application string) (watcher.StringsWatcher, error)

WatchRemoteApplicationRelations returns remote relations watchers that delivers changes according to the addition, removal, and lifecycle changes of relations that the specified remote application is involved in; and also according to the entering, departing, and change of unit settings in those relations.

func (*Client) WatchRemoteApplications Uses

func (c *Client) WatchRemoteApplications() (watcher.StringsWatcher, error)

WatchRemoteApplications returns a strings watcher that notifies of the addition, removal, and lifecycle changes of remote applications in the model.

func (*Client) WatchRemoteRelations Uses

func (c *Client) WatchRemoteRelations() (watcher.StringsWatcher, error)

WatchRemoteRelations returns a strings watcher that notifies of the addition, removal, and lifecycle changes of remote relations in the model.

Package remoterelations imports 9 packages (graph) and is imported by 14 packages. Updated 2019-08-23. Refresh now. Tools for package owners.