Fix ASAN clean shutdown logic

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Done
    • Priority: Major - P3
    • 3.3.12
    • Affects Version/s: 3.3.10
    • Component/s: Networking
    • None
    • Fully Compatible
    • ALL
    • Hide

      ./buildscripts/resmoke.py --executor sharding_jscore_passthrough jstests/core/all.js # or anything else that isn't blacklisted.

      1. Watch and see that it takes a full 10 seconds before the fixture comes down because a connection is live in shutdown
      Show
      ./buildscripts/resmoke.py --executor sharding_jscore_passthrough jstests/core/all.js # or anything else that isn't blacklisted. Watch and see that it takes a full 10 seconds before the fixture comes down because a connection is live in shutdown
    • Platforms 2016-08-26
    • 0
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None

      During shutdown a number of things are currently happening that shouldn't be:

      1. The legacy transport layer is failing to actually close sockets in closeAll. It's doing this because the default argument to closeAll is to leave all sockets open on the legacy transport layer (versus to close them on the actual interface header).

      2. The thing we're checking for in shutdown is wrong. It's just that we've left recv in all db workers, rather than that we've left all client workers (so ASAN is occasionally unhappy about "leaks")

      3. Tests rely on external callers to close sockets. when this contract changes, we take an extra 10 seconds to shut down every mongod, making some tests time out.

      Fix this by adding a counter for actual live workers, so we can track when it's safe to shutdown correctly. Also fix the typo

            Assignee:
            Mira Carey
            Reporter:
            Mira Carey
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: