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

fix(lambda-tiler): correctly log fetch requests #3359

Merged
merged 4 commits into from
Oct 17, 2024

Conversation

blacha
Copy link
Member

@blacha blacha commented Oct 17, 2024

Motivation

Requests tracing has been broken for a while (not entire sure when it broke)

It is very very helpful to have statistics on the number of s3 requests required to make a tile

Modifications

  • requestCount is reserved for the number of lambda invocations so move to fetchCount for number of fetches
  • include the fetchIds to trace hot fetches
  • increase the percent of requests with tracing enabled
  • Use async local storage to gain access to the logger for the request that triggers the log message, this fixes a bug where the request may be in trace but the fetch is using the base logger which is set to info so no logs are generated.

Verification

Ran locally and verified logs are now appearing.

@blacha blacha marked this pull request as ready for review October 17, 2024 00:14
@blacha blacha requested a review from a team as a code owner October 17, 2024 00:14
Wentao-Kuang
Wentao-Kuang previously approved these changes Oct 17, 2024
Co-authored-by: Wentao Kuang <wkuang@linz.govt.nz>
@blacha blacha added this pull request to the merge queue Oct 17, 2024
Merged via the queue into master with commit 9fa3681 Oct 17, 2024
11 checks passed
@blacha blacha deleted the feat/restore-request-tracing branch October 17, 2024 22:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants