Documentation ¶
Index ¶
- Variables
- func DeserializeExecutionResult[T ExecutionResult](s SerializedExecutionResult) (*T, error)
- type DeprovisionNodeExecutionResult
- type DeprovisionNodeInput
- type Execution
- type ExecutionIdentifier
- type ExecutionInput
- type ExecutionResult
- type ProvisionNodeExecutionResult
- type ProvisionNodeInput
- type SerializedExecutionResult
- type Status
- type WorkflowName
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrUnknownStatus = errors.New("unknown job status") ErrUnknownWorkflow = errors.New("unknown workflow") )
Functions ¶
func DeserializeExecutionResult ¶ added in v0.0.3
func DeserializeExecutionResult[T ExecutionResult](s SerializedExecutionResult) (*T, error)
Types ¶
type DeprovisionNodeExecutionResult ¶ added in v0.0.3
type DeprovisionNodeExecutionResult struct { ResourcesFailedToDelete []string `json:"resourcesFailedToDelete,omitempty"` Error *string `json:"error,omitempty"` }
func NewDeprovisionNodeExecutionResult ¶ added in v0.0.3
func NewDeprovisionNodeExecutionResult() DeprovisionNodeExecutionResult
func (*DeprovisionNodeExecutionResult) GetError ¶ added in v0.0.6
func (r *DeprovisionNodeExecutionResult) GetError() string
func (DeprovisionNodeExecutionResult) Serialize ¶ added in v0.0.3
func (r DeprovisionNodeExecutionResult) Serialize() (SerializedExecutionResult, error)
func (*DeprovisionNodeExecutionResult) SetError ¶ added in v0.0.6
func (r *DeprovisionNodeExecutionResult) SetError(err string)
type DeprovisionNodeInput ¶ added in v0.0.6
type DeprovisionNodeInput struct { ExecutionId string `json:"executionId"` NodeId string `json:"nodeId"` Tailnet string `json:"tailnetName"` TailnetDeviceId string `json:"tailnetDeviceId"` }
func (DeprovisionNodeInput) ExecutionIdentifier ¶ added in v0.0.6
func (i DeprovisionNodeInput) ExecutionIdentifier() string
func (*DeprovisionNodeInput) ToJson ¶ added in v0.0.6
func (i *DeprovisionNodeInput) ToJson() (string, error)
type Execution ¶
type Execution struct { Identifier ExecutionIdentifier Workflow WorkflowName Status Status Created time.Time Updated time.Time Finished *time.Time Results SerializedExecutionResult }
func NewExecution ¶
func NewExecution(id ExecutionIdentifier, workflow WorkflowName) *Execution
type ExecutionIdentifier ¶
type ExecutionIdentifier string
func ExecutionIdentifierFromString ¶
func ExecutionIdentifierFromString(id string) (ExecutionIdentifier, error)
func FormExecutionIdentifier ¶
func FormExecutionIdentifier(workflow WorkflowName) ExecutionIdentifier
func (ExecutionIdentifier) String ¶
func (id ExecutionIdentifier) String() string
type ExecutionInput ¶ added in v0.0.6
type ExecutionResult ¶ added in v0.0.3
type ExecutionResult interface {
Serialize() (SerializedExecutionResult, error)
}
type ProvisionNodeExecutionResult ¶ added in v0.0.3
type ProvisionNodeExecutionResult struct { Node *string `json:"nodeId,omitempty"` Error *string `json:"error,omitempty"` }
func NewProvisionNodeExecutionResult ¶ added in v0.0.3
func NewProvisionNodeExecutionResult() ProvisionNodeExecutionResult
func (*ProvisionNodeExecutionResult) GetError ¶ added in v0.0.6
func (r *ProvisionNodeExecutionResult) GetError() string
func (ProvisionNodeExecutionResult) GetNode ¶ added in v0.0.3
func (r ProvisionNodeExecutionResult) GetNode() string
func (ProvisionNodeExecutionResult) Serialize ¶ added in v0.0.3
func (r ProvisionNodeExecutionResult) Serialize() (SerializedExecutionResult, error)
func (*ProvisionNodeExecutionResult) SetError ¶ added in v0.0.6
func (r *ProvisionNodeExecutionResult) SetError(err string)
type ProvisionNodeInput ¶ added in v0.0.6
type ProvisionNodeInput struct { ExecutionId string `json:"executionId"` ProviderName string `json:"providerName"` Location string `json:"location"` TailnetName string `json:"tailnetName"` TailnetControlServer string `json:"tailnetControlServer"` Ephemeral bool `json:"ephemeral"` }
func (ProvisionNodeInput) ExecutionIdentifier ¶ added in v0.0.6
func (i ProvisionNodeInput) ExecutionIdentifier() string
func (*ProvisionNodeInput) ToJson ¶ added in v0.0.6
func (i *ProvisionNodeInput) ToJson() (string, error)
type SerializedExecutionResult ¶ added in v0.0.3
type SerializedExecutionResult string
func (SerializedExecutionResult) IsEmpty ¶ added in v0.0.3
func (r SerializedExecutionResult) IsEmpty() bool
func (SerializedExecutionResult) String ¶ added in v0.0.3
func (r SerializedExecutionResult) String() string
type WorkflowName ¶
type WorkflowName int
const ( WorkflowNameUnknown WorkflowName = iota WorkflowNameProvisionNode WorkflowNameDeprovisionNode )
func WorkflowNameFromString ¶
func WorkflowNameFromString(s string) (WorkflowName, error)
func (WorkflowName) String ¶
func (n WorkflowName) String() string
Click to show internal directories.
Click to hide internal directories.