dotnet / orleans

Cloud Native application framework for .NET
https://docs.microsoft.com/dotnet/orleans
MIT License
10.12k stars 2.04k forks source link

Activate reminders #7405

Open magazin81 opened 2 years ago

magazin81 commented 2 years ago

We are using an Azure Table as a storage for the Reminder Service. A fresh deployment comes with an empty table. When we start Silos no reminder grain is triggered as there is no registration stored in the Azure Table. What would be the best way to initialize the reminders? Should we do RegisterOrUpdateReminder in OnActivateAsync of the reminder grains, and try to activate the grains by reaching them. If so, what would be the best way to do in a multi-silo deployment? We tried to do it by participating in the silo's lifecycle and reaching the reminder grains in the stage ServiceLifecycleStage.Active, but it result in calling OnActivateAsync multiple times (one per silo).

benjaminpetit commented 2 years ago

Any reason you are deploying every time with an empty table?

magazin81 commented 2 years ago

This only applies to the first deployment (fresh table) or when we add a new reminder.

scalalang2 commented 1 month ago

👀