Skip to content

Conversation

carlydf
Copy link
Contributor

@carlydf carlydf commented Feb 6, 2025

What changed?

Make updates and signals use args
Try to delete oldest to newest version if we hit limit

Why?

How did you test it?

New functional test

Potential risks

Documentation

Is hotfix candidate?

Shivs11 and others added 30 commits February 5, 2025 16:57
## What changed?
<!-- Describe what has changed in this PR -->
- Updated deployment entity wf's API's (naming) for versioning-3.1.
Removed those which will not be required.
- Added functionality for RegisterTaskQueue +  DescribeVersion
- Added functional tests for verifying the above two work.
- UserData stuff has been removed right now since there are pending
discussions

## Why?
<!-- Tell your future self why have you made these changes -->
- Versioning-3.1

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
- Functional tests have been added. Note, the tests added are exact
replicas (in terms of their core functionality) with the existing tests
under `deployment_test.go`

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->
- None, feature branch.

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
- No
## What changed?
<!-- Describe what has changed in this PR -->
Using new Deployment Options fields sent by SDK in Versioning 3
functionality. Old fields are still used when new fields are absent.
Implementation did not change, both new and old fields sent in polls and
task responses are still converted to old `Deployment` object and used
as before. Later, code will be refactored to change the `Deployment`
usages to `DeploymentVersion`.
Also added new fields to replace `Deployment` with `DeploymentVersion`
fields in internal protos where needed. Matching<->History communication
happens via these new fields, only new internal fields are written but
both new and old fields are read.

## Why?
<!-- Tell your future self why have you made these changes -->
Incorporating latest renames in Versioning APIs.

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
Existing tests changed to use new fields (or both old and new depending
on the test).

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->
None.

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->
None yet.

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
No.
## What changed?
<!-- Describe what has changed in this PR -->
- DescribeWorkerDeployment API for versioning-3.1

For this API to work, I realized that the worker deployment workflow has
to have information about the various deployment versions it
encapsulates. Now that version deployment workflows won't have a
`deploymentName` present in their workflowID (for now), partial matching
workflow ID's with the received deployment name to target version
workflows was not feasible.

Another option was to store the mapping from "versions" to "the local
state of a version workflow". However, this would have made the
deployment workflow arguments large in size since in theory, we could
have many deployment versions each with large sized local states.

The option I ended up going with was storing the version in a deployment
workflow during task-queue registration. During a
`DescribeWorkerDeployment` call, we would call `Describe` on each stored
version and return the aggregated info to the user. A version will be
removed from a worker deployment when it becomes "scavenged" (to be
implemented)

Potential future improvements include adding a caching mechanism.

## Why?
<!-- Tell your future self why have you made these changes -->
- Versioning-3.1

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
- Added a functional test + more tests to follow

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->
- None, going inside a feature.

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
- No
## What changed?
<!-- Describe what has changed in this PR -->

Matching to Worker Deployment Ramping Version and its percentage when
routing tasks. User-facing APIs are not implemented yet.

The implementation also supports ramping from a Deployment Version to
unversioned workers.

## Why?
<!-- Tell your future self why have you made these changes -->
Part of Worker Versioning features.

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
Added unit and functional tests.

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->
None.

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->
None.

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
No

---------

Co-authored-by: Shivam Saraf <shivam.saraf@temporal.io>
## What changed?
<!-- Describe what has changed in this PR -->
- Fix flaky `DescribeWorkerDeployment`. The flake was caused because I
forgot to pass in the right parameters when creating version entity
workflows. Moreover, recent proto changes meant that my assertions also
had to be updated and have done so :)
- Other breaking unit tests in the versioning-3.1 repo

## Why?
<!-- Tell your future self why have you made these changes -->
- don't like seeing red markers after CI is done running

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
- Ran unit and functional tests

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->
- None, going to a feature.

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
## What changed?
<!-- Describe what has changed in this PR -->
- title

## Why?
<!-- Tell your future self why have you made these changes -->
- versioning-3.1

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
- existing suite of tests + added functional tests

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->
- None, feature branch

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
- No
## What changed?
<!-- Describe what has changed in this PR -->
- ListWorkerDeployments API
- Also removed presence of locks when adding a version to a
worker-deployment workflow. Causes deadlocks and we don't need them.

## Why?
<!-- Tell your future self why have you made these changes -->
- Versioning-3.1

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
- Added functional tests (happy-path)
- Existing suite

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->
- None, feature

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
- No
## What changed?
Add DrainageStatus child workflow to worker deployment system

## Why?
To periodically update the version workflow with results from
visibility.

## How did you test it?
Functional tests. Currently broken (see todo comment in code)

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->

---------

Co-authored-by: Shivam Saraf <shivam.saraf@temporal.io>
…, fix comments (#7178)

## What changed?
<!-- Describe what has changed in this PR -->

## Why?
<!-- Tell your future self why have you made these changes -->

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
## What changed?
<!-- Describe what has changed in this PR -->
- Ramping PR for versioning-3.1
- now, if a ramping version becomes current, the ramp will be unset.

## Why?
<!-- Tell your future self why have you made these changes -->
- Versioning-3.1

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
- Added more functional tests
- Existing suite

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->
- None, going to feature.

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
No
## What changed?
<!-- Describe what has changed in this PR -->
- Deployment BuildId's are no longer unique across a namespace. The
combination of <DeploymentName, BuildID> will be.
- Constraints for not allowing "/" and "__" in deploymentName and
buildID respectively
- We want the APIs to leave open the possibility of using a custom
version id instead of deployment_name/build_id to set current or
ramping. Also we want to accept the "__unversioned__" string without
having to accep an "unversioned version" . To support this, refactored
APIs to accept version strings. Refactored internal code to use build id
string for build id only, and version string for fully-qualified version
string only.

## Why?
<!-- Tell your future self why have you made these changes -->
- Versioning-3.1

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
- Existing suite of tests 

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->

---------

Co-authored-by: Carly de Frondeville <carly.defrondeville@temporal.io>
## What changed?
<!-- Describe what has changed in this PR -->

## Why?
<!-- Tell your future self why have you made these changes -->

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->

---------

Co-authored-by: Shivam <57200924+Shivs11@users.noreply.github.com>
## What changed?
<!-- Describe what has changed in this PR -->
Updated code to use latest API changes in which Deployment Versions are
represented by string fields rather than structs.
`WorkerDeploymentVersion` proto message still exists but only for the
internal APIs.

## Why?
<!-- Tell your future self why have you made these changes -->
See temporalio/api#547.

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->

---------

Co-authored-by: Carly de Frondeville <carly.defrondeville@temporal.io>
## What changed?
<!-- Describe what has changed in this PR -->

## Why?
<!-- Tell your future self why have you made these changes -->

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->

---------

Co-authored-by: Shivam <57200924+Shivs11@users.noreply.github.com>
Co-authored-by: Shahab Tajik <shahab@temporal.io>
Co-authored-by: Shivam Saraf <shivam.saraf@temporal.io>
Co-authored-by: ShahabT <shahab.tajik@temporal.io>
## What changed?
<!-- Describe what has changed in this PR -->

## Why?
<!-- Tell your future self why have you made these changes -->

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
## What changed?
<!-- Describe what has changed in this PR -->
- added poller presence (called MissingTaskQueue in code) checks when a
version starts to ramp or wants to be set as current
- happy path tests for delete version have been added
- happy path tests for poller presence checks have been added

## Why?
<!-- Tell your future self why have you made these changes -->
- versioning-3.1

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
- NO TESTS have been added - just an initial prototype for review.

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->

---------

Co-authored-by: Carly de Frondeville <carly.defrondeville@temporal.io>
… wf (#7240)

## What changed?
<!-- Describe what has changed in this PR -->

## Why?
<!-- Tell your future self why have you made these changes -->

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
…kQueueFamilyData (#7234)

## What changed?
1. Pass Task Queue Types to `CheckIfTaskQueuesHavePollers` activity so
that we check pollers for only the task queue types that are registered
in that version.
2. Remove `DeploymentVersionData` from the per-type map in
`TaskQueueFamilyData`. `DeploymentVersionData` stores the same info as
`VersionLocalState`, so repeating it num_task_queue times inside the
VersionLocalState was a waste of space, and kind of confusing. I spoke
with Shahab yesterday about how `TaskQueueFamilyData` should contain
information that is specific to each task queue type within that
version. So far, the only data that is specific to the version + task
queue tuple is `first_poller_time`, so I put that in a new
`TaskQueueVersionData` struct and put it in `TaskQueueFamilyData`.

## Why?
See explanation above.

## How did you test it?
Tested that the existing Versioning 3.1 functional tests still work, including DeleteVersion with poller presence.

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
… wf (#7240)

## What changed?
<!-- Describe what has changed in this PR -->

## Why?
<!-- Tell your future self why have you made these changes -->

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
## What changed?
- The initial current version of a worker deployment is now
`"__unversioned__"` instead of `""`
- When the ramping version of a worker deployment becomes unversioned,
the deployment tells all the task queues in the current version that
they now have an unversioned ramp.
- If the unversioned ramp is promoted to current version, or if the
unversioned ramping version is unset, the deployment tells all the task
queues of the previous current version that they no longer have an
unversioned ramp.

## Why?
<!-- Tell your future self why have you made these changes -->

## How did you test it?
- Made sure all existing WorkerDeploymentSuite and
DeploymentVersionSuite tests pass
- Wrote new tests in WorkerDeploymentSuite for the specific edge cases
that this code handles:
- `TestSetCurrentVersion_Unversioned_NoRamp`: Test that when current
version changes from versioned -> unversioned, the task queues become
unversioned
- `TestSetCurrentVersion_Unversioned_PromoteUnversionedRamp`: Test that
when the current version changes from versioned -> unversioned and
unversioned was previously ramping, the task queues become unversioned
with no more unversioned ramp
- `TestSetRampingVersion_Unversioned_UnversionedCurrent`: Test that this
fails with "Ramping version __unversioned__ is already current" error
- `TestSetRampingVersion_Unversioned_VersionedCurrent`: Test that the
ramping version of the current version's task queues becomes unversioned

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->

---------

Co-authored-by: Shivam <57200924+shivs11@users.noreply.github.com>
Co-authored-by: Shahab Tajik <shahab@temporal.io>
Co-authored-by: Shivam Saraf <shivam.saraf@temporal.io>
Co-authored-by: ShahabT <shahab.tajik@temporal.io>
## What changed?
<!-- Describe what has changed in this PR -->

## Why?
<!-- Tell your future self why have you made these changes -->

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
## What changed?
<!-- Describe what has changed in this PR -->
- Changed areas of code in the deployment client whereby we were using
update-with-start instead of update

## Why?
<!-- Tell your future self why have you made these changes -->
- We don't want users to create workflows on operations like
setCurrent/setRamping - we advice users to first create them by
registering your workers

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
- Bunch of tests have been modified and the suites now pass

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
## What changed?
<!-- Describe what has changed in this PR -->
Child workflows start in parent's pinned Worker Deployment Version.

## Why?
<!-- Tell your future self why have you made these changes -->
So user do not have to worry about interface compatibility between
pinned parents and children.

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
Added new tests.

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
## What changed?
<!-- Describe what has changed in this PR -->
Syncing TQ User Data for all types of a single TQ name at once to reduce
the SetCurrent and SetRamping latency and flakiness of tests.

## Why?
<!-- Tell your future self why have you made these changes -->

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->

---------

Co-authored-by: Carly de Frondeville <carly.defrondeville@temporal.io>
## What changed?
<!-- Describe what has changed in this PR -->
- make deletes idempotent

## Why?
<!-- Tell your future self why have you made these changes -->

## How did you test it?
<!-- How have you verified this change? Tested locally? Added a unit
test? Checked in staging env? -->
- added functional tests 
- also changes to functional test to make them have a stricter
consistency check

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->
@carlydf carlydf requested a review from a team as a code owner February 6, 2025 06:11
@carlydf carlydf marked this pull request as draft February 6, 2025 06:11
@ShahabT ShahabT force-pushed the versioning-3.1-merge branch from f356ee3 to 616671c Compare February 6, 2025 07:58
@ShahabT ShahabT force-pushed the versioning-3.1-merge branch 2 times, most recently from 122d338 to 9140a68 Compare February 6, 2025 17:17
@carlydf carlydf marked this pull request as ready for review February 6, 2025 18:47
Comment on lines +198 to +207
// Sent from Drainage child workflow to Version parent
message SyncDrainageInfoSignalArgs {
temporal.api.deployment.v1.VersionDrainageInfo drainage_info = 1;
}

// Sent from Version workflow to Worker Deployment workflow
message SyncDrainageStatusSignalArgs {
string version = 1;
temporal.api.enums.v1.VersionDrainageStatus drainage_status = 2;
}
Copy link
Contributor Author

@carlydf carlydf Feb 6, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the SyncDrainage...Args are not currently used, I wanted to keep this PR short, but I will have another PR using them so that we can keep the VersionSummaries up to date in the deployment WF

fmt.Println("CARLY: AFTER DRAINAGE")

// try to add a version again, and it succeeds, after deleting the second version but not the third (both are eligible)
// TODO: This fails if I try to add tvMax again...
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not sure if this is a problem

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

or, I think it is a problem but I'm not sure how to fix it. Hopefully in most cases when this is happening, at least one out of 100 versions will be eligible deletion so the first add would not fail.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's not worth fixing this until everything else we need to do is done

}
return 0
})
for _, v := range d.State.Versions {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you want to check for version not being drained here, or that info is not sent to the deployment wf yet?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's not sent to the deployment wf yet, but when I do that I will

@carlydf carlydf merged commit 44afdad into versioning-3.1-merge Feb 6, 2025
47 of 49 checks passed
@carlydf carlydf deleted the cdf/scavenger branch February 6, 2025 19:39
ShahabT added a commit that referenced this pull request Feb 6, 2025
## What changed?
Make updates and signals use args
Try to delete oldest to newest version if we hit limit

## Why?
<!-- Tell your future self why have you made these changes -->

## How did you test it?
New functional test

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->

---------

Co-authored-by: Shivam <57200924+shivs11@users.noreply.github.com>
Co-authored-by: Shahab Tajik <shahab@temporal.io>
Co-authored-by: Shivam Saraf <shivam.saraf@temporal.io>
Co-authored-by: ShahabT <shahab.tajik@temporal.io>
ShahabT added a commit that referenced this pull request Feb 6, 2025
## What changed?
Make updates and signals use args
Try to delete oldest to newest version if we hit limit

## Why?
<!-- Tell your future self why have you made these changes -->

## How did you test it?
New functional test

## Potential risks
<!-- Assuming the worst case, what can be broken when deploying this
change to production? -->

## Documentation
<!-- Have you made sure this change doesn't falsify anything currently
stated in `docs/`? If significant
new behavior is added, have you described that in `docs/`? -->

## Is hotfix candidate?
<!-- Is this PR a hotfix candidate or does it require a notification to
be sent to the broader community? (Yes/No) -->

---------

Co-authored-by: Shivam <57200924+shivs11@users.noreply.github.com>
Co-authored-by: Shahab Tajik <shahab@temporal.io>
Co-authored-by: Shivam Saraf <shivam.saraf@temporal.io>
Co-authored-by: ShahabT <shahab.tajik@temporal.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants