Documentation ¶
Overview ¶
Package swarming contains utilities for skylab swarming tasks.
Index ¶
- func AddCommonTags(ctx context.Context, ts ...string) []string
- func DimensionsMap(sdims []*swarming.SwarmingRpcsStringListPair) strpair.Map
- func ExtractSingleValuedDimension(dims strpair.Map, key string) (string, error)
- func SetCommonTaskArgs(ctx context.Context, args *clients.SwarmingCreateTaskArgs) *clients.SwarmingCreateTaskArgs
- func URLForTags(ctx context.Context, tags []string) string
- func URLForTask(ctx context.Context, tid string) string
- type BotState
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddCommonTags ¶
AddCommonTags adds some Swarming tags common to all Skylab admin tasks.
func DimensionsMap ¶
func DimensionsMap(sdims []*swarming.SwarmingRpcsStringListPair) strpair.Map
DimensionsMap converts swarming bot dimensions to a map.
func ExtractSingleValuedDimension ¶
ExtractSingleValuedDimension extracts one specified dimension from a dimension slice.
func SetCommonTaskArgs ¶
func SetCommonTaskArgs(ctx context.Context, args *clients.SwarmingCreateTaskArgs) *clients.SwarmingCreateTaskArgs
SetCommonTaskArgs sets Swarming task arguments common to all Skylab admin tasks.
func URLForTags ¶
URLForTags returns the task URL for a given tag list.
Types ¶
type BotState ¶
type BotState struct { StorageState []string `json:"storage_state"` ServoUSBState []string `json:"servo_usb_state"` RpmState []string `json:"rpm_state"` }
BotState represents State of the BOT in the swarming
func ExtractBotState ¶
func ExtractBotState(botInfo *swarming.SwarmingRpcsBotInfo) BotState
ExtractBotState extracts BOTState from BOT info.
Click to show internal directories.
Click to hide internal directories.