postgresql - Connecting to Postgres Heroku DB through Intellij IDEA -
i've been trying connect postgres db day. can through pgadmin, can't connect through mysqlworkbench migrate , can't connect through intellij idea. we'll start w/intellij though...
so, when try connect through intellij, this...
connection sinthetics failed java.sql.sqlexception: ssl error: sun.security.validator.validatorexception: pkix path building failed: sun.security.provider.certpath.suncertpathbuilderexception: unable find valid certification path requested target i take mean need certificate, since i'm using ssl (because it's postgres/heroku). so, run handy installcert so...
java installcert ec2-54-243-235-169.compute-1.amazonaws.com:5432 and back:
loading keystore /usr/lib/jvm/java-7-openjdk-amd64/jre/lib/security/cacerts... opening connection ec2-54-243-235-169.compute-1.amazonaws.com:5432... starting ssl handshake... javax.net.ssl.sslhandshakeexception: remote host closed connection during handshake @ sun.security.ssl.sslsocketimpl.readrecord(sslsocketimpl.java:953) @ sun.security.ssl.sslsocketimpl.performinitialhandshake(sslsocketimpl.java:1332) @ sun.security.ssl.sslsocketimpl.starthandshake(sslsocketimpl.java:1359) @ sun.security.ssl.sslsocketimpl.starthandshake(sslsocketimpl.java:1343) @ installcert.main(installcert.java:87) caused by: java.io.eofexception: ssl peer shut down incorrectly @ sun.security.ssl.inputrecord.read(inputrecord.java:482) @ sun.security.ssl.sslsocketimpl.readrecord(sslsocketimpl.java:934) ... 4 more not obtain server certificate chain so why can't cert this, connects no problem pgadmin!? have clue @ all?
to add new connection postresql on heroku in intellij idea need to:
database tool window / new / data source / postresql
put host, port, database, user, password find on https://postgres.heroku.com/databases
go advanced tab , put:
- ssl: true
- sslfactory: org.postgresql.ssl.nonvalidatingfactory
profit.
Comments
Post a Comment