I was going through the possibility of building an universal data backend with Google Cloud Endpoints
but because I was considering it for a business application so I needed to have Google Cloud SQL
as my data storage and use Google Cloud DataStore
to store configuration level data. This architecture really intrigued me to find more about the possibility of how to do this with Java but I'm astonished that there is not one single resource on the web where somebody show you how to use Google Cloud Endpoints
with Google Cloud SQL
, not even google has some documentation of how to achieve this. Does this mean that is impossible to achieve this in Google Cloud
infrastructure. Can somebody point me to some resource or atleast shed some light onto this matter. Please I'd be very obliged to get some replies.
我正在尝试使用Google Cloud Endpoints构建通用数据后端,但因为我正在考虑将其用于业务应用程序,因此我需要将Google Cloud SQL作为我的数据存储并使用Google Cloud DataStore来存储配置级数据。这个架构真的让我很想知道如何用Java做这个的可能性,但我很惊讶网上没有一个单一的资源,有人向你展示了如何将Google Cloud Endpoints与Google Cloud SQL结合使用,甚至没有谷歌有一些如何实现这一目标的文档。这是否意味着在Google Cloud基础架构中无法实现此目标。有人可以指点我一些资源,或者至少可以解释一下这个问题。请我非常有必要得到一些回复。
1 个解决方案
#1
2
Assuming that you already use a library such as Hibernate to convert from the SQL data to Java objects, you do not have much more to do to make Cloud Endpoints work with Cloud SQL.
假设您已经使用诸如Hibernate之类的库将SQL数据转换为Java对象,那么您无需做太多工作就可以使Cloud Endpoints与Cloud SQL一起使用。
Simply return serializable objects when using Cloud Endpoints.
使用Cloud Endpoints时,只需返回可序列化对象。
#1
2
Assuming that you already use a library such as Hibernate to convert from the SQL data to Java objects, you do not have much more to do to make Cloud Endpoints work with Cloud SQL.
假设您已经使用诸如Hibernate之类的库将SQL数据转换为Java对象,那么您无需做太多工作就可以使Cloud Endpoints与Cloud SQL一起使用。
Simply return serializable objects when using Cloud Endpoints.
使用Cloud Endpoints时,只需返回可序列化对象。