alexradzin / aerospike-jdbc-driver

JDBC driver for Aerospike
Apache License 2.0
12 stars 3 forks source link

connection string does not support non-standard ports #2

Closed realmgic closed 5 years ago

realmgic commented 5 years ago

It seems that the connection string does not support non-standard port (it hard-coded uses 3000). I assume the connection string should look something like SQL Server's URL in order for this to work (looking at the url parsing code): jdbc:sqlserver://[serverName[\instanceName][:portNumber]][;property=value[;property=value]]

This will allow adding ports and later even security features such as user/password.

alexradzin commented 5 years ago

Unlike SQL server most of relational databases I know use slightly different format of JDBC URL and I followed this convention. The port is optional and follows the host separated from it by colon. Then you can optionally specify the namespace separated by slash. After that you can write parameters. For example jdbc:aerospike:myhost:3456/mynamespace?timeout=10000

The bug was in the README file that did not mention the format of JDBC URL. I've updated it following your bug report. Thanks a lot.

alexradzin commented 5 years ago

In fact it was a lack of documentation that was fixed.