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

Fix System.UriFormatException on muliple server in NatsURL #125

Merged
merged 1 commit into from
May 10, 2019
Merged

Fix System.UriFormatException on muliple server in NatsURL #125

merged 1 commit into from
May 10, 2019

Conversation

sujitn
Copy link
Contributor

@sujitn sujitn commented May 9, 2019

Fixes the following exception if NatUrl contains multiple server

e.g.
var opts = StanOptions.GetDefaultOptions();
opts.NatsURL = "nats://127.0.0.1:4222,nats://127.0.0.1:4222";

Exception
STAN.Client.StanConnectionException : Invalid connection.
[09/05/2019 19:22:36 Informational] [xUnit.net 00:00:02.0486549] ---- System.UriFormatException : Invalid URI: Invalid port specified.
[09/05/2019 19:22:36 Informational] [xUnit.net 00:00:02.0497734] Stack Trace:
[09/05/2019 19:22:36 Informational] [xUnit.net 00:00:02.0509682] C:\dev\csharp-nats-streaming\STAN.CLIENT\StanConnection.cs(200,0): at STAN.Client.Connection..ctor(String stanClusterID, String clientID, StanOptions options)
[09/05/2019 19:22:36 Informational] [xUnit.net 00:00:02.0513004] C:\dev\csharp-nats-streaming\STAN.CLIENT\StanConnectionFactory.cs(32,0): at STAN.Client.StanConnectionFactory.CreateConnection(String clusterID, String clientID, StanOptions options)

Copy link
Collaborator

@watfordgnf watfordgnf left a comment

Choose a reason for hiding this comment

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

Looks good to me! @ColinSullivan1 let me know when AppVeyor goes green.

Copy link
Member

@ColinSullivan1 ColinSullivan1 left a comment

Choose a reason for hiding this comment

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

LGTM. Tests are green. Thanks for the contribution!

@ColinSullivan1 ColinSullivan1 merged commit aa46de8 into nats-io:master May 10, 2019
@sujitn
Copy link
Contributor Author

sujitn commented May 12, 2019

Are you guys able to push a new nuget package with this fix? Currently this issue is preventing us from switching to latest package.

Thanks

@ColinSullivan1
Copy link
Member

ColinSullivan1 commented May 17, 2019

Early the last week of May, but we'll get to it sooner if we can.

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.

3 participants