shard

package
v1.25.0-115.2 Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2024 License: MIT Imports: 67 Imported by: 0

Documentation

Overview

Package shard is a generated GoMock package.

Package shard is a generated GoMock package.

Package shard is a generated GoMock package.

Package shard is a generated GoMock package.

Package shard is a generated GoMock package.

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNonPositiveTotalNumShards = errors.New("totalNumShards must be greater than 0")
)
View Source
var (
	// ErrShardStatusUnknown means we're not sure if we have the shard lock or not. This may be returned
	// during short windows at initialization and if we've lost the connection to the database.
	ErrShardStatusUnknown = serviceerror.NewUnavailable("shard status unknown")
)
View Source
var Module = fx.Options(
	fx.Provide(
		ControllerProvider,
		func(impl *ControllerImpl) Controller { return impl },
		ContextFactoryProvider,
		fx.Annotate(
			func(p Controller) pingable.Pingable { return p },
			fx.ResultTags(`group:"deadlockDetectorRoots"`),
		),
	),
	ownershipBasedQuotaScalerModule,
)

Functions

func ConvertFromPersistenceTaskKey added in v1.21.0

func ConvertFromPersistenceTaskKey(
	key *persistencespb.TaskKey,
) tasks.Key

func ConvertToPersistenceTaskKey added in v1.21.0

func ConvertToPersistenceTaskKey(
	key tasks.Key,
) *persistencespb.TaskKey

func IsShardOwnershipLostError

func IsShardOwnershipLostError(err error) bool

func OperationPossiblySucceeded added in v1.17.0

func OperationPossiblySucceeded(err error) bool

func ReplicationReaderIDFromClusterShardID added in v1.21.0

func ReplicationReaderIDFromClusterShardID(
	clusterID int64,
	shardID int32,
) int64

ReplicationReaderIDFromClusterShardID convert from cluster ID & shard ID to reader ID NOTE: cluster metadata guarantee

  1. initial failover version <= int32 max
  2. failover increment <= int32 max
  3. initial failover version == cluster ID

func ReplicationReaderIDToClusterShardID added in v1.21.0

func ReplicationReaderIDToClusterShardID(
	readerID int64,
) (int64, int32)

ReplicationReaderIDToClusterShardID convert from reader ID to cluster ID & shard ID NOTE: see ReplicationReaderIDFromClusterShardID

Types

type CloseCallback added in v1.21.5

type CloseCallback func(ControllableContext)

type Context

type Context interface {
	GetShardID() int32
	GetRangeID() int64
	GetOwner() string
	GetExecutionManager() persistence.ExecutionManager
	GetNamespaceRegistry() namespace.Registry
	GetClusterMetadata() cluster.Metadata
	GetConfig() *configs.Config
	GetEventsCache() events.Cache
	GetLogger() log.Logger
	GetThrottledLogger() log.Logger
	GetMetricsHandler() metrics.Handler
	GetTimeSource() clock.TimeSource

	GetRemoteAdminClient(string) (adminservice.AdminServiceClient, error)
	GetHistoryClient() historyservice.HistoryServiceClient
	GetPayloadSerializer() serialization.Serializer

	GetSearchAttributesProvider() searchattribute.Provider
	GetSearchAttributesMapperProvider() searchattribute.MapperProvider
	GetArchivalMetadata() archiver.ArchivalMetadata

	GetEngine(ctx context.Context) (Engine, error)

	AssertOwnership(ctx context.Context) error
	NewVectorClock() (*clockspb.VectorClock, error)
	CurrentVectorClock() *clockspb.VectorClock

	GenerateTaskID() (int64, error)
	GenerateTaskIDs(number int) ([]int64, error)

	GetQueueExclusiveHighReadWatermark(category tasks.Category) tasks.Key
	GetQueueState(category tasks.Category) (*persistencespb.QueueState, bool)
	SetQueueState(category tasks.Category, tasksCompleted int, state *persistencespb.QueueState) error
	UpdateReplicationQueueReaderState(readerID int64, readerState *persistencespb.QueueReaderState) error

	GetReplicatorDLQAckLevel(sourceCluster string) int64
	UpdateReplicatorDLQAckLevel(sourCluster string, ackLevel int64) error

	UpdateRemoteClusterInfo(cluster string, ackTaskID int64, ackTimestamp time.Time)
	UpdateRemoteReaderInfo(readerID int64, ackTaskID int64, ackTimestamp time.Time) error

	SetCurrentTime(cluster string, currentTime time.Time)
	GetCurrentTime(cluster string) time.Time

	GetReplicationStatus(cluster []string) (map[string]*historyservice.ShardReplicationStatusPerCluster, map[string]*historyservice.HandoverNamespaceInfo, error)

	UpdateHandoverNamespace(ns *namespace.Namespace, deletedFromDb bool)

	AppendHistoryEvents(ctx context.Context, request *persistence.AppendHistoryNodesRequest, namespaceID namespace.ID, execution *commonpb.WorkflowExecution) (int, error)

	AddTasks(ctx context.Context, request *persistence.AddHistoryTasksRequest) error
	AddSpeculativeWorkflowTaskTimeoutTask(task *tasks.WorkflowTaskTimeoutTask) error
	CreateWorkflowExecution(ctx context.Context, request *persistence.CreateWorkflowExecutionRequest) (*persistence.CreateWorkflowExecutionResponse, error)
	UpdateWorkflowExecution(ctx context.Context, request *persistence.UpdateWorkflowExecutionRequest) (*persistence.UpdateWorkflowExecutionResponse, error)
	ConflictResolveWorkflowExecution(ctx context.Context, request *persistence.ConflictResolveWorkflowExecutionRequest) (*persistence.ConflictResolveWorkflowExecutionResponse, error)
	SetWorkflowExecution(ctx context.Context, request *persistence.SetWorkflowExecutionRequest) (*persistence.SetWorkflowExecutionResponse, error)
	GetCurrentExecution(ctx context.Context, request *persistence.GetCurrentExecutionRequest) (*persistence.GetCurrentExecutionResponse, error)
	GetWorkflowExecution(ctx context.Context, request *persistence.GetWorkflowExecutionRequest) (*persistence.GetWorkflowExecutionResponse, error)
	// DeleteWorkflowExecution add task to delete visibility, current workflow execution, and deletes workflow execution.
	// If branchToken != nil, then delete history also, otherwise leave history.
	DeleteWorkflowExecution(ctx context.Context, workflowKey definition.WorkflowKey, branchToken []byte, closeExecutionVisibilityTaskID int64, stage *tasks.DeleteWorkflowExecutionStage) error

	UnloadForOwnershipLost()

	StateMachineRegistry() *hsm.Registry
}

Context represents a history engine shard

type ContextConfigOverrides added in v1.24.0

type ContextConfigOverrides struct {
	ShardInfo        *persistencespb.ShardInfo
	Config           *configs.Config
	Registry         namespace.Registry
	ClusterMetadata  cluster.Metadata
	ExecutionManager persistence.ExecutionManager
}

type ContextFactory added in v1.21.5

type ContextFactory interface {
	CreateContext(shardID int32, closeCallback CloseCallback) (ControllableContext, error)
}

func ContextFactoryProvider added in v1.21.5

func ContextFactoryProvider(params ContextFactoryParams) ContextFactory

type ContextFactoryParams added in v1.21.5

type ContextFactoryParams struct {
	fx.In

	ArchivalMetadata            archiver.ArchivalMetadata
	ClientBean                  client.Bean
	ClusterMetadata             cluster.Metadata
	Config                      *configs.Config
	PersistenceConfig           config.Persistence
	EngineFactory               EngineFactory
	HistoryClient               resource.HistoryClient
	HistoryServiceResolver      membership.ServiceResolver
	HostInfoProvider            membership.HostInfoProvider
	Logger                      log.Logger
	MetricsHandler              metrics.Handler
	NamespaceRegistry           namespace.Registry
	PayloadSerializer           serialization.Serializer
	PersistenceExecutionManager persistence.ExecutionManager
	PersistenceShardManager     persistence.ShardManager
	SaMapperProvider            searchattribute.MapperProvider
	SaProvider                  searchattribute.Provider
	ThrottledLogger             log.ThrottledLogger
	TimeSource                  clock.TimeSource
	TaskCategoryRegistry        tasks.TaskCategoryRegistry
	EventsCache                 events.Cache

	StateMachineRegistry *hsm.Registry
}

type ContextImpl

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

func (*ContextImpl) AddSpeculativeWorkflowTaskTimeoutTask added in v1.21.0

func (s *ContextImpl) AddSpeculativeWorkflowTaskTimeoutTask(
	task *tasks.WorkflowTaskTimeoutTask,
) error

func (*ContextImpl) AddTasks added in v1.5.0

func (s *ContextImpl) AddTasks(
	ctx context.Context,
	request *persistence.AddHistoryTasksRequest,
) error

func (*ContextImpl) AppendHistoryEvents added in v1.5.0

func (s *ContextImpl) AppendHistoryEvents(
	ctx context.Context,
	request *persistence.AppendHistoryNodesRequest,
	namespaceID namespace.ID,
	execution *commonpb.WorkflowExecution,
) (int, error)

func (*ContextImpl) AssertOwnership added in v1.17.0

func (s *ContextImpl) AssertOwnership(
	ctx context.Context,
) error

func (*ContextImpl) CurrentVectorClock added in v1.17.0

func (s *ContextImpl) CurrentVectorClock() *clockspb.VectorClock

func (*ContextImpl) DeleteWorkflowExecution added in v1.14.0

func (s *ContextImpl) DeleteWorkflowExecution(
	ctx context.Context,
	key definition.WorkflowKey,
	branchToken []byte,
	closeVisibilityTaskId int64,
	stage *tasks.DeleteWorkflowExecutionStage,
) (retErr error)

func (*ContextImpl) FinishStop added in v1.21.5

func (s *ContextImpl) FinishStop()

FinishStop should only be called by the controller.

func (*ContextImpl) GenerateTaskID added in v1.16.0

func (s *ContextImpl) GenerateTaskID() (int64, error)

func (*ContextImpl) GenerateTaskIDs added in v1.16.0

func (s *ContextImpl) GenerateTaskIDs(number int) ([]int64, error)

func (*ContextImpl) GetArchivalMetadata added in v1.14.0

func (s *ContextImpl) GetArchivalMetadata() archiver.ArchivalMetadata

func (*ContextImpl) GetClusterMetadata added in v1.14.0

func (s *ContextImpl) GetClusterMetadata() cluster.Metadata

func (*ContextImpl) GetConfig

func (s *ContextImpl) GetConfig() *configs.Config

func (*ContextImpl) GetCurrentExecution added in v1.16.0

func (*ContextImpl) GetCurrentTime

func (s *ContextImpl) GetCurrentTime(cluster string) time.Time

func (*ContextImpl) GetEngine

func (s *ContextImpl) GetEngine(
	ctx context.Context,
) (Engine, error)

func (*ContextImpl) GetEventsCache

func (s *ContextImpl) GetEventsCache() events.Cache

func (*ContextImpl) GetExecutionManager

func (s *ContextImpl) GetExecutionManager() persistence.ExecutionManager

func (*ContextImpl) GetHistoryClient added in v1.14.0

func (s *ContextImpl) GetHistoryClient() historyservice.HistoryServiceClient

func (*ContextImpl) GetLogger

func (s *ContextImpl) GetLogger() log.Logger

func (*ContextImpl) GetMetricsHandler added in v1.17.3

func (s *ContextImpl) GetMetricsHandler() metrics.Handler

func (*ContextImpl) GetNamespaceRegistry added in v1.14.0

func (s *ContextImpl) GetNamespaceRegistry() namespace.Registry

func (*ContextImpl) GetOwner added in v1.21.0

func (s *ContextImpl) GetOwner() string

func (*ContextImpl) GetPayloadSerializer added in v1.14.0

func (s *ContextImpl) GetPayloadSerializer() serialization.Serializer

func (*ContextImpl) GetPingChecks added in v1.19.0

func (s *ContextImpl) GetPingChecks() []pingable.Check

func (*ContextImpl) GetQueueExclusiveHighReadWatermark added in v1.17.3

func (s *ContextImpl) GetQueueExclusiveHighReadWatermark(
	category tasks.Category,
) tasks.Key

func (*ContextImpl) GetQueueState added in v1.17.3

func (s *ContextImpl) GetQueueState(
	category tasks.Category,
) (*persistencespb.QueueState, bool)

func (*ContextImpl) GetRangeID added in v1.21.0

func (s *ContextImpl) GetRangeID() int64

func (*ContextImpl) GetRemoteAdminClient added in v1.14.0

func (s *ContextImpl) GetRemoteAdminClient(cluster string) (adminservice.AdminServiceClient, error)

func (*ContextImpl) GetReplicationStatus added in v1.14.0

func (s *ContextImpl) GetReplicationStatus(clusterNames []string) (map[string]*historyservice.ShardReplicationStatusPerCluster, map[string]*historyservice.HandoverNamespaceInfo, error)

func (*ContextImpl) GetReplicatorDLQAckLevel

func (s *ContextImpl) GetReplicatorDLQAckLevel(sourceCluster string) int64

func (*ContextImpl) GetSearchAttributesMapperProvider added in v1.20.0

func (s *ContextImpl) GetSearchAttributesMapperProvider() searchattribute.MapperProvider

func (*ContextImpl) GetSearchAttributesProvider added in v1.14.0

func (s *ContextImpl) GetSearchAttributesProvider() searchattribute.Provider

func (*ContextImpl) GetShardID

func (s *ContextImpl) GetShardID() int32

func (*ContextImpl) GetThrottledLogger

func (s *ContextImpl) GetThrottledLogger() log.Logger

func (*ContextImpl) GetTimeSource added in v1.14.0

func (s *ContextImpl) GetTimeSource() cclock.TimeSource

func (*ContextImpl) GetWorkflowExecution added in v1.16.0

func (*ContextImpl) IsValid added in v1.21.0

func (s *ContextImpl) IsValid() bool

func (*ContextImpl) NewVectorClock added in v1.17.0

func (s *ContextImpl) NewVectorClock() (*clockspb.VectorClock, error)

func (*ContextImpl) SetCurrentTime

func (s *ContextImpl) SetCurrentTime(cluster string, currentTime time.Time)

func (*ContextImpl) SetQueueState added in v1.21.0

func (s *ContextImpl) SetQueueState(
	category tasks.Category,
	tasksCompleted int,
	state *persistencespb.QueueState,
) error

func (*ContextImpl) SetWorkflowExecution added in v1.16.0

func (*ContextImpl) StateMachineRegistry added in v1.24.0

func (s *ContextImpl) StateMachineRegistry() *hsm.Registry

func (*ContextImpl) String added in v1.17.0

func (s *ContextImpl) String() string

func (*ContextImpl) UnloadForOwnershipLost added in v1.21.5

func (s *ContextImpl) UnloadForOwnershipLost()

func (*ContextImpl) UpdateHandoverNamespace added in v1.20.0

func (s *ContextImpl) UpdateHandoverNamespace(ns *namespace.Namespace, deletedFromDb bool)

func (*ContextImpl) UpdateRemoteClusterInfo added in v1.16.0

func (s *ContextImpl) UpdateRemoteClusterInfo(
	clusterName string,
	ackTaskID int64,
	ackTimestamp time.Time,
)

UpdateRemoteClusterInfo deprecated Deprecated use UpdateRemoteReaderInfo in the future instead

func (*ContextImpl) UpdateRemoteReaderInfo added in v1.21.0

func (s *ContextImpl) UpdateRemoteReaderInfo(
	readerID int64,
	ackTaskID int64,
	ackTimestamp time.Time,
) error

UpdateRemoteReaderInfo do not use streaming replication until remoteClusterInfo is updated to allow both streaming & pull based replication

func (*ContextImpl) UpdateReplicationQueueReaderState added in v1.21.0

func (s *ContextImpl) UpdateReplicationQueueReaderState(
	readerID int64,
	readerState *persistencespb.QueueReaderState,
) error

func (*ContextImpl) UpdateReplicatorDLQAckLevel

func (s *ContextImpl) UpdateReplicatorDLQAckLevel(
	sourceCluster string,
	ackLevel int64,
) error

type ContextTest

type ContextTest struct {
	*ContextImpl

	Resource *resourcetest.Test

	MockEventsCache *events.MockCache
}

func NewTestContext

func NewTestContext(
	ctrl *gomock.Controller,
	shardInfo *persistencespb.ShardInfo,
	config *configs.Config,
) *ContextTest

func NewTestContextWithTimeSource added in v1.14.0

func NewTestContextWithTimeSource(
	ctrl *gomock.Controller,
	shardInfo *persistencespb.ShardInfo,
	config *configs.Config,
	timeSource clock.TimeSource,
) *ContextTest

func (*ContextTest) SetEngineForTesting added in v1.14.0

func (s *ContextTest) SetEngineForTesting(engine Engine)

SetEngineForTest sets s.engine. Only used by tests.

func (*ContextTest) SetEventsCacheForTesting added in v1.14.0

func (s *ContextTest) SetEventsCacheForTesting(c events.Cache)

SetEventsCacheForTesting sets s.eventsCache. Only used by tests.

func (*ContextTest) SetHistoryClientForTesting added in v1.20.0

func (s *ContextTest) SetHistoryClientForTesting(client historyservice.HistoryServiceClient)

SetHistoryClientForTesting sets history client. Only used by tests.

func (*ContextTest) SetLoggers added in v1.25.0

func (s *ContextTest) SetLoggers(l log.Logger)

SetLoggers sets both s.throttledLogger and s.contextTaggedLogger. Only used by tests.

func (*ContextTest) SetStateMachineRegistry added in v1.24.0

func (s *ContextTest) SetStateMachineRegistry(reg *hsm.Registry)

SetStateMachineRegistry sets the state machine registry on this shard.

func (*ContextTest) StopForTest added in v1.14.0

func (s *ContextTest) StopForTest()

StopForTest calls FinishStop(). In general only the controller should call that, but integration tests need to do it also to clean up any background acquireShard goroutines that may exist.

type ControllableContext added in v1.21.5

type ControllableContext interface {
	Context
	pingable.Pingable

	IsValid() bool
	FinishStop()
}

A ControllableContext is a Context plus other methods needed by the Controller.

type Controller added in v1.17.3

type Controller interface {
	pingable.Pingable

	GetShardByID(shardID int32) (Context, error)
	GetShardByNamespaceWorkflow(namespaceID namespace.ID, workflowID string) (Context, error)
	CloseShardByID(shardID int32)
	ShardIDs() []int32
	Start()
	Stop()
}

type ControllerImpl

type ControllerImpl struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

func ControllerProvider added in v1.17.3

func ControllerProvider(
	config *configs.Config,
	logger log.Logger,
	historyServiceResolver membership.ServiceResolver,
	metricsHandler metrics.Handler,
	hostInfoProvider membership.HostInfoProvider,
	contextFactory ContextFactory,
) *ControllerImpl

func (*ControllerImpl) CloseShardByID added in v1.14.0

func (c *ControllerImpl) CloseShardByID(shardID int32)

func (*ControllerImpl) GetPingChecks added in v1.19.0

func (c *ControllerImpl) GetPingChecks() []pingable.Check

func (*ControllerImpl) GetShardByID added in v1.17.0

func (c *ControllerImpl) GetShardByID(
	shardID int32,
) (Context, error)

GetShardByID returns a shard context for the given shard id. The shard context may not have acquired a rangeid lease yet. Callers can use GetEngine on the shard to block on rangeid lease acquisition.

func (*ControllerImpl) GetShardByNamespaceWorkflow added in v1.17.0

func (c *ControllerImpl) GetShardByNamespaceWorkflow(
	namespaceID namespace.ID,
	workflowID string,
) (Context, error)

GetShardByID returns a shard context for the given namespace and workflow. The shard context may not have acquired a rangeid lease yet. Callers can use GetEngine on the shard to block on rangeid lease acquisition.

func (*ControllerImpl) ShardIDs

func (c *ControllerImpl) ShardIDs() []int32

func (*ControllerImpl) Start

func (c *ControllerImpl) Start()

func (*ControllerImpl) Status

func (c *ControllerImpl) Status() int32

func (*ControllerImpl) Stop

func (c *ControllerImpl) Stop()

func (*ControllerImpl) SubscribeShardCount added in v1.22.0

func (c *ControllerImpl) SubscribeShardCount() ShardCountSubscription

SubscribeShardCount returns a subscription to shard count updates with a 1-buffered channel. This method is thread-safe.

type Engine

type Engine interface {
	StartWorkflowExecution(ctx context.Context, request *historyservice.StartWorkflowExecutionRequest) (*historyservice.StartWorkflowExecutionResponse, error)
	GetMutableState(ctx context.Context, request *historyservice.GetMutableStateRequest) (*historyservice.GetMutableStateResponse, error)
	PollMutableState(ctx context.Context, request *historyservice.PollMutableStateRequest) (*historyservice.PollMutableStateResponse, error)
	DescribeMutableState(ctx context.Context, request *historyservice.DescribeMutableStateRequest) (*historyservice.DescribeMutableStateResponse, error)
	ResetStickyTaskQueue(ctx context.Context, resetRequest *historyservice.ResetStickyTaskQueueRequest) (*historyservice.ResetStickyTaskQueueResponse, error)
	DescribeWorkflowExecution(ctx context.Context, request *historyservice.DescribeWorkflowExecutionRequest) (*historyservice.DescribeWorkflowExecutionResponse, error)
	RecordWorkflowTaskStarted(ctx context.Context, request *historyservice.RecordWorkflowTaskStartedRequest) (*historyservice.RecordWorkflowTaskStartedResponse, error)
	RecordActivityTaskStarted(ctx context.Context, request *historyservice.RecordActivityTaskStartedRequest) (*historyservice.RecordActivityTaskStartedResponse, error)
	RespondWorkflowTaskCompleted(ctx context.Context, request *historyservice.RespondWorkflowTaskCompletedRequest) (*historyservice.RespondWorkflowTaskCompletedResponse, error)
	RespondWorkflowTaskFailed(ctx context.Context, request *historyservice.RespondWorkflowTaskFailedRequest) error
	RespondActivityTaskCompleted(ctx context.Context, request *historyservice.RespondActivityTaskCompletedRequest) (*historyservice.RespondActivityTaskCompletedResponse, error)
	RespondActivityTaskFailed(ctx context.Context, request *historyservice.RespondActivityTaskFailedRequest) (*historyservice.RespondActivityTaskFailedResponse, error)
	RespondActivityTaskCanceled(ctx context.Context, request *historyservice.RespondActivityTaskCanceledRequest) (*historyservice.RespondActivityTaskCanceledResponse, error)
	RecordActivityTaskHeartbeat(ctx context.Context, request *historyservice.RecordActivityTaskHeartbeatRequest) (*historyservice.RecordActivityTaskHeartbeatResponse, error)
	RequestCancelWorkflowExecution(ctx context.Context, request *historyservice.RequestCancelWorkflowExecutionRequest) (*historyservice.RequestCancelWorkflowExecutionResponse, error)
	SignalWorkflowExecution(ctx context.Context, request *historyservice.SignalWorkflowExecutionRequest) (*historyservice.SignalWorkflowExecutionResponse, error)
	SignalWithStartWorkflowExecution(ctx context.Context, request *historyservice.SignalWithStartWorkflowExecutionRequest) (*historyservice.SignalWithStartWorkflowExecutionResponse, error)
	ExecuteMultiOperation(ctx context.Context, request *historyservice.ExecuteMultiOperationRequest) (*historyservice.ExecuteMultiOperationResponse, error)
	RemoveSignalMutableState(ctx context.Context, request *historyservice.RemoveSignalMutableStateRequest) (*historyservice.RemoveSignalMutableStateResponse, error)
	TerminateWorkflowExecution(ctx context.Context, request *historyservice.TerminateWorkflowExecutionRequest) (*historyservice.TerminateWorkflowExecutionResponse, error)
	DeleteWorkflowExecution(ctx context.Context, deleteRequest *historyservice.DeleteWorkflowExecutionRequest) (*historyservice.DeleteWorkflowExecutionResponse, error)
	ResetWorkflowExecution(ctx context.Context, request *historyservice.ResetWorkflowExecutionRequest) (*historyservice.ResetWorkflowExecutionResponse, error)
	ScheduleWorkflowTask(ctx context.Context, request *historyservice.ScheduleWorkflowTaskRequest) error
	IsActivityTaskValid(ctx context.Context, request *historyservice.IsActivityTaskValidRequest) (*historyservice.IsActivityTaskValidResponse, error)
	IsWorkflowTaskValid(ctx context.Context, request *historyservice.IsWorkflowTaskValidRequest) (*historyservice.IsWorkflowTaskValidResponse, error)
	VerifyFirstWorkflowTaskScheduled(ctx context.Context, request *historyservice.VerifyFirstWorkflowTaskScheduledRequest) error
	RecordChildExecutionCompleted(ctx context.Context, request *historyservice.RecordChildExecutionCompletedRequest) (*historyservice.RecordChildExecutionCompletedResponse, error)
	VerifyChildExecutionCompletionRecorded(ctx context.Context, request *historyservice.VerifyChildExecutionCompletionRecordedRequest) (*historyservice.VerifyChildExecutionCompletionRecordedResponse, error)
	// ReplicateHistoryEvents is for a WIP feature. Ultimately will replace the ReplicateEventsV2 API
	ReplicateHistoryEvents(
		ctx context.Context,
		workflowKey definition.WorkflowKey,
		baseExecutionInfo *workflowpb.BaseExecutionInfo,
		versionHistoryItems []*historyspb.VersionHistoryItem,
		historyEvents [][]*historypb.HistoryEvent,
		newEvents []*historypb.HistoryEvent,
		newRunID string,
	) error
	ReplicateEventsV2(ctx context.Context, request *historyservice.ReplicateEventsV2Request) error
	ReplicateWorkflowState(ctx context.Context, request *historyservice.ReplicateWorkflowStateRequest) error
	SyncShardStatus(ctx context.Context, request *historyservice.SyncShardStatusRequest) error
	SyncActivity(ctx context.Context, request *historyservice.SyncActivityRequest) error
	SyncActivities(ctx context.Context, request *historyservice.SyncActivitiesRequest) error
	GetReplicationMessages(ctx context.Context, pollingCluster string, ackMessageID int64, ackTimestamp time.Time, queryMessageID int64) (*replicationspb.ReplicationMessages, error)
	GetDLQReplicationMessages(ctx context.Context, taskInfos []*replicationspb.ReplicationTaskInfo) ([]*replicationspb.ReplicationTask, error)
	QueryWorkflow(ctx context.Context, request *historyservice.QueryWorkflowRequest) (*historyservice.QueryWorkflowResponse, error)
	ReapplyEvents(ctx context.Context, namespaceUUID namespace.ID, workflowID string, runID string, events []*historypb.HistoryEvent) error
	GetDLQMessages(ctx context.Context, messagesRequest *historyservice.GetDLQMessagesRequest) (*historyservice.GetDLQMessagesResponse, error)
	PurgeDLQMessages(ctx context.Context, messagesRequest *historyservice.PurgeDLQMessagesRequest) (*historyservice.PurgeDLQMessagesResponse, error)
	MergeDLQMessages(ctx context.Context, messagesRequest *historyservice.MergeDLQMessagesRequest) (*historyservice.MergeDLQMessagesResponse, error)
	RebuildMutableState(ctx context.Context, namespaceUUID namespace.ID, execution *commonpb.WorkflowExecution) error
	ImportWorkflowExecution(ctx context.Context, request *historyservice.ImportWorkflowExecutionRequest) (*historyservice.ImportWorkflowExecutionResponse, error)
	RefreshWorkflowTasks(ctx context.Context, namespaceUUID namespace.ID, execution *commonpb.WorkflowExecution) error
	GenerateLastHistoryReplicationTasks(ctx context.Context, request *historyservice.GenerateLastHistoryReplicationTasksRequest) (*historyservice.GenerateLastHistoryReplicationTasksResponse, error)
	GetReplicationStatus(ctx context.Context, request *historyservice.GetReplicationStatusRequest) (*historyservice.ShardReplicationStatus, error)
	UpdateWorkflowExecution(ctx context.Context, request *historyservice.UpdateWorkflowExecutionRequest) (*historyservice.UpdateWorkflowExecutionResponse, error)
	PollWorkflowExecutionUpdate(ctx context.Context, request *historyservice.PollWorkflowExecutionUpdateRequest) (*historyservice.PollWorkflowExecutionUpdateResponse, error)
	GetWorkflowExecutionHistory(ctx context.Context, request *historyservice.GetWorkflowExecutionHistoryRequest) (*historyservice.GetWorkflowExecutionHistoryResponse, error)
	GetWorkflowExecutionHistoryReverse(ctx context.Context, request *historyservice.GetWorkflowExecutionHistoryReverseRequest) (*historyservice.GetWorkflowExecutionHistoryReverseResponse, error)
	GetWorkflowExecutionRawHistory(ctx context.Context, request *historyservice.GetWorkflowExecutionRawHistoryRequest) (*historyservice.GetWorkflowExecutionRawHistoryResponse, error)
	GetWorkflowExecutionRawHistoryV2(ctx context.Context, request *historyservice.GetWorkflowExecutionRawHistoryV2Request) (*historyservice.GetWorkflowExecutionRawHistoryV2Response, error)
	AddTasks(ctx context.Context, request *historyservice.AddTasksRequest) (*historyservice.AddTasksResponse, error)
	ListTasks(ctx context.Context, request *historyservice.ListTasksRequest) (*historyservice.ListTasksResponse, error)

	NotifyNewHistoryEvent(event *events.Notification)
	NotifyNewTasks(tasks map[tasks.Category][]tasks.Task)
	AddSpeculativeWorkflowTaskTimeoutTask(task *tasks.WorkflowTaskTimeoutTask)
	// TODO(bergundy): This Environment should be host level once shard level workflow cache is deprecated.
	StateMachineEnvironment() hsm.Environment

	ReplicationStream
	Start()
	Stop()
}

Engine represents an interface for managing workflow execution history.

type EngineFactory

type EngineFactory interface {
	CreateEngine(context Context) Engine
}

EngineFactory is used to create an instance of sharded history engine

type LazyLoadedOwnershipBasedQuotaScaler added in v1.23.0

type LazyLoadedOwnershipBasedQuotaScaler struct {
	*atomic.Value // value type is OwnershipBasedQuotaScaler
}

func (LazyLoadedOwnershipBasedQuotaScaler) ScaleFactor added in v1.23.0

type MockContext

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

MockContext is a mock of Context interface.

func NewMockContext

func NewMockContext(ctrl *gomock.Controller) *MockContext

NewMockContext creates a new mock instance.

func (*MockContext) AddSpeculativeWorkflowTaskTimeoutTask added in v1.21.0

func (m *MockContext) AddSpeculativeWorkflowTaskTimeoutTask(task *tasks.WorkflowTaskTimeoutTask) error

AddSpeculativeWorkflowTaskTimeoutTask mocks base method.

func (*MockContext) AddTasks added in v1.5.0

AddTasks mocks base method.

func (*MockContext) AppendHistoryEvents added in v1.5.0

func (m *MockContext) AppendHistoryEvents(ctx context.Context, request *persistence.AppendHistoryNodesRequest, namespaceID namespace.ID, execution *v1.WorkflowExecution) (int, error)

AppendHistoryEvents mocks base method.

func (*MockContext) AssertOwnership added in v1.17.0

func (m *MockContext) AssertOwnership(ctx context.Context) error

AssertOwnership mocks base method.

func (*MockContext) ConflictResolveWorkflowExecution

ConflictResolveWorkflowExecution mocks base method.

func (*MockContext) CreateWorkflowExecution

CreateWorkflowExecution mocks base method.

func (*MockContext) CurrentVectorClock added in v1.17.0

func (m *MockContext) CurrentVectorClock() *v11.VectorClock

CurrentVectorClock mocks base method.

func (*MockContext) DeleteWorkflowExecution added in v1.14.0

func (m *MockContext) DeleteWorkflowExecution(ctx context.Context, workflowKey definition.WorkflowKey, branchToken []byte, closeExecutionVisibilityTaskID int64, stage *tasks.DeleteWorkflowExecutionStage) error

DeleteWorkflowExecution mocks base method.

func (*MockContext) EXPECT

func (m *MockContext) EXPECT() *MockContextMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockContext) GenerateTaskID added in v1.16.0

func (m *MockContext) GenerateTaskID() (int64, error)

GenerateTaskID mocks base method.

func (*MockContext) GenerateTaskIDs added in v1.16.0

func (m *MockContext) GenerateTaskIDs(number int) ([]int64, error)

GenerateTaskIDs mocks base method.

func (*MockContext) GetArchivalMetadata added in v1.14.0

func (m *MockContext) GetArchivalMetadata() archiver.ArchivalMetadata

GetArchivalMetadata mocks base method.

func (*MockContext) GetClusterMetadata

func (m *MockContext) GetClusterMetadata() cluster.Metadata

GetClusterMetadata mocks base method.

func (*MockContext) GetConfig

func (m *MockContext) GetConfig() *configs.Config

GetConfig mocks base method.

func (*MockContext) GetCurrentExecution added in v1.16.0

GetCurrentExecution mocks base method.

func (*MockContext) GetCurrentTime

func (m *MockContext) GetCurrentTime(cluster string) time.Time

GetCurrentTime mocks base method.

func (*MockContext) GetEngine

func (m *MockContext) GetEngine(ctx context.Context) (Engine, error)

GetEngine mocks base method.

func (*MockContext) GetEventsCache

func (m *MockContext) GetEventsCache() events.Cache

GetEventsCache mocks base method.

func (*MockContext) GetExecutionManager

func (m *MockContext) GetExecutionManager() persistence.ExecutionManager

GetExecutionManager mocks base method.

func (*MockContext) GetHistoryClient added in v1.14.0

func (m *MockContext) GetHistoryClient() v12.HistoryServiceClient

GetHistoryClient mocks base method.

func (*MockContext) GetLogger

func (m *MockContext) GetLogger() log.Logger

GetLogger mocks base method.

func (*MockContext) GetMetricsHandler added in v1.17.3

func (m *MockContext) GetMetricsHandler() metrics.Handler

GetMetricsHandler mocks base method.

func (*MockContext) GetNamespaceRegistry added in v1.13.0

func (m *MockContext) GetNamespaceRegistry() namespace.Registry

GetNamespaceRegistry mocks base method.

func (*MockContext) GetOwner added in v1.21.0

func (m *MockContext) GetOwner() string

GetOwner mocks base method.

func (*MockContext) GetPayloadSerializer added in v1.14.0

func (m *MockContext) GetPayloadSerializer() serialization.Serializer

GetPayloadSerializer mocks base method.

func (*MockContext) GetQueueExclusiveHighReadWatermark added in v1.17.3

func (m *MockContext) GetQueueExclusiveHighReadWatermark(category tasks.Category) tasks.Key

GetQueueExclusiveHighReadWatermark mocks base method.

func (*MockContext) GetQueueState added in v1.17.3

func (m *MockContext) GetQueueState(category tasks.Category) (*v13.QueueState, bool)

GetQueueState mocks base method.

func (*MockContext) GetRangeID added in v1.21.0

func (m *MockContext) GetRangeID() int64

GetRangeID mocks base method.

func (*MockContext) GetRemoteAdminClient added in v1.14.0

func (m *MockContext) GetRemoteAdminClient(arg0 string) (v10.AdminServiceClient, error)

GetRemoteAdminClient mocks base method.

func (*MockContext) GetReplicationStatus added in v1.14.0

func (m *MockContext) GetReplicationStatus(cluster []string) (map[string]*v12.ShardReplicationStatusPerCluster, map[string]*v12.HandoverNamespaceInfo, error)

GetReplicationStatus mocks base method.

func (*MockContext) GetReplicatorDLQAckLevel

func (m *MockContext) GetReplicatorDLQAckLevel(sourceCluster string) int64

GetReplicatorDLQAckLevel mocks base method.

func (*MockContext) GetSearchAttributesMapperProvider added in v1.20.0

func (m *MockContext) GetSearchAttributesMapperProvider() searchattribute.MapperProvider

GetSearchAttributesMapperProvider mocks base method.

func (*MockContext) GetSearchAttributesProvider added in v1.14.0

func (m *MockContext) GetSearchAttributesProvider() searchattribute.Provider

GetSearchAttributesProvider mocks base method.

func (*MockContext) GetShardID

func (m *MockContext) GetShardID() int32

GetShardID mocks base method.

func (*MockContext) GetThrottledLogger

func (m *MockContext) GetThrottledLogger() log.Logger

GetThrottledLogger mocks base method.

func (*MockContext) GetTimeSource

func (m *MockContext) GetTimeSource() clock.TimeSource

GetTimeSource mocks base method.

func (*MockContext) GetWorkflowExecution added in v1.16.0

GetWorkflowExecution mocks base method.

func (*MockContext) NewVectorClock added in v1.17.0

func (m *MockContext) NewVectorClock() (*v11.VectorClock, error)

NewVectorClock mocks base method.

func (*MockContext) SetCurrentTime

func (m *MockContext) SetCurrentTime(cluster string, currentTime time.Time)

SetCurrentTime mocks base method.

func (*MockContext) SetQueueState added in v1.21.0

func (m *MockContext) SetQueueState(category tasks.Category, tasksCompleted int, state *v13.QueueState) error

SetQueueState mocks base method.

func (*MockContext) SetWorkflowExecution added in v1.16.0

SetWorkflowExecution mocks base method.

func (*MockContext) StateMachineRegistry added in v1.24.0

func (m *MockContext) StateMachineRegistry() *hsm.Registry

StateMachineRegistry mocks base method.

func (*MockContext) UnloadForOwnershipLost added in v1.21.5

func (m *MockContext) UnloadForOwnershipLost()

UnloadForOwnershipLost mocks base method.

func (*MockContext) UpdateHandoverNamespace added in v1.20.0

func (m *MockContext) UpdateHandoverNamespace(ns *namespace.Namespace, deletedFromDb bool)

UpdateHandoverNamespace mocks base method.

func (*MockContext) UpdateRemoteClusterInfo added in v1.16.0

func (m *MockContext) UpdateRemoteClusterInfo(cluster string, ackTaskID int64, ackTimestamp time.Time)

UpdateRemoteClusterInfo mocks base method.

func (*MockContext) UpdateRemoteReaderInfo added in v1.21.0

func (m *MockContext) UpdateRemoteReaderInfo(readerID, ackTaskID int64, ackTimestamp time.Time) error

UpdateRemoteReaderInfo mocks base method.

func (*MockContext) UpdateReplicationQueueReaderState added in v1.21.0

func (m *MockContext) UpdateReplicationQueueReaderState(readerID int64, readerState *v13.QueueReaderState) error

UpdateReplicationQueueReaderState mocks base method.

func (*MockContext) UpdateReplicatorDLQAckLevel

func (m *MockContext) UpdateReplicatorDLQAckLevel(sourCluster string, ackLevel int64) error

UpdateReplicatorDLQAckLevel mocks base method.

func (*MockContext) UpdateWorkflowExecution

UpdateWorkflowExecution mocks base method.

type MockContextFactory added in v1.21.5

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

MockContextFactory is a mock of ContextFactory interface.

func NewMockContextFactory added in v1.21.5

func NewMockContextFactory(ctrl *gomock.Controller) *MockContextFactory

NewMockContextFactory creates a new mock instance.

func (*MockContextFactory) CreateContext added in v1.21.5

func (m *MockContextFactory) CreateContext(shardID int32, closeCallback CloseCallback) (ControllableContext, error)

CreateContext mocks base method.

func (*MockContextFactory) EXPECT added in v1.21.5

EXPECT returns an object that allows the caller to indicate expected use.

type MockContextFactoryMockRecorder added in v1.21.5

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

MockContextFactoryMockRecorder is the mock recorder for MockContextFactory.

func (*MockContextFactoryMockRecorder) CreateContext added in v1.21.5

func (mr *MockContextFactoryMockRecorder) CreateContext(shardID, closeCallback interface{}) *gomock.Call

CreateContext indicates an expected call of CreateContext.

type MockContextMockRecorder

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

MockContextMockRecorder is the mock recorder for MockContext.

func (*MockContextMockRecorder) AddSpeculativeWorkflowTaskTimeoutTask added in v1.21.0

func (mr *MockContextMockRecorder) AddSpeculativeWorkflowTaskTimeoutTask(task interface{}) *gomock.Call

AddSpeculativeWorkflowTaskTimeoutTask indicates an expected call of AddSpeculativeWorkflowTaskTimeoutTask.

func (*MockContextMockRecorder) AddTasks added in v1.5.0

func (mr *MockContextMockRecorder) AddTasks(ctx, request interface{}) *gomock.Call

AddTasks indicates an expected call of AddTasks.

func (*MockContextMockRecorder) AppendHistoryEvents added in v1.5.0

func (mr *MockContextMockRecorder) AppendHistoryEvents(ctx, request, namespaceID, execution interface{}) *gomock.Call

AppendHistoryEvents indicates an expected call of AppendHistoryEvents.

func (*MockContextMockRecorder) AssertOwnership added in v1.17.0

func (mr *MockContextMockRecorder) AssertOwnership(ctx interface{}) *gomock.Call

AssertOwnership indicates an expected call of AssertOwnership.

func (*MockContextMockRecorder) ConflictResolveWorkflowExecution

func (mr *MockContextMockRecorder) ConflictResolveWorkflowExecution(ctx, request interface{}) *gomock.Call

ConflictResolveWorkflowExecution indicates an expected call of ConflictResolveWorkflowExecution.

func (*MockContextMockRecorder) CreateWorkflowExecution

func (mr *MockContextMockRecorder) CreateWorkflowExecution(ctx, request interface{}) *gomock.Call

CreateWorkflowExecution indicates an expected call of CreateWorkflowExecution.

func (*MockContextMockRecorder) CurrentVectorClock added in v1.17.0

func (mr *MockContextMockRecorder) CurrentVectorClock() *gomock.Call

CurrentVectorClock indicates an expected call of CurrentVectorClock.

func (*MockContextMockRecorder) DeleteWorkflowExecution added in v1.14.0

func (mr *MockContextMockRecorder) DeleteWorkflowExecution(ctx, workflowKey, branchToken, closeExecutionVisibilityTaskID, stage interface{}) *gomock.Call

DeleteWorkflowExecution indicates an expected call of DeleteWorkflowExecution.

func (*MockContextMockRecorder) GenerateTaskID added in v1.16.0

func (mr *MockContextMockRecorder) GenerateTaskID() *gomock.Call

GenerateTaskID indicates an expected call of GenerateTaskID.

func (*MockContextMockRecorder) GenerateTaskIDs added in v1.16.0

func (mr *MockContextMockRecorder) GenerateTaskIDs(number interface{}) *gomock.Call

GenerateTaskIDs indicates an expected call of GenerateTaskIDs.

func (*MockContextMockRecorder) GetArchivalMetadata added in v1.14.0

func (mr *MockContextMockRecorder) GetArchivalMetadata() *gomock.Call

GetArchivalMetadata indicates an expected call of GetArchivalMetadata.

func (*MockContextMockRecorder) GetClusterMetadata

func (mr *MockContextMockRecorder) GetClusterMetadata() *gomock.Call

GetClusterMetadata indicates an expected call of GetClusterMetadata.

func (*MockContextMockRecorder) GetConfig

func (mr *MockContextMockRecorder) GetConfig() *gomock.Call

GetConfig indicates an expected call of GetConfig.

func (*MockContextMockRecorder) GetCurrentExecution added in v1.16.0

func (mr *MockContextMockRecorder) GetCurrentExecution(ctx, request interface{}) *gomock.Call

GetCurrentExecution indicates an expected call of GetCurrentExecution.

func (*MockContextMockRecorder) GetCurrentTime

func (mr *MockContextMockRecorder) GetCurrentTime(cluster interface{}) *gomock.Call

GetCurrentTime indicates an expected call of GetCurrentTime.

func (*MockContextMockRecorder) GetEngine

func (mr *MockContextMockRecorder) GetEngine(ctx interface{}) *gomock.Call

GetEngine indicates an expected call of GetEngine.

func (*MockContextMockRecorder) GetEventsCache

func (mr *MockContextMockRecorder) GetEventsCache() *gomock.Call

GetEventsCache indicates an expected call of GetEventsCache.

func (*MockContextMockRecorder) GetExecutionManager

func (mr *MockContextMockRecorder) GetExecutionManager() *gomock.Call

GetExecutionManager indicates an expected call of GetExecutionManager.

func (*MockContextMockRecorder) GetHistoryClient added in v1.14.0

func (mr *MockContextMockRecorder) GetHistoryClient() *gomock.Call

GetHistoryClient indicates an expected call of GetHistoryClient.

func (*MockContextMockRecorder) GetLogger

func (mr *MockContextMockRecorder) GetLogger() *gomock.Call

GetLogger indicates an expected call of GetLogger.

func (*MockContextMockRecorder) GetMetricsHandler added in v1.17.3

func (mr *MockContextMockRecorder) GetMetricsHandler() *gomock.Call

GetMetricsHandler indicates an expected call of GetMetricsHandler.

func (*MockContextMockRecorder) GetNamespaceRegistry added in v1.13.0

func (mr *MockContextMockRecorder) GetNamespaceRegistry() *gomock.Call

GetNamespaceRegistry indicates an expected call of GetNamespaceRegistry.

func (*MockContextMockRecorder) GetOwner added in v1.21.0

func (mr *MockContextMockRecorder) GetOwner() *gomock.Call

GetOwner indicates an expected call of GetOwner.

func (*MockContextMockRecorder) GetPayloadSerializer added in v1.14.0

func (mr *MockContextMockRecorder) GetPayloadSerializer() *gomock.Call

GetPayloadSerializer indicates an expected call of GetPayloadSerializer.

func (*MockContextMockRecorder) GetQueueExclusiveHighReadWatermark added in v1.17.3

func (mr *MockContextMockRecorder) GetQueueExclusiveHighReadWatermark(category interface{}) *gomock.Call

GetQueueExclusiveHighReadWatermark indicates an expected call of GetQueueExclusiveHighReadWatermark.

func (*MockContextMockRecorder) GetQueueState added in v1.17.3

func (mr *MockContextMockRecorder) GetQueueState(category interface{}) *gomock.Call

GetQueueState indicates an expected call of GetQueueState.

func (*MockContextMockRecorder) GetRangeID added in v1.21.0

func (mr *MockContextMockRecorder) GetRangeID() *gomock.Call

GetRangeID indicates an expected call of GetRangeID.

func (*MockContextMockRecorder) GetRemoteAdminClient added in v1.14.0

func (mr *MockContextMockRecorder) GetRemoteAdminClient(arg0 interface{}) *gomock.Call

GetRemoteAdminClient indicates an expected call of GetRemoteAdminClient.

func (*MockContextMockRecorder) GetReplicationStatus added in v1.14.0

func (mr *MockContextMockRecorder) GetReplicationStatus(cluster interface{}) *gomock.Call

GetReplicationStatus indicates an expected call of GetReplicationStatus.

func (*MockContextMockRecorder) GetReplicatorDLQAckLevel

func (mr *MockContextMockRecorder) GetReplicatorDLQAckLevel(sourceCluster interface{}) *gomock.Call

GetReplicatorDLQAckLevel indicates an expected call of GetReplicatorDLQAckLevel.

func (*MockContextMockRecorder) GetSearchAttributesMapperProvider added in v1.20.0

func (mr *MockContextMockRecorder) GetSearchAttributesMapperProvider() *gomock.Call

GetSearchAttributesMapperProvider indicates an expected call of GetSearchAttributesMapperProvider.

func (*MockContextMockRecorder) GetSearchAttributesProvider added in v1.14.0

func (mr *MockContextMockRecorder) GetSearchAttributesProvider() *gomock.Call

GetSearchAttributesProvider indicates an expected call of GetSearchAttributesProvider.

func (*MockContextMockRecorder) GetShardID

func (mr *MockContextMockRecorder) GetShardID() *gomock.Call

GetShardID indicates an expected call of GetShardID.

func (*MockContextMockRecorder) GetThrottledLogger

func (mr *MockContextMockRecorder) GetThrottledLogger() *gomock.Call

GetThrottledLogger indicates an expected call of GetThrottledLogger.

func (*MockContextMockRecorder) GetTimeSource

func (mr *MockContextMockRecorder) GetTimeSource() *gomock.Call

GetTimeSource indicates an expected call of GetTimeSource.

func (*MockContextMockRecorder) GetWorkflowExecution added in v1.16.0

func (mr *MockContextMockRecorder) GetWorkflowExecution(ctx, request interface{}) *gomock.Call

GetWorkflowExecution indicates an expected call of GetWorkflowExecution.

func (*MockContextMockRecorder) NewVectorClock added in v1.17.0

func (mr *MockContextMockRecorder) NewVectorClock() *gomock.Call

NewVectorClock indicates an expected call of NewVectorClock.

func (*MockContextMockRecorder) SetCurrentTime

func (mr *MockContextMockRecorder) SetCurrentTime(cluster, currentTime interface{}) *gomock.Call

SetCurrentTime indicates an expected call of SetCurrentTime.

func (*MockContextMockRecorder) SetQueueState added in v1.21.0

func (mr *MockContextMockRecorder) SetQueueState(category, tasksCompleted, state interface{}) *gomock.Call

SetQueueState indicates an expected call of SetQueueState.

func (*MockContextMockRecorder) SetWorkflowExecution added in v1.16.0

func (mr *MockContextMockRecorder) SetWorkflowExecution(ctx, request interface{}) *gomock.Call

SetWorkflowExecution indicates an expected call of SetWorkflowExecution.

func (*MockContextMockRecorder) StateMachineRegistry added in v1.24.0

func (mr *MockContextMockRecorder) StateMachineRegistry() *gomock.Call

StateMachineRegistry indicates an expected call of StateMachineRegistry.

func (*MockContextMockRecorder) UnloadForOwnershipLost added in v1.21.5

func (mr *MockContextMockRecorder) UnloadForOwnershipLost() *gomock.Call

UnloadForOwnershipLost indicates an expected call of UnloadForOwnershipLost.

func (*MockContextMockRecorder) UpdateHandoverNamespace added in v1.20.0

func (mr *MockContextMockRecorder) UpdateHandoverNamespace(ns, deletedFromDb interface{}) *gomock.Call

UpdateHandoverNamespace indicates an expected call of UpdateHandoverNamespace.

func (*MockContextMockRecorder) UpdateRemoteClusterInfo added in v1.16.0

func (mr *MockContextMockRecorder) UpdateRemoteClusterInfo(cluster, ackTaskID, ackTimestamp interface{}) *gomock.Call

UpdateRemoteClusterInfo indicates an expected call of UpdateRemoteClusterInfo.

func (*MockContextMockRecorder) UpdateRemoteReaderInfo added in v1.21.0

func (mr *MockContextMockRecorder) UpdateRemoteReaderInfo(readerID, ackTaskID, ackTimestamp interface{}) *gomock.Call

UpdateRemoteReaderInfo indicates an expected call of UpdateRemoteReaderInfo.

func (*MockContextMockRecorder) UpdateReplicationQueueReaderState added in v1.21.0

func (mr *MockContextMockRecorder) UpdateReplicationQueueReaderState(readerID, readerState interface{}) *gomock.Call

UpdateReplicationQueueReaderState indicates an expected call of UpdateReplicationQueueReaderState.

func (*MockContextMockRecorder) UpdateReplicatorDLQAckLevel

func (mr *MockContextMockRecorder) UpdateReplicatorDLQAckLevel(sourCluster, ackLevel interface{}) *gomock.Call

UpdateReplicatorDLQAckLevel indicates an expected call of UpdateReplicatorDLQAckLevel.

func (*MockContextMockRecorder) UpdateWorkflowExecution

func (mr *MockContextMockRecorder) UpdateWorkflowExecution(ctx, request interface{}) *gomock.Call

UpdateWorkflowExecution indicates an expected call of UpdateWorkflowExecution.

type MockControllableContext added in v1.21.5

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

MockControllableContext is a mock of ControllableContext interface.

func NewMockControllableContext added in v1.21.5

func NewMockControllableContext(ctrl *gomock.Controller) *MockControllableContext

NewMockControllableContext creates a new mock instance.

func (*MockControllableContext) AddSpeculativeWorkflowTaskTimeoutTask added in v1.21.5

func (m *MockControllableContext) AddSpeculativeWorkflowTaskTimeoutTask(task *tasks.WorkflowTaskTimeoutTask) error

AddSpeculativeWorkflowTaskTimeoutTask mocks base method.

func (*MockControllableContext) AddTasks added in v1.21.5

AddTasks mocks base method.

func (*MockControllableContext) AppendHistoryEvents added in v1.21.5

func (m *MockControllableContext) AppendHistoryEvents(ctx context.Context, request *persistence.AppendHistoryNodesRequest, namespaceID namespace.ID, execution *v1.WorkflowExecution) (int, error)

AppendHistoryEvents mocks base method.

func (*MockControllableContext) AssertOwnership added in v1.21.5

func (m *MockControllableContext) AssertOwnership(ctx context.Context) error

AssertOwnership mocks base method.

func (*MockControllableContext) ConflictResolveWorkflowExecution added in v1.21.5

ConflictResolveWorkflowExecution mocks base method.

func (*MockControllableContext) CreateWorkflowExecution added in v1.21.5

CreateWorkflowExecution mocks base method.

func (*MockControllableContext) CurrentVectorClock added in v1.21.5

func (m *MockControllableContext) CurrentVectorClock() *v11.VectorClock

CurrentVectorClock mocks base method.

func (*MockControllableContext) DeleteWorkflowExecution added in v1.21.5

func (m *MockControllableContext) DeleteWorkflowExecution(ctx context.Context, workflowKey definition.WorkflowKey, branchToken []byte, closeExecutionVisibilityTaskID int64, stage *tasks.DeleteWorkflowExecutionStage) error

DeleteWorkflowExecution mocks base method.

func (*MockControllableContext) EXPECT added in v1.21.5

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockControllableContext) FinishStop added in v1.21.5

func (m *MockControllableContext) FinishStop()

FinishStop mocks base method.

func (*MockControllableContext) GenerateTaskID added in v1.21.5

func (m *MockControllableContext) GenerateTaskID() (int64, error)

GenerateTaskID mocks base method.

func (*MockControllableContext) GenerateTaskIDs added in v1.21.5

func (m *MockControllableContext) GenerateTaskIDs(number int) ([]int64, error)

GenerateTaskIDs mocks base method.

func (*MockControllableContext) GetArchivalMetadata added in v1.21.5

func (m *MockControllableContext) GetArchivalMetadata() archiver.ArchivalMetadata

GetArchivalMetadata mocks base method.

func (*MockControllableContext) GetClusterMetadata added in v1.21.5

func (m *MockControllableContext) GetClusterMetadata() cluster.Metadata

GetClusterMetadata mocks base method.

func (*MockControllableContext) GetConfig added in v1.21.5

func (m *MockControllableContext) GetConfig() *configs.Config

GetConfig mocks base method.

func (*MockControllableContext) GetCurrentExecution added in v1.21.5

GetCurrentExecution mocks base method.

func (*MockControllableContext) GetCurrentTime added in v1.21.5

func (m *MockControllableContext) GetCurrentTime(cluster string) time.Time

GetCurrentTime mocks base method.

func (*MockControllableContext) GetEngine added in v1.21.5

func (m *MockControllableContext) GetEngine(ctx context.Context) (Engine, error)

GetEngine mocks base method.

func (*MockControllableContext) GetEventsCache added in v1.21.5

func (m *MockControllableContext) GetEventsCache() events.Cache

GetEventsCache mocks base method.

func (*MockControllableContext) GetExecutionManager added in v1.21.5

func (m *MockControllableContext) GetExecutionManager() persistence.ExecutionManager

GetExecutionManager mocks base method.

func (*MockControllableContext) GetHistoryClient added in v1.21.5

func (m *MockControllableContext) GetHistoryClient() v12.HistoryServiceClient

GetHistoryClient mocks base method.

func (*MockControllableContext) GetLogger added in v1.21.5

func (m *MockControllableContext) GetLogger() log.Logger

GetLogger mocks base method.

func (*MockControllableContext) GetMetricsHandler added in v1.21.5

func (m *MockControllableContext) GetMetricsHandler() metrics.Handler

GetMetricsHandler mocks base method.

func (*MockControllableContext) GetNamespaceRegistry added in v1.21.5

func (m *MockControllableContext) GetNamespaceRegistry() namespace.Registry

GetNamespaceRegistry mocks base method.

func (*MockControllableContext) GetOwner added in v1.21.5

func (m *MockControllableContext) GetOwner() string

GetOwner mocks base method.

func (*MockControllableContext) GetPayloadSerializer added in v1.21.5

func (m *MockControllableContext) GetPayloadSerializer() serialization.Serializer

GetPayloadSerializer mocks base method.

func (*MockControllableContext) GetPingChecks added in v1.21.5

func (m *MockControllableContext) GetPingChecks() []pingable.Check

GetPingChecks mocks base method.

func (*MockControllableContext) GetQueueExclusiveHighReadWatermark added in v1.23.0

func (m *MockControllableContext) GetQueueExclusiveHighReadWatermark(category tasks.Category) tasks.Key

GetQueueExclusiveHighReadWatermark mocks base method.

func (*MockControllableContext) GetQueueState added in v1.21.5

func (m *MockControllableContext) GetQueueState(category tasks.Category) (*v13.QueueState, bool)

GetQueueState mocks base method.

func (*MockControllableContext) GetRangeID added in v1.21.5

func (m *MockControllableContext) GetRangeID() int64

GetRangeID mocks base method.

func (*MockControllableContext) GetRemoteAdminClient added in v1.21.5

func (m *MockControllableContext) GetRemoteAdminClient(arg0 string) (v10.AdminServiceClient, error)

GetRemoteAdminClient mocks base method.

func (*MockControllableContext) GetReplicationStatus added in v1.21.5

GetReplicationStatus mocks base method.

func (*MockControllableContext) GetReplicatorDLQAckLevel added in v1.21.5

func (m *MockControllableContext) GetReplicatorDLQAckLevel(sourceCluster string) int64

GetReplicatorDLQAckLevel mocks base method.

func (*MockControllableContext) GetSearchAttributesMapperProvider added in v1.21.5

func (m *MockControllableContext) GetSearchAttributesMapperProvider() searchattribute.MapperProvider

GetSearchAttributesMapperProvider mocks base method.

func (*MockControllableContext) GetSearchAttributesProvider added in v1.21.5

func (m *MockControllableContext) GetSearchAttributesProvider() searchattribute.Provider

GetSearchAttributesProvider mocks base method.

func (*MockControllableContext) GetShardID added in v1.21.5

func (m *MockControllableContext) GetShardID() int32

GetShardID mocks base method.

func (*MockControllableContext) GetThrottledLogger added in v1.21.5

func (m *MockControllableContext) GetThrottledLogger() log.Logger

GetThrottledLogger mocks base method.

func (*MockControllableContext) GetTimeSource added in v1.21.5

func (m *MockControllableContext) GetTimeSource() clock.TimeSource

GetTimeSource mocks base method.

func (*MockControllableContext) GetWorkflowExecution added in v1.21.5

GetWorkflowExecution mocks base method.

func (*MockControllableContext) IsValid added in v1.21.5

func (m *MockControllableContext) IsValid() bool

IsValid mocks base method.

func (*MockControllableContext) NewVectorClock added in v1.21.5

func (m *MockControllableContext) NewVectorClock() (*v11.VectorClock, error)

NewVectorClock mocks base method.

func (*MockControllableContext) SetCurrentTime added in v1.21.5

func (m *MockControllableContext) SetCurrentTime(cluster string, currentTime time.Time)

SetCurrentTime mocks base method.

func (*MockControllableContext) SetQueueState added in v1.21.5

func (m *MockControllableContext) SetQueueState(category tasks.Category, tasksCompleted int, state *v13.QueueState) error

SetQueueState mocks base method.

func (*MockControllableContext) SetWorkflowExecution added in v1.21.5

SetWorkflowExecution mocks base method.

func (*MockControllableContext) StateMachineRegistry added in v1.24.0

func (m *MockControllableContext) StateMachineRegistry() *hsm.Registry

StateMachineRegistry mocks base method.

func (*MockControllableContext) UnloadForOwnershipLost added in v1.21.5

func (m *MockControllableContext) UnloadForOwnershipLost()

UnloadForOwnershipLost mocks base method.

func (*MockControllableContext) UpdateHandoverNamespace added in v1.21.5

func (m *MockControllableContext) UpdateHandoverNamespace(ns *namespace.Namespace, deletedFromDb bool)

UpdateHandoverNamespace mocks base method.

func (*MockControllableContext) UpdateRemoteClusterInfo added in v1.21.5

func (m *MockControllableContext) UpdateRemoteClusterInfo(cluster string, ackTaskID int64, ackTimestamp time.Time)

UpdateRemoteClusterInfo mocks base method.

func (*MockControllableContext) UpdateRemoteReaderInfo added in v1.21.5

func (m *MockControllableContext) UpdateRemoteReaderInfo(readerID, ackTaskID int64, ackTimestamp time.Time) error

UpdateRemoteReaderInfo mocks base method.

func (*MockControllableContext) UpdateReplicationQueueReaderState added in v1.21.5

func (m *MockControllableContext) UpdateReplicationQueueReaderState(readerID int64, readerState *v13.QueueReaderState) error

UpdateReplicationQueueReaderState mocks base method.

func (*MockControllableContext) UpdateReplicatorDLQAckLevel added in v1.21.5

func (m *MockControllableContext) UpdateReplicatorDLQAckLevel(sourCluster string, ackLevel int64) error

UpdateReplicatorDLQAckLevel mocks base method.

func (*MockControllableContext) UpdateWorkflowExecution added in v1.21.5

UpdateWorkflowExecution mocks base method.

type MockControllableContextMockRecorder added in v1.21.5

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

MockControllableContextMockRecorder is the mock recorder for MockControllableContext.

func (*MockControllableContextMockRecorder) AddSpeculativeWorkflowTaskTimeoutTask added in v1.21.5

func (mr *MockControllableContextMockRecorder) AddSpeculativeWorkflowTaskTimeoutTask(task interface{}) *gomock.Call

AddSpeculativeWorkflowTaskTimeoutTask indicates an expected call of AddSpeculativeWorkflowTaskTimeoutTask.

func (*MockControllableContextMockRecorder) AddTasks added in v1.21.5

func (mr *MockControllableContextMockRecorder) AddTasks(ctx, request interface{}) *gomock.Call

AddTasks indicates an expected call of AddTasks.

func (*MockControllableContextMockRecorder) AppendHistoryEvents added in v1.21.5

func (mr *MockControllableContextMockRecorder) AppendHistoryEvents(ctx, request, namespaceID, execution interface{}) *gomock.Call

AppendHistoryEvents indicates an expected call of AppendHistoryEvents.

func (*MockControllableContextMockRecorder) AssertOwnership added in v1.21.5

func (mr *MockControllableContextMockRecorder) AssertOwnership(ctx interface{}) *gomock.Call

AssertOwnership indicates an expected call of AssertOwnership.

func (*MockControllableContextMockRecorder) ConflictResolveWorkflowExecution added in v1.21.5

func (mr *MockControllableContextMockRecorder) ConflictResolveWorkflowExecution(ctx, request interface{}) *gomock.Call

ConflictResolveWorkflowExecution indicates an expected call of ConflictResolveWorkflowExecution.

func (*MockControllableContextMockRecorder) CreateWorkflowExecution added in v1.21.5

func (mr *MockControllableContextMockRecorder) CreateWorkflowExecution(ctx, request interface{}) *gomock.Call

CreateWorkflowExecution indicates an expected call of CreateWorkflowExecution.

func (*MockControllableContextMockRecorder) CurrentVectorClock added in v1.21.5

func (mr *MockControllableContextMockRecorder) CurrentVectorClock() *gomock.Call

CurrentVectorClock indicates an expected call of CurrentVectorClock.

func (*MockControllableContextMockRecorder) DeleteWorkflowExecution added in v1.21.5

func (mr *MockControllableContextMockRecorder) DeleteWorkflowExecution(ctx, workflowKey, branchToken, closeExecutionVisibilityTaskID, stage interface{}) *gomock.Call

DeleteWorkflowExecution indicates an expected call of DeleteWorkflowExecution.

func (*MockControllableContextMockRecorder) FinishStop added in v1.21.5

FinishStop indicates an expected call of FinishStop.

func (*MockControllableContextMockRecorder) GenerateTaskID added in v1.21.5

func (mr *MockControllableContextMockRecorder) GenerateTaskID() *gomock.Call

GenerateTaskID indicates an expected call of GenerateTaskID.

func (*MockControllableContextMockRecorder) GenerateTaskIDs added in v1.21.5

func (mr *MockControllableContextMockRecorder) GenerateTaskIDs(number interface{}) *gomock.Call

GenerateTaskIDs indicates an expected call of GenerateTaskIDs.

func (*MockControllableContextMockRecorder) GetArchivalMetadata added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetArchivalMetadata() *gomock.Call

GetArchivalMetadata indicates an expected call of GetArchivalMetadata.

func (*MockControllableContextMockRecorder) GetClusterMetadata added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetClusterMetadata() *gomock.Call

GetClusterMetadata indicates an expected call of GetClusterMetadata.

func (*MockControllableContextMockRecorder) GetConfig added in v1.21.5

GetConfig indicates an expected call of GetConfig.

func (*MockControllableContextMockRecorder) GetCurrentExecution added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetCurrentExecution(ctx, request interface{}) *gomock.Call

GetCurrentExecution indicates an expected call of GetCurrentExecution.

func (*MockControllableContextMockRecorder) GetCurrentTime added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetCurrentTime(cluster interface{}) *gomock.Call

GetCurrentTime indicates an expected call of GetCurrentTime.

func (*MockControllableContextMockRecorder) GetEngine added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetEngine(ctx interface{}) *gomock.Call

GetEngine indicates an expected call of GetEngine.

func (*MockControllableContextMockRecorder) GetEventsCache added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetEventsCache() *gomock.Call

GetEventsCache indicates an expected call of GetEventsCache.

func (*MockControllableContextMockRecorder) GetExecutionManager added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetExecutionManager() *gomock.Call

GetExecutionManager indicates an expected call of GetExecutionManager.

func (*MockControllableContextMockRecorder) GetHistoryClient added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetHistoryClient() *gomock.Call

GetHistoryClient indicates an expected call of GetHistoryClient.

func (*MockControllableContextMockRecorder) GetLogger added in v1.21.5

GetLogger indicates an expected call of GetLogger.

func (*MockControllableContextMockRecorder) GetMetricsHandler added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetMetricsHandler() *gomock.Call

GetMetricsHandler indicates an expected call of GetMetricsHandler.

func (*MockControllableContextMockRecorder) GetNamespaceRegistry added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetNamespaceRegistry() *gomock.Call

GetNamespaceRegistry indicates an expected call of GetNamespaceRegistry.

func (*MockControllableContextMockRecorder) GetOwner added in v1.21.5

GetOwner indicates an expected call of GetOwner.

func (*MockControllableContextMockRecorder) GetPayloadSerializer added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetPayloadSerializer() *gomock.Call

GetPayloadSerializer indicates an expected call of GetPayloadSerializer.

func (*MockControllableContextMockRecorder) GetPingChecks added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetPingChecks() *gomock.Call

GetPingChecks indicates an expected call of GetPingChecks.

func (*MockControllableContextMockRecorder) GetQueueExclusiveHighReadWatermark added in v1.23.0

func (mr *MockControllableContextMockRecorder) GetQueueExclusiveHighReadWatermark(category interface{}) *gomock.Call

GetQueueExclusiveHighReadWatermark indicates an expected call of GetQueueExclusiveHighReadWatermark.

func (*MockControllableContextMockRecorder) GetQueueState added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetQueueState(category interface{}) *gomock.Call

GetQueueState indicates an expected call of GetQueueState.

func (*MockControllableContextMockRecorder) GetRangeID added in v1.21.5

GetRangeID indicates an expected call of GetRangeID.

func (*MockControllableContextMockRecorder) GetRemoteAdminClient added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetRemoteAdminClient(arg0 interface{}) *gomock.Call

GetRemoteAdminClient indicates an expected call of GetRemoteAdminClient.

func (*MockControllableContextMockRecorder) GetReplicationStatus added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetReplicationStatus(cluster interface{}) *gomock.Call

GetReplicationStatus indicates an expected call of GetReplicationStatus.

func (*MockControllableContextMockRecorder) GetReplicatorDLQAckLevel added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetReplicatorDLQAckLevel(sourceCluster interface{}) *gomock.Call

GetReplicatorDLQAckLevel indicates an expected call of GetReplicatorDLQAckLevel.

func (*MockControllableContextMockRecorder) GetSearchAttributesMapperProvider added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetSearchAttributesMapperProvider() *gomock.Call

GetSearchAttributesMapperProvider indicates an expected call of GetSearchAttributesMapperProvider.

func (*MockControllableContextMockRecorder) GetSearchAttributesProvider added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetSearchAttributesProvider() *gomock.Call

GetSearchAttributesProvider indicates an expected call of GetSearchAttributesProvider.

func (*MockControllableContextMockRecorder) GetShardID added in v1.21.5

GetShardID indicates an expected call of GetShardID.

func (*MockControllableContextMockRecorder) GetThrottledLogger added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetThrottledLogger() *gomock.Call

GetThrottledLogger indicates an expected call of GetThrottledLogger.

func (*MockControllableContextMockRecorder) GetTimeSource added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetTimeSource() *gomock.Call

GetTimeSource indicates an expected call of GetTimeSource.

func (*MockControllableContextMockRecorder) GetWorkflowExecution added in v1.21.5

func (mr *MockControllableContextMockRecorder) GetWorkflowExecution(ctx, request interface{}) *gomock.Call

GetWorkflowExecution indicates an expected call of GetWorkflowExecution.

func (*MockControllableContextMockRecorder) IsValid added in v1.21.5

IsValid indicates an expected call of IsValid.

func (*MockControllableContextMockRecorder) NewVectorClock added in v1.21.5

func (mr *MockControllableContextMockRecorder) NewVectorClock() *gomock.Call

NewVectorClock indicates an expected call of NewVectorClock.

func (*MockControllableContextMockRecorder) SetCurrentTime added in v1.21.5

func (mr *MockControllableContextMockRecorder) SetCurrentTime(cluster, currentTime interface{}) *gomock.Call

SetCurrentTime indicates an expected call of SetCurrentTime.

func (*MockControllableContextMockRecorder) SetQueueState added in v1.21.5

func (mr *MockControllableContextMockRecorder) SetQueueState(category, tasksCompleted, state interface{}) *gomock.Call

SetQueueState indicates an expected call of SetQueueState.

func (*MockControllableContextMockRecorder) SetWorkflowExecution added in v1.21.5

func (mr *MockControllableContextMockRecorder) SetWorkflowExecution(ctx, request interface{}) *gomock.Call

SetWorkflowExecution indicates an expected call of SetWorkflowExecution.

func (*MockControllableContextMockRecorder) StateMachineRegistry added in v1.24.0

func (mr *MockControllableContextMockRecorder) StateMachineRegistry() *gomock.Call

StateMachineRegistry indicates an expected call of StateMachineRegistry.

func (*MockControllableContextMockRecorder) UnloadForOwnershipLost added in v1.21.5

func (mr *MockControllableContextMockRecorder) UnloadForOwnershipLost() *gomock.Call

UnloadForOwnershipLost indicates an expected call of UnloadForOwnershipLost.

func (*MockControllableContextMockRecorder) UpdateHandoverNamespace added in v1.21.5

func (mr *MockControllableContextMockRecorder) UpdateHandoverNamespace(ns, deletedFromDb interface{}) *gomock.Call

UpdateHandoverNamespace indicates an expected call of UpdateHandoverNamespace.

func (*MockControllableContextMockRecorder) UpdateRemoteClusterInfo added in v1.21.5

func (mr *MockControllableContextMockRecorder) UpdateRemoteClusterInfo(cluster, ackTaskID, ackTimestamp interface{}) *gomock.Call

UpdateRemoteClusterInfo indicates an expected call of UpdateRemoteClusterInfo.

func (*MockControllableContextMockRecorder) UpdateRemoteReaderInfo added in v1.21.5

func (mr *MockControllableContextMockRecorder) UpdateRemoteReaderInfo(readerID, ackTaskID, ackTimestamp interface{}) *gomock.Call

UpdateRemoteReaderInfo indicates an expected call of UpdateRemoteReaderInfo.

func (*MockControllableContextMockRecorder) UpdateReplicationQueueReaderState added in v1.21.5

func (mr *MockControllableContextMockRecorder) UpdateReplicationQueueReaderState(readerID, readerState interface{}) *gomock.Call

UpdateReplicationQueueReaderState indicates an expected call of UpdateReplicationQueueReaderState.

func (*MockControllableContextMockRecorder) UpdateReplicatorDLQAckLevel added in v1.21.5

func (mr *MockControllableContextMockRecorder) UpdateReplicatorDLQAckLevel(sourCluster, ackLevel interface{}) *gomock.Call

UpdateReplicatorDLQAckLevel indicates an expected call of UpdateReplicatorDLQAckLevel.

func (*MockControllableContextMockRecorder) UpdateWorkflowExecution added in v1.21.5

func (mr *MockControllableContextMockRecorder) UpdateWorkflowExecution(ctx, request interface{}) *gomock.Call

UpdateWorkflowExecution indicates an expected call of UpdateWorkflowExecution.

type MockController added in v1.17.3

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

MockController is a mock of Controller interface.

func NewMockController added in v1.17.3

func NewMockController(ctrl *gomock.Controller) *MockController

NewMockController creates a new mock instance.

func (*MockController) CloseShardByID added in v1.17.3

func (m *MockController) CloseShardByID(shardID int32)

CloseShardByID mocks base method.

func (*MockController) EXPECT added in v1.17.3

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockController) GetPingChecks added in v1.19.0

func (m *MockController) GetPingChecks() []pingable.Check

GetPingChecks mocks base method.

func (*MockController) GetShardByID added in v1.17.3

func (m *MockController) GetShardByID(shardID int32) (Context, error)

GetShardByID mocks base method.

func (*MockController) GetShardByNamespaceWorkflow added in v1.17.3

func (m *MockController) GetShardByNamespaceWorkflow(namespaceID namespace.ID, workflowID string) (Context, error)

GetShardByNamespaceWorkflow mocks base method.

func (*MockController) ShardIDs added in v1.17.3

func (m *MockController) ShardIDs() []int32

ShardIDs mocks base method.

func (*MockController) Start added in v1.17.3

func (m *MockController) Start()

Start mocks base method.

func (*MockController) Stop added in v1.17.3

func (m *MockController) Stop()

Stop mocks base method.

type MockControllerMockRecorder added in v1.17.3

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

MockControllerMockRecorder is the mock recorder for MockController.

func (*MockControllerMockRecorder) CloseShardByID added in v1.17.3

func (mr *MockControllerMockRecorder) CloseShardByID(shardID interface{}) *gomock.Call

CloseShardByID indicates an expected call of CloseShardByID.

func (*MockControllerMockRecorder) GetPingChecks added in v1.19.0

func (mr *MockControllerMockRecorder) GetPingChecks() *gomock.Call

GetPingChecks indicates an expected call of GetPingChecks.

func (*MockControllerMockRecorder) GetShardByID added in v1.17.3

func (mr *MockControllerMockRecorder) GetShardByID(shardID interface{}) *gomock.Call

GetShardByID indicates an expected call of GetShardByID.

func (*MockControllerMockRecorder) GetShardByNamespaceWorkflow added in v1.17.3

func (mr *MockControllerMockRecorder) GetShardByNamespaceWorkflow(namespaceID, workflowID interface{}) *gomock.Call

GetShardByNamespaceWorkflow indicates an expected call of GetShardByNamespaceWorkflow.

func (*MockControllerMockRecorder) ShardIDs added in v1.17.3

func (mr *MockControllerMockRecorder) ShardIDs() *gomock.Call

ShardIDs indicates an expected call of ShardIDs.

func (*MockControllerMockRecorder) Start added in v1.17.3

func (mr *MockControllerMockRecorder) Start() *gomock.Call

Start indicates an expected call of Start.

func (*MockControllerMockRecorder) Stop added in v1.17.3

Stop indicates an expected call of Stop.

type MockEngine

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

MockEngine is a mock of Engine interface.

func NewMockEngine

func NewMockEngine(ctrl *gomock.Controller) *MockEngine

NewMockEngine creates a new mock instance.

func (*MockEngine) AddSpeculativeWorkflowTaskTimeoutTask added in v1.21.0

func (m *MockEngine) AddSpeculativeWorkflowTaskTimeoutTask(task *tasks.WorkflowTaskTimeoutTask)

AddSpeculativeWorkflowTaskTimeoutTask mocks base method.

func (*MockEngine) AddTasks added in v1.23.0

AddTasks mocks base method.

func (*MockEngine) ConvertReplicationTask added in v1.21.0

func (m *MockEngine) ConvertReplicationTask(ctx context.Context, task tasks.Task) (*repication.ReplicationTask, error)

ConvertReplicationTask mocks base method.

func (*MockEngine) DeleteWorkflowExecution added in v1.15.0

DeleteWorkflowExecution mocks base method.

func (*MockEngine) DescribeMutableState

DescribeMutableState mocks base method.

func (*MockEngine) DescribeWorkflowExecution

DescribeWorkflowExecution mocks base method.

func (*MockEngine) EXPECT

func (m *MockEngine) EXPECT() *MockEngineMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockEngine) ExecuteMultiOperation added in v1.24.0

ExecuteMultiOperation mocks base method.

func (*MockEngine) GenerateLastHistoryReplicationTasks added in v1.14.0

GenerateLastHistoryReplicationTasks mocks base method.

func (*MockEngine) GetDLQMessages

GetDLQMessages mocks base method.

func (*MockEngine) GetDLQReplicationMessages

func (m *MockEngine) GetDLQReplicationMessages(ctx context.Context, taskInfos []*repication.ReplicationTaskInfo) ([]*repication.ReplicationTask, error)

GetDLQReplicationMessages mocks base method.

func (*MockEngine) GetMutableState

GetMutableState mocks base method.

func (*MockEngine) GetReplicationMessages

func (m *MockEngine) GetReplicationMessages(ctx context.Context, pollingCluster string, ackMessageID int64, ackTimestamp time.Time, queryMessageID int64) (*repication.ReplicationMessages, error)

GetReplicationMessages mocks base method.

func (*MockEngine) GetReplicationStatus added in v1.14.0

GetReplicationStatus mocks base method.

func (*MockEngine) GetReplicationTasksIter added in v1.21.0

func (m *MockEngine) GetReplicationTasksIter(ctx context.Context, pollingCluster string, minInclusiveTaskID, maxExclusiveTaskID int64) (collection.Iterator[tasks.Task], error)

GetReplicationTasksIter mocks base method.

func (*MockEngine) GetWorkflowExecutionHistory added in v1.23.0

GetWorkflowExecutionHistory mocks base method.

func (*MockEngine) GetWorkflowExecutionHistoryReverse added in v1.23.0

GetWorkflowExecutionHistoryReverse mocks base method.

func (*MockEngine) GetWorkflowExecutionRawHistory added in v1.24.0

GetWorkflowExecutionRawHistory mocks base method.

func (*MockEngine) GetWorkflowExecutionRawHistoryV2 added in v1.23.0

GetWorkflowExecutionRawHistoryV2 mocks base method.

func (*MockEngine) ImportWorkflowExecution added in v1.23.0

ImportWorkflowExecution mocks base method.

func (*MockEngine) IsActivityTaskValid added in v1.22.0

IsActivityTaskValid mocks base method.

func (*MockEngine) IsWorkflowTaskValid added in v1.22.0

IsWorkflowTaskValid mocks base method.

func (*MockEngine) ListTasks added in v1.24.0

ListTasks mocks base method.

func (*MockEngine) MergeDLQMessages

MergeDLQMessages mocks base method.

func (*MockEngine) NotifyNewHistoryEvent

func (m *MockEngine) NotifyNewHistoryEvent(event *events.Notification)

NotifyNewHistoryEvent mocks base method.

func (*MockEngine) NotifyNewTasks added in v1.16.0

func (m *MockEngine) NotifyNewTasks(tasks map[tasks.Category][]tasks.Task)

NotifyNewTasks mocks base method.

func (*MockEngine) PollMutableState

PollMutableState mocks base method.

func (*MockEngine) PollWorkflowExecutionUpdate added in v1.21.0

PollWorkflowExecutionUpdate mocks base method.

func (*MockEngine) PurgeDLQMessages

PurgeDLQMessages mocks base method.

func (*MockEngine) QueryWorkflow

QueryWorkflow mocks base method.

func (*MockEngine) ReapplyEvents

func (m *MockEngine) ReapplyEvents(ctx context.Context, namespaceUUID namespace.ID, workflowID, runID string, events []*history.HistoryEvent) error

ReapplyEvents mocks base method.

func (*MockEngine) RebuildMutableState added in v1.16.0

func (m *MockEngine) RebuildMutableState(ctx context.Context, namespaceUUID namespace.ID, execution *common.WorkflowExecution) error

RebuildMutableState mocks base method.

func (*MockEngine) RecordActivityTaskHeartbeat

RecordActivityTaskHeartbeat mocks base method.

func (*MockEngine) RecordActivityTaskStarted

RecordActivityTaskStarted mocks base method.

func (*MockEngine) RecordChildExecutionCompleted

RecordChildExecutionCompleted mocks base method.

func (*MockEngine) RecordWorkflowTaskStarted

RecordWorkflowTaskStarted mocks base method.

func (*MockEngine) RefreshWorkflowTasks

func (m *MockEngine) RefreshWorkflowTasks(ctx context.Context, namespaceUUID namespace.ID, execution *common.WorkflowExecution) error

RefreshWorkflowTasks mocks base method.

func (*MockEngine) RemoveSignalMutableState

RemoveSignalMutableState mocks base method.

func (*MockEngine) ReplicateEventsV2

func (m *MockEngine) ReplicateEventsV2(ctx context.Context, request *historyservice.ReplicateEventsV2Request) error

ReplicateEventsV2 mocks base method.

func (*MockEngine) ReplicateHistoryEvents added in v1.23.0

func (m *MockEngine) ReplicateHistoryEvents(ctx context.Context, workflowKey definition.WorkflowKey, baseExecutionInfo *workflow.BaseExecutionInfo, versionHistoryItems []*history0.VersionHistoryItem, historyEvents [][]*history.HistoryEvent, newEvents []*history.HistoryEvent, newRunID string) error

ReplicateHistoryEvents mocks base method.

func (*MockEngine) ReplicateWorkflowState added in v1.17.0

func (m *MockEngine) ReplicateWorkflowState(ctx context.Context, request *historyservice.ReplicateWorkflowStateRequest) error

ReplicateWorkflowState mocks base method.

func (*MockEngine) RequestCancelWorkflowExecution

RequestCancelWorkflowExecution mocks base method.

func (*MockEngine) ResetStickyTaskQueue

ResetStickyTaskQueue mocks base method.

func (*MockEngine) ResetWorkflowExecution

ResetWorkflowExecution mocks base method.

func (*MockEngine) RespondActivityTaskCanceled

RespondActivityTaskCanceled mocks base method.

func (*MockEngine) RespondActivityTaskCompleted

RespondActivityTaskCompleted mocks base method.

func (*MockEngine) RespondActivityTaskFailed

RespondActivityTaskFailed mocks base method.

func (*MockEngine) RespondWorkflowTaskCompleted

RespondWorkflowTaskCompleted mocks base method.

func (*MockEngine) RespondWorkflowTaskFailed

func (m *MockEngine) RespondWorkflowTaskFailed(ctx context.Context, request *historyservice.RespondWorkflowTaskFailedRequest) error

RespondWorkflowTaskFailed mocks base method.

func (*MockEngine) ScheduleWorkflowTask

func (m *MockEngine) ScheduleWorkflowTask(ctx context.Context, request *historyservice.ScheduleWorkflowTaskRequest) error

ScheduleWorkflowTask mocks base method.

func (*MockEngine) SignalWithStartWorkflowExecution

SignalWithStartWorkflowExecution mocks base method.

func (*MockEngine) SignalWorkflowExecution

SignalWorkflowExecution mocks base method.

func (*MockEngine) Start

func (m *MockEngine) Start()

Start mocks base method.

func (*MockEngine) StartWorkflowExecution

StartWorkflowExecution mocks base method.

func (*MockEngine) StateMachineEnvironment added in v1.24.0

func (m *MockEngine) StateMachineEnvironment() hsm.Environment

StateMachineEnvironment mocks base method.

func (*MockEngine) Stop

func (m *MockEngine) Stop()

Stop mocks base method.

func (*MockEngine) SubscribeReplicationNotification added in v1.21.0

func (m *MockEngine) SubscribeReplicationNotification() (<-chan struct{}, string)

SubscribeReplicationNotification mocks base method.

func (*MockEngine) SyncActivities added in v1.24.0

func (m *MockEngine) SyncActivities(ctx context.Context, request *historyservice.SyncActivitiesRequest) error

SyncActivities mocks base method.

func (*MockEngine) SyncActivity

func (m *MockEngine) SyncActivity(ctx context.Context, request *historyservice.SyncActivityRequest) error

SyncActivity mocks base method.

func (*MockEngine) SyncShardStatus

func (m *MockEngine) SyncShardStatus(ctx context.Context, request *historyservice.SyncShardStatusRequest) error

SyncShardStatus mocks base method.

func (*MockEngine) TerminateWorkflowExecution

TerminateWorkflowExecution mocks base method.

func (*MockEngine) UnsubscribeReplicationNotification added in v1.21.0

func (m *MockEngine) UnsubscribeReplicationNotification(arg0 string)

UnsubscribeReplicationNotification mocks base method.

func (*MockEngine) UpdateWorkflowExecution added in v1.20.0

UpdateWorkflowExecution mocks base method.

func (*MockEngine) VerifyChildExecutionCompletionRecorded added in v1.17.0

VerifyChildExecutionCompletionRecorded mocks base method.

func (*MockEngine) VerifyFirstWorkflowTaskScheduled added in v1.17.0

func (m *MockEngine) VerifyFirstWorkflowTaskScheduled(ctx context.Context, request *historyservice.VerifyFirstWorkflowTaskScheduledRequest) error

VerifyFirstWorkflowTaskScheduled mocks base method.

type MockEngineFactory

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

MockEngineFactory is a mock of EngineFactory interface.

func NewMockEngineFactory

func NewMockEngineFactory(ctrl *gomock.Controller) *MockEngineFactory

NewMockEngineFactory creates a new mock instance.

func (*MockEngineFactory) CreateEngine

func (m *MockEngineFactory) CreateEngine(context Context) Engine

CreateEngine mocks base method.

func (*MockEngineFactory) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

type MockEngineFactoryMockRecorder

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

MockEngineFactoryMockRecorder is the mock recorder for MockEngineFactory.

func (*MockEngineFactoryMockRecorder) CreateEngine

func (mr *MockEngineFactoryMockRecorder) CreateEngine(context interface{}) *gomock.Call

CreateEngine indicates an expected call of CreateEngine.

type MockEngineMockRecorder

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

MockEngineMockRecorder is the mock recorder for MockEngine.

func (*MockEngineMockRecorder) AddSpeculativeWorkflowTaskTimeoutTask added in v1.21.0

func (mr *MockEngineMockRecorder) AddSpeculativeWorkflowTaskTimeoutTask(task interface{}) *gomock.Call

AddSpeculativeWorkflowTaskTimeoutTask indicates an expected call of AddSpeculativeWorkflowTaskTimeoutTask.

func (*MockEngineMockRecorder) AddTasks added in v1.23.0

func (mr *MockEngineMockRecorder) AddTasks(ctx, request interface{}) *gomock.Call

AddTasks indicates an expected call of AddTasks.

func (*MockEngineMockRecorder) ConvertReplicationTask added in v1.21.0

func (mr *MockEngineMockRecorder) ConvertReplicationTask(ctx, task interface{}) *gomock.Call

ConvertReplicationTask indicates an expected call of ConvertReplicationTask.

func (*MockEngineMockRecorder) DeleteWorkflowExecution added in v1.15.0

func (mr *MockEngineMockRecorder) DeleteWorkflowExecution(ctx, deleteRequest interface{}) *gomock.Call

DeleteWorkflowExecution indicates an expected call of DeleteWorkflowExecution.

func (*MockEngineMockRecorder) DescribeMutableState

func (mr *MockEngineMockRecorder) DescribeMutableState(ctx, request interface{}) *gomock.Call

DescribeMutableState indicates an expected call of DescribeMutableState.

func (*MockEngineMockRecorder) DescribeWorkflowExecution

func (mr *MockEngineMockRecorder) DescribeWorkflowExecution(ctx, request interface{}) *gomock.Call

DescribeWorkflowExecution indicates an expected call of DescribeWorkflowExecution.

func (*MockEngineMockRecorder) ExecuteMultiOperation added in v1.24.0

func (mr *MockEngineMockRecorder) ExecuteMultiOperation(ctx, request interface{}) *gomock.Call

ExecuteMultiOperation indicates an expected call of ExecuteMultiOperation.

func (*MockEngineMockRecorder) GenerateLastHistoryReplicationTasks added in v1.14.0

func (mr *MockEngineMockRecorder) GenerateLastHistoryReplicationTasks(ctx, request interface{}) *gomock.Call

GenerateLastHistoryReplicationTasks indicates an expected call of GenerateLastHistoryReplicationTasks.

func (*MockEngineMockRecorder) GetDLQMessages

func (mr *MockEngineMockRecorder) GetDLQMessages(ctx, messagesRequest interface{}) *gomock.Call

GetDLQMessages indicates an expected call of GetDLQMessages.

func (*MockEngineMockRecorder) GetDLQReplicationMessages

func (mr *MockEngineMockRecorder) GetDLQReplicationMessages(ctx, taskInfos interface{}) *gomock.Call

GetDLQReplicationMessages indicates an expected call of GetDLQReplicationMessages.

func (*MockEngineMockRecorder) GetMutableState

func (mr *MockEngineMockRecorder) GetMutableState(ctx, request interface{}) *gomock.Call

GetMutableState indicates an expected call of GetMutableState.

func (*MockEngineMockRecorder) GetReplicationMessages

func (mr *MockEngineMockRecorder) GetReplicationMessages(ctx, pollingCluster, ackMessageID, ackTimestamp, queryMessageID interface{}) *gomock.Call

GetReplicationMessages indicates an expected call of GetReplicationMessages.

func (*MockEngineMockRecorder) GetReplicationStatus added in v1.14.0

func (mr *MockEngineMockRecorder) GetReplicationStatus(ctx, request interface{}) *gomock.Call

GetReplicationStatus indicates an expected call of GetReplicationStatus.

func (*MockEngineMockRecorder) GetReplicationTasksIter added in v1.21.0

func (mr *MockEngineMockRecorder) GetReplicationTasksIter(ctx, pollingCluster, minInclusiveTaskID, maxExclusiveTaskID interface{}) *gomock.Call

GetReplicationTasksIter indicates an expected call of GetReplicationTasksIter.

func (*MockEngineMockRecorder) GetWorkflowExecutionHistory added in v1.23.0

func (mr *MockEngineMockRecorder) GetWorkflowExecutionHistory(ctx, request interface{}) *gomock.Call

GetWorkflowExecutionHistory indicates an expected call of GetWorkflowExecutionHistory.

func (*MockEngineMockRecorder) GetWorkflowExecutionHistoryReverse added in v1.23.0

func (mr *MockEngineMockRecorder) GetWorkflowExecutionHistoryReverse(ctx, request interface{}) *gomock.Call

GetWorkflowExecutionHistoryReverse indicates an expected call of GetWorkflowExecutionHistoryReverse.

func (*MockEngineMockRecorder) GetWorkflowExecutionRawHistory added in v1.24.0

func (mr *MockEngineMockRecorder) GetWorkflowExecutionRawHistory(ctx, request interface{}) *gomock.Call

GetWorkflowExecutionRawHistory indicates an expected call of GetWorkflowExecutionRawHistory.

func (*MockEngineMockRecorder) GetWorkflowExecutionRawHistoryV2 added in v1.23.0

func (mr *MockEngineMockRecorder) GetWorkflowExecutionRawHistoryV2(ctx, request interface{}) *gomock.Call

GetWorkflowExecutionRawHistoryV2 indicates an expected call of GetWorkflowExecutionRawHistoryV2.

func (*MockEngineMockRecorder) ImportWorkflowExecution added in v1.23.0

func (mr *MockEngineMockRecorder) ImportWorkflowExecution(ctx, request interface{}) *gomock.Call

ImportWorkflowExecution indicates an expected call of ImportWorkflowExecution.

func (*MockEngineMockRecorder) IsActivityTaskValid added in v1.22.0

func (mr *MockEngineMockRecorder) IsActivityTaskValid(ctx, request interface{}) *gomock.Call

IsActivityTaskValid indicates an expected call of IsActivityTaskValid.

func (*MockEngineMockRecorder) IsWorkflowTaskValid added in v1.22.0

func (mr *MockEngineMockRecorder) IsWorkflowTaskValid(ctx, request interface{}) *gomock.Call

IsWorkflowTaskValid indicates an expected call of IsWorkflowTaskValid.

func (*MockEngineMockRecorder) ListTasks added in v1.24.0

func (mr *MockEngineMockRecorder) ListTasks(ctx, request interface{}) *gomock.Call

ListTasks indicates an expected call of ListTasks.

func (*MockEngineMockRecorder) MergeDLQMessages

func (mr *MockEngineMockRecorder) MergeDLQMessages(ctx, messagesRequest interface{}) *gomock.Call

MergeDLQMessages indicates an expected call of MergeDLQMessages.

func (*MockEngineMockRecorder) NotifyNewHistoryEvent

func (mr *MockEngineMockRecorder) NotifyNewHistoryEvent(event interface{}) *gomock.Call

NotifyNewHistoryEvent indicates an expected call of NotifyNewHistoryEvent.

func (*MockEngineMockRecorder) NotifyNewTasks added in v1.16.0

func (mr *MockEngineMockRecorder) NotifyNewTasks(tasks interface{}) *gomock.Call

NotifyNewTasks indicates an expected call of NotifyNewTasks.

func (*MockEngineMockRecorder) PollMutableState

func (mr *MockEngineMockRecorder) PollMutableState(ctx, request interface{}) *gomock.Call

PollMutableState indicates an expected call of PollMutableState.

func (*MockEngineMockRecorder) PollWorkflowExecutionUpdate added in v1.21.0

func (mr *MockEngineMockRecorder) PollWorkflowExecutionUpdate(ctx, request interface{}) *gomock.Call

PollWorkflowExecutionUpdate indicates an expected call of PollWorkflowExecutionUpdate.

func (*MockEngineMockRecorder) PurgeDLQMessages

func (mr *MockEngineMockRecorder) PurgeDLQMessages(ctx, messagesRequest interface{}) *gomock.Call

PurgeDLQMessages indicates an expected call of PurgeDLQMessages.

func (*MockEngineMockRecorder) QueryWorkflow

func (mr *MockEngineMockRecorder) QueryWorkflow(ctx, request interface{}) *gomock.Call

QueryWorkflow indicates an expected call of QueryWorkflow.

func (*MockEngineMockRecorder) ReapplyEvents

func (mr *MockEngineMockRecorder) ReapplyEvents(ctx, namespaceUUID, workflowID, runID, events interface{}) *gomock.Call

ReapplyEvents indicates an expected call of ReapplyEvents.

func (*MockEngineMockRecorder) RebuildMutableState added in v1.16.0

func (mr *MockEngineMockRecorder) RebuildMutableState(ctx, namespaceUUID, execution interface{}) *gomock.Call

RebuildMutableState indicates an expected call of RebuildMutableState.

func (*MockEngineMockRecorder) RecordActivityTaskHeartbeat

func (mr *MockEngineMockRecorder) RecordActivityTaskHeartbeat(ctx, request interface{}) *gomock.Call

RecordActivityTaskHeartbeat indicates an expected call of RecordActivityTaskHeartbeat.

func (*MockEngineMockRecorder) RecordActivityTaskStarted

func (mr *MockEngineMockRecorder) RecordActivityTaskStarted(ctx, request interface{}) *gomock.Call

RecordActivityTaskStarted indicates an expected call of RecordActivityTaskStarted.

func (*MockEngineMockRecorder) RecordChildExecutionCompleted

func (mr *MockEngineMockRecorder) RecordChildExecutionCompleted(ctx, request interface{}) *gomock.Call

RecordChildExecutionCompleted indicates an expected call of RecordChildExecutionCompleted.

func (*MockEngineMockRecorder) RecordWorkflowTaskStarted

func (mr *MockEngineMockRecorder) RecordWorkflowTaskStarted(ctx, request interface{}) *gomock.Call

RecordWorkflowTaskStarted indicates an expected call of RecordWorkflowTaskStarted.

func (*MockEngineMockRecorder) RefreshWorkflowTasks

func (mr *MockEngineMockRecorder) RefreshWorkflowTasks(ctx, namespaceUUID, execution interface{}) *gomock.Call

RefreshWorkflowTasks indicates an expected call of RefreshWorkflowTasks.

func (*MockEngineMockRecorder) RemoveSignalMutableState

func (mr *MockEngineMockRecorder) RemoveSignalMutableState(ctx, request interface{}) *gomock.Call

RemoveSignalMutableState indicates an expected call of RemoveSignalMutableState.

func (*MockEngineMockRecorder) ReplicateEventsV2

func (mr *MockEngineMockRecorder) ReplicateEventsV2(ctx, request interface{}) *gomock.Call

ReplicateEventsV2 indicates an expected call of ReplicateEventsV2.

func (*MockEngineMockRecorder) ReplicateHistoryEvents added in v1.23.0

func (mr *MockEngineMockRecorder) ReplicateHistoryEvents(ctx, workflowKey, baseExecutionInfo, versionHistoryItems, historyEvents, newEvents, newRunID interface{}) *gomock.Call

ReplicateHistoryEvents indicates an expected call of ReplicateHistoryEvents.

func (*MockEngineMockRecorder) ReplicateWorkflowState added in v1.17.0

func (mr *MockEngineMockRecorder) ReplicateWorkflowState(ctx, request interface{}) *gomock.Call

ReplicateWorkflowState indicates an expected call of ReplicateWorkflowState.

func (*MockEngineMockRecorder) RequestCancelWorkflowExecution

func (mr *MockEngineMockRecorder) RequestCancelWorkflowExecution(ctx, request interface{}) *gomock.Call

RequestCancelWorkflowExecution indicates an expected call of RequestCancelWorkflowExecution.

func (*MockEngineMockRecorder) ResetStickyTaskQueue

func (mr *MockEngineMockRecorder) ResetStickyTaskQueue(ctx, resetRequest interface{}) *gomock.Call

ResetStickyTaskQueue indicates an expected call of ResetStickyTaskQueue.

func (*MockEngineMockRecorder) ResetWorkflowExecution

func (mr *MockEngineMockRecorder) ResetWorkflowExecution(ctx, request interface{}) *gomock.Call

ResetWorkflowExecution indicates an expected call of ResetWorkflowExecution.

func (*MockEngineMockRecorder) RespondActivityTaskCanceled

func (mr *MockEngineMockRecorder) RespondActivityTaskCanceled(ctx, request interface{}) *gomock.Call

RespondActivityTaskCanceled indicates an expected call of RespondActivityTaskCanceled.

func (*MockEngineMockRecorder) RespondActivityTaskCompleted

func (mr *MockEngineMockRecorder) RespondActivityTaskCompleted(ctx, request interface{}) *gomock.Call

RespondActivityTaskCompleted indicates an expected call of RespondActivityTaskCompleted.

func (*MockEngineMockRecorder) RespondActivityTaskFailed

func (mr *MockEngineMockRecorder) RespondActivityTaskFailed(ctx, request interface{}) *gomock.Call

RespondActivityTaskFailed indicates an expected call of RespondActivityTaskFailed.

func (*MockEngineMockRecorder) RespondWorkflowTaskCompleted

func (mr *MockEngineMockRecorder) RespondWorkflowTaskCompleted(ctx, request interface{}) *gomock.Call

RespondWorkflowTaskCompleted indicates an expected call of RespondWorkflowTaskCompleted.

func (*MockEngineMockRecorder) RespondWorkflowTaskFailed

func (mr *MockEngineMockRecorder) RespondWorkflowTaskFailed(ctx, request interface{}) *gomock.Call

RespondWorkflowTaskFailed indicates an expected call of RespondWorkflowTaskFailed.

func (*MockEngineMockRecorder) ScheduleWorkflowTask

func (mr *MockEngineMockRecorder) ScheduleWorkflowTask(ctx, request interface{}) *gomock.Call

ScheduleWorkflowTask indicates an expected call of ScheduleWorkflowTask.

func (*MockEngineMockRecorder) SignalWithStartWorkflowExecution

func (mr *MockEngineMockRecorder) SignalWithStartWorkflowExecution(ctx, request interface{}) *gomock.Call

SignalWithStartWorkflowExecution indicates an expected call of SignalWithStartWorkflowExecution.

func (*MockEngineMockRecorder) SignalWorkflowExecution

func (mr *MockEngineMockRecorder) SignalWorkflowExecution(ctx, request interface{}) *gomock.Call

SignalWorkflowExecution indicates an expected call of SignalWorkflowExecution.

func (*MockEngineMockRecorder) Start

func (mr *MockEngineMockRecorder) Start() *gomock.Call

Start indicates an expected call of Start.

func (*MockEngineMockRecorder) StartWorkflowExecution

func (mr *MockEngineMockRecorder) StartWorkflowExecution(ctx, request interface{}) *gomock.Call

StartWorkflowExecution indicates an expected call of StartWorkflowExecution.

func (*MockEngineMockRecorder) StateMachineEnvironment added in v1.24.0

func (mr *MockEngineMockRecorder) StateMachineEnvironment() *gomock.Call

StateMachineEnvironment indicates an expected call of StateMachineEnvironment.

func (*MockEngineMockRecorder) Stop

func (mr *MockEngineMockRecorder) Stop() *gomock.Call

Stop indicates an expected call of Stop.

func (*MockEngineMockRecorder) SubscribeReplicationNotification added in v1.21.0

func (mr *MockEngineMockRecorder) SubscribeReplicationNotification() *gomock.Call

SubscribeReplicationNotification indicates an expected call of SubscribeReplicationNotification.

func (*MockEngineMockRecorder) SyncActivities added in v1.24.0

func (mr *MockEngineMockRecorder) SyncActivities(ctx, request interface{}) *gomock.Call

SyncActivities indicates an expected call of SyncActivities.

func (*MockEngineMockRecorder) SyncActivity

func (mr *MockEngineMockRecorder) SyncActivity(ctx, request interface{}) *gomock.Call

SyncActivity indicates an expected call of SyncActivity.

func (*MockEngineMockRecorder) SyncShardStatus

func (mr *MockEngineMockRecorder) SyncShardStatus(ctx, request interface{}) *gomock.Call

SyncShardStatus indicates an expected call of SyncShardStatus.

func (*MockEngineMockRecorder) TerminateWorkflowExecution

func (mr *MockEngineMockRecorder) TerminateWorkflowExecution(ctx, request interface{}) *gomock.Call

TerminateWorkflowExecution indicates an expected call of TerminateWorkflowExecution.

func (*MockEngineMockRecorder) UnsubscribeReplicationNotification added in v1.21.0

func (mr *MockEngineMockRecorder) UnsubscribeReplicationNotification(arg0 interface{}) *gomock.Call

UnsubscribeReplicationNotification indicates an expected call of UnsubscribeReplicationNotification.

func (*MockEngineMockRecorder) UpdateWorkflowExecution added in v1.20.0

func (mr *MockEngineMockRecorder) UpdateWorkflowExecution(ctx, request interface{}) *gomock.Call

UpdateWorkflowExecution indicates an expected call of UpdateWorkflowExecution.

func (*MockEngineMockRecorder) VerifyChildExecutionCompletionRecorded added in v1.17.0

func (mr *MockEngineMockRecorder) VerifyChildExecutionCompletionRecorded(ctx, request interface{}) *gomock.Call

VerifyChildExecutionCompletionRecorded indicates an expected call of VerifyChildExecutionCompletionRecorded.

func (*MockEngineMockRecorder) VerifyFirstWorkflowTaskScheduled added in v1.17.0

func (mr *MockEngineMockRecorder) VerifyFirstWorkflowTaskScheduled(ctx, request interface{}) *gomock.Call

VerifyFirstWorkflowTaskScheduled indicates an expected call of VerifyFirstWorkflowTaskScheduled.

type MockReplicationStream added in v1.21.0

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

MockReplicationStream is a mock of ReplicationStream interface.

func NewMockReplicationStream added in v1.21.0

func NewMockReplicationStream(ctrl *gomock.Controller) *MockReplicationStream

NewMockReplicationStream creates a new mock instance.

func (*MockReplicationStream) ConvertReplicationTask added in v1.21.0

func (m *MockReplicationStream) ConvertReplicationTask(ctx context.Context, task tasks.Task) (*repication.ReplicationTask, error)

ConvertReplicationTask mocks base method.

func (*MockReplicationStream) EXPECT added in v1.21.0

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockReplicationStream) GetReplicationTasksIter added in v1.21.0

func (m *MockReplicationStream) GetReplicationTasksIter(ctx context.Context, pollingCluster string, minInclusiveTaskID, maxExclusiveTaskID int64) (collection.Iterator[tasks.Task], error)

GetReplicationTasksIter mocks base method.

func (*MockReplicationStream) SubscribeReplicationNotification added in v1.21.0

func (m *MockReplicationStream) SubscribeReplicationNotification() (<-chan struct{}, string)

SubscribeReplicationNotification mocks base method.

func (*MockReplicationStream) UnsubscribeReplicationNotification added in v1.21.0

func (m *MockReplicationStream) UnsubscribeReplicationNotification(arg0 string)

UnsubscribeReplicationNotification mocks base method.

type MockReplicationStreamMockRecorder added in v1.21.0

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

MockReplicationStreamMockRecorder is the mock recorder for MockReplicationStream.

func (*MockReplicationStreamMockRecorder) ConvertReplicationTask added in v1.21.0

func (mr *MockReplicationStreamMockRecorder) ConvertReplicationTask(ctx, task interface{}) *gomock.Call

ConvertReplicationTask indicates an expected call of ConvertReplicationTask.

func (*MockReplicationStreamMockRecorder) GetReplicationTasksIter added in v1.21.0

func (mr *MockReplicationStreamMockRecorder) GetReplicationTasksIter(ctx, pollingCluster, minInclusiveTaskID, maxExclusiveTaskID interface{}) *gomock.Call

GetReplicationTasksIter indicates an expected call of GetReplicationTasksIter.

func (*MockReplicationStreamMockRecorder) SubscribeReplicationNotification added in v1.21.0

func (mr *MockReplicationStreamMockRecorder) SubscribeReplicationNotification() *gomock.Call

SubscribeReplicationNotification indicates an expected call of SubscribeReplicationNotification.

func (*MockReplicationStreamMockRecorder) UnsubscribeReplicationNotification added in v1.21.0

func (mr *MockReplicationStreamMockRecorder) UnsubscribeReplicationNotification(arg0 interface{}) *gomock.Call

UnsubscribeReplicationNotification indicates an expected call of UnsubscribeReplicationNotification.

type OwnershipAwareNamespaceQuotaCalculator added in v1.23.0

type OwnershipAwareNamespaceQuotaCalculator struct {
	calculator.ClusterAwareNamespaceQuotaCalculator
	// contains filtered or unexported fields
}

func NewOwnershipAwareNamespaceQuotaCalculator added in v1.23.0

func NewOwnershipAwareNamespaceQuotaCalculator(
	scaler OwnershipBasedQuotaScaler,
	memberCounter calculator.MemberCounter,
	perInstanceQuota func(namespace string) int,
	globalQuota func(namespace string) int,
) *OwnershipAwareNamespaceQuotaCalculator

func (*OwnershipAwareNamespaceQuotaCalculator) GetQuota added in v1.23.0

func (c *OwnershipAwareNamespaceQuotaCalculator) GetQuota(namespace string) float64

type OwnershipAwareQuotaCalculator added in v1.23.0

type OwnershipAwareQuotaCalculator struct {
	calculator.ClusterAwareQuotaCalculator
	// contains filtered or unexported fields
}

func NewOwnershipAwareQuotaCalculator added in v1.23.0

func NewOwnershipAwareQuotaCalculator(
	scaler OwnershipBasedQuotaScaler,
	memberCounter calculator.MemberCounter,
	perInstanceQuota func() int,
	globalQuota func() int,
) *OwnershipAwareQuotaCalculator

func (*OwnershipAwareQuotaCalculator) GetQuota added in v1.23.0

func (c *OwnershipAwareQuotaCalculator) GetQuota() float64

type OwnershipBasedQuotaScaler added in v1.22.0

type OwnershipBasedQuotaScaler interface {
	ScaleFactor() (float64, bool)
}

type OwnershipBasedQuotaScalerImpl added in v1.23.0

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

OwnershipBasedQuotaScalerImpl scales rate-limiting quotas linearly with the fraction of the total shards in the cluster owned by this host. The purpose is to allocate more quota to hosts with a higher workload. This object can be obtained from the fx Module within this package.

func NewOwnershipBasedQuotaScaler added in v1.22.0

func NewOwnershipBasedQuotaScaler(
	shardCounter ShardCounter,
	totalNumShards int,
	updateAppliedCallback chan struct{},
) (*OwnershipBasedQuotaScalerImpl, error)

NewOwnershipBasedQuotaScaler returns an OwnershipBasedQuotaScaler. The updateAppliedCallback field is a channel which is sent to in a blocking fashion when the shard count updates are applied. This is useful for testing. In production, you should pass in nil, which will cause the callback to be ignored. If totalNumShards is non-positive, then an error is returned.

func (*OwnershipBasedQuotaScalerImpl) Close added in v1.23.0

func (s *OwnershipBasedQuotaScalerImpl) Close()

func (*OwnershipBasedQuotaScalerImpl) ScaleFactor added in v1.23.0

func (s *OwnershipBasedQuotaScalerImpl) ScaleFactor() (float64, bool)

type ReplicationStream added in v1.21.0

type ReplicationStream interface {
	SubscribeReplicationNotification() (<-chan struct{}, string)
	UnsubscribeReplicationNotification(string)
	ConvertReplicationTask(
		ctx context.Context,
		task tasks.Task,
	) (*replicationspb.ReplicationTask, error)
	GetReplicationTasksIter(
		ctx context.Context,
		pollingCluster string,
		minInclusiveTaskID int64,
		maxExclusiveTaskID int64,
	) (collection.Iterator[tasks.Task], error)
}

type ShardCountSubscription added in v1.22.0

type ShardCountSubscription interface {
	// ShardCount returns a channel that receives shard count updates.
	ShardCount() <-chan int
	// Unsubscribe unsubscribes from the shard counter. This closes the ShardCount channel.
	Unsubscribe()
}

ShardCountSubscription is a subscription to a ShardCounter. It provides a channel that receives the shard count updates and an Unsubscribe method that unsubscribes from the counter.

type ShardCounter added in v1.22.0

type ShardCounter interface {
	// SubscribeShardCount returns a ShardCountSubscription for receiving shard count updates.
	SubscribeShardCount() ShardCountSubscription
}

ShardCounter is an observable object that emits the current shard count.

type StubContext added in v1.24.0

type StubContext struct {
	ContextTest
	// contains filtered or unexported fields
}

func NewStubContext added in v1.24.0

func NewStubContext(
	ctrl *gomock.Controller,
	overrides ContextConfigOverrides,
	engine Engine,
) *StubContext

func (*StubContext) GetEngine added in v1.24.0

func (s *StubContext) GetEngine(_ context.Context) (Engine, error)

Jump to

Keyboard shortcuts

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