Uploaded image for project: 'Ruby Driver'
  1. Ruby Driver
  2. RUBY-433

IOError stream closed

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 1.6.2
    • Affects Version/s: 1.6.1
    • Component/s: None
    • Labels:
    • Environment:
      nginx + passenger; the application spawns another thread during initialization (delayed job)

      In a multithreaded environment the latest version crashes with IOError (stream closed) here:
      https://github.com/mongodb/mongo-ruby-driver/blob/master/lib/mongo/util/pool.rb#L220

      I'm not familiar with the mongo driver internals, therefore I just did a workaround by changing the line to:

      socket.close if socket and !socket.closed?

      It was working before, but unfortunately I cannot pinpoint the version it became broken.

            Assignee:
            tyler@10gen.com Tyler Brock
            Reporter:
            romanbsd Roman
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: