Skip to content

Commit

Permalink
added v1.0.2 Release Notes (#201)
Browse files Browse the repository at this point in the history
## [1.0.2] / 31 January 2023

Version 1.0.2 introduces a new method to the `ActorRegistry.GetAsync` in order to allow users to force parts of their application to wait until a specific `IActorRef` has been started and added to the `ActorRegistry`.

```csharp
// arrange
var registry = new ActorRegistry();

// act
var task = registry.GetAsync<Nobody>();
task.IsCompletedSuccessfully.Should().BeFalse();

registry.Register<Nobody>(Nobody.Instance);
var result = await task;

// assert
result.Should().Be(Nobody.Instance);
```

This method is designed to allow users to wait via `async Task<IActorRef>` for an actor to be registered in the event that a specific `IRequiredActor<TKey>` is needed before Akka.Hosting can start the `ActorSystem` inside its `IHostedService`.
  • Loading branch information
Aaronontheweb authored Jan 31, 2023
1 parent f836703 commit a140512
Showing 1 changed file with 22 additions and 1 deletion.
23 changes: 22 additions & 1 deletion RELEASE_NOTES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,24 @@
## [1.0.2] / 31 January 2023

Version 1.0.2 introduces a new method to the `ActorRegistry.GetAsync` in order to allow users to force parts of their application to wait until a specific `IActorRef` has been started and added to the `ActorRegistry`.

```csharp
// arrange
var registry = new ActorRegistry();

// act
var task = registry.GetAsync<Nobody>();
task.IsCompletedSuccessfully.Should().BeFalse();

registry.Register<Nobody>(Nobody.Instance);
var result = await task;

// assert
result.Should().Be(Nobody.Instance);
```

This method is designed to allow users to wait via `async Task<IActorRef>` for an actor to be registered in the event that a specific `IRequiredActor<TKey>` is needed before Akka.Hosting can start the `ActorSystem` inside its `IHostedService`.

## [1.0.1] / 6 January 2023

Version 1.0.1 fixes options bug used in the cluster sharding Akka.Hosting extension method.
Expand Down Expand Up @@ -323,4 +344,4 @@ This feature is useful when a user need to run a specific initialization code if

For example, this feature is useful for:
- kicking off actor initializations by using Tell()s once all of the actor infrastructure are in place, or
- pre-populating certain persistence or database data after everything is set up and running, useful for unit testing or adding fake data for local development.
- pre-populating certain persistence or database data after everything is set up and running, useful for unit testing or adding fake data for local development.

0 comments on commit a140512

Please sign in to comment.