Skip to content

Conversation

@xcoderzach
Copy link
Contributor

It seems to be an issue with MongolianServer._connection not having a cached value until one of the connections callbacks is called, it fixes the issue of you call the callback right away.

it doesn't break any of the existing tests, but I couldn't think of a clever way to test this without digging into internals.

@jaekwon
Copy link

jaekwon commented Dec 20, 2011

#67

@demian85
Copy link

I don't get it, how can i close the connection? my script won't finish!

@jaekwon
Copy link

jaekwon commented Jan 23, 2012

force your script to close the server connection in a callback that actually uses one of the collections, say, listing the available indices for the collection.

      getCollection (err, collection) ->
        collection.indexes (err, indexes) ->
          server.close()

@defunctzombie
Copy link

db.server.close() or just server.close() if your have the server instance

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants