We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
对于有状态的服务,可能存在这样的需求。要求该服务每过一段时间(Days、Hours.....)重建一次服务的状态。
请问有什么较好的实现方案吗?
The text was updated successfully, but these errors were encountered:
Phoenix对状态的管理是以聚合根为单位的,每一个聚合根都有唯一标识聚合根ID。Phoenix会自动从内存中淘汰不活跃的聚合根,配置为:
聚合根
聚合根ID
quantex.phoenix.server.performance.actor-survive-time= 86400000 单位为毫秒
所以,针对服务每过一段时间,重建服务状态。 可以让客户端在发送命令时,对聚合根加上时间维度单位,比如:id001-2020-02-03,再第二天时ID为id001-2020-02-04,发送的聚合根ID不一样,状态就是全新的。
id001-2020-02-03
id001-2020-02-04
Sorry, something went wrong.
No branches or pull requests
对于有状态的服务,可能存在这样的需求。要求该服务每过一段时间(Days、Hours.....)重建一次服务的状态。
请问有什么较好的实现方案吗?
The text was updated successfully, but these errors were encountered: