util

package
v0.5.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 21, 2022 License: Apache-2.0 Imports: 23 Imported by: 5

Documentation

Overview

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Copyright 2019 The Fossul Authors. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BasicAuth

func BasicAuth(h http.Handler, myUser, myPass string) http.Handler

func BoolToString

func BoolToString(b bool) string

func ConfigMapToJson

func ConfigMapToJson(configMap map[string]string) (string, error)

func ConvertEpoch

func ConvertEpoch(epoch string) string

func ConvertEpochToTime

func ConvertEpochToTime(epoch string) time.Time

func CreateDir

func CreateDir(path string, mode os.FileMode) error

func DirectoryList

func DirectoryList(path string) ([]string, error)

func DirectoryTreeList

func DirectoryTreeList(dir string) ([]string, error)

func EncodeConfig

func EncodeConfig(config Config) (*bytes.Buffer, error)

func EncodePluginConfig

func EncodePluginConfig(configMap map[string]string) (*bytes.Buffer, error)

func ExistsBackupRetention

func ExistsBackupRetention(policy string, retentions []BackupRetention) bool

func ExistsInArray

func ExistsInArray(array []string, str string) bool

func ExistsPath

func ExistsPath(path string) bool

func FileList

func FileList(path string) ([]string, error)

func GetArchiveRetention

func GetArchiveRetention(policy string, retentions []ArchiveRetention) int

func GetBackupDirFromConfig

func GetBackupDirFromConfig(config Config) string

func GetBackupDirFromMap

func GetBackupDirFromMap(configMap map[string]string) string

func GetBackupName

func GetBackupName(name, policy, workflowId, timestamp string) string

func GetBackupPathFromConfig

func GetBackupPathFromConfig(config Config) string

func GetBackupPathFromMap

func GetBackupPathFromMap(configMap map[string]string) string

func GetBackupRetention

func GetBackupRetention(policy string, retentions []BackupRetention) int

func GetCronScheduleId

func GetCronScheduleId(w http.ResponseWriter, r *http.Request) (cron.EntryID, error)

func GetLoggerInstance

func GetLoggerInstance() *log.Logger

func GetPluginConfig

func GetPluginConfig(w http.ResponseWriter, r *http.Request) (map[string]string, error)

func GetPluginPath

func GetPluginPath(pluginName, pluginType string) string

func GetRestoreSnapshot

func GetRestoreSnapshot(config Config, snapshots []string) (string, error)

func GetRestoreSrcPath

func GetRestoreSrcPath(config Config) (string, error)

func GetRestoreSrcPathFromMap

func GetRestoreSrcPathFromMap(configMap map[string]string) (string, error)

func GetTimestamp

func GetTimestamp() int64

func GetWorkflowId

func GetWorkflowId() int

func Int32ToString

func Int32ToString(i int32) string

func Int64ToString

func Int64ToString(i int64) string

func IntInSlice

func IntInSlice(i int, list []int) bool

func IntToString

func IntToString(i int) string

func IsDirectory

func IsDirectory(path string) (bool, error)

func JoinArray

func JoinArray(array, combinedArray []string) []string

func LogApi

func LogApi(inner http.Handler, name string) http.Handler

func LogCmdMessage

func LogCmdMessage(l *log.Logger, message string)

func LogCommentMessage

func LogCommentMessage(l *log.Logger, message string)

func LogDebugMessage

func LogDebugMessage(l *log.Logger, message string)

func LogErrorMessage

func LogErrorMessage(l *log.Logger, message string)

func LogInfoMessage

func LogInfoMessage(l *log.Logger, message string)

func LogMessageToConsole

func LogMessageToConsole(l *log.Logger, message Message)

func LogResult

func LogResult(l *log.Logger, result Result)

func LogResults

func LogResults(l *log.Logger, result []Result)

func LogWarnMessage

func LogWarnMessage(l *log.Logger, message string)

func PluginList

func PluginList(path, configName string) ([]string, error)

func ReadConfigToMap

func ReadConfigToMap(filePath string) (map[string]string, error)

func ReadGob

func ReadGob(filePath string, object interface{}) error

func RecursiveDirDelete

func RecursiveDirDelete(dir string) error

func SerializeBackup

func SerializeBackup(resultsDir string, backup *Backup)

func SerializeWorkflow

func SerializeWorkflow(resultsDir string, workflow *Workflow)

func SerializeWorkflowStepResults

func SerializeWorkflowStepResults(resultsDir string, stepId int, results Result)

func SetStepComplete

func SetStepComplete(workflow *Workflow, step Step)

func SetStepError

func SetStepError(workflow *Workflow, step Step)

func SetWorkflowStatusEnd

func SetWorkflowStatusEnd(workflow *Workflow)

func SetWorkflowStatusError

func SetWorkflowStatusError(workflow *Workflow)

func SetWorkflowStatusStart

func SetWorkflowStatusStart(workflow *Workflow)

func SetWorkflowStep

func SetWorkflowStep(workflow *Workflow, step Step)

func StringToInt

func StringToInt(s string) int

func StringToInt64

func StringToInt64(s string) int64

func WriteConfig

func WriteConfig(filePath string, config Config) error

func WriteGob

func WriteGob(filePath string, object interface{}) error

func WritePluginConfig

func WritePluginConfig(filePath string, configMap map[string]string) error

Types

type AppPlugin

type AppPlugin interface {
	SetEnv(Config) Result
	Quiesce(Config) Result
	Unquiesce(Config) Result
	PreRestore(Config) Result
	PostRestore(Config) Result
	Discover(Config) DiscoverResult
	Info() Plugin
}

func GetAppInterface

func GetAppInterface(path string) (AppPlugin, error)

type Archive

type Archive struct {
	Name       string `json:"name,omitempty"`
	Timestamp  string `json:"timestamp,omitempty"`
	Epoch      int    `json:"epoch,omitempty"`
	Policy     string `json:"policy,omitempty"`
	WorkflowId string `json:"workflowId,omitempty"`
}

func GetArchivesByPolicy

func GetArchivesByPolicy(policy string, archives []Archive) []Archive

type ArchivePlugin

type ArchivePlugin interface {
	SetEnv(Config) Result
	Archive(Config) Result
	ArchiveDelete(Config) Result
	ArchiveList(Config) Archives
	Info() Plugin
}

func GetArchiveInterface

func GetArchiveInterface(path string) (ArchivePlugin, error)

type ArchiveRetention

type ArchiveRetention struct {
	Policy          string `json:"policy"`
	RetentionNumber int    `json:"retentionNumber"`
}

type Archives

type Archives struct {
	Archives []Archive `json:"archive,omitempty"`
	Result   Result    `json:"result,omitempty"`
}

type Backup

type Backup struct {
	Name       string    `json:"name,omitempty"`
	Timestamp  string    `json:"timestamp,omitempty"`
	Epoch      int       `json:"epoch,omitempty"`
	Policy     string    `json:"policy,omitempty"`
	WorkflowId string    `json:"workflowId,omitempty"`
	Contents   []Content `json:"contents,omitempty"`
}

func GetBackup

func GetBackup(w http.ResponseWriter, r *http.Request) (Backup, error)

func GetBackupsByPolicy

func GetBackupsByPolicy(policy string, backups []Backup) []Backup

type BackupByWorkflow

type BackupByWorkflow struct {
	Backup Backup `json:"backup,omitempty"`
	Result Result `json:"result,omitempty"`
}

type BackupRetention

type BackupRetention struct {
	Policy          string `json:"policy"`
	RetentionNumber int    `json:"retentionNumber"`
}

type Backups

type Backups struct {
	Backups []Backup `json:"backup,omitempty"`
	Result  Result   `json:"result,omitempty"`
}

type ByEpochArchive

type ByEpochArchive []Archive

func (ByEpochArchive) Len

func (a ByEpochArchive) Len() int

func (ByEpochArchive) Less

func (a ByEpochArchive) Less(i, j int) bool

func (ByEpochArchive) Swap

func (a ByEpochArchive) Swap(i, j int)

type ByEpochBackup

type ByEpochBackup []Backup

func (ByEpochBackup) Len

func (a ByEpochBackup) Len() int

func (ByEpochBackup) Less

func (a ByEpochBackup) Less(i, j int) bool

func (ByEpochBackup) Swap

func (a ByEpochBackup) Swap(i, j int)

type Capability

type Capability struct {
	Name string `json:"name"`
}

type Config

type Config struct {
	ProfileName              string             `json:"profileName,omitempty"`
	ConfigName               string             `json:"configName,omitempty"`
	WorkflowId               string             `json:"workflowId,omitempty"`
	WorkflowType             string             `json:"workflowType,omitempty"`
	WorkflowTimestamp        int64              `json:"workflowTimestamp,omitempty"`
	Backup                   Backup             `json:"backup,omitempty"`
	OperatorControlled       bool               `json:"operatorControlled"`
	ContainerPlatform        string             `json:"containerPlatform,omitempty"`
	AccessWithinCluster      string             `json:"accessWithinCluster,omitempty"`
	AppPlugin                string             `json:"appPlugin"`
	StoragePlugin            string             `json:"storagePlugin"`
	ArchivePlugin            string             `json:"archivePlugin"`
	AutoDiscovery            bool               `json:"autoDiscovery"`
	JobRetention             int                `json:"jobRetention"`
	BackupRetentions         []BackupRetention  `json:"backupRetentions"`
	ArchiveRetentions        []ArchiveRetention `json:"archiveRetentions"`
	SelectedBackupPolicy     string             `json:"backupPolicy,omitmepty"`
	SelectedBackupRetention  int                `json:"backupRetention,omitmepty"`
	SelectedArchiveRetention int                `json:"archiveRetention,omitmepty"`
	SelectedWorkflowId       int                `json:"selectedWorkflowId,omitmepty"`
	PreAppQuiesceCmd         string             `json:"preAppQuiesceCmd,omitempty"`
	AppQuiesceCmd            string             `json:"appQuiesceCmd,omitempty"`
	PostAppQuiesceCmd        string             `json:"postAppQuiesceCmd,omitempty"`
	BackupCreateCmd          string             `json:"backupCreateCmd,omitempty"`
	BackupDeleteCmd          string             `json:"backupDeleteCmd,omitempty"`
	ArchiveCreateCmd         string             `json:"archiveCreateCmd,omitempty"`
	ArchiveDeleteCmd         string             `json:"archiveDeleteCmd,omitempty"`
	PreAppUnquiesceCmd       string             `json:"preAppUnquiesceCmd,omitempty"`
	AppUnquiesceCmd          string             `json:"appUnquiesceCmd,omitempty"`
	PostAppUnquiesceCmd      string             `json:"postAppUnquiesceCmd,omitempty"`
	PreAppRestoreCmd         string             `json:"preAppRestoreCmd,omitempty"`
	RestoreCmd               string             `json:"restoreCmd,omitempty"`
	PostAppRestoreCmd        string             `json:"postAppRestoreCmd,omitempty"`
	SendTrapErrorCmd         string             `json:"sendTrapErrorCmd,omitempty"`
	SendTrapSuccessCmd       string             `json:"sendTrapSuccessCmd,omitempty"`
	AppPluginParameters      map[string]string  `json:"appPluginParameters,omitempty"`
	StoragePluginParameters  map[string]string  `json:"storagePluginParameters,omitempty"`
	ArchivePluginParameters  map[string]string  `json:"archivePluginParameters,omitempty"`
}

func GetConfig

func GetConfig(w http.ResponseWriter, r *http.Request) (Config, error)

func GetConsolidatedConfig

func GetConsolidatedConfig(configDir, profileName, configName, policyName string) (Config, error)

func ReadConfig

func ReadConfig(filePath string) (Config, error)

func SetAppPluginParameters

func SetAppPluginParameters(appConfigPath string, config Config) (Config, error)

func SetArchivePluginParameters

func SetArchivePluginParameters(archiveConfigPath string, config Config) (Config, error)

func SetStoragePluginParameters

func SetStoragePluginParameters(storageConfigPath string, config Config) (Config, error)

type ConfigMapResult

type ConfigMapResult struct {
	ConfigMap map[string]string `json:"configMap,omitmepty"`
	Result    Result            `json:"result,omitmepty"`
}

type ConfigResult

type ConfigResult struct {
	Config Config `json:"config,omitmepty"`
	Result Result `json:"result,omitmepty"`
}

type Content

type Content struct {
	Type                string `json:"type,omitempty"`
	Source              string `json:"source,omitempty"`
	Metadata            string `json:"metadata,omitempty"`
	Data                string `json:"data,omitempty"`
	Size                string `json:"size,omitempty"`
	StorageClass        string `json:"storageClass,omitempty"`
	VolumeSnapshotClass string `json:"volumeSnapshotClass,omitempty"`
}

type CronSchedule

type CronSchedule struct {
	Value string `json:"value,omitempty"`
}

func GetCronSchedule

func GetCronSchedule(w http.ResponseWriter, r *http.Request) (CronSchedule, error)

type Discover

type Discover struct {
	Instance      string   `json:"instance,omitempty"`
	DataFilePaths []string `json:"data,omitempty"`
	LogFilePaths  []string `json:"logs,omitempty"`
}

type DiscoverResult

type DiscoverResult struct {
	DiscoverList []Discover `json:"discoverList,omitempty"`
	Result       Result     `json:"result,omitempty"`
}

type Job

type Job struct {
	Id        int    `json:"id,omitempty"`
	Status    string `json:"status,omitempty"`
	Type      string `json:"type,omitempty"`
	Policy    string `json:"policy"`
	Timestamp string `json:"timestamp,omitempty"`
}

func ListJobs

func ListJobs(jobsDir string) ([]Job, error)

type JobSchedule

type JobSchedule struct {
	CronId       cron.EntryID `json:"cronId"`
	CronSchedule string       `json:"cronSchedule"`
	ProfileName  string       `json:"profileName"`
	ConfigName   string       `json:"configName"`
	BackupPolicy string       `json:"backupPolicy"`
}

type JobScheduleResult

type JobScheduleResult struct {
	JobSchedule JobSchedule `json:"jobSchedule,omitempty"`
	Result      Result      `json:"result,omitempty"`
}

type JobSchedulesResult

type JobSchedulesResult struct {
	JobSchedules []JobSchedule `json:"jobSchedules,omitempty"`
	Result       Result        `json:"result,omitempty"`
}

type Jobs

type Jobs struct {
	Jobs   []Job  `json:"backup,omitempty"`
	Result Result `json:"result,omitempty"`
}

type Message

type Message struct {
	Timestamp int64  `json:"time,omitempty"`
	Level     string `json:"level,omitempty"`
	Message   string `json:"message,omitempty"`
}

func PrependMessage

func PrependMessage(message Message, messages []Message) []Message

func PrependMessages

func PrependMessages(prependedMessages, postpendedMessages []Message) []Message

func SetMessage

func SetMessage(level string, msg string) Message

func SetMessages

func SetMessages(inputMessages []string) []Message

type Plugin

type Plugin struct {
	Name         string       `json:"name,omitempty"`
	Description  string       `json:"description,omitempty"`
	Version      string       `json:"version,omitempty"`
	Type         string       `json:"type,omitempty"`
	Capabilities []Capability `json:"capabilities"`
}

type PluginConfigMap

type PluginConfigMap struct {
	Key1 string `json:"key1,omitempty"`
	Key2 string `json:"key2,omitempty"`
}

type PluginInfoResult

type PluginInfoResult struct {
	Plugin Plugin `json:"plugin,omitempty"`
	Result Result `json:"result,omitempty"`
}

type Result

type Result struct {
	Code     int       `json:"code,omitempty"`
	Messages []Message `json:"messages,omitempty"`
	Data     []string  `json:"data,omitempty"`
	Backup   Backup    `json:"backup,omitempty"`
}

func DeleteJobs

func DeleteJobs(baseDir, profileName, configName string, jobRetention int) Result

func ExecuteCommand

func ExecuteCommand(args ...string) (result Result)

func ExecutePlugin

func ExecutePlugin(config Config, pluginType string, args ...string) (result Result)

func SetResult

func SetResult(code int, messages []Message) Result

func SetResultMessage

func SetResultMessage(code int, level, msg string) Result

type ResultSimple

type ResultSimple struct {
	Code     int      `json:"code,omitempty"`
	Messages []string `json:"messages,omitempty"`
	Data     []string `json:"data,omitempty"`
}

func ExecutePluginSimple

func ExecutePluginSimple(config Config, pluginType string, args ...string) (result ResultSimple)

func SetResultSimple

func SetResultSimple(code int, messages []string) ResultSimple

type Status

type Status struct {
	Msg     string `json:"msg"`
	Version string `json:"version"`
}

type Step

type Step struct {
	Id     int    `json:"id"`
	Status string `json:"status"`
	Label  string `json:"label,omitempty"`
}

func CreateCommentStep

func CreateCommentStep(workflow *Workflow) Step

func CreateStep

func CreateStep(workflow *Workflow) Step

func GetWorkflowSteps

func GetWorkflowSteps(w http.ResponseWriter, r *http.Request) []Step

type StoragePlugin

type StoragePlugin interface {
	SetEnv(Config) Result
	Backup(Config) Result
	Restore(Config) Result
	BackupDelete(Config) Result
	BackupDeleteWorkflow(Config) Result
	Mount(Config) Result
	Unmount(Config) Result
	BackupList(Config) Backups
	Info() Plugin
}

func GetStorageInterface

func GetStorageInterface(path string) (StoragePlugin, error)

type Workflow

type Workflow struct {
	Id          int    `json:"id"`
	Status      string `json:"status"`
	Type        string `json:"type"`
	Policy      string `json:"policy"`
	Timestamp   string `json:"timestamp,omitempty"`
	Steps       []Step `json:"steps,omitempty"`
	LastMessage string `json:"lastMessage,omitempty"`
}

type WorkflowResult

type WorkflowResult struct {
	Id     int    `json:"id"`
	Result Result `json:"result,omitempty"`
}

type WorkflowStatusResult

type WorkflowStatusResult struct {
	Workflow Workflow `json:"workflow,omitempty"`
	Result   Result   `json:"result,omitempty"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL