Uploaded image for project: 'Couchbase Server'
  1. Couchbase Server
  2. MB-38831

VBucketBackupWriter should correctly handle an empty stats file

    XMLWordPrintable

Details

    Description

      In the event of an os crash (while testing an unrelated bug I inserted an os.Exit() to simulate a crash) it's possible for a stats file to have been created, but the contents were not marshalled and written in time. This will trigger a branch on the resume which will try to read the old stats file before adding the additional stats information.

      Whats' the fix?
      When we do the 'Stat' call to check if the file exists, we should check if the size is zero, if it is, we should just write the in-memory stats and not bother "appending" our stats information.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            james.lee James Lee
            james.lee James Lee
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty