[英]Talend failing connection to PostgreSQL
I am currently creating an ETL job in talend which is connecting to a PostgreSQL database and I ran into a connection error. 我目前正在连接到PostgreSQL数据库的talend中创建ETL作业,但遇到连接错误。
I have set up a db connection in my talend repository with all the connection details I need to connect to my postgreSQL database and saved as 'mydbconnection', which specific database schema specified. 我已经在talend存储库中建立了一个数据库连接,其中包含了连接到postgreSQL数据库所需的所有连接详细信息,并保存为“ mydbconnection”,即指定的特定数据库架构。
I have used mydbconnection
in tPostgreSQLOutput
and tPostgreSQLInput
and both worked perfectly. 我在
tPostgreSQLOutput
和tPostgreSQLInput
使用了mydbconnection
,两者都工作得很好。 However, when I use that same connection from the repository in a tEltPostgreSQLOutput_1
it throws an error (see below). 但是,当我在
tEltPostgreSQLOutput_1
的存储库中使用相同的连接时,会引发错误(请参见下文)。
... and have no idea where to go from here. ...而且不知道从这里去哪里。 Does anyone know of any other good lines of investigation to resolve this?
有谁知道其他解决这个问题的好方法?
Error message : 错误讯息 :
Exception in component tELTPostgresqlOutput_1
org.postgresql.util.PSQLException: The connection attempt failed.
at org.postgresql.core.v3.ConnectionFactoryImpl.openConnectionImpl(ConnectionFactoryImpl.java:137)
at org.postgresql.core.ConnectionFactory.openConnection(ConnectionFactory.java:66)
at org.postgresql.jdbc2.AbstractJdbc2Connection.<init>(AbstractJdbc2Connection.java:124)
at org.postgresql.jdbc3.AbstractJdbc3Connection.<init>(AbstractJdbc3Connection.java:30)
at org.postgresql.jdbc3.Jdbc3Connection.<init>(Jdbc3Connection.java:24)
at org.postgresql.Driver.makeConnection(Driver.java:386)
at org.postgresql.Driver.connect(Driver.java:260)
at java.sql.DriverManager.getConnection(Unknown Source)
at java.sql.DriverManager.getConnection(Unknown Source)
at zurich_segmentation_prod.is_300_customer_new_0_1.is_300_customer_new.tELTPostgresqlMap_1Process(is_300_customer_new.java:338)
at zurich_segmentation_prod.is_300_customer_new_0_1.is_300_customer_new.runJobInTOS(is_300_customer_new.java:602)
at zurich_segmentation_prod.is_300_customer_new_0_1.is_300_customer_new.main(is_300_customer_new.java:470)
for anyone who runs into this problem in the future.. i found a way around it. 对于将来遇到此问题的任何人..我找到了解决之道。 I added a tPostgreSQLConnection to my workspace, then ticked the option in my tELTPostgreSQLMap to 'use existing connection' this then seems to remain connected when the work flow reaches the tEltPostgreSQLOutput component.
我在工作空间中添加了一个tPostgreSQLConnection,然后在我的tELTPostgreSQLMap中选中了“使用现有连接”选项,当工作流程到达tEltPostgreSQLOutput组件时,该选项似乎保持连接状态。 It's not pretty but it works.
它不是很漂亮,但是可以。 The more obvious way (the way i had initial done it) does not work.
更明显的方式(我最初做的方式)不起作用。 A bug has been added to Talend's JIRA for this exact scenario.
针对此确切情况,已在Talend的JIRA中添加了一个错误。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.