Skip to content

Document that Undertow's record-request-start-time server option must be enabled for %D to work in access logging #31103

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

Closed
JCass149 opened this issue May 18, 2022 · 1 comment
Assignees
Labels
type: documentation A documentation update
Milestone

Comments

@JCass149
Copy link

JCass149 commented May 18, 2022

In this paragraph it is stated:

Access logging for Undertow can be configured in a similar fashion, as shown in the following example:

server:
  undertow:
    accesslog:
      enabled: true
      pattern: "%t %a %r %s (%D ms)"

However, the %D RESPONSE_TIME exchange attribute does not work "out of the box" with Spring Boot (at least for me with spring-boot-starter-parent 2.3.8.RELEASE).

I needed to also add the following:

server
  undertow:
    options:
      server:
        record-request-start-time: true

Should the docs be updated to reflect this?

Thanks :)

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label May 18, 2022
@wilkinsona wilkinsona added type: documentation A documentation update and removed status: waiting-for-triage An issue we've not yet triaged labels May 18, 2022
@wilkinsona wilkinsona added this to the 2.6.x milestone May 18, 2022
@wilkinsona wilkinsona changed the title Configure Access Logging for Undertow Docs improvement Document that Undertow's record-request-start-time server option must be enabled for %D to work in access logging May 18, 2022
@wilkinsona wilkinsona self-assigned this Aug 3, 2022
@wilkinsona wilkinsona modified the milestones: 2.6.x, 2.6.11 Aug 3, 2022
@barryzpc
Copy link

In this paragraph it is stated:

Access logging for Undertow can be configured in a similar fashion, as shown in the following example:

server:
  undertow:
    accesslog:
      enabled: true
      pattern: "%t %a %r %s (%D ms)"

However, the %D RESPONSE_TIME exchange attribute does not work "out of the box" with Spring Boot (at least for me with spring-boot-starter-parent 2.3.8.RELEASE).

I needed to also add the following:

server
  undertow:
    options:
      server:
        record-request-start-time: true

Should the docs be updated to reflect this?

Thanks :)

I couldn't agree with you more, and you solved my problem. thank you

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

No branches or pull requests

4 participants