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

[New Feature]: Log each request and response with relevant details #43480

Closed
chathurace opened this issue Oct 10, 2024 · 0 comments
Closed

[New Feature]: Log each request and response with relevant details #43480

chathurace opened this issue Oct 10, 2024 · 0 comments
Labels
Team/Observability Observability in general, Metrics, Tracing & Logging Type/NewFeature

Comments

@chathurace
Copy link
Contributor

chathurace commented Oct 10, 2024

Description

Logging each request and response with a timestamp, status, response time, etc, is useful for observability purposes. This is especially useful for deriving metrics from logs. Such logs need to be generated from all transports, and should have the ability to enable or disable logging via a configuration.

e.g. logs for HTTP:
[timestamp] <request|response> <correlation id> <method> <service> <resource> <status> <response time>
[2024-07-27T11:31:06] request b76a4c42-8eaa-466b-b471-fbfa4cb759bf GET /sales /accounts
[2024-07-27T11:31:06] response 9e01c068-97c9-44be-8424-5643eb4852 GET /sales /accounts 200 2489

Describe your problem(s)

No response

Describe your solution(s)

No response

Related area

-> Observability

Related issue(s) (optional)

No response

Suggested label(s) (optional)

No response

Suggested assignee(s) (optional)

No response

@ballerina-bot ballerina-bot added the Team/Observability Observability in general, Metrics, Tracing & Logging label Oct 10, 2024
@chathurace chathurace closed this as not planned Won't fix, can't repro, duplicate, stale Oct 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Team/Observability Observability in general, Metrics, Tracing & Logging Type/NewFeature
Projects
None yet
Development

No branches or pull requests

2 participants