Reduce logging severity/don't log expired tokens/401s

Created on 23 September 2019, almost 5 years ago
Updated 13 March 2023, over 1 year ago

It's a common pattern for clients to attempt a request with an access token, and if it responds with a 401 HTTP status code, refresh and try again. Currently this module logs these as errors, which is probably log spam in the sense that it's not a very actionable error for administrators on the server-side.

Generating proper response codes is handled in #2840205: Error messages/codes should be more helpful & match spec. β†’ - this issue is for the logging component.

πŸ“Œ Task
Status

Needs review

Version

5.2

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States bradjones1 Digital Nomad Life

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡­πŸ‡ΊHungary segi

    I re-rolled my patch if somebody use it. I have check the MR and it looks promising and it covers my little "fix" as well.

  • πŸ‡ΊπŸ‡ΈUnited States bradjones1 Digital Nomad Life

    Thanks, although to be clear the MR is the code that is under review, the patch is outdated and is not the subject of the issue any longer.

  • πŸ‡²πŸ‡ΊMauritius Arnaud Kali Roches-Brunes, Beau-Bassin

    @bradjones1 I don't seem to be able to review/test that patch from #12. I cant apply the patch to 5.2.x either as the code seems to be outdated. I'm seeing the merge request and actually needing it on one of my projects, I'd guess it's about to be merged and released?

  • πŸ‡ΊπŸ‡ΈUnited States bradjones1 Digital Nomad Life

    I don't seem to be able to review/test that patch from #12. I cant apply the patch to 5.2.x either as the code seems to be outdated.

    Yes, I'd consider that patch to be outdated so I can't help you here and not sure why you're trying to apply it.

    I'm seeing the merge request and actually needing it on one of my projects, I'd guess it's about to be merged and released?

    It will get released when it gets to RTBC, so I welcome the effort to review it. Feel free to apply the diff from the MR to your project and tell me how it goes. The fact it's an MR doesn't mean anything regarding its timeline to release. Patches are going away imminently on drupal.org, anyway.

  • πŸ‡²πŸ‡ΊMauritius Arnaud Kali Roches-Brunes, Beau-Bassin

    Thanks for your comment @bradjones1 - Even if I kinda know after I've been around on d.o for such a long time, I'm just never sure about the way to proceed. I'm re-rolling the patch against 5.2.x as I need an online link to be able to test on my platform (which already has an online API from which I need to test that code).
    Thanks! I'll keep you informed of my findings.

  • πŸ‡²πŸ‡ΊMauritius Arnaud Kali Roches-Brunes, Beau-Bassin
Production build 0.69.0 2024