gitbase
gitbase copied to clipboard
Error when connecting from JDBC MariaDB driver
Error on gitbase side:
gsc-gitbase | time="2019-04-26T08:22:34Z" level=info msg="NewConnection: client 1"
gsc-gitbase | time="2019-04-26T08:22:34Z" level=error msg="Cannot parse client handshake response from client 1 (172.19.0.4:59740): Code: INTERNAL\nparseClientHandshakePacket: can't read connection attribute value\n"
Error from the client side:
gsc-gitbase-spark-connector-jupyter | Exception in thread "main" java.sql.SQLNonTransientConnectionException: Could not connect to gitbase:3306 : unexpected end of stream, read 0 bytes from 4 (socket was closed by server)
gsc-gitbase-spark-connector-jupyter | at org.mariadb.jdbc.internal.util.exceptions.ExceptionMapper.get(ExceptionMapper.java:234)
gsc-gitbase-spark-connector-jupyter | at org.mariadb.jdbc.internal.util.exceptions.ExceptionMapper.getException(ExceptionMapper.java:165)
gsc-gitbase-spark-connector-jupyter | at org.mariadb.jdbc.internal.protocol.AbstractConnectProtocol.connectWithoutProxy(AbstractConnectProtocol.java:1199)
gsc-gitbase-spark-connector-jupyter | at org.mariadb.jdbc.internal.util.Utils.retrieveProxy(Utils.java:560)
gsc-gitbase-spark-connector-jupyter | at org.mariadb.jdbc.MariaDbConnection.newConnection(MariaDbConnection.java:174)
...
Only happening with the latest v0.20.0-beta4 release
What query are you making? Can you provide more specific details. I've been trying to reproduce this with both 0.20.0-beta4 and master and it works for me.
From https://github.com/src-d/gitbase-spark-connector repo:
- go to docker-compose.yml
- change
srcd/gitbase:v0.20.0-beta3
tosrcd/gitbase:v0.20.0-beta4
- change
/path/to/repos
to a valid path with repositories
- change
- execute docker-compose up
- go to localhost:8080
- try to execute first notebook page
- error appears
Ok, got to reproduce this.
There's an error parsing connection attributes, which has been reported for a couple months: https://github.com/vitessio/vitess/issues/4603
I added more details to the issue and a reproduction case.
We have two options here:
- Try to fix the issue in vitess.
- Wait until they fix it, rollback to go-vitess 1.4.0 and scan manually for "SHOW SCHEMAS" instead of using the builtin support in vitess we added.
I think we should fix vitess, but no idea how much that's gonna take.
WDYT @ajnavarro?
Not fixed in gitbase.
https://github.com/vitessio/vitess/pull/4897
Will be fixed once we upgrade to latest vitess version.