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 a mode to surveyor where it subscribe to the server's id it is connected to. #28

Open
matthiashanel opened this issue Jul 16, 2020 · 7 comments
Assignees

Comments

@matthiashanel
Copy link

This way it will only receive it's local events, which will allow it to be deployed in the same way as the prometheus exporter.
Once we support this deployment model we can retire the prometheus exporter.

@ColinSullivan1
Copy link
Member

We can deprecate the prometheus exporter with a suitable sunset period, and leave it open afterword.

As surveyor provides more comprehensive monitoring and features it'll be where efforts are focused moving forward. We understand that a migration will require user changes to their prometheus configurations and dashboards so we will be sensitive to that.

@matthiashanel
Copy link
Author

potentially we can move some of the prometheus exporter parsing code into surveyor and make it a drop in replacement.

@ripienaar
Copy link
Collaborator

Even then people will have to move forward at some point as we will not be able to make this company later have new features without equal amount of work as managing both

I would just go for a clean break.

@ColinSullivan1
Copy link
Member

Agreed - clean break is best imo.

@ripienaar
Copy link
Collaborator

This is actually quite hard to do in practise. The go nats client will always listen to server discovery and add discovered servers to the pool, you simply dont know if the nats client is connected to the server you had in mind.

So the only thing we can really do is say --serverid NB3LQCYTCZH66EWXYLMBIN5WYXGQGRK6FKFAPPDERR2DWP3HCRCGCXPA and have surveyor for ever more try to monitor that one ID, which will be flakey since IDs are not deterministic, so maybe --name fooserver and assume people will set name? I am still deeply convinced the default behaviour for name is wrong.

Does that sound reasonable? For sure saying monitor the server we're connected to won't be the right thing

@matthiashanel
Copy link
Author

When we go for a name, wouldn't we have to try to suppress this behavior, just so we get the intended topology?

I would imagine that if you want to set up surveyor this way, you can be expected to set server_name.
However, what would happen if a server is restarted while a pod is still somewhat running? (possibly receive from two server)

Would it work to make use of NoReconnect? OR add a new option NoAllowDiscoveredServer intended for our use only.

@ripienaar
Copy link
Collaborator

If we do name based it would for as long as there is no dupes yeah. We should make sure that the servers stop responding to REQ during lame duck mode though

I doubt there is much appetite for turning off learning topologies in the libraries - though personally I would like such an option.

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

No branches or pull requests

3 participants