commands

package
v0.0.0-...-6700e38 Latest Latest
Warning

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

Go to latest
Published: Feb 24, 2025 License: BSD-3-Clause Imports: 57 Imported by: 0

Documentation

Overview

Package commands contains the definitions for all commands used in CTPv2.

Index

Constants

View Source
const (
	TranslateV1toV2RequestType     interfaces.CommandType = "TranslateV1toV2Request"
	PrepareFilterContainersCmdType interfaces.CommandType = "PrepareFilterContainers"
	FilterExecutionCmdType         interfaces.CommandType = "FilterExecution"
	FilterStopCmdType              interfaces.CommandType = "FilterStop"
	TranslateRequestType           interfaces.CommandType = "TranslateRequest"
	MiddleoutExecutionType         interfaces.CommandType = "MiddleOutExecution"
	ScheduleTasksCmdType           interfaces.CommandType = "ScheduleTasks"
	GenerateTrv2RequestsCmdType    interfaces.CommandType = "GenerateTrv2Requests"
	SummarizeCmdType               interfaces.CommandType = "Summarize"
	AlStatusUpdateCmdType          interfaces.CommandType = "AlStatusUpdate"
	AlStatusCleanUpCmdType         interfaces.CommandType = "AlStatusCleanUp"
)

All supported command types.

View Source
const (
	// This deadline is constructed from various CTP req params that we do not
	// want to depend on for ctpv2. So hardcoding them for now so that they are in
	// one place. And later may move to new input params for ctpv2 or configs if
	// required.
	// TODO (azrahman): revisit this.
	DefaultTimeout = 8 * time.Hour // Intentionally put a large number for now so
	Day            = 24 * time.Hour

	CtpRequestUIDTemplate = "TestPlanRuns/%d/%s"
	DutPoolQuota          = "DUT_POOL_QUOTA"
)
View Source
const (
	TautoTastPrefix = "tauto.tast"
	NoDevicesInt    = math.MinInt32 + 1
	TastPrefix      = "tast"
)

Variables

View Source
var GenerateTrv2ReqCmdLock sync.Mutex

GenerateTrv2ReqCmdLock ensures only one instance of this cmd execution at a time between all async suite. b/377196624 - to avoid bot run oom as this cmd execution is memory intensive.

Functions

func ConvertSwarmingLabelsToDims

func ConvertSwarmingLabelsToDims(defaultDims []string, swarmingLabels []string) []string

ConvertSwarmingLabelsToDims converts provided swarming labels to swarming dims.

func CreateDims

func CreateDims(ctx context.Context, hwInfo *hwInfo, pool string, readycheck bool) []string

CreateDims creates dims list from hwInfo object.

func CtpFilterToContainerInfo

func CtpFilterToContainerInfo(ctpFilter *testapi.CTPFilter, build int) *data.ContainerInfo

CtpFilterToContainerInfo creates container info from provided ctp filter.

func DisplayError

func DisplayError(ctx context.Context, result *data.TestResults, step *build.Step)

func DisplayResult

func DisplayResult(ctx context.Context, key string, resultsList []*data.TestResults) error

func DoesResultBelongToAllRequestsInChain

func DoesResultBelongToAllRequestsInChain(reqChain map[string]string, resultBMVkey string) bool

func FindBuildName

func FindBuildName(suiteInfo *api.SuiteInfo, board string) string

FindBuildName finds build name from suite info.

func FindSchedulingUnit

func FindSchedulingUnit(primary *HwTarget, companions []*HwTarget, schedUnitMetadataMap map[string][]*testapi.SchedulingUnit) *testapi.SchedulingUnit

FindSchedulingUnit matches scheduling targets by board-variant, then attempts to find by model. If the requested target has a model then try to match on model, fall back to match on no model. If no request model, choose first match.

func GenerateArgs

func GenerateArgs(ctx context.Context, trHelper *TrV2ReqHelper) (*request.Args, error)

GenerateArgs generates args for the builder request.

func GenerateNewBuildReqForRetry

func GenerateNewBuildReqForRetry(ctx context.Context, buildReq *data.BuildRequest, retriableTests map[string]bool) *data.BuildRequest

func GenerateTrv2Req

func GenerateTrv2Req(ctx context.Context, canOutliveParent bool, trHelper *TrV2ReqHelper, isLED bool) (*buildbucketpb.ScheduleBuildRequest, error)

GenerateTrv2Req generates ScheduleBuildRequest.

func GetBoardModelVariantKey

func GetBoardModelVariantKey(ctx context.Context, trReq *data.TrRequest) (string, error)

func GetBoardModelVariantKeyFromTarget

func GetBoardModelVariantKeyFromTarget(target *api.Target) string

func GetResultsMapFromList

func GetResultsMapFromList(resultsList []*data.TestResults) map[string][]*data.TestResults

func GroupErrAndNonErrResults

func GroupErrAndNonErrResults(inputMap map[string][]*data.TestResults) ([]string, map[string][]*data.TestResults, []string, map[string][]*data.TestResults)

func IsAnyTautoTastTestCase

func IsAnyTautoTastTestCase(testCases []*api.TestCase_Id) bool

func IsTcRetriable

IsTcRetriable determines if a task result indicates that the test needs to be retried.

Panics on unknown verdicts.

func LogTestCasesIfAny

func LogTestCasesIfAny(ctx context.Context, result *data.TestResults, step *build.Step)

func ProcessResultsMap

func ProcessResultsMap(ctx context.Context, keys []string, resultMap map[string][]*data.TestResults) error

func TargetsToNewTarget

func TargetsToNewTarget(targ *testapi.Targets) *testapi.Target

func ToExecuteResponses

func ToExecuteResponses(testResultMap map[string][]*data.TestResults) *steps.ExecuteResponses

func TrResultToErTaskResult

func TrResultToErTaskResult(testResult *data.TestResults) *steps.ExecuteResponse_TaskResult

Types

type ATPTriggerType

type ATPTriggerType int
const (
	PresubmitBlocking ATPTriggerType = iota
	PresubmitWarn                    // not used yet
	PostsubmitBlocking
	PostsubmitWarn // not used yet
	Cron
)

type AlStatusCleanUpCmd

type AlStatusCleanUpCmd struct {
	*interfaces.AbstractSingleCmdByNoExecutor

	BuildState *build.State

	// Deps
	AlStateInfo *data.AlStateInfo

	ExecutionError error
}

func NewAlStatusCleanUpCmd

func NewAlStatusCleanUpCmd() *AlStatusCleanUpCmd

NewAlStatusCleanUpCmd returns a new AlStatusUpdateCmd

func (*AlStatusCleanUpCmd) Execute

func (cmd *AlStatusCleanUpCmd) Execute(ctx context.Context) error

func (*AlStatusCleanUpCmd) ExtractDependencies

func (cmd *AlStatusCleanUpCmd) ExtractDependencies(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

ExtractDependencies extracts all the command dependencies from state keeper.

func (*AlStatusCleanUpCmd) UpdateStateKeeper

func (cmd *AlStatusCleanUpCmd) UpdateStateKeeper(ctx context.Context, ski interfaces.StateKeeperInterface) error

UpdateStateKeeper updates the state keeper with info from the cmd.

type AlStatusUpdateCmd

type AlStatusUpdateCmd struct {
	*interfaces.AbstractSingleCmdByNoExecutor

	BuildState *build.State

	BuildsMap map[string]*data.BuildRequest

	// Deps
	AlStateInfo *data.AlStateInfo

	// CTPRequest
	CtpRequest *testapi.CTPRequest

	ExecutionError error
	// contains filtered or unexported fields
}

AlStatusUpdateCmd represents al state update cmd.

func NewAlStatusUpdateCmd

func NewAlStatusUpdateCmd() *AlStatusUpdateCmd

NewAlStatusUpdateCmd returns a new AlStatusUpdateCmd

func (*AlStatusUpdateCmd) Execute

func (cmd *AlStatusUpdateCmd) Execute(ctx context.Context) error

Execute executes the command.

func (*AlStatusUpdateCmd) ExtractDependencies

func (cmd *AlStatusUpdateCmd) ExtractDependencies(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

ExtractDependencies extracts all the command dependencies from state keeper.

func (*AlStatusUpdateCmd) UpdateStateKeeper

func (cmd *AlStatusUpdateCmd) UpdateStateKeeper(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

UpdateStateKeeper updates the state keeper with info from the cmd.

type FilterExecutionCmd

type FilterExecutionCmd struct {
	*interfaces.SingleCmdByExecutor

	// Deps
	InputTestPlan *testapi.InternalTestplan
	ContainerInfo *data.ContainerInfo

	// Updates
	OutputTestPlan *testapi.InternalTestplan

	BuildState *build.State

	// Logging
	BQClient *bigquery.Client
}

FilterExecutionCmd represents test execution cmd.

func NewFilterExecutionCmd

func NewFilterExecutionCmd(executor interfaces.ExecutorInterface) *FilterExecutionCmd

func (*FilterExecutionCmd) ExtractDependencies

func (cmd *FilterExecutionCmd) ExtractDependencies(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

ExtractDependencies extracts all the command dependencies from state keeper.

func (*FilterExecutionCmd) UpdateStateKeeper

func (cmd *FilterExecutionCmd) UpdateStateKeeper(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

UpdateStateKeeper updates the state keeper with info from the cmd.

type GenerateTrv2RequestsCmd

type GenerateTrv2RequestsCmd struct {
	*interfaces.AbstractSingleCmdByNoExecutor

	// Deps
	MiddledOutResp   *data.MiddleOutResponse
	BuildState       *build.State
	Scheduler        interfaces.SchedulerInterface
	DynamicRun       bool
	InternalTestPlan *api.InternalTestplan
	Config           *config.Config
	RequestKey       string
	CredentialsFile  string
	IsAlRun          bool
	IsPartnerRun     bool
	// EnvVersion denotes whether the environment
	// is prod or something else.
	EnvVersion      string
	FirestoreDBName string

	// Updates
	BuildsMap   map[string]*data.BuildRequest
	TestResults map[string]*data.TestResults
	AlStateInfo *data.AlStateInfo // will be used as dep as well

	// For logging
	BQClient          *bigquery.Client
	StartCmdTime      time.Time
	StartTrReqGenTime time.Time
	DynamicExperiment bool

	TrReqsStart []*analytics.TaskData
	TrReqsEnd   []*analytics.TaskData

	ExecutionError error
	// contains filtered or unexported fields
}

GenerateTrv2RequestsCmd represents scheduling task(s) cmd.

func NewGenerateTrv2RequestsCmd

func NewGenerateTrv2RequestsCmd() *GenerateTrv2RequestsCmd

func (*GenerateTrv2RequestsCmd) Execute

func (cmd *GenerateTrv2RequestsCmd) Execute(ctx context.Context) error

Execute executes the command.

func (*GenerateTrv2RequestsCmd) ExtractDependencies

func (cmd *GenerateTrv2RequestsCmd) ExtractDependencies(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

ExtractDependencies extracts all the command dependencies from state keeper.

func (*GenerateTrv2RequestsCmd) GenerateReq

func (cmd *GenerateTrv2RequestsCmd) GenerateReq(ctx context.Context, trReq *data.TrRequest, key string, shardNum int) (*buildbucketpb.ScheduleBuildRequest, error)

func (*GenerateTrv2RequestsCmd) GenerateRequests

func (cmd *GenerateTrv2RequestsCmd) GenerateRequests(ctx context.Context, step *build.Step) (map[string]*data.BuildRequest, error)

GenerateRequests generates trv2 requests

func (*GenerateTrv2RequestsCmd) ObserveCmdEndFailure

func (cmd *GenerateTrv2RequestsCmd) ObserveCmdEndFailure(ctx context.Context)

func (*GenerateTrv2RequestsCmd) ObserveCmdEndSuccess

func (cmd *GenerateTrv2RequestsCmd) ObserveCmdEndSuccess(ctx context.Context)

func (*GenerateTrv2RequestsCmd) ObserveCmdStart

func (cmd *GenerateTrv2RequestsCmd) ObserveCmdStart(ctx context.Context)

func (*GenerateTrv2RequestsCmd) ObserveEnumerationFailure

func (cmd *GenerateTrv2RequestsCmd) ObserveEnumerationFailure(ctx context.Context)

func (*GenerateTrv2RequestsCmd) ObserveEnumerationStart

func (cmd *GenerateTrv2RequestsCmd) ObserveEnumerationStart(ctx context.Context)

func (*GenerateTrv2RequestsCmd) ObserveEnumerationSuccess

func (cmd *GenerateTrv2RequestsCmd) ObserveEnumerationSuccess(ctx context.Context)

func (*GenerateTrv2RequestsCmd) ObserveTrReqGenFail

func (cmd *GenerateTrv2RequestsCmd) ObserveTrReqGenFail(ctx context.Context, req *data.TrRequest, key string, err string)

func (*GenerateTrv2RequestsCmd) ObserveTrReqGenStart

func (cmd *GenerateTrv2RequestsCmd) ObserveTrReqGenStart(ctx context.Context, req *data.TrRequest, key string)

func (*GenerateTrv2RequestsCmd) ObserveTrReqGenSuccess

func (cmd *GenerateTrv2RequestsCmd) ObserveTrReqGenSuccess(ctx context.Context, req *data.TrRequest, key string)

func (*GenerateTrv2RequestsCmd) ProcessEnumError

func (cmd *GenerateTrv2RequestsCmd) ProcessEnumError(ctx context.Context, step *build.Step) error

ProcessEnumError processes enum error

func (*GenerateTrv2RequestsCmd) SealTrReqGenEnd

func (cmd *GenerateTrv2RequestsCmd) SealTrReqGenEnd(ctx context.Context)

func (*GenerateTrv2RequestsCmd) SealTrReqGenStart

func (cmd *GenerateTrv2RequestsCmd) SealTrReqGenStart(ctx context.Context)

func (*GenerateTrv2RequestsCmd) UpdateStateKeeper

func (cmd *GenerateTrv2RequestsCmd) UpdateStateKeeper(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

UpdateStateKeeper updates the state keeper with info from the cmd.

type HwTarget

type HwTarget struct {
	// contains filtered or unexported fields
}

func FakeHwTarget

func FakeHwTarget(board, model, variant string) *HwTarget

FakeHwTarget is for testing since fields are private.

type MiddleOutRequestCmd

type MiddleOutRequestCmd struct {
	*interfaces.AbstractSingleCmdByNoExecutor

	// Deps
	InternalTestPlan *api.InternalTestplan

	// Updates
	MiddledOutResp *data.MiddleOutResponse

	// BQ client for logging
	BQClient *bigquery.Client
	// BuildState
	BuildState *build.State

	ExecutionError error

	DurationBasedSharding bool
}

MiddleOutRequestCmd represents middle out command.

func NewMiddleOutRequestCmd

func NewMiddleOutRequestCmd() *MiddleOutRequestCmd

func (*MiddleOutRequestCmd) Execute

func (cmd *MiddleOutRequestCmd) Execute(ctx context.Context) error

Execute executes the command.

func (*MiddleOutRequestCmd) ExtractDependencies

func (cmd *MiddleOutRequestCmd) ExtractDependencies(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

ExtractDependencies (Boiler plate)

func (*MiddleOutRequestCmd) UpdateStateKeeper

func (cmd *MiddleOutRequestCmd) UpdateStateKeeper(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

UpdateStateKeeper (Boiler plate)

type PrepareFilterContainersInfoCmd

type PrepareFilterContainersInfoCmd struct {
	*interfaces.AbstractSingleCmdByNoExecutor

	// Deps
	CtpReq       *testapi.CTPRequest
	CredsFile    string
	CTPversion   string
	Environment  string
	Experiments  []string
	IsAlRun      bool
	IsPartnerRun bool
	// Updates
	ContainerInfoQueue   *list.List
	ContainerMetadataMap map[string]*buildapi.ContainerImageInfo
}

PrepareFilterContainersInfoCmd represents prepare filter containers info cmd.

func NewPrepareFilterContainersInfoCmd

func NewPrepareFilterContainersInfoCmd() *PrepareFilterContainersInfoCmd

func (*PrepareFilterContainersInfoCmd) Execute

Execute executes the command.

func (*PrepareFilterContainersInfoCmd) ExtractDependencies

ExtractDependencies extracts all the command dependencies from state keeper.

func (*PrepareFilterContainersInfoCmd) UpdateStateKeeper

UpdateStateKeeper updates the state keeper with info from the cmd.

type ScheduleTasksCmd

type ScheduleTasksCmd struct {
	*interfaces.AbstractSingleCmdByNoExecutor

	// Deps
	BuildState      *build.State
	Scheduler       interfaces.SchedulerInterface
	DynamicRun      bool
	CredentialsFile string
	// EnvVersion denotes whether the environment
	// is prod or something else.
	EnvVersion      string
	FirestoreDBName string

	// Deps
	InternalTestPlan *api.InternalTestplan
	BuildsMap        map[string]*data.BuildRequest
	RequestKey       string
	IsAlRun          bool

	// Updates
	TestResults map[string]*data.TestResults
	AlStateInfo *data.AlStateInfo // will be used as dep as well

	// For logging
	BQClient     *bigquery.Client
	StartCmdTime time.Time
	Config       *config.Config

	ExecutionError error
}

ScheduleTasksCmd represents scheduling task(s) cmd.

func NewScheduleTasksCmd

func NewScheduleTasksCmd() *ScheduleTasksCmd

func (*ScheduleTasksCmd) Execute

func (cmd *ScheduleTasksCmd) Execute(ctx context.Context) error

Execute executes the command.

func (*ScheduleTasksCmd) ExtractDependencies

func (cmd *ScheduleTasksCmd) ExtractDependencies(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

ExtractDependencies extracts all the command dependencies from state keeper.

func (*ScheduleTasksCmd) GenerateReqForRetry

func (cmd *ScheduleTasksCmd) GenerateReqForRetry(ctx context.Context, buildReq *data.BuildRequest) (*buildbucketpb.ScheduleBuildRequest, error)

func (*ScheduleTasksCmd) ObserveCmdEndSuccess

func (cmd *ScheduleTasksCmd) ObserveCmdEndSuccess(ctx context.Context)

func (*ScheduleTasksCmd) ObserveCmdStart

func (cmd *ScheduleTasksCmd) ObserveCmdStart(ctx context.Context)

func (*ScheduleTasksCmd) ObserveSchedulerSetupFailure

func (cmd *ScheduleTasksCmd) ObserveSchedulerSetupFailure(ctx context.Context, err string)

func (*ScheduleTasksCmd) ObserveSchedulerSetupSuccess

func (cmd *ScheduleTasksCmd) ObserveSchedulerSetupSuccess(ctx context.Context)

func (*ScheduleTasksCmd) ObserveTrBuildFail

func (cmd *ScheduleTasksCmd) ObserveTrBuildFail(ctx context.Context, buildReq *data.BuildRequest, err string, start time.Time)

func (*ScheduleTasksCmd) ObserveTrBuildStart

func (cmd *ScheduleTasksCmd) ObserveTrBuildStart(ctx context.Context, buildReq *data.BuildRequest)

func (*ScheduleTasksCmd) ObserveTrBuildSuccess

func (cmd *ScheduleTasksCmd) ObserveTrBuildSuccess(ctx context.Context, buildReq *data.BuildRequest, buildInfo *buildbucketpb.Build, start time.Time)

func (*ScheduleTasksCmd) ObserveTrSchedulingFail

func (cmd *ScheduleTasksCmd) ObserveTrSchedulingFail(ctx context.Context, buildReq *data.BuildRequest, err string, start time.Time)

func (*ScheduleTasksCmd) ObserveTrSchedulingStart

func (cmd *ScheduleTasksCmd) ObserveTrSchedulingStart(ctx context.Context, buildReq *data.BuildRequest)

func (*ScheduleTasksCmd) ObserveTrSchedulingSuccess

func (cmd *ScheduleTasksCmd) ObserveTrSchedulingSuccess(ctx context.Context, buildReq *data.BuildRequest, taskBBId string, start time.Time)

func (*ScheduleTasksCmd) RetryReqIfQualifies

func (cmd *ScheduleTasksCmd) RetryReqIfQualifies(ctx context.Context, trResult *skylab_test_runner.Result, step *build.Step, buildReq *data.BuildRequest) *data.BuildRequest

func (*ScheduleTasksCmd) ScheduleAndMonitor

func (cmd *ScheduleTasksCmd) ScheduleAndMonitor(rootCtx context.Context, key string, buildReq *data.BuildRequest, wg *sync.WaitGroup, resultsChan chan<- *data.TestResults, retryNum int, dmc *dm.Client, buildsMapLen int, bbClient buildbucketpb.BuildsClient)

func (*ScheduleTasksCmd) UpdateStateKeeper

func (cmd *ScheduleTasksCmd) UpdateStateKeeper(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

UpdateStateKeeper updates the state keeper with info from the cmd.

type SummarizeCmd

type SummarizeCmd struct {
	*interfaces.AbstractSingleCmdByNoExecutor

	// Deps
	AllTestResults          map[string][]*data.TestResults
	RequestToTargetChainMap map[string]map[string]string
	DddTrackerMap           map[string]bool

	// Updates
	ExecuteResponses *steps.ExecuteResponses

	AlStateInfo *data.AlStateInfo
	BuildState  *build.State
}

SummarizeCmd represents summarizing of all test results cmd.

func NewSummarizeCmd

func NewSummarizeCmd() *SummarizeCmd

NewSummarizeCmd returns a new SummarizeCmd

func (*SummarizeCmd) AttachATILinkIfApplicable

func (cmd *SummarizeCmd) AttachATILinkIfApplicable(step *build.Step)

AttachATILinkIfApplicable adds an ATI link to step, If we are in an AL run and have an invocation attached link to the ATI page.

func (*SummarizeCmd) DisplaySuite

func (cmd *SummarizeCmd) DisplaySuite(ctx context.Context, suite string) error

func (*SummarizeCmd) Execute

func (cmd *SummarizeCmd) Execute(ctx context.Context) error

Execute executes the command.

func (*SummarizeCmd) ExtractDependencies

func (cmd *SummarizeCmd) ExtractDependencies(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

ExtractDependencies extracts all the command dependencies from state keeper.

func (*SummarizeCmd) RestructureResultsMap

func (cmd *SummarizeCmd) RestructureResultsMap(testResultMap map[string][]*data.TestResults) (map[string][]*data.TestResults, error)

func (*SummarizeCmd) UpdateStateKeeper

func (cmd *SummarizeCmd) UpdateStateKeeper(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

UpdateStateKeeper updates the state keeper with info from the cmd.

type TrV2ReqHelper

type TrV2ReqHelper struct {
	// contains filtered or unexported fields
}

type TranslateRequestCmd

type TranslateRequestCmd struct {
	*interfaces.AbstractSingleCmdByNoExecutor

	// Deps
	CtpReq     *testapi.CTPRequest
	RequestKey string
	IsAlRun    bool

	// Updates
	InternalTestPlan *testapi.InternalTestplan
	TestResults      map[string]*data.TestResults

	ExecutionError error
	IsPartnerRun   bool
}

TranslateRequestCmd represents translate command

func NewTranslateRequestCmd

func NewTranslateRequestCmd() *TranslateRequestCmd

func (*TranslateRequestCmd) Execute

func (cmd *TranslateRequestCmd) Execute(ctx context.Context) error

Execute executes the command.

func (*TranslateRequestCmd) ExtractDependencies

func (cmd *TranslateRequestCmd) ExtractDependencies(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

ExtractDependencies extracts all the command dependencies from state keeper.

func (*TranslateRequestCmd) UpdateStateKeeper

func (cmd *TranslateRequestCmd) UpdateStateKeeper(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

UpdateStateKeeper updates the state keeper with info from the cmd.

type TranslateV1ToV2Cmd

type TranslateV1ToV2Cmd struct {
	*interfaces.AbstractSingleCmdByNoExecutor

	// Deps
	CtpV1Requests map[string]*test_platform.Request
	CtpV2Request  *api.CTPv2Request // This will be updated if isn't set by deps
	BuildState    *build.State

	// Updates
	RequestToTargetChainMap map[string]map[string]string
	CtpV2RequestMap         map[string]*api.CTPRequest
	DddTrackerMap           map[string]bool

	AlStateInfo *data.AlStateInfo

	IsPartnerRun bool
}

TranslateV1ToV2Cmd represents v1 to v2 translation cmd.

func NewTranslateV1toV2Cmd

func NewTranslateV1toV2Cmd() *TranslateV1ToV2Cmd

NewTranslateV1toV2Cmd returns a new TranslateV1ToV2Cmd

func (*TranslateV1ToV2Cmd) CreateKeyToBMVTargetChain

func (cmd *TranslateV1ToV2Cmd) CreateKeyToBMVTargetChain(v1KeysMap map[string]string, requestChainMap map[string][]string) map[string]map[string]string

func (*TranslateV1ToV2Cmd) CreateKeysForEachV1Request

func (cmd *TranslateV1ToV2Cmd) CreateKeysForEachV1Request() map[string]string

func (*TranslateV1ToV2Cmd) Execute

func (cmd *TranslateV1ToV2Cmd) Execute(ctx context.Context) error

Execute executes the command.

func (*TranslateV1ToV2Cmd) ExtractDependencies

func (cmd *TranslateV1ToV2Cmd) ExtractDependencies(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

ExtractDependencies extracts all the command dependencies from state keeper.

func (*TranslateV1ToV2Cmd) UpdateStateKeeper

func (cmd *TranslateV1ToV2Cmd) UpdateStateKeeper(
	ctx context.Context,
	ski interfaces.StateKeeperInterface) error

UpdateStateKeeper updates the state keeper with info from the cmd.

Jump to

Keyboard shortcuts

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