Google Cloud SQL第二代-> “终止的连接" [英] Google Cloud SQL Second generation -> "Aborted connection"

查看:141
本文介绍了Google Cloud SQL第二代-> “终止的连接"的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在Appengine上运行Java + JPA/Hibernate应用程序,并将数据库从第一代Google Cloud SQL实例切换到第二代,现在出现了很多这样的错误:

I am running a Java + JPA/Hibernate application on Appengine and switched my database from the first generation Google Cloud SQL instance to the second generation and now get a lot of this errors:

2017-05-20T22:49:53.533247Z 2235 [Note] Aborted connection 2235 to db:
'mydb' user: 'root' host: 'cloudsqlproxy~myip' 
(Got an error reading communication packets)

据我所知,这些错误大多数是在任务队列任务内的数据库请求期间发生的.

As far as I can tell, most of these error occur during database requests inside task queue tasks.

第一代并没有发生这种情况.如何避免这种情况?

This did not happen with the first generation. How can this be avoided?

推荐答案

如果如我建议您遵循Google关于管理 Cloud SQL连接的文档,重点放在连接池"部分和当然,打开和关闭连接"部分.

I advise you to follow the Google’s documentation about managing Cloud SQL connections, emphasizing on the "connection pools" section and of course the "opening and closing connection" section.

这篇关于Google Cloud SQL第二代-> “终止的连接"的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆