英文:
Springboot 2.3.4.RELEASE connection to Azure postgresql fails
问题
我们最近将其中一个服务升级到了2.3.4.RELEASE版本。升级后,我们无法再连接到Azure PAAS PostgreSQL,出现以下错误:
无法从数据库获取连接(jdbc:postgresql://postgisdb:5432/someDb) ,用户为 'someUser@someDB' :连接尝试失败
我们注意到PostgreSQL的依赖从4.2.14版本升级到了4.2.16版本。切换回4.2.14版本后,问题消失了。但无论如何,我想知道在当前版本上为什么会出现连接失败的问题。
英文:
We upgraded one of our services to 2.3.4.RELEASE lately. After the update, we are no longer able to connect to Azure PAAS PostgreSQL, we receive
Unable to obtain connection from database (jdbc:postgresql://postgisdb:5432/someDb) for user 'someUser@someDB': The connection attempt failed
We saw that the PostgreSQL dependency was updated from 4.2.14 to 4.2.16. Switching back to 4.2.14 made the issue disappear, but nevertheless, I would like to know why it fails on the current version.
答案1
得分: 7
Appending gssEncMode=disable
to the connection string fixes the problem. We tried it and it worked for us.
For further details, check the github page
英文:
Appending gssEncMode=disable
to the connection string fixes the problem. We tried it and it worked for us.
For further details, check the github page
答案2
得分: 0
解决方法:将 gssEncMode=disable
添加到连接字符串中,可以修复这个问题。
> jdbc:postgresql://x.x.x.x:5432/db-user?gssEncMode=disable
英文:
Solution: Appending gssEncMode=disable to the connection string fixes the problem.
> jdbc:postgresql://x.x.x.x:5432/db-user?gssEncMode=disable
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论