package empty

import "github.com/purpleidea/mgmt/gapi/empty"

Index

Constants

const (
	// Name is the name of this frontend.
	Name = "empty"
)

Types

type GAPI

type GAPI struct {
	// Wait should be true if we don't use any existing (stale) deploys.
	// This means that if you start an empty GAPI, then it will immediately
	// try to look for and run any existing deploys that have been stored in
	// the cluster that it has connected to. If this is true, then it will
	// only start on the next deploy. To be honest, we should probably never
	// wait, but this was accidentally how it was initially implemented, so
	// we'll change the default and add this in as a flag for now. We may
	// remove this in the future unless someone has a good reason for
	// needing it.
	Wait bool
	// contains filtered or unexported fields
}

GAPI implements the main lang GAPI interface.

func (*GAPI) Cli

func (obj *GAPI) Cli(info *gapi.Info) (*gapi.Deploy, error)

Cli takes an *Info struct, and returns our deploy if activated, and if there are any validation problems, you should return an error. If there is no deploy, then you should return a nil deploy and a nil error.

func (*GAPI) Close

func (obj *GAPI) Close() error

Close shuts down the lang GAPI.

func (*GAPI) Graph

func (obj *GAPI) Graph() (*pgraph.Graph, error)

Graph returns a current Graph.

func (*GAPI) Info

func (obj *GAPI) Info() *gapi.InfoResult

Info returns some data about the GAPI implementation.

func (*GAPI) Init

func (obj *GAPI) Init(data *gapi.Data) error

Init initializes the lang GAPI struct.

func (*GAPI) Next

func (obj *GAPI) Next() chan gapi.Next

Next returns nil errors every time there could be a new graph.

Source Files

empty.go

Version
v0.0.0-20250322185616-c50a578426f1 (latest)
Published
Mar 22, 2025
Platform
linux/amd64
Imports
5 packages
Last checked
5 days ago

Tools for package owners.