Uploaded image for project: 'C Driver'
  1. C Driver
  2. CDRIVER-578

v1.2 gets into endless loop when server closes the connection

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 1.2.0
    • Component/s: None
    • None

      Looks like mongoc_socket_recv() will never fail, even though the remote server had rejected the connection

      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: mongoc_topology_description_init():50
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   >  EXIT: mongoc_topology_description_init():70
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: mongoc_server_description_init():89
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   >  EXIT: mongoc_server_description_init():118
      [2015-03-12T23:51:37+00:00]    cluster: TRACE   > ENTRY: mongoc_cluster_init():1338
      [2015-03-12T23:51:37+00:00]    cluster: TRACE   >  EXIT: mongoc_cluster_init():1358
      [2015-03-12T23:51:37+00:00]     client: DEBUG   > Using custom stream initiator.
      [2015-03-12T23:51:37+00:00] PHONGO-BSON: TRACE   > Added new _id
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: mongoc_bulk_operation_insert():180
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: _mongoc_write_command_init_insert():121
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: _mongoc_write_command_insert_append():72
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   >  EXIT: _mongoc_write_command_insert_append():109
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   >  EXIT: _mongoc_write_command_init_insert():137
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   >  EXIT: mongoc_bulk_operation_insert():200
      [2015-03-12T23:51:37+00:00] PHONGO-BSON: TRACE   > Added new _id
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: mongoc_bulk_operation_insert():180
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: _mongoc_write_command_insert_append():72
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   >  EXIT: _mongoc_write_command_insert_append():109
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   >  EXIT: mongoc_bulk_operation_insert():191
      [2015-03-12T23:51:37+00:00] PHONGO-BSON: TRACE   > Added new _id
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: mongoc_bulk_operation_insert():180
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: _mongoc_write_command_insert_append():72
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   >  EXIT: _mongoc_write_command_insert_append():109
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   >  EXIT: mongoc_bulk_operation_insert():191
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: mongoc_bulk_operation_remove_one():140
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: _mongoc_write_command_init_delete():147
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   >  EXIT: _mongoc_write_command_init_delete():157
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   >  EXIT: mongoc_bulk_operation_remove_one():145
      [2015-03-12T23:51:37+00:00] PHONGO-BSON: TRACE   > encoding as-if was stdclass
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: mongoc_bulk_operation_update_one():283
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: _mongoc_write_command_init_update():169
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   >  EXIT: _mongoc_write_command_init_update():182
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   >  EXIT: mongoc_bulk_operation_update_one():299
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: mongoc_bulk_operation_execute():313
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: _mongoc_write_result_init():866
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   >  EXIT: _mongoc_write_result_init():876
      [2015-03-12T23:51:37+00:00]     mongoc: TRACE   > ENTRY: _mongoc_write_command_execute():799
      [2015-03-12T23:51:37+00:00]    cluster: TRACE   > ENTRY: _mongoc_cluster_select_by_optype():1418
      [2015-03-12T23:51:37+00:00] topology_scanner: TRACE   > ENTRY: mongoc_topology_scanner_node_connect_tcp():190
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: mongoc_socket_new():682
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: _mongoc_socket_setnodelay():255
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  EXIT: _mongoc_socket_setnodelay():267
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  EXIT: mongoc_socket_new():706
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: mongoc_socket_connect():545
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: _mongoc_socket_wait():123
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  EXIT: _mongoc_socket_wait():164
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  EXIT: mongoc_socket_connect():575
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: _mongoc_stream_socket_poll():215
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: mongoc_socket_poll():205
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: _mongoc_stream_socket_poll():241
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: mongoc_stream_writev():117
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: _mongoc_stream_socket_writev():191
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: mongoc_socket_sendv():1031
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: _mongoc_socket_try_sendv():955
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  sendbuf = 0x7fd7339da660 [58]
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > 00000:  3a 00 00 00 01 00 00 00  00 00 00 00 d4 07 00 00  : . . . . . . .  . . . . . . . .
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > 00010:  04 00 00 00 61 64 6d 69  6e 2e 24 63 6d 64 00 00  . . . . a d m i  n . $ c m d . .
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > 00020:  00 00 00 ff ff ff ff 13  00 00 00 10 69 73 4d 61  . . . . . . . .  . . . . i s M a
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > 00030:  73 74 65 72 00 01 00 00  00 00                    s t e r . . . .  . .
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  EXIT: _mongoc_socket_try_sendv():994
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  EXIT: mongoc_socket_sendv():1106
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: _mongoc_stream_socket_writev():197
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: mongoc_stream_writev():131
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: _mongoc_stream_socket_poll():215
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: mongoc_socket_poll():205
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: _mongoc_stream_socket_poll():241
      [2015-03-12T23:51:37+00:00]     buffer: TRACE   > ENTRY: _mongoc_buffer_try_append_from_stream():295
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: mongoc_stream_read():232
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: mongoc_stream_readv():193
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: _mongoc_stream_socket_readv():128
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: mongoc_socket_recv():753
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  recvbuf = 0x7fd7339da208 [0]
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >                                                          
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  EXIT: mongoc_socket_recv():785
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: _mongoc_stream_socket_readv():150
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: mongoc_stream_readv():203
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: mongoc_stream_read():244
      [2015-03-12T23:51:37+00:00]     buffer: TRACE   >  EXIT: _mongoc_buffer_try_append_from_stream():325
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: _mongoc_stream_socket_poll():215
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: mongoc_socket_poll():205
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: _mongoc_stream_socket_poll():241
      [2015-03-12T23:51:37+00:00]     buffer: TRACE   > ENTRY: _mongoc_buffer_try_append_from_stream():295
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: mongoc_stream_read():232
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: mongoc_stream_readv():193
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: _mongoc_stream_socket_readv():128
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: mongoc_socket_recv():753
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  recvbuf = 0x7fd7339da208 [0]
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >                                                          
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  EXIT: mongoc_socket_recv():785
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: _mongoc_stream_socket_readv():150
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: mongoc_stream_readv():203
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: mongoc_stream_read():244
      [2015-03-12T23:51:37+00:00]     buffer: TRACE   >  EXIT: _mongoc_buffer_try_append_from_stream():325
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: _mongoc_stream_socket_poll():215
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: mongoc_socket_poll():205
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: _mongoc_stream_socket_poll():241
      [2015-03-12T23:51:37+00:00]     buffer: TRACE   > ENTRY: _mongoc_buffer_try_append_from_stream():295
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: mongoc_stream_read():232
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: mongoc_stream_readv():193
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: _mongoc_stream_socket_readv():128
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: mongoc_socket_recv():753
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  recvbuf = 0x7fd7339da208 [0]
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >                                                          
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  EXIT: mongoc_socket_recv():785
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: _mongoc_stream_socket_readv():150
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: mongoc_stream_readv():203
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: mongoc_stream_read():244
      [2015-03-12T23:51:37+00:00]     buffer: TRACE   >  EXIT: _mongoc_buffer_try_append_from_stream():325
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: _mongoc_stream_socket_poll():215
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: mongoc_socket_poll():205
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: _mongoc_stream_socket_poll():241
      [2015-03-12T23:51:37+00:00]     buffer: TRACE   > ENTRY: _mongoc_buffer_try_append_from_stream():295
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: mongoc_stream_read():232
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: mongoc_stream_readv():193
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: _mongoc_stream_socket_readv():128
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: mongoc_socket_recv():753
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  recvbuf = 0x7fd7339da208 [0]
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >                                                          
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  EXIT: mongoc_socket_recv():785
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: _mongoc_stream_socket_readv():150
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: mongoc_stream_readv():203
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: mongoc_stream_read():244
      [2015-03-12T23:51:37+00:00]     buffer: TRACE   >  EXIT: _mongoc_buffer_try_append_from_stream():325
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: _mongoc_stream_socket_poll():215
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: mongoc_socket_poll():205
      [2015-03-12T23:51:37+00:00]     stream: TRACE   >  EXIT: _mongoc_stream_socket_poll():241
      [2015-03-12T23:51:37+00:00]     buffer: TRACE   > ENTRY: _mongoc_buffer_try_append_from_stream():295
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: mongoc_stream_read():232
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: mongoc_stream_readv():193
      [2015-03-12T23:51:37+00:00]     stream: TRACE   > ENTRY: _mongoc_stream_socket_readv():128
      [2015-03-12T23:51:37+00:00]     socket: TRACE   > ENTRY: mongoc_socket_recv():753
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >  recvbuf = 0x7fd7339da208 [0]
      [2015-03-12T23:51:37+00:00]     socket: TRACE   >                                                          
      

      (repeat forever)

            Assignee:
            mira.carey@mongodb.com Mira Carey
            Reporter:
            bjori Hannes Magnusson
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: