Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1eu2q8-0006Gg-52 for pgsql-general@arkaria.postgresql.org; Thu, 08 Mar 2018 21:12:40 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1eu2q6-0006KR-Vz for pgsql-general@arkaria.postgresql.org; Thu, 08 Mar 2018 21:12:38 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1eu2q6-0006IB-Eo for pgsql-general@lists.postgresql.org; Thu, 08 Mar 2018 21:12:38 +0000 Received: from mail-oi0-x22e.google.com ([2607:f8b0:4003:c06::22e]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1eu2q3-0008DK-Ot for pgsql-general@postgresql.org; Thu, 08 Mar 2018 21:12:37 +0000 Received: by mail-oi0-x22e.google.com with SMTP id g5so5444216oiy.8 for ; Thu, 08 Mar 2018 13:12:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pgsqlrocket-com.20150623.gappssmtp.com; s=20150623; h=to:from:subject:message-id:date:user-agent:mime-version :content-language; bh=ScBoatBBPXgF4oYcWCIRccTtx7wh6VzoG8d6+6IItOw=; b=o+VIJBdzXQDzeeasQhm4cWxP0nMVxZwUjnVSMZeFxeVP2xTu9janonp3LzyTbP1/iB mwPJwaZRSTcVlhIcARO9ImpPSOR1fFi2f7BzxPaTlkQ/h8ImtJgNw9+ChU8CAFu+ypls TMPvchYHgLy5c1ma+MlKDxJ1ioSJG5UqKtJB84tDbLpfJM581p8s4RH6r14RpsWwJr1h fFwTDhqZEjlb0bavoAZvv+jk7YOEUV4A86fSKmoDf1CAPAynfYhScFiC69f0SnkJVwHu vRyM/Es2QomFiBzDTp+99MttBEqnBE9fjHjuHD2m7qCjtWTedI2apMRxEwD7pYkkyCRh dqaw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:to:from:subject:message-id:date:user-agent :mime-version:content-language; bh=ScBoatBBPXgF4oYcWCIRccTtx7wh6VzoG8d6+6IItOw=; b=MQeQckVFAenIrFSdcmkLrq7hpwpDepuVA/WeuPCBYltxevWUat3npbAa9NS5+4IXao /3cplWGMXGrEN8uZOFOQsqMGSzA9nzaP1WOroQSTpIWDHhNH45J3i/tVG/LBAyjFYg7q P+l5zRqwMUSKbgMbJOUqijT8I/6HpSZ8KYtcKCJ4zAIBKRUTglyRDQ/LNYGBiJtXif/N KgSY8E/W93lpVP9+24WiTLaH+3o6BYjm1ez/I/VrUxsndOJyr0O+bW/LEM/oo4lEFhVv s2deW5VR5hKyiRQr09V/v4AlMXZGyZjXMBD7JC40GgF3SVU7UZ0Q+lsdIBLmLyUj+Paf pUMw== X-Gm-Message-State: APf1xPBmJTE3b/qzww5i6OKboGPWcfwv23UP4fVnxk839T7A4TVSEfpF 8RjiF+Ten24zGWyzq4LW/O7PC+19l5k= X-Google-Smtp-Source: AG47ELuSBMZVJH0afYGoNfSdXi8YJ01kU4Ynzos8K1H4cnjAM5k+OnTfuZweXsaUC/QLKznWWrndJA== X-Received: by 10.202.240.212 with SMTP id o203mr18539772oih.182.1520543555091; Thu, 08 Mar 2018 13:12:35 -0800 (PST) Received: from localhost.localdomain ([65.132.155.214]) by smtp.gmail.com with ESMTPSA id r58sm10907706otb.58.2018.03.08.13.12.34 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 08 Mar 2018 13:12:34 -0800 (PST) To: Postgres General From: chris Subject: JDBC connectivity issue Message-ID: Date: Thu, 8 Mar 2018 14:12:33 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="------------00E89BC99639996073580519" Content-Language: en-US List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk This is a multi-part message in MIME format. --------------00E89BC99639996073580519 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit 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 out to the standby. I looked online and found the suggested way to do this, but it's not working. This is the JDBC line we have: /jdbc.url=jdbc:postgresql://10.16.10.12:5432,10.16.10.13:5432/app_db/ Here is the error we are getting:/ / /2018-03-07 13:54:36, 994 ERROR:com.zaxxer.hikari.util.PropertyElf - failed to set properly port number on target class org.postgresql.ds.PGSimpleDataSource java.langNumberFormatException:for input string: "5432,10.16.10.13:5432"/ It looks like the first IP address has disappeared or is not set right./ / Thanks in advance for the help. // --------------00E89BC99639996073580519 Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 7bit

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 out to the standby.

I looked online and found the suggested way to do this, but it's not working.

This is the JDBC line we have:

jdbc.url=jdbc:postgresql://10.16.10.12:5432,10.16.10.13:5432/app_db

Here is the error we are getting:

2018-03-07 13:54:36, 994 ERROR:com.zaxxer.hikari.util.PropertyElf - failed to set properly port number on target class org.postgresql.ds.PGSimpleDataSource java.langNumberFormatException:for input string: "5432,10.16.10.13:5432"

It looks like the first IP address has disappeared or is not set right.

Thanks in advance for the help.



--------------00E89BC99639996073580519--