Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-28468

Improve exception handling in ESE at-rest encryption WT callbacks

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.1.1
    • Component/s: Storage
    • Labels:
    • Backwards Compatibility:
      Fully Compatible
    • Sprint:
      Storage NYC 2018-06-04, Storage NYC 2018-06-18, Storage NYC 2018-07-02
    • Case:
    • Linked BF Score:
      0

      Description

      The WT callbacks catch and log all exceptions, because they cannot be allowed to propagate up into the WT C code. However, the only information about the exception that is logged is exceptionToStatus(), which does not include anything about where the exception occurred. The code then calls fassertFailed(), which will abort the server with a stacktrace that leads to this generic exception-catching code in the WT callbacks.

      When diagnosing the cause of exceptions that have occurred during these callbacks, it would be much more useful to have the backtrace of the actual exception. Thus, this exception handling code should log the backtrace of the caught exception, before calling fassertFailedNoTrace().

      In addition, the customize callback may do network operations to obtain keys from a KMIP server, which means that SocketExceptions are not unexpected. Currently, these are logged with the vague generic message "Aborting due to exception in WT_ENCRYPTOR::customize", which is geared towards unexpected exceptions of any type. Thus this callback should catch SocketExceptions separately, and log them with a better message.

        Attachments

          Activity

            People

            Assignee:
            ben.judd Ben Judd
            Reporter:
            kevin.pulo Kevin Pulo
            Participants:
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: