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

package modelgeneration

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

Index

Package Files

modelgeneration.go

type Client Uses

type Client struct {
    base.ClientFacade
    // contains filtered or unexported fields
}

Client provides methods that the Juju client command uses to interact with models stored in the Juju Server.

func NewClient Uses

func NewClient(st base.APICallCloser) *Client

NewClient creates a new `Client` based on an existing authenticated API connection.

func (*Client) AbortBranch Uses

func (c *Client) AbortBranch(branchName string) error

Abort aborts an existing branch to the model.

func (*Client) AddBranch Uses

func (c *Client) AddBranch(branchName string) error

AddBranch adds a new branch to the model.

func (*Client) BranchInfo Uses

func (c *Client) BranchInfo(
    branchName string, detailed bool, formatTime func(time.Time) string,
) (model.GenerationSummaries, error)

BranchInfo returns information about "in-flight" branches. If a non-empty string is supplied for branch name, then only information for that branch is returned. Supplying true for detailed returns extra unit detail for the branch.

func (*Client) CommitBranch Uses

func (c *Client) CommitBranch(branchName string) (int, error)

CommitBranch commits the branch with the input name to the model, effectively completing it and applying all branch changes across the model. The new generation ID of the model is returned.

func (*Client) HasActiveBranch Uses

func (c *Client) HasActiveBranch(branchName string) (bool, error)

HasActiveBranch returns true if the model has an "in-flight" branch with the input name.

func (*Client) TrackBranch Uses

func (c *Client) TrackBranch(branchName string, entities []string) error

TrackBranch sets the input units and/or applications to track changes made under the input branch name.

Package modelgeneration imports 6 packages (graph) and is imported by 3 packages. Updated 2019-08-23. Refresh now. Tools for package owners.