Re: JDBC connectivity issue

2018-03-23 Thread Dave Cramer
Cool, thanks. I'd love to see this work Dave Cramer da...@postgresintl.com www.postgresintl.com On 23 March 2018 at 10:24, JCMS22 wrote: > I forgot to say I am trying to investigate how to make it work as we need > specific stuff from the DataSource object. > > It

Re: JDBC connectivity issue

2018-03-23 Thread JCMS22
I forgot to say I am trying to investigate how to make it work as we need specific stuff from the DataSource object. It might work if you use setServerName rather than setUrl. setServerName will append itself the jdbc:postgresql:// so you only give it the server name (i.e

Re: JDBC connectivity issue

2018-03-23 Thread JCMS22
I am surprised this was not answered correct yet. I am in the same bucket as you and here is the problem. A quick look at the code and you find the answer. The BaseDataSource class (from which PGSimpleDataSource inherits) does NOT support failover addresses. The underlying driver used to parse

Re: JDBC connectivity issue

2018-03-22 Thread Dave Cramer
Chris, At this point I'd write small piece of code to test if the url and failover is working correctly. Sounds like you have a considerably sized stack making it difficult to debug. With a small piece of code it should become clear as to how things work or don't as the case may be Dave Cramer

Re: JDBC connectivity issue

2018-03-21 Thread Adrian Klaver
On 03/21/2018 01:56 PM, chris wrote: I did the re install not to change versions but to now know what version I am running My previous question was not as clear as should have been. So: 1) At some place in your software stack there is some sort of configuration that links your app via JDBC to

Re: JDBC connectivity issue

2018-03-21 Thread chris
I did the re install not to change versions but to now know what version I am running On 03/21/2018 02:44 PM, Adrian Klaver wrote: On 03/21/2018 01:16 PM, chris wrote: I wasnt able to find what version we had installed so we went ahead and reinstalled it Maybe I am missing something, but

Re: JDBC connectivity issue

2018-03-21 Thread Adrian Klaver
On 03/21/2018 01:16 PM, chris wrote: I wasnt able to find what version we had installed so we went ahead and reinstalled it Maybe I am missing something, but if you could not find the version you where using how do you know installing a new driver actually changed the version you are using

Re: JDBC connectivity issue

2018-03-21 Thread chris
I wasnt able to find what version we had installed so we went ahead and reinstalled it. we downloaded the current version JDBC 4.1 Driver 42.2.1.jre7 We are still having the same problem. Thanks On 03/14/2018 03:27 PM, Adrian Klaver wrote: On 03/14/2018 01:47 PM, chris wrote: Oh sorry

Re: JDBC connectivity issue

2018-03-14 Thread chris
Oh sorry for getting the wrong information. How would I get the information on what driver is currently installed? On 03/14/2018 09:44 AM, Adrian Klaver wrote: On 03/14/2018 07:51 AM, chris wrote: I believe its Postgresql-9.4.1208.jre7.jar Pretty sure solving this is going to require

Re: JDBC connectivity issue

2018-03-14 Thread Adrian Klaver
On 03/14/2018 07:51 AM, chris wrote: I believe its Postgresql-9.4.1208.jre7.jar Pretty sure solving this is going to require knowing exactly what driver is in use. The failover syntax looks to be fairly recent, so being off by a little on the driver version can make a big difference. Or

Re: JDBC connectivity issue

2018-03-14 Thread chris
I believe its Postgresql-9.4.1208.jre7.jar On 03/13/2018 05:48 PM, Adrian Klaver wrote: On 03/13/2018 04:46 PM, chris wrote: I'm sorry that took a few days but I am running; Postgresql-9.4 and jre7.jar What we are looking for is the JDBC driver you are using? Thanks in advance. On

Re: JDBC connectivity issue

2018-03-13 Thread Adrian Klaver
On 03/13/2018 04:46 PM, chris wrote: I'm sorry that took a few days but I am running; Postgresql-9.4 and jre7.jar What we are looking for is the JDBC driver you are using? Thanks in advance. On 03/08/2018 02:30 PM, chris wrote: Given that the syntax looks correct for the url, how

Re: JDBC connectivity issue

2018-03-13 Thread chris
I'm sorry that took a few days but I am running; Postgresql-9.4 and jre7.jar Thanks in advance. On 03/08/2018 02:30 PM, chris wrote: Given that the syntax looks correct for the url, how would we go about debugging that it's not seeing the comma? On 03/08/2018 02:27 PM, Adrian Klaver

Re: JDBC connectivity issue

2018-03-08 Thread Dave Cramer
You should be using the latest version of the driver. What version are you using ? Even though you have a 9.4 database the latest version is the correct version to use. Dave Cramer da...@postgresintl.com www.postgresintl.com On 8 March 2018 at 22:14, David G. Johnston

Re: JDBC connectivity issue

2018-03-08 Thread David G. Johnston
On Thu, Mar 8, 2018 at 2:30 PM, chris wrote: > Given that the syntax looks correct for the url, how would we go about > debugging that it's not seeing the comma? ​First thing I'd do is ensure the version of the driver I'm using supports the feature I'm trying to use.

Re: JDBC connectivity issue

2018-03-08 Thread Adrian Klaver
On 03/08/2018 01:30 PM, chris wrote: Given that the syntax looks correct for the url, how would we go about debugging that it's not seeing the comma? From previous post: Can you provide more information about the JDBC version you are using and the app code you are using? On 03/08/2018

Re: JDBC connectivity issue

2018-03-08 Thread chris
Given that the syntax looks correct for the url, how would we go about debugging that it's not seeing the comma? On 03/08/2018 02:27 PM, Adrian Klaver wrote: On 03/08/2018 01:12 PM, chris wrote: Hi, I have a JDBC temping to connect to 2 postgres nodes in a hot standby configuration.

Re: JDBC connectivity issue

2018-03-08 Thread Adrian Klaver
On 03/08/2018 01:12 PM, chris wrote: Hi, I have a JDBC temping to connect to 2 postgres nodes in a hot standby configuration. Running postgres 9.4 on centos6. What we are trying to accomplish is in an event of a failover, to first try to connect to the master. If that fails to then reach

Re: JDBC connectivity issue

2018-03-08 Thread Tim Cross
My interpretation of that error is slightly different. I think what it is saying is that for the first IP address, it thinks the port number is the full string "5432,10.16.10.13:5432" and fails when it tries to convert that into a port number. Are you positive the URL format you are trying to use

Re: JDBC connectivity issue

2018-03-08 Thread Adrian Klaver
On 03/08/2018 01:12 PM, chris wrote: Hi, I have a JDBC temping to connect to 2 postgres nodes in a hot standby configuration. Running postgres 9.4 on centos6. What we are trying to accomplish is in an event of a failover, to first try to connect to the master. If that fails to then reach