-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
[ADDED] Distributed Message Tracing #5014
Commits on Feb 5, 2024
-
[ADDED] Distributed Message Tracing
When an incoming message contains the header `Nats-Trace-Dest` set to a valid subject, the server will send there messages representing events happening in each server where the message is processed. The events will give details about ingress, subject mapping, stream export and service imports, jetstream and egress to subscriptions and/or routes, leafnodes and gateways. Except for a standalone server it is expected to receive multiple trace messages for a given inbound message. The header `Nats-Trace-Only`, if set to `true`, will produce the same tracing events than without that header, except that the message will not be delivered to subscriptions or inserted in the JetStream stream. This is usefull to see the path that a message would take but without affecting running applications. Note that in a mixed environment where not all servers would be running at 2.11+, when a message is supposed to be traced only and the remote does not understand message tracing, the message will not be forwared and the Egress event for that remote will indicate the reason. Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
Configuration menu - View commit details
-
Copy full SHA for c3e5cbc - Browse repository at this point
Copy the full SHA c3e5cbcView commit details -
Move unmarshal into server code and add Link to MsgTraceEgress
Moving the unmarshal to server code helps with the library importing the server code and be able to reuse that code. Added a Link field to a MsgTraceEgress that the server does not do anything with, but library will be able to link trace events together. Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
Configuration menu - View commit details
-
Copy full SHA for 2a822fd - Browse repository at this point
Copy the full SHA 2a822fdView commit details -
Adding Timestamp to MsgTraceBase
This way, each event has a timestamp and this can help checking latency between an egress in one server and ingress in another. Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
Configuration menu - View commit details
-
Copy full SHA for 25bc267 - Browse repository at this point
Copy the full SHA 25bc267View commit details -
Updates based on code review (without service/stream changes)
Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
Configuration menu - View commit details
-
Copy full SHA for 085b39b - Browse repository at this point
Copy the full SHA 085b39bView commit details
Commits on Feb 6, 2024
-
Add allow_trace to service exports and stream imports and update tests
Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
Configuration menu - View commit details
-
Copy full SHA for 7c1341e - Browse repository at this point
Copy the full SHA 7c1341eView commit details
Commits on Feb 7, 2024
-
Use protocol version for server connection msg tracing capability
Signed-off-by: Ivan Kozlovic <ivan@synadia.com>
Configuration menu - View commit details
-
Copy full SHA for 33a5155 - Browse repository at this point
Copy the full SHA 33a5155View commit details
Commits on Feb 8, 2024
-
Configuration menu - View commit details
-
Copy full SHA for b2778aa - Browse repository at this point
Copy the full SHA b2778aaView commit details