epimorphics / json-rails-logger

A custom rails logger that outputs JSON instead of raw text
MIT License
1 stars 1 forks source link

Skip internal request id generation step #23

Closed bogdanadrianmarc closed 3 years ago

bogdanadrianmarc commented 3 years ago

This PR is related to issue #22 . Normally a request id is either passed on from the web server or internally generated with the request id middleware. The internally generated one caused issues with checks such as if the app is alive and can connect to the API; this PR fixes that by retrieving the request id straight from the request. If there is no request id header the field in the returned JSON will simply be missing rather than internally generated

bogdanadrianmarc commented 3 years ago

I'm not able to meaningfully review this change.

Not a problem, I added you as a reviewer only so that you are aware of the change 🙂

ijdickinson commented 3 years ago

OK, let's stick with HTTP_X_REQUEST_ID then