Improve error logging

Created on 29 June 2022, over 2 years ago
Updated 7 December 2023, about 1 year ago

Problem/Motivation

It's pretty hard to figure out what's going on under the hood during a file operation error. AWS client throws very handy exceptions, but neither of them is catched.

Steps to reproduce

Just make any error, check the error log, only the core file system errors are logged, nothing AWS specific.

Proposed resolution

Catch and log AWS exceptions.

๐Ÿ“Œ Task
Status

Downport

Version

4.0

Component

Code

Created by

๐Ÿ‡ญ๐Ÿ‡บHungary szantog

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

Merge Requests

Comments & Activities

Not all content is available!

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

  • Merge request !17Issue #3293269: Improve error logging โ†’ (Merged) created by szantog
  • ๐Ÿ‡ง๐Ÿ‡ทBrazil luizsgpetri Campinas

    Hi, I rerolled the patch up to 8.3.3 version.

    I wasn't able to create an interdiff file because the previous patch doesn't apply anymore.

    I've found out that In some cases the getAwsErrorMessage() method is returns an empty string. Like when we try to use an nonexistent bucket.
    So I've added a fallback to it.

    All the comments in the previous patch are now resolved but the one related with providing a fallback to the logger parameter. It mentioned that this would be needed because we were in beta, which doesn't seems to be the case anymore.

  • Status changed to Needs review over 1 year ago
  • Open in Jenkins โ†’ Open on Drupal.org โ†’
    Core: 9.5.x + Environment: PHP 7.4 & MySQL 8
    last update over 1 year ago
    78 pass
  • ๐Ÿ‡ง๐Ÿ‡ทBrazil luizsgpetri Campinas
  • Status changed to Needs work over 1 year ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States cmlara

    It mentioned that this would be needed because we were in beta, which doesn't seems to be the case anymore.

    Itโ€™s a โ€œonce a BETA release is made, BC measure should be doneโ€ which especially applies to Stable since we didnโ€™t mark the class internal it may be being extended.

    The simple fallback for this is, when the parameter is null fallback to calling \Drupal::service() to get the logger and raise a deprecation notice.

  • Status changed to Downport about 1 year ago
  • ๐Ÿ‡บ๐Ÿ‡ธUnited States cmlara

    Committed to 8.x-3.x needs port to 4.x

Production build 0.71.5 2024