Logs, Telemetry Events

Telemetry is a specification to instrument all the key events. Using this specification reference applications & services will generate telemetry events. For more info refer Sunbird-Telemetry documentation here. Also to know how telemetry is processed refer to Telemetry Processing Documentation in https://lern.sunbird.org/learn/telemetry-processing.

Logs also use telemetry specification and request tracing/ tracking is accomplished by passing the request context into the logs and telemetry. This helps in troubleshooting issues. Request context has below details:

uid //user id from user authentication token in header (x-authenticated-user-token)
did //device id from request header (x-device-id)
sid //session id from request header (x-session-id)
reqId //request id from request header (x-request-id)

This request id also set to API response as msgid. This helps in tracking once request that invokes multiple APIs and flows.

Configuration

Telemetry has request context information and it is set during the telemetry logging.

Below are the properties set by the application to add the producer information into the telemetry data:

#Telemetry producer related info

Telemetry is logged and also send to SB-Obsrv data-pipeline using logback in notification service. logback.xml configuration has a kafka appender which will send the telemetry generated by the code to a kafka topic.

Logback.xml configuration:

List of Events

Audit Event
Error Event
Log Event

Sample Telemetry Data

Audit Event Data

Last updated

Was this helpful?