Skip to content
New issue

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

Add ClusterClientDiscovery Hosting extension support #478

Merged
merged 16 commits into from
Jul 29, 2024

Conversation

Arkatufus
Copy link
Contributor

@Arkatufus Arkatufus commented Jul 25, 2024

Changes

  • Add ClusterClientDiscoveryOptions class
  • Add new ClusterClient extensions methods WithClusterClientDiscovery that allows users to use ClusterClientDiscovery
  • Add XML-DOC
  • Add unit tests
  • Update main documentation

Copy link
Member

@Aaronontheweb Aaronontheweb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't reference any part of Akka.Management in this project. That will create a dependency cycle.

src/Akka.Cluster.Hosting/Akka.Cluster.Hosting.csproj Outdated Show resolved Hide resolved
@Arkatufus Arkatufus marked this pull request as ready for review July 29, 2024 13:43
Copy link
Member

@Aaronontheweb Aaronontheweb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggestions

/// <see cref="ClusterClientDiscovery"/> to work, you <b>will need</b> to set
/// <c>DiscoveryOptions.IsDefaultPlugin</c> to <c>false</c>
/// </summary>
public IHoconOption DiscoveryOptions { get; set; } = null!;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Per our call, use IDiscoveryOption or whatever here

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

private void Validate()
{
var type = DiscoveryOptions.GetType().Name;
if(!(type.Contains("ConfigServiceDiscoveryOptions")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rather than do stringly-typed stuff, use the IDiscoveryOption type we proposed on the call

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Copy link
Member

@Aaronontheweb Aaronontheweb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Aaronontheweb Aaronontheweb merged commit 3ec5de4 into akkadotnet:dev Jul 29, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants