Uploaded image for project: 'Mongoid'
  1. Mongoid
  2. MONGOID-637

reconnect! should support multi-database reconnect

    • Type: Icon: Task Task
    • Resolution: Done
    • 12_01_17
    • Affects Version/s: None
    • Component/s: None

      In lib/mongoid/config.rb

      <pre>
      def reconnect!(now = true)
      if now
      master.connection.connect
      else

      1. We set a @reconnect flag so that #master knows to reconnect the next
      2. time the connection is accessed.
        @reconnect = true
        end
        end
        </pre>

      In the recent releases mongoid already added support for multi-database connections. reconnect! should also reconnect other connections but now it only reconnect the Mongoid.master connection.

            Assignee:
            Unassigned Unassigned
            Reporter:
            stonegao Stone, Gao
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: