Stamatis Zampetakis created HIVE-25675:
------------------------------------------
Summary: Intermittent PSQLException when trying to connect to
Postgres in tests
Key: HIVE-25675
URL: https://issues.apache.org/jira/browse/HIVE-25675
Project: Hive
Issue Type: Bug
Components: Testing Infrastructure
Affects Versions: 4.0.0
Reporter: Stamatis Zampetakis
Assignee: Stamatis Zampetakis
The following exception appears intermittently when running tests using
dockerized Postgres.
{noformat}
Unexpected exception org.postgresql.util.PSQLException: FATAL: the database
system is starting up
21:26:55 at
org.postgresql.core.v3.ConnectionFactoryImpl.doAuthentication(ConnectionFactoryImpl.java:525)
21:26:55 at
org.postgresql.core.v3.ConnectionFactoryImpl.tryConnect(ConnectionFactoryImpl.java:146)
21:26:55 at
org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:197)
21:26:55 at
org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:49)
21:26:55 at
org.postgresql.jdbc.PgConnection.<init>(PgConnection.java:217)
21:26:55 at org.postgresql.Driver.makeConnection(Driver.java:458)
21:26:55 at org.postgresql.Driver.connect(Driver.java:260)
21:26:55 at java.sql.DriverManager.getConnection(DriverManager.java:664)
21:26:55 at java.sql.DriverManager.getConnection(DriverManager.java:247)
21:26:55 at
org.apache.hadoop.hive.ql.externalDB.AbstractExternalDB.execute(AbstractExternalDB.java:191)
21:26:55 at
org.apache.hadoop.hive.ql.qoption.QTestDatabaseHandler.beforeTest(QTestDatabaseHandler.java:116)
21:26:55 at
org.apache.hadoop.hive.ql.qoption.QTestOptionDispatcher.beforeTest(QTestOptionDispatcher.java:79)
21:26:55 at
org.apache.hadoop.hive.ql.QTestUtil.cliInit(QTestUtil.java:717)
21:26:55 at
org.apache.hadoop.hive.cli.control.CoreCliDriver.runTest(CoreCliDriver.java:189)
21:26:55 at
org.apache.hadoop.hive.cli.control.CliAdapter.runTest(CliAdapter.java:104)
21:26:55 at
org.apache.hadoop.hive.cli.TestMiniLlapLocalCliDriver.testCliDriver(TestMiniLlapLocalCliDriver.java:62)
{noformat}
As the exception indicates when we try to connect to Postgres the database is
not yet completely ready despite the fact that the respective port is open thus
leading to the previous exception.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)