Documentation ¶
Index ¶
- Constants
- func AdminAddOrUpdateRemoteCluster(c *cli.Context)
- func AdminAddSearchAttributes(c *cli.Context)
- func AdminDBClean(c *cli.Context)
- func AdminDBScan(c *cli.Context)
- func AdminDecodeBase64(c *cli.Context)
- func AdminDecodeProto(c *cli.Context)
- func AdminDeleteWorkflow(c *cli.Context)
- func AdminDescribeCluster(c *cli.Context)
- func AdminDescribeHistoryHost(c *cli.Context)
- func AdminDescribeShard(c *cli.Context)
- func AdminDescribeTask(c *cli.Context)
- func AdminDescribeTaskQueue(c *cli.Context)
- func AdminDescribeWorkflow(c *cli.Context)
- func AdminGetDLQMessages(c *cli.Context)
- func AdminGetSearchAttributes(c *cli.Context)
- func AdminGetShardID(c *cli.Context)
- func AdminListClusterMembers(c *cli.Context)
- func AdminListGossipMembers(c *cli.Context)
- func AdminListShardTasks(c *cli.Context)
- func AdminListTaskQueueTasks(c *cli.Context)
- func AdminMergeDLQMessages(c *cli.Context)
- func AdminPurgeDLQMessages(c *cli.Context)
- func AdminRefreshWorkflowTasks(c *cli.Context)
- func AdminRemoveRemoteCluster(c *cli.Context)
- func AdminRemoveSearchAttributes(c *cli.Context)
- func AdminRemoveTask(c *cli.Context)
- func AdminShardManagement(c *cli.Context)
- func AdminShowWorkflow(c *cli.Context)
- func CancelWorkflow(c *cli.Context)
- func ColorEvent(e *historypb.HistoryEvent) string
- func CompleteActivity(c *cli.Context)
- func CountWorkflow(c *cli.Context)
- func CreateDefaultDBConfig(c *cli.Context) (config.DataStore, error)
- func CreatePersistenceFactory(c *cli.Context) persistenceClient.Factory
- func DataConverter(c *cli.Context)
- func DescribeBatchJob(c *cli.Context)
- func DescribeTaskQueue(c *cli.Context)
- func DescribeWorkflow(c *cli.Context)
- func DescribeWorkflowWithID(c *cli.Context)
- func ErrorAndExit(msg string, err error)
- func FailActivity(c *cli.Context)
- func GetHistory(ctx context.Context, workflowClient sdkclient.Client, workflowID, runID string) (*historypb.History, error)
- func GetQPS(...dynamicconfig.FilterOption) int
- func GetSearchAttributes(c *cli.Context)
- func HealthCheck(c *cli.Context)
- func HistoryEventToString(e *historypb.HistoryEvent, printFully bool, maxFieldLength int) string
- func ListAllWorkflow(c *cli.Context)
- func ListArchivedWorkflow(c *cli.Context)
- func ListBatchJobs(c *cli.Context)
- func ListTaskQueuePartitions(c *cli.Context)
- func ListWorkflow(c *cli.Context)
- func NewCliApp() *cli.App
- func ObserveHistory(c *cli.Context)
- func ObserveHistoryWithID(c *cli.Context)
- func QueryWorkflow(c *cli.Context)
- func QueryWorkflowUsingStackTrace(c *cli.Context)
- func ResetInBatch(c *cli.Context)
- func ResetWorkflow(c *cli.Context)
- func RunWorkflow(c *cli.Context)
- func ScanAllWorkflow(c *cli.Context)
- func SetFactory(factory ClientFactory)
- func SetRequiredNamespaceDataKeys(keys []string)
- func ShowHistory(c *cli.Context)
- func ShowHistoryWithWID(c *cli.Context)
- func SignalWorkflow(c *cli.Context)
- func StartBatchJob(c *cli.Context)
- func StartWorkflow(c *cli.Context)
- func TerminateBatchJob(c *cli.Context)
- func TerminateWorkflow(c *cli.Context)
- type BufferedWriter
- type CleanOutputDirectories
- type CleanProgressReport
- type ClientFactory
- type CorruptedExceptionMetadata
- type CorruptedExecution
- type CorruptionType
- type CorruptionTypeBreakdown
- type ExecutionCheckFailure
- type HttpGetter
- type PayloadRequest
- type PayloadResponse
- type ProgressReport
- type Rates
- type ScanOutputDirectories
- type ShardCleanOutputFiles
- type ShardCleanReport
- type ShardCleanReportFailure
- type ShardCleanReportHandled
- type ShardExecutionCountsDistribution
- type ShardScanOutputFiles
- type ShardScanReport
- type ShardScanReportExecutionsScanned
- type ShardScanReportFailure
- type VerificationResult
Constants ¶
const ( // HistoryMissing is the CorruptionType indicating that history is missing HistoryMissing CorruptionType = "history_missing" // InvalidFirstEvent is the CorruptionType indicating that the first event is invalid InvalidFirstEvent = "invalid_first_event" // OpenExecutionInvalidCurrentExecution is the CorruptionType that indicates there is an orphan concrete execution OpenExecutionInvalidCurrentExecution = "open_execution_invalid_current_execution" CorruptActivityIdPresent = "corrupt_activity_id_present" )
const ( FlagUsername = "username" FlagPassword = "password" FlagKeyspace = "keyspace" FlagAddress = "address" FlagAddressWithAlias = FlagAddress + ", ad" FlagDBEngine = "db_engine" FlagDBAddress = "db_address" FlagDBPort = "db_port" FlagHistoryAddress = "history_address" FlagHistoryAddressWithAlias = FlagHistoryAddress + ", had" FlagFrontendAddress = "frontend_address" FlagFrontendAddressWithAlias = FlagFrontendAddress + ", fad" FlagNamespaceID = "namespace_id" FlagNamespace = "namespace" FlagNamespaceWithAlias = FlagNamespace + ", ns" FlagShardID = "shard_id" FlagShardIDWithAlias = FlagShardID + ", sid" FlagWorkflowID = "workflow_id" FlagWorkflowIDWithAlias = FlagWorkflowID + ", wid, w" FlagRunID = "run_id" FlagTreeID = "tree_id" FlagBranchID = "branch_id" FlagNumberOfShards = "number_of_shards" FlagRunIDWithAlias = FlagRunID + ", rid, r" FlagTargetCluster = "target_cluster" FlagMinEventID = "min_event_id" FlagMaxEventID = "max_event_id" FlagMinEventVersion = "min_event_version" FlagMaxEventVersion = "max_event_version" FlagTaskQueue = "taskqueue" FlagTaskQueueWithAlias = FlagTaskQueue + ", tq" FlagTaskQueueType = "taskqueuetype" FlagTaskQueueTypeWithAlias = FlagTaskQueueType + ", tqt" FlagWorkflowIDReusePolicy = "workflowidreusepolicy" FlagWorkflowIDReusePolicyAlias = FlagWorkflowIDReusePolicy + ", wrp" FlagCronSchedule = "cron" FlagWorkflowType = "workflow_type" FlagWorkflowTypeWithAlias = FlagWorkflowType + ", wt" FlagWorkflowStatus = "status" FlagWorkflowStatusWithAlias = FlagWorkflowStatus + ", s" FlagWorkflowExecutionTimeout = "execution_timeout" FlagWorkflowExecutionTimeoutWithAlias = FlagWorkflowExecutionTimeout + ", et" FlagWorkflowRunTimeout = "run-timeout" FlagWorkflowRunTimeoutWithAlias = FlagWorkflowRunTimeout + ", rt" FlagWorkflowTaskTimeout = "workflow_task_timeout" FlagWorkflowTaskTimeoutWithAlias = FlagWorkflowTaskTimeout + ", wtt" FlagContextTimeout = "context_timeout" FlagContextTimeoutWithAlias = FlagContextTimeout + ", ct" FlagInput = "input" FlagInputWithAlias = FlagInput + ", i" FlagInputFile = "input_file" FlagInputFileWithAlias = FlagInputFile + ", if" FlagExcludeFile = "exclude_file" FlagInputSeparator = "input_separator" FlagParallism = "input_parallism" FlagSkipCurrentOpen = "skip_current_open" FlagSkipBaseIsNotCurrent = "skip_base_is_not_current" FlagDryRun = "dry_run" FlagNonDeterministicOnly = "only_non_deterministic" FlagCluster = "cluster" FlagResult = "result" FlagIdentity = "identity" FlagDetail = "detail" FlagReason = "reason" FlagReasonWithAlias = FlagReason + ", re" FlagOpen = "open" FlagOpenWithAlias = FlagOpen + ", op" FlagMore = "more" FlagMoreWithAlias = FlagMore + ", m" FlagAll = "all" FlagAllWithAlias = FlagAll + ", a" FlagPageSize = "pagesize" FlagPageSizeWithAlias = FlagPageSize + ", ps" FlagEarliestTime = "earliest_time" FlagEarliestTimeWithAlias = FlagEarliestTime + ", et" FlagLatestTime = "latest_time" FlagLatestTimeWithAlias = FlagLatestTime + ", lt" FlagPrintEventVersion = "print_event_version" FlagPrintEventVersionWithAlias = FlagPrintEventVersion + ", pev" FlagPrintFullyDetail = "print_full" FlagPrintFullyDetailWithAlias = FlagPrintFullyDetail + ", pf" FlagPrintRawTime = "print_raw_time" FlagPrintRawTimeWithAlias = FlagPrintRawTime + ", prt" FlagPrintRaw = "print_raw" FlagPrintRawWithAlias = FlagPrintRaw + ", praw" FlagPrintDateTime = "print_datetime" FlagPrintDateTimeWithAlias = FlagPrintDateTime + ", pdt" FlagPrintMemo = "print_memo" FlagPrintMemoWithAlias = FlagPrintMemo + ", pme" FlagPrintSearchAttr = "print_search_attr" FlagPrintSearchAttrWithAlias = FlagPrintSearchAttr + ", psa" FlagPrintJSON = "print_json" FlagPrintJSONWithAlias = FlagPrintJSON + ", pjson" FlagDescription = "description" FlagDescriptionWithAlias = FlagDescription + ", desc" FlagOwnerEmail = "owner_email" FlagOwnerEmailWithAlias = FlagOwnerEmail + ", oe" FlagRetention = "retention" FlagRetentionWithAlias = FlagRetention + ", rd" FlagHistoryArchivalState = "history_archival_state" FlagHistoryArchivalStateWithAlias = FlagHistoryArchivalState + ", has" FlagHistoryArchivalURI = "history_uri" FlagHistoryArchivalURIWithAlias = FlagHistoryArchivalURI + ", huri" FlagHeartbeatedWithin = "heartbeated_within" FlagVisibilityArchivalState = "visibility_archival_state" FlagVisibilityArchivalStateWithAlias = FlagVisibilityArchivalState + ", vas" FlagVisibilityArchivalURI = "visibility_uri" FlagVisibilityArchivalURIWithAlias = FlagVisibilityArchivalURI + ", vuri" FlagName = "name" FlagNameWithAlias = FlagName + ", n" FlagOutputFilename = "output_filename" FlagOutputFilenameWithAlias = FlagOutputFilename + ", of" FlagOutputFormat = "output" FlagQueryType = "query_type" FlagQueryTypeWithAlias = FlagQueryType + ", qt" FlagQueryRejectCondition = "query_reject_condition" FlagQueryRejectConditionWithAlias = FlagQueryRejectCondition + ", qrc" FlagShowDetail = "show_detail" FlagShowDetailWithAlias = FlagShowDetail + ", sd" FlagActiveClusterName = "active_cluster" FlagActiveClusterNameWithAlias = FlagActiveClusterName + ", ac" FlagClusters = "clusters" FlagClustersWithAlias = FlagClusters + ", cl" FlagClusterMembershipRole = "role" FlagIsGlobalNamespace = "global_namespace" FlagIsGlobalNamespaceWithAlias = FlagIsGlobalNamespace + ", gd" FlagPromoteNamespace = "promote_namespace" FlagPromoteNamespaceWithAlias = FlagPromoteNamespace + ", pn" FlagNamespaceData = "namespace_data" FlagNamespaceDataWithAlias = FlagNamespaceData + ", dmd" FlagEventID = "event_id" FlagEventIDWithAlias = FlagEventID + ", eid" FlagActivityID = "activity_id" FlagActivityIDWithAlias = FlagActivityID + ", aid" FlagMaxFieldLength = "max_field_length" FlagMaxFieldLengthWithAlias = FlagMaxFieldLength + ", maxl" FlagSkipErrorMode = "skip_errors" FlagSkipErrorModeWithAlias = FlagSkipErrorMode + ", serr" FlagElasticsearchURL = "url" FlagElasticsearchUsername = "es-username" FlagElasticsearchPassword = "es-password" FlagElasticsearchIndex = "index" FlagMemoKey = "memo_key" FlagMemo = "memo" FlagMemoFile = "memo_file" FlagSearchAttributeKey = "search_attr_key" FlagSearchAttributeValue = "search_attr_value" FlagAddBadBinary = "add_bad_binary" FlagRemoveBadBinary = "remove_bad_binary" FlagResetType = "reset_type" FlagResetReapplyType = "reset_reapply_type" FlagResetPointsOnly = "reset_points_only" FlagResetBadBinaryChecksum = "reset_bad_binary_checksum" FlagListQuery = "query" FlagListQueryWithAlias = FlagListQuery + ", q" FlagBatchType = "batch_type" FlagBatchTypeWithAlias = FlagBatchType + ", bt" FlagSignalName = "signal_name" FlagSignalNameWithAlias = FlagSignalName + ", sig" FlagTaskID = "task_id" FlagTaskType = "task_type" FlagMinTaskID = "min_task_id" FlagMaxTaskID = "max_task_id" FlagTaskVisibilityTimestamp = "task_timestamp" FlagMinVisibilityTimestamp = "min_visibility_ts" FlagMaxVisibilityTimestamp = "max_visibility_ts" FlagStartingRPS = "starting_rps" FlagRPS = "rps" FlagJobID = "job_id" FlagJobIDWithAlias = FlagJobID + ", jid" FlagYes = "yes" FlagServiceConfigDir = "service_config_dir" FlagServiceConfigDirWithAlias = FlagServiceConfigDir + ", scd" FlagServiceEnv = "service_env" FlagServiceEnvWithAlias = FlagServiceEnv + ", se" FlagServiceZone = "service_zone" FlagServiceZoneWithAlias = FlagServiceZone + ", sz" FlagEnableTLS = "tls" FlagTLSCertPath = "tls_cert_path" FlagTLSKeyPath = "tls_key_path" FlagTLSCaPath = "tls_ca_path" FlagTLSDisableHostVerification = "tls_disable_host_verification" FlagTLSServerName = "tls_server_name" FlagTLSRootCaData = "tls_ca_data" FlagTLSForceEnable = "tls_force_enable" FlagDLQType = "dlq_type" FlagDLQTypeWithAlias = FlagDLQType + ", dt" FlagMaxMessageCount = "max_message_count" FlagMaxMessageCountWithAlias = FlagMaxMessageCount + ", mmc" FlagLastMessageID = "last_message_id" FlagConcurrency = "concurrency" FlagReportRate = "report_rate" FlagLowerShardBound = "lower_shard_bound" FlagUpperShardBound = "upper_shard_bound" FlagInputDirectory = "input_directory" FlagAutoConfirm = "auto_confirm" FlagDataConverterPlugin = "data_converter_plugin" FlagDataConverterPluginWithAlias = FlagDataConverterPlugin + ", dcp" FlagWebURL = "web_ui_url" FlagHeadersProviderPlugin = "headers_provider_plugin" FlagHeadersProviderPluginWithAlias = FlagHeadersProviderPlugin + ", hpp" FlagHeadersProviderPluginOptions = "headers_provider_plugin_options" FlagHeadersProviderPluginOptionsWithAlias = FlagHeadersProviderPluginOptions + ", hppo" FlagType = "type" FlagTypeWithAlias = FlagType + ", t" FlagVersion = "version" FlagPort = "port" FlagConnectionEnable = "enable_connection" FlagConnectionEnableWithAlias = FlagConnectionEnable + ", ec" FlagProtoType = "type" FlagHexData = "hex_data" FlagHexFile = "hex_file" FlagBinaryFile = "binary_file" FlagBase64Data = "base64_data" FlagBase64File = "base64_file" FlagSkipSchemaUpdate = "skip-schema-update" )
Flags used to specify cli command line arguments
Variables ¶
This section is empty.
Functions ¶
func AdminAddOrUpdateRemoteCluster ¶ added in v1.14.0
AdminAddOrUpdateRemoteCluster is used to add or update remote cluster information
func AdminAddSearchAttributes ¶ added in v1.10.0
AdminAddSearchAttributes to add search attributes
func AdminDBClean ¶ added in v0.27.0
AdminDBClean is the command to clean up executions
func AdminDBScan ¶ added in v0.27.0
AdminDBScan is used to scan over all executions in database and detect corruptions
func AdminDecodeBase64 ¶ added in v1.5.7
func AdminDecodeProto ¶ added in v1.5.7
func AdminDeleteWorkflow ¶ added in v0.5.0
AdminDeleteWorkflow delete a workflow execution from Cassandra and visibility document from Elasticsearch.
func AdminDescribeCluster ¶ added in v0.27.0
AdminDescribeCluster is used to dump information about the cluster
func AdminDescribeHistoryHost ¶ added in v0.3.13
AdminDescribeHistoryHost describes history host
func AdminDescribeShard ¶ added in v0.27.0
AdminDescribeShard describes shard by shard id
func AdminDescribeTask ¶ added in v0.27.0
AdminDescribeTask outputs the details of a task given Task Id, Task Type, Shard Id and Visibility Timestamp
func AdminDescribeTaskQueue ¶ added in v0.27.0
AdminDescribeTaskQueue displays poller and status information of task queue.
func AdminDescribeWorkflow ¶ added in v0.3.13
AdminDescribeWorkflow describe a new workflow execution for admin
func AdminGetDLQMessages ¶ added in v0.27.0
AdminGetDLQMessages gets DLQ metadata
func AdminGetSearchAttributes ¶ added in v1.10.0
AdminGetSearchAttributes to print search attributes
func AdminGetShardID ¶ added in v0.5.0
AdminGetShardID get shardID
func AdminListClusterMembers ¶ added in v1.14.0
AdminListClusterMembers outputs a list of cluster members
func AdminListGossipMembers ¶ added in v0.27.0
AdminListGossipMembers outputs a list of gossip members
func AdminListShardTasks ¶ added in v1.14.0
AdminListShardTasks outputs a list of a tasks for given Shard and Task Category
func AdminListTaskQueueTasks ¶ added in v0.27.0
AdminListTaskQueueTasks displays task information
func AdminMergeDLQMessages ¶ added in v0.27.0
AdminMergeDLQMessages merges message from DLQ
func AdminPurgeDLQMessages ¶ added in v0.27.0
AdminPurgeDLQMessages deletes messages from DLQ
func AdminRefreshWorkflowTasks ¶ added in v0.27.0
AdminRefreshWorkflowTasks refreshes all the tasks of a workflow
func AdminRemoveRemoteCluster ¶ added in v1.14.0
AdminRemoveRemoteCluster is used to remove remote cluster information from the cluster
func AdminRemoveSearchAttributes ¶ added in v1.11.0
AdminRemoveSearchAttributes to add search attributes
func AdminRemoveTask ¶ added in v0.27.0
AdminRemoveTask describes history host
func AdminShardManagement ¶ added in v0.27.0
AdminShardManagement describes history host
func AdminShowWorkflow ¶ added in v0.5.0
AdminShowWorkflow shows history
func CancelWorkflow ¶
CancelWorkflow cancels a workflow execution
func ColorEvent ¶ added in v0.3.11
func ColorEvent(e *historypb.HistoryEvent) string
ColorEvent takes an event and return string with color Event with color mapping rules:
Failed - red Timeout - yellow Canceled - magenta Completed - green Started - blue Others - default (white/black)
func CompleteActivity ¶ added in v0.5.7
CompleteActivity completes an activity
func CountWorkflow ¶ added in v0.6.0
CountWorkflow count number of workflows
func CreateDefaultDBConfig ¶ added in v0.27.0
CreateDefaultDBConfig return default DB configuration based on provided options
func CreatePersistenceFactory ¶ added in v0.27.0
func CreatePersistenceFactory(c *cli.Context) persistenceClient.Factory
CreatePersistenceFactory returns an initialized persistence managers factory. The factory allows to easily initialize concrete persistence managers to execute commands against persistence layer
func DataConverter ¶ added in v1.10.0
DataConverter provides a data converter over a websocket for Temporal web
func DescribeBatchJob ¶ added in v0.7.0
DescribeBatchJob describe the status of the batch job
func DescribeTaskQueue ¶ added in v0.27.0
DescribeTaskQueue show pollers info of a given taskqueue
func DescribeWorkflow ¶ added in v0.3.11
DescribeWorkflow show information about the specified workflow execution
func DescribeWorkflowWithID ¶ added in v0.3.11
DescribeWorkflowWithID show information about the specified workflow execution
func ErrorAndExit ¶
ErrorAndExit print easy to understand error msg first then error detail in a new line
func FailActivity ¶ added in v0.5.7
FailActivity fails an activity
func GetHistory ¶
func GetHistory(ctx context.Context, workflowClient sdkclient.Client, workflowID, runID string) (*historypb.History, error)
GetHistory helper method to iterate over all pages and return complete list of history events
func GetQPS ¶ added in v0.27.0
func GetQPS(...dynamicconfig.FilterOption) int
GetQPS returns default queries per second
func GetSearchAttributes ¶ added in v0.5.9
GetSearchAttributes get valid search attributes
func HealthCheck ¶ added in v1.5.0
HealthCheck check frontend health.
func HistoryEventToString ¶
func HistoryEventToString(e *historypb.HistoryEvent, printFully bool, maxFieldLength int) string
HistoryEventToString convert HistoryEvent to string
func ListAllWorkflow ¶ added in v0.3.11
ListAllWorkflow list all workflow executions based on filters
func ListArchivedWorkflow ¶ added in v0.27.0
ListArchivedWorkflow lists archived workflow executions based on filters
func ListBatchJobs ¶ added in v0.7.0
ListBatchJobs list the started batch jobs
func ListTaskQueuePartitions ¶ added in v0.27.0
ListTaskQueuePartitions gets all the taskqueue partition and host information.
func ListWorkflow ¶
ListWorkflow list workflow executions based on filters
func ObserveHistory ¶ added in v0.3.11
ObserveHistory show the process of running workflow
func ObserveHistoryWithID ¶ added in v0.3.11
ObserveHistoryWithID show the process of running workflow
func QueryWorkflowUsingStackTrace ¶
QueryWorkflowUsingStackTrace query workflow execution using __stack_trace as query type
func ResetInBatch ¶ added in v0.5.8
ResetInBatch resets workflow in batch
func ResetWorkflow ¶ added in v0.5.2
ResetWorkflow reset workflow
func RunWorkflow ¶
RunWorkflow starts a new workflow execution and print workflow progress and result
func ScanAllWorkflow ¶ added in v0.27.0
ScanAllWorkflow list all workflow executions using Scan API. It should be faster than ListAllWorkflow, but result are not sorted.
func SetFactory ¶ added in v0.5.0
func SetFactory(factory ClientFactory)
SetFactory is used to set the ClientFactory global
func SetRequiredNamespaceDataKeys ¶ added in v0.27.0
func SetRequiredNamespaceDataKeys(keys []string)
SetRequiredNamespaceDataKeys will set requiredNamespaceDataKeys
func ShowHistory ¶
ShowHistory shows the history of given workflow execution based on workflowID and runID.
func ShowHistoryWithWID ¶
ShowHistoryWithWID shows the history of given workflow with workflow_id
func SignalWorkflow ¶
SignalWorkflow signals a workflow execution
func StartBatchJob ¶ added in v0.7.0
StartBatchJob starts a batch job
func StartWorkflow ¶
StartWorkflow starts a new workflow execution
func TerminateBatchJob ¶ added in v0.7.0
TerminateBatchJob stops abatch job
func TerminateWorkflow ¶
TerminateWorkflow terminates a workflow execution
Types ¶
type BufferedWriter ¶ added in v0.27.0
type BufferedWriter interface { Add(interface{}) Flush() }
BufferedWriter is used to buffer entities and write them to a file
func NewBufferedWriter ¶ added in v0.27.0
func NewBufferedWriter(f *os.File) BufferedWriter
NewBufferedWriter constructs a new BufferedWriter
type CleanOutputDirectories ¶ added in v0.27.0
type CleanOutputDirectories struct { ShardCleanReportDirectoryPath string SuccessfullyCleanedDirectoryPath string FailedCleanedDirectoryPath string }
CleanOutputDirectories are the directory paths for output of clean
type CleanProgressReport ¶ added in v0.27.0
type CleanProgressReport struct { NumberOfShardsFinished int TotalExecutionsCount int64 SuccessfullyCleanedCount int64 FailedCleanedCount int64 TotalDBRequests int64 DatabaseRPS float64 NumberOfShardCleanFailures int64 ShardsPerHour float64 ExecutionsPerHour float64 }
CleanProgressReport represents the aggregate progress of the clean job. It is periodically printed to stdout
type ClientFactory ¶ added in v0.5.0
type ClientFactory interface { FrontendClient(c *cli.Context) workflowservice.WorkflowServiceClient AdminClient(c *cli.Context) adminservice.AdminServiceClient SDKClient(c *cli.Context, namespace string) sdkclient.Client HealthClient(c *cli.Context) healthpb.HealthClient }
ClientFactory is used to construct rpc clients
func NewClientFactory ¶ added in v0.5.0
func NewClientFactory() ClientFactory
NewClientFactory creates a new ClientFactory
type CorruptedExceptionMetadata ¶ added in v0.27.0
type CorruptedExceptionMetadata struct { CorruptionType CorruptionType Note string Details string }
CorruptedExceptionMetadata is the metadata for a CorruptedExecution
type CorruptedExecution ¶ added in v0.27.0
type CorruptedExecution struct { ShardID int32 NamespaceID string WorkflowID string RunID string NextEventID int64 TreeID primitives.UUID BranchID primitives.UUID CloseStatus enumspb.WorkflowExecutionStatus CorruptedExceptionMetadata CorruptedExceptionMetadata }
CorruptedExecution is the type that gets written to CorruptedExecutionFile
type CorruptionType ¶ added in v0.27.0
type CorruptionType string
CorruptionType indicates the type of corruption that was found
type CorruptionTypeBreakdown ¶ added in v0.27.0
type CorruptionTypeBreakdown struct { TotalHistoryMissing int64 TotalInvalidFirstEvent int64 TotalOpenExecutionInvalidCurrentExecution int64 TotalActivityIdsCorrupted int64 PercentageHistoryMissing float64 PercentageInvalidStartEvent float64 PercentageOpenExecutionInvalidCurrentExecution float64 PercentageActivityIdsCorrupted float64 }
CorruptionTypeBreakdown breaks down counts and percentages of corruption types
type ExecutionCheckFailure ¶ added in v0.27.0
type ExecutionCheckFailure struct { ShardID int32 NamespaceID string WorkflowID string RunID string Note string Details string }
ExecutionCheckFailure is the type that gets written to ExecutionCheckFailureFile
type HttpGetter ¶ added in v1.12.0
HttpGetter defines http.Client.Get(...) as an interface so we can mock it
type PayloadRequest ¶ added in v1.10.0
type PayloadResponse ¶ added in v1.10.0
type ProgressReport ¶ added in v0.27.0
type ProgressReport struct { NumberOfShardsFinished int TotalExecutionsCount int64 CorruptedExecutionsCount int64 ExecutionCheckFailureCount int64 NumberOfShardScanFailures int64 PercentageCorrupted float64 PercentageCheckFailure float64 Rates Rates CorruptionTypeBreakdown CorruptionTypeBreakdown ShardExecutionCountsDistribution ShardExecutionCountsDistribution }
ProgressReport contains metadata about the scan for all shards which have been finished This is periodically printed to stdout
type Rates ¶ added in v0.27.0
type Rates struct { TimeRunning string DatabaseRPS float64 TotalDBRequests int64 ShardsPerHour float64 ExecutionsPerHour float64 }
Rates indicates the rates at which the scan is progressing
type ScanOutputDirectories ¶ added in v0.27.0
type ScanOutputDirectories struct { ShardScanReportDirectoryPath string ExecutionCheckFailureDirectoryPath string CorruptedExecutionDirectoryPath string }
ScanOutputDirectories are the directory paths for output of scan
type ShardCleanOutputFiles ¶ added in v0.27.0
type ShardCleanOutputFiles struct { ShardCleanReportFile *os.File SuccessfullyCleanedFile *os.File FailedCleanedFile *os.File }
ShardCleanOutputFiles are the files produced for a clean of a single shard
type ShardCleanReport ¶ added in v0.27.0
type ShardCleanReport struct { ShardID int32 TotalDBRequests int64 Handled *ShardCleanReportHandled Failure *ShardCleanReportFailure }
ShardCleanReport represents the result of cleaning a single shard
type ShardCleanReportFailure ¶ added in v0.27.0
ShardCleanReportFailure is the part of ShardCleanReport that indicates a failure to clean some or all of the executions found in corruption file
type ShardCleanReportHandled ¶ added in v0.27.0
type ShardCleanReportHandled struct { TotalExecutionsCount int64 SuccessfullyCleanedCount int64 FailedCleanedCount int64 }
ShardCleanReportHandled is the part of ShardCleanReport of executions which were read from corruption file and were attempted to be deleted
type ShardExecutionCountsDistribution ¶ added in v0.27.0
type ShardExecutionCountsDistribution struct { MinExecutions *int64 MaxExecutions *int64 AverageExecutions int64 }
ShardExecutionCountsDistribution breaks down stats on the distribution of executions per shard
type ShardScanOutputFiles ¶ added in v0.27.0
type ShardScanOutputFiles struct { ShardScanReportFile *os.File ExecutionCheckFailureFile *os.File CorruptedExecutionFile *os.File }
ShardScanOutputFiles are the files produced for a scan of a single shard
type ShardScanReport ¶ added in v0.27.0
type ShardScanReport struct { ShardID int32 TotalDBRequests int64 Scanned *ShardScanReportExecutionsScanned Failure *ShardScanReportFailure }
ShardScanReport is the type that gets written to ShardScanReportFile
type ShardScanReportExecutionsScanned ¶ added in v0.27.0
type ShardScanReportExecutionsScanned struct { TotalExecutionsCount int64 CorruptedExecutionsCount int64 ExecutionCheckFailureCount int64 CorruptionTypeBreakdown CorruptionTypeBreakdown }
ShardScanReportExecutionsScanned is the part of the ShardScanReport of executions which were scanned
type ShardScanReportFailure ¶ added in v0.27.0
ShardScanReportFailure is the part of the ShardScanReport that indicates failure to scan all or part of the shard
type VerificationResult ¶ added in v0.27.0
type VerificationResult int
VerificationResult is the result of running a verification
const ( // VerificationResultNoCorruption indicates that no corruption was found VerificationResultNoCorruption VerificationResult = iota // VerificationResultDetectedCorruption indicates a corruption was found VerificationResultDetectedCorruption // VerificationResultCheckFailure indicates there was a failure to check corruption VerificationResultCheckFailure )
Source Files ¶
- activity.go
- admin.go
- adminClusterCommands.go
- adminCommands.go
- adminDBCleanCommand.go
- adminDBCommandsFileWriter.go
- adminDBScanCommand.go
- adminDLQCommands.go
- adminTaskQueueCommands.go
- admin_cluster_search_attributes_commands.go
- admin_decode_commands.go
- app.go
- batch.go
- cluster.go
- clusterCommands.go
- cluster_search_attributes_commands.go
- data_converter.go
- data_converter_commands.go
- defs.go
- factory.go
- flags.go
- namespace.go
- namespaceCommands.go
- namespaceUtils.go
- persistenceUtil.go
- taskQueue.go
- taskQueueCommands.go
- util.go
- workflow.go
- workflowBatchCommands.go
- workflowCommands.go