-
Type: Bug
-
Resolution: Done
-
Priority: Major - P3
-
None
-
Affects Version/s: 2.2.3
-
Component/s: Concurrency
-
None
-
ALL
import pymongo c = pymongo.Connection('localhost:27119') c.database_names()
c.database_names() doesn't appear to return while a large index is being rebuilt on one of the shards in a sharded cluster.
We had a server crash due to exceeding the filedescriptor limit. Now, having restarted it with an increased fd limit. The index has taken 30mins to build to 20%. During this time, operations like listing database_names() seem to hang forever
c.database_names() File "/local/home/jblackburn/net/pymongo-2.4.2/pymongo/mongo_client.py", line 1068, in database_names self.admin.command("listDatabases")["databases"]] File "/local/home/jblackburn/net/pymongo-2.4.2/pymongo/database.py", line 390, in command result = self["$cmd"].find_one(command, **extra_opts) File "/local/home/jblackburn/net/pymongo-2.4.2/pymongo/collection.py", line 598, in find_one for result in self.find(spec_or_id, *args, **kwargs).limit(-1): File "/local/home/jblackburn/net/pymongo-2.4.2/pymongo/cursor.py", line 814, in next if len(self.__data) or self._refresh(): File "/local/home/jblackburn/net/pymongo-2.4.2/pymongo/cursor.py", line 763, in _refresh self.__uuid_subtype)) File "/local/home/jblackburn/net/pymongo-2.4.2/pymongo/cursor.py", line 700, in __send_message **kwargs) File "/local/home/jblackburn/net/pymongo-2.4.2/pymongo/mongo_client.py", line 915, in _send_message_with_response return self.__send_and_receive(message, sock_info) File "/local/home/jblackburn/net/pymongo-2.4.2/pymongo/mongo_client.py", line 893, in __send_and_receive return self.__receive_message_on_socket(1, request_id, sock_info) File "/local/home/jblackburn/net/pymongo-2.4.2/pymongo/mongo_client.py", line 878, in __receive_message_on_socket header = self.__receive_data_on_socket(16, sock_info) File "/local/home/jblackburn/net/pymongo-2.4.2/pymongo/mongo_client.py", line 866, in __receive_data_on_socket chunk = sock_info.sock.recv(length) KeyboardInterrupt