Skip to content

Conversation

@WhitWaldo
Copy link
Contributor

Description

Added method to try getting a named reminder from the actor. Especially as the Dapr.Actors package doesn't support nullability annotations, it can be confusing to understand what a null value means (especially if it never returns null, which #1468 seeks to fix).

As out parameters aren't supported in async operations per this document, this instead implements an async method that returns a ConditionalValue<TValue>.

If the return type is not available, HasValue will be false and the Value property will be null. If the return type is available, HasValue will be true and the Value property will be populated with the IActorReminder value.

Issue reference

We strive to have all PR being opened based on an issue, where the problem or feature have been discussed prior to implementation.

Please reference the issue this PR will close: #1465

Checklist

Please make sure you've completed the relevant tasks for this PR, out of the following list:

  • Code compiles correctly
  • Created/updated tests
  • Extended the documentation

@WhitWaldo WhitWaldo self-assigned this Feb 22, 2025
@WhitWaldo WhitWaldo requested review from a team as code owners February 22, 2025 02:42
@WhitWaldo WhitWaldo added the P2 label Feb 26, 2025
@WhitWaldo WhitWaldo added this to the v1.16 milestone Feb 26, 2025
@WhitWaldo WhitWaldo closed this Feb 26, 2025
@mikeee mikeee removed this from the v1.16 milestone Aug 26, 2025
@WhitWaldo WhitWaldo deleted the try-get-reminder branch September 3, 2025 01:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add TryGetReminder to actor SDK

2 participants