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

Do not count duplicate index exception (E11000) as user-assertion

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Done
    • Icon: Minor - P4 Minor - P4
    • None
    • 2.6.0, 2.6.5
    • Storage
    • None

    Description

      We're trying to use MongoDB as a global lock across multiple VMs. We've created a lock collection with a unique index on the type of lock, and we lock by trying to insert a record with a certain lock type value. If there's a duplicate exception, we know it's already locked. Otherwise, we know we're locked.

      The problem now that we upgraded to 2.6.5 from 2.4 is that mongo sees the duplicate key exception as a user error and is logging it into our log files and counting it internally as a user error. So, our monitoring software keeps flagging this as an exception, whereas it's really the way the system was designed to run.

      Attachments

        Activity

          People

            Unassigned Unassigned
            elirov Erez Lirov
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: