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 current time field for request and response log #1122

Closed
yiminyangguang520 opened this issue Aug 25, 2021 · 1 comment
Closed

add current time field for request and response log #1122

yiminyangguang520 opened this issue Aug 25, 2021 · 1 comment
Labels

Comments

@yiminyangguang520
Copy link

yiminyangguang520 commented Aug 25, 2021

add current time field for request and response log

Detailed Description

add current time field for request and response log, which log when request happen

Context

Possible Implementation

add time key in content map, where method Map<String, Object> prepare(final Precorrelation precorrelation, final HttpRequest request) throws IOException in StructuredHttpLogFormatter.java

Your Environment

  • Version used:
    logbook version: 2.12.0
  • Link to your project:
@whiskeysierra
Copy link
Collaborator

This is better left to your logging framework. Logbook produces just the message. If you want JSON logs all the way through, you can take a look at https://logging.apache.org/log4j/2.x/manual/layouts.html#JSONLayout.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants