添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接

I opened a trial account and enabled CI and a Postgres Database.

Now I want to access the postgres from CI. I added JDBC Adapter with credentials from key file and a jdbc connection string like:
jdbc:postgresql://postgres-xxxxxfxx-85bf-4909-9476-b579cdc8893d.ce4jcviyvogb.eu-central-1.rds.amazonaws.com:4638/cMXXXXxxxZQ?ssl=false&loglevel=2

Unfortunately i always get org.springframework.jdbc.CannotGetJdbcConnectionException: Failed to obtain JDBC Connection; nested exception is org.postgresql.util.PSQLException: Connection to postgres-xxxxxxx-85bf-4909-9476-b579cdc8893d.ce4jcviyvogb.eu-central-1.rds.amazonaws.com:4638 refused. Check that the hostname and port are correct and that the postmaster is accepting TCP/IP connections., cause: java.net.ConnectException: error 111 - Connection refused (Connection refused) (local port 55746 to address 10.145.79.214 (33c72b56-d8a4-417f-7cd5-1ffc), remote port 4638 to address 10.16.56.221 (ip-10-16-56-221.eu-central-1.compute.internal))

Can anyone help here? do I need to establish a special connection between CPI and Postgres?


BR and thanks for the help

Hi Vladimir,

no I did not get it running. I found a sapnote with supported jdbc databases and postgres on aws was not on the list. So it might be that SAP does not support its own offered databases in BTP.

I have tried this ending: ?sslfactory=org.postgresql.ssl.NonValidatingFactory&ssl=true but still not possible. Where did you get this from?

My current String is

jdbc:postgresql://postgres-xxxxxxx-a28f-4251-a307-5e6437927b9f.ce4jcviyvogb.eu-central-1.rds.amazonaws.com:4690/zoDjKtxxxxx?sslfactory=org.postgresql.ssl.NonValidatingFactory&ssl=true

Same error as before.

I found that comment of alfonsoarmenta in a discussion.

I was also able to connect to the postgres by DBeaver tool - but only after I made SSH tunnel. But only when I set SSL mode to require and SSL Factory to NonValidating. In the connection settings.

But when I tried to elaborate with connection string in SCI - I wasnt succesfull too. But I think that the problem is that I cannot convince jdbc adapter to enable SSL - because that was the problem in DBeaver too.

New Release of SAP Data and Analytics Advisory Methodology in Technology Blogs by SAP Leveraging SAP AI Core APIs to Build your own AI Powered Apps in Technology Blogs by SAP Problem when binding CAP application with PostgreSQL, Hyperscaler Option - No default database in Technology Q&A Powering Logistics with SAP Business Technology Platform in Technology Blogs by SAP RingFencing & DeCoupling S/4HANA with Enterprise Blockchain and SAP BTP - Ultimate Cyber Security 🚀 in Technology Blogs by Members