Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CLI ¶
type CLI struct {
// contains filtered or unexported fields
}
CLI uses the CLI interface for site interactions. Don't initialize directly, use NewCLI()
func NewCLI ¶
func NewCLI(wpCLIPath string, wpPath string, fpmURL string, metrics metrics.Manager, logger logger.Logger) *CLI
NewCLI sets up the CLI Performer w/ special initializations.
type Event ¶
type Event struct { URL string Timestamp int `json:"timestamp"` Action string `json:"action"` Instance string `json:"instance"` }
The Event recieved and run from the WP site.
type Mock ¶
type Mock struct { UseSleeps bool LogCommands bool RotateSites bool // contains filtered or unexported fields }
Mock is a fake performer, gives example data back. Useful for testing orchestrator changes.
type Performer ¶
type Performer interface { IsReady() bool GetSites(time.Duration) (Sites, error) GetEvents(site Site) ([]Event, error) RunEvent(event Event) error }
Performer is responsible for the real interaction w/ sites. It does the event fetching and running, be that through wp cli, php-fpm, or rest apis.
Click to show internal directories.
Click to hide internal directories.