Skip to content

Subscribe to LEAFNODE.CONNECT and LEAFNODE.DISCONNECT events #5902

Closed Answered by derekcollison
ZarkoRunjevac asked this question in Q&A
Discussion options

You must be logged in to vote

From the system account you can subscribe to the following.

$SYS.ACCOUNT.*.CONNECT

This will show all connections of all types for all accounts. The third token is the account.

e.g.

[#1] Received on "$SYS.ACCOUNT.ADEREKYKHPGHKP3UOOWSTAVFTYSFSXZELVLTRXOWQ74RG7CI2BFUKOQ3.CONNECT"
{"type":"io.nats.server.advisory.v1.client_connect","id":"jf9HGwRRs9OWS65PwUxOVc","timestamp":"2024-09-18T21:28:49.735218109Z","server":{"name":"aws-uswest2-natscj1-3","host":"52.26.44.194","id":"NCYS3GAN7R5FEPE5AZSRMGLLMXV7MTIFI4UDCEACTQHHP4NBRHYI5A3I","cluster":"ngsprod-aws-uswest2","domain":"ngs","ver":"2.10.21-RC.1","tags":["cloud:aws","cluster:ngsprod-aws-uswest2","country:us","geo:us","geo:us-west","index:3",…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by derekcollison
# for free to join this conversation on GitHub. Already have an account? # to comment
Category
Q&A
Labels
None yet
2 participants