Repository navigation
Closed
Milestone
Description
I ran the JS tests a bunch last night to try and reproduce #2602 . I ran into the following errors, all of which seem to happen randomly:
#1
== Running connections/connection.js test
== Failed connections/connection.js test with result code 2 (/home/ssd2/mlucy/rethinkdb/test/rql_test/connections/connection.js.test) Output:
???????????????????????????
? 2 of 27 tests failed:
1) Javascript connection API With a server correct authorization key:
AssertionError: {"name":"RqlDriverError","msg":"Could not connect to localhost:57958.\nconnect ECONNREFUSED","message":"Could not connect to loc == null
at assertNull (/home/ssd2/mlucy/rethinkdb/test/rql_test/connections/connection.js:65:12)
at /home/ssd2/mlucy/rethinkdb/test/rql_test/connections/connection.js:149:21
at TcpConnection.<anonymous> (/home/ssd2/mlucy/rethinkdb/build/packages/js/net.js:77:18)
at TcpConnection.g (events.js:175:14)
at TcpConnection.EventEmitter.emit (events.js:95:17)
at Socket.<anonymous> (/home/ssd2/mlucy/rethinkdb/build/packages/js/net.js:526:27)
at Socket.EventEmitter.emit (events.js:117:20)
at net.js:426:14
at process._tickCallback (node.js:415:13)
2) Javascript connection API With a server test use:
Error: timeout of 2000ms exceeded
at null.<anonymous> (/usr/local/lib/node_modules/mocha/lib/runnable.js:167:14)
at Timer.listOnTimeout [as ontimeout] (timers.js:110:15)
== Running connections/connection.js test
== Failed connections/connection.js test with result code 1 (/home/ssd2/mlucy/rethinkdb/test/rql_test/connections/connection.js.test) Output:
???????????????????????????
? 1 of 27 tests failed:
1) Javascript connection API With a server Emits close event on close:
AssertionError: {"name":"RqlDriverError","msg":"Server dropped connection with message: \"RethinkDB cluster\n\u0004\"","message":"Server dropped == null
at assertNull (/home/ssd2/mlucy/rethinkdb/test/rql_test/connections/connection.js:65:12)
at /home/ssd2/mlucy/rethinkdb/test/rql_test/connections/connection.js:43:13
at TcpConnection.<anonymous> (/home/ssd2/mlucy/rethinkdb/build/packages/js/net.js:75:18)
at TcpConnection.g (events.js:175:14)
at TcpConnection.EventEmitter.emit (events.js:95:17)
at Socket.handshake_callback (/home/ssd2/mlucy/rethinkdb/build/packages/js/net.js:513:23)
at Socket.EventEmitter.emit (events.js:95:17)
at Socket.<anonymous> (_stream_readable.js:736:14)
at Socket.EventEmitter.emit (events.js:92:17)
at emitReadable_ (_stream_readable.js:408:10)
at emitReadable (_stream_readable.js:404:5)
at readableAddChunk (_stream_readable.js:165:9)
at Socket.Readable.push (_stream_readable.js:127:10)
at TCP.onread (net.js:511:21)
The unlisted second failed test is a dup of #2 above
== Running connections/connection.js test
== Failed connections/connection.js test with result code 1 (/home/ssd2/mlucy/rethinkdb/test/rql_test/connections/connection.js.test) Output:
???????????????????????????
? 1 of 27 tests failed:
1) Javascript connection API With a server close twice and reconnect:
Error: timeout of 2000ms exceeded
at null.<anonymous> (/usr/local/lib/node_modules/mocha/lib/runnable.js:167:14)
at Timer.listOnTimeout [as ontimeout] (timers.js:110:15)
== Running polyglot/aggregation.js test
RethinkDB server failed: Error: rethinkdb process 14076 failed with error code 1
info: Our machine ID: 292b38b9-74ce-4936-b437-d7637055ab0c
info: Created directory '/home/ssd2/mlucy/rethinkdb/test/rql_test/run/server_34221/rdb' and a metadata file inside it.
info: Running rethinkdb 1.12.5-1524-g76cd47-dirty (CLANG 3.2 (tags/RELEASE_32/final))...
info: Running on Linux 3.2.0-61-generic x86_64
info: Using cache size of 1024 MB
info: Loading data from directory /home/ssd2/mlucy/rethinkdb/test/rql_test/run/server_34221/rdb
error: Could not bind to cluster port: The address at localhost:48796 is reserved or already in use.
== Failed polyglot/aggregation.js test with result code 1 (/home/ssd2/mlucy/rethinkdb/test/rql_test/src/aggregation.yaml) Output:
Failed to connect to server: { name: 'RqlDriverError',
msg: 'Could not connect to localhost:34221.\nconnect ECONNREFUSED',
message: 'Could not connect to localhost:34221.\nconnect ECONNREFUSED' }
== Running connections/feeds.js test
== Failed connections/feeds.js test with result code 1 (/home/ssd2/mlucy/rethinkdb/test/rql_test/connections/feeds.js.test) Output:
Running JS feeds
Running test1
[Error: Timeout]
Error: TimeoutError: Timeout
at r.connect.port [as _onTimeout] (/home/ssd2/mlucy/rethinkdb/test/rql_test/connections/feeds.js:23:11)
at Timer.listOnTimeout [as ontimeout] (timers.js:110:15)
Metadata
Metadata
Assignees
Labels
No labels
Activity
mlucy commentedon Jun 25, 2014
Most of these look like timing errors or things that can be fixed in the tests (like the "port in use" error), but 2 might be a driver error.
neumino commentedon Jun 26, 2014
Looking into this.
neumino commentedon Jun 27, 2014
The reason why the tests were failing was because we were trying to start RethinkDB on a port already used. Now if we fail to bind to a port, we just try again on another port.
In review 1713 assigned to @larkost
Branch michel_2606_test
neumino commentedon Jun 30, 2014
Merged in next as ffcfb60
Ship 1.14