Skip to content

Commit 52ce682

Browse files
Shivs11claude
andcommitted
Add integration test for stale partition trampolining suppression
TestStalePartition_RevisionSuppressesTrampolining verifies that when a stale matching partition sends an outdated target version with a low revision number, the revision-based comparison in case 4 of the target version change switch suppresses the signal. Also verifies that a genuinely new version with a higher revision correctly fires the signal. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent c969b65 commit 52ce682

10,316 files changed

Lines changed: 520 additions & 9459792 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

api/persistence/v1/executions.pb.go

Lines changed: 4 additions & 16 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

go.mod

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -216,5 +216,3 @@ require (
216216
modernc.org/mathutil v1.7.1 // indirect
217217
modernc.org/memory v1.11.0 // indirect
218218
)
219-
220-
replace go.temporal.io/api => /Users/shivamsaraf/Desktop/work/api-go

go.sum

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -440,6 +440,8 @@ go.opentelemetry.io/otel/trace v1.40.0 h1:WA4etStDttCSYuhwvEa8OP8I5EWu24lkOzp+ZY
440440
go.opentelemetry.io/otel/trace v1.40.0/go.mod h1:zeAhriXecNGP/s2SEG3+Y8X9ujcJOTqQ5RgdEJcawiA=
441441
go.opentelemetry.io/proto/otlp v1.7.1 h1:gTOMpGDb0WTBOP8JaO72iL3auEZhVmAQg4ipjOVAtj4=
442442
go.opentelemetry.io/proto/otlp v1.7.1/go.mod h1:b2rVh6rfI/s2pHWNlB7ILJcRALpcNDzKhACevjI+ZnE=
443+
go.temporal.io/api v1.62.8-0.20260406230818-5423d0dd678a h1:2nCxSSKutK1VP2eA7/lw5/DfHk+UxNtr1GN5KsZTSNo=
444+
go.temporal.io/api v1.62.8-0.20260406230818-5423d0dd678a/go.mod h1:iaxoP/9OXMJcQkETTECfwYq4cw/bj4nwov8b3ZLVnXM=
443445
go.temporal.io/auto-scaled-workers v0.0.0-20260407181057-edd947d743d2 h1:1hKeH3GyR6YD6LKMHGCZ76t6h1Sgha0hXVQBxWi3dlQ=
444446
go.temporal.io/auto-scaled-workers v0.0.0-20260407181057-edd947d743d2/go.mod h1:T8dnzVPeO+gaUTj9eDgm/lT2lZH4+JXNvrGaQGyVi50=
445447
go.temporal.io/sdk v1.41.1 h1:yOpvsHyDD1lNuwlGBv/SUodCPhjv9nDeC9lLHW/fJUA=

proto/internal/temporal/server/api/persistence/v1/executions.proto

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -321,10 +321,6 @@ message WorkflowExecutionInfo {
321321
// Used only within server persistence; never flows to the public API.
322322
message LastNotifiedTargetVersion {
323323
temporal.api.deployment.v1.WorkerDeploymentVersion deployment_version = 1;
324-
// Revision number of the task queue routing config at the time the
325-
// notification was sent. Carried forward to DeclinedTargetVersionUpgrade
326-
// at continue-as-new time.
327-
int64 revision_number = 2;
328324
}
329325

330326
message ExecutionStats {

service/history/api/create_workflow_util.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,6 @@ func NewWorkflowWithSignal(
113113
nil,
114114
false,
115115
nil,
116-
0,
117116
)
118117
if err != nil {
119118
// Unable to add WorkflowTaskStarted event to history

service/history/api/recordworkflowtaskstarted/api.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,6 @@ func Invoke(
170170
workflowLease.GetContext().UpdateRegistry(ctx),
171171
false,
172172
req.TargetDeploymentVersion,
173-
req.TaskDispatchRevisionNumber,
174173
)
175174
if err != nil {
176175
// Unable to add WorkflowTaskStarted event to history

service/history/api/respondworkflowtaskcompleted/api.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -597,7 +597,6 @@ func (handler *WorkflowTaskCompletedHandler) Invoke(
597597
workflowLease.GetContext().UpdateRegistry(ctx),
598598
false,
599599
nil,
600-
0,
601600
)
602601
if err != nil {
603602
return nil, err
@@ -723,7 +722,6 @@ func (handler *WorkflowTaskCompletedHandler) Invoke(
723722
workflowLease.GetContext().UpdateRegistry(ctx),
724723
false,
725724
nil,
726-
0,
727725
)
728726
if err != nil {
729727
return nil, err

service/history/api/respondworkflowtaskcompleted/api_test.go

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -726,7 +726,6 @@ func (s *WorkflowTaskCompletedHandlerSuite) createSentUpdate(tv *testvars.TestVa
726726
nil,
727727
false,
728728
nil,
729-
0,
730729
)
731730
taskToken := &tokenspb.Task{
732731
Attempt: 1,
@@ -806,7 +805,6 @@ func (s *WorkflowTaskCompletedHandlerSuite) createPausedWorkflowWithWFT(tv *test
806805
nil,
807806
false,
808807
nil,
809-
0,
810808
)
811809
_, _ = ms.AddWorkflowTaskCompletedEvent(wt, &workflowservice.RespondWorkflowTaskCompletedRequest{
812810
Identity: tv.Any().String(),
@@ -824,7 +822,6 @@ func (s *WorkflowTaskCompletedHandlerSuite) createPausedWorkflowWithWFT(tv *test
824822
nil,
825823
false,
826824
nil,
827-
0,
828825
)
829826
taskToken := &tokenspb.Task{
830827
Attempt: 1,

service/history/api/verifyfirstworkflowtaskscheduled/api_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,6 @@ func (s *VerifyFirstWorkflowTaskScheduledSuite) TestVerifyFirstWorkflowTaskSched
238238
nil,
239239
false,
240240
nil,
241-
0,
242241
)
243242
wt.StartedEventID = workflowTasksStartEvent.GetEventId()
244243

service/history/history_engine_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6618,7 +6618,6 @@ func addWorkflowTaskStartedEventWithRequestID(ms historyi.MutableState, schedule
66186618
nil,
66196619
false,
66206620
nil,
6621-
0,
66226621
)
66236622

66246623
return event

0 commit comments

Comments
 (0)