Releases: Tochemey/goakt
v2.10.2
v2.10.1
What's Changed
- perf: change boundedmailbox implementation by @Tochemey in #559
- refactor: renamed test proto messages for proper naming by @Tochemey in #562
- fix: fix potential resource leakage by @Tochemey in #564
- feat: add ActorSuspended event to the events stream by @Tochemey in #566
- refactor: refactor deadletters by @Tochemey in #571
- fix(bugs): enforce actors uniqueness creation in cluster by @Tochemey in #575
Full Changelog: v2.10.0...v2.10.1
v2.10.0
What's Changed
- Refactor supervisor strategy. See breaking change note.
- Modify testkit method
Send
signature to enforce that testing remains in the probe context by using the actor name instead of the PID - New testkit method
SendSync
to assert Ask-pattern messages has been added. - Actor restart implementation has been refactored. This is the new restart behavior:
- Restart the given actor
- Restart all direct children of the given actor that are alive before the actor is restarted. Grand children are excluded.
- Respect hierarchical relationship between the direct children and the restarted actor in a parent-child relation.
- The restarted actor should be added back to its parent if any.
- Message processing implementation has been refactored to enhance the throughput of number of messages to handle and reduce resource consumption.
- Unbounded priority mailbox added. Performance wise it seems ok for most use cases. Further work may enhance its performance.
BREAKING CHANGE
The main breaking in this release is how the supervisor strategy work now. The developer can easily create mappings between error types and supervisor strategy directives via the NewSupervisorStrategy
method and SpawnOption
. This allows fine-grained error handling during message processing by actor. In that regard the same actor can have one more ways of dealing with error types. Supervisor strategies are defined during the creation of actors. Therefore a faulty actor can be handled differently depending upon the error type. For instance with this new enhancement one can restart
an actor with the following error type &runtime.PanicNilError{}
and the same actor to be stopped on a different error type. More information on the readme.
The following methods are removed:
WithSupervisorDirective
: removed from the actor system optionWithSupervisor
: removed from the SpawnOption
Pull requests
- feat: implement priority mailbox by @Tochemey in #546
- refactor: refactor internal engine by @Tochemey in #548
- fix: fix actor restarting implementation by @Tochemey in #550
- perf: enhance message processing by @Tochemey in #551
- refactor: refactor implementation of supervisor strategy by @Tochemey in #553
- feat: add ask-pattern testing mechanism by @Tochemey in #555
Full Changelog: v2.9.1...v2.10.0
v2.9.1
What's Changed
- Revert the DNS feature. Only IP addresses will be used due to this issues hashicorp/memberlist#147 and hashicorp/memberlist#162. At the moment DNS hinder cluster nodes discovery. The best option for the meantime is to set the host to "0.0.0.0" and then GoAkt will figure out the right IP address.
- Refactor the whole actors storage using a tree-like structure
- Add two methods to ActorSystem:
Host
andPort
- Fully tested (cluster mode included)
- Fix some bugs introduced from version v2.8.3 around clustering.
Commits
Full Changelog: v2.9.0...v2.9.1
v2.9.0
New Features
ForwardTo
on theReceiveContext
to forward message to a given actor when cluster mode is enabled. It passes a message from one actor to another actor by preserving the initial sender of the message.RemoteForward
on theReceiveContext
to pass a message from one actor to another actor on a remote machine by preserving the initial sender of the message.
Breaking Changes
- Fix bad api design of the remoting methods which necessitated a breaking changes in the accepted arguments of the following methods which now accepts a
from
alongside the existing argumentsRemoteTell
RemoteAsk
RemoteBatchAsk
RemoteBatchTell
Commits and PRs
- feat(enhancement): add ForwardTo and RemoteForward by @Tochemey in #538
- fix(design): fix bad design of remoting call by @Tochemey in #539
Full Changelog: v2.8.3...v.2.8.4
v2.8.3
v2.8.2
v2.8.1
What's Changed
- Dependencies upgrade by @renovate in #519
- NATs discovery configuration now accept
host
anddiscoveryPort
rather than a node instance. by @Tochemey in #520. See https://github.com/Tochemey/goakt?tab=readme-ov-file#nats-discovery-provider-setup - One can set a custom
supervisor directive
when creating an actor using the newly added optionWithSupervisor
by @Tochemey in #522. See https://github.com/Tochemey/goakt/blob/main/actors/spawn_option.go#L70C6-L70C20 - Code maintenance by @Tochemey in #521
Full Changelog: v2.8.0...v2.8.1
v2.8.0
Breaking Changes
WithReplyTimeout
removed from the ActorSystem option- All ask-based methods on
PID
andReceiveContext
accept a mandatorytimeout
argument:- Ask`
- SendSync`
BatchAsk
RemoteAsk
RemoteBatchAsk
Add-ons
- Add
Schedule
andRemoteSchedule
methods toScheduler
ExpectMessage
andExpectMessageWithin
in the testkit have been refactored- New remoting API that will allow to extend it with mTLS in the future
- Abstract remoting into a nice struct called
Remoting
for client communication - Refactor the cluster client to accept concrete
Node
instance rather than mere array list of addresses. This help to tailor client connection appropriately to the given node - Ensure that every http client connection closes appropriately to avoid resource leakage.
What's Changed
- feat: add Schedule and RemoteSchedule to scheduler by @Tochemey in #493
- refactor: refactor ExpectMessage and ExpectMessageWithin by @Tochemey in #496
- Fix typo by @autodidaddict in #503
- refactor: cleanup the code to allow easy extensibility by @Tochemey in #505
- refactor: use sync.Map for peersCache in actor system by @Tochemey in #512
- refactor: remove system ask timeout and pass timeout to asks by @Tochemey in #515
New Contributors
- @autodidaddict made their first contribution in #503
Full Changelog: v2.7.1...v2.8.0
v2.7.1
What's Changed
- refactor: enhance code coverage by @Tochemey in #482
- refactor: remove otel collector from client code by @Tochemey in #485
- refactor: refactor pidMap using sync.Map by @Tochemey in #486
- perf: add sync loop to message processing by @Tochemey in #491
Note
🎉🎉🎉This release enhances the performance of the framework drastically by the introduction of sync.Map
and sync.Pool
🎉🎉🎉
Full Changelog: v2.7.0...v2.7.1