Discussion:
[google-appengine] GCP ARCHITECTS: GCF + GAE + CloudSQL == common library??
y***@pitch.studio
2018-11-30 21:02:37 UTC
Permalink
Hi,
Does anyone care to offer an opinion/experience:
I have a certain operation, something like creating a new customer record,
that:

1. Creates records in Cloud SQL;
2. Requires some logic per operation, which may be complex;
3. And may be executed from:
1. App Engine (so, off-line)
2. Cloud Functions, triggered by Firebase events
3. The command line, like Cloud Shell

Any thoughts on what's the best place for this routine to live in?

1. MySQL stored proc (meh...)
2. App Engine (but can you call that from a Function?)
3. A function (but can you call that from anything?)
4. Somewhere else?

Thank you for your advice
Yanay
--
You received this message because you are subscribed to the Google Groups "Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-appengine+***@googlegroups.com.
To post to this group, send email to google-***@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-appengine/32939324-79fe-4305-8fce-47ff56d7e007%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
'Katayoon (Cloud Platform Support)' via Google App Engine
2018-12-04 20:22:04 UTC
Permalink
Hi Yanay,

It seems you are looking for an architecture solution, however your
usecase/scenario it not clear for me. I should note that here we provide
support for general discussions on Google Cloud Platform-end products and
for architecture solutions you may either refer to Google Cloud Partners
<https://cloud.google.com/partners/>which is a paid service or take a look
at the solutions provided here
<https://cloud.google.com/docs/#build-it-on-gcp> for Google Cloud Platform
products and services. For the questions you mentioned:

- You can create and use stored procedures and triggers in Cloud SQL
<https://cloud.google.com/sql/docs/features#unsupported_client_program_features>,
however you cannot import or export them into Cloud SQL.
- Here <https://cloud.google.com/functions/docs/concepts/events-triggers>
you may see all the events can trigger Cloud Functions. You can invoke
Cloud Functions over HTTP(S) from your App Engine and vice versa.
- I am not sure about your usecase but should note that you can connect
your Cloud Functions to Cloud SQL instances
<https://cloud.google.com/functions/docs/sql#best_practices_for_cloud_sql_in_cloud_functions>
using a local socket interface provided in the Cloud Functions execution
environment as well.
--
You received this message because you are subscribed to the Google Groups "Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-appengine+***@googlegroups.com.
To post to this group, send email to google-***@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-appengine/80375dcc-b119-458c-9c2e-aba01894ce42%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Yanay @Pitch
2018-12-04 22:05:44 UTC
Permalink
Hi Katayoon,

Thank you for clarifying the rules (
) and for the references below. I am very well familiar with all of these and have written Cloud SQL, GCF and GAE code.

Allow me then to ask a very specific question:

Say I have a piece of python code, that talks to Cloud SQL.
If I deploy this code into GAE Standard, can I call it from within a GCF function?

Thanks again

Yanay Lehavi
Founder & CEO
Pitch
***@pitch.studio
949.903.4678

From: 'Katayoon (Cloud Platform Support)' via Google App Engine
Sent: Tuesday, December 4, 2018 12:22 PM
To: Google App Engine
Subject: [google-appengine] Re: GCP ARCHITECTS: GCF + GAE + CloudSQL == commonlibrary??

Hi Yanay,

It seems you are looking for an architecture solution, however your usecase/scenario it not clear for me. I should note that here we provide support for general discussions on Google Cloud Platform-end products and for architecture solutions you may either refer to Google Cloud Partners which is a paid service or take a look at the solutions provided here for Google Cloud Platform products and services. For the questions you mentioned:

- You can create and use stored procedures and triggers in Cloud SQL, however you cannot import or export them into Cloud SQL. 
- Here you may see all the events can trigger Cloud Functions. You can invoke Cloud Functions over HTTP(S) from your App Engine and vice versa. 
- I am not sure about your usecase but should note that you can connect your Cloud Functions to Cloud SQL instances using a local socket interface provided in the Cloud Functions execution environment as well.
--
You received this message because you are subscribed to a topic in the Google Groups "Google App Engine" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-appengine/qpFWofURom0/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-appengine+***@googlegroups.com.
To post to this group, send email to google-***@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-appengine/80375dcc-b119-458c-9c2e-aba01894ce42%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-appengine+***@googlegroups.com.
To post to this group, send email to google-***@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-appengine/5c06fa38.1c69fb81.59a18.142f%40mx.google.com.
For more options, visit https://groups.google.com/d/optout.
'Katayoon (Cloud Platform Support)' via Google App Engine
2018-12-05 16:37:43 UTC
Permalink
Hi again,

Yes, you can make an outbound call
<https://cloud.google.com/appengine/docs/standard/python/communicating-between-services>
to communicate with your App Engine services.
--
You received this message because you are subscribed to the Google Groups "Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-appengine+***@googlegroups.com.
To post to this group, send email to google-***@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-appengine/81ec9598-6206-461e-a41a-f002d09741fe%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Yanay @Pitch
2018-12-05 18:19:12 UTC
Permalink
Thank you.

Are you aware of some documentation about how to build GAE standard services that are not driven by a web page? All the examples always include webapp2 or Django or Flask. If I just want some python code, no web page, just trigger it with an HTTP call, is it possible?

Yanay Lehavi
Founder & CEO
Pitch
***@pitch.studio
949.903.4678

From: 'Katayoon (Cloud Platform Support)' via Google App Engine
Sent: Wednesday, December 5, 2018 8:38 AM
To: Google App Engine
Subject: Re: [google-appengine] Re: GCP ARCHITECTS: GCF + GAE + CloudSQL ==commonlibrary??

Hi again,

Yes, you can make an outbound call to communicate with your App Engine services.
--
You received this message because you are subscribed to a topic in the Google Groups "Google App Engine" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-appengine/qpFWofURom0/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-appengine+***@googlegroups.com.
To post to this group, send email to google-***@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-appengine/81ec9598-6206-461e-a41a-f002d09741fe%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-appengine+***@googlegroups.com.
To post to this group, send email to google-***@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-appengine/5c0816a0.1c69fb81.59a18.b45c%40mx.google.com.
For more options, visit https://groups.google.com/d/optout.
'George (Cloud Platform Support)' via Google App Engine
2018-12-06 23:43:39 UTC
Permalink
Hello Yanay,

What concerns your use-case: no web page, just trigger it with an HTTP
call, I am happy to signal to you that the scenario maps closely, and seems
well-suited for Google Cloud Functions. [1] You are encouraged to have a
look, and ascertain this is what you were seeking.

[1] https://cloud.google.com/functions/
--
You received this message because you are subscribed to the Google Groups "Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-appengine+***@googlegroups.com.
To post to this group, send email to google-***@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-appengine/8f80a045-773d-46f6-bcc5-b54655a229c7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Yanay @Pitch
2018-12-07 00:09:41 UTC
Permalink
Hi,

Yes, I agree. I was trying to avoid GCF as the python local development support leaves a little bit to be desired.

Thank you

Yanay Lehavi
Founder & CEO
Pitch
***@pitch.studio
949.903.4678

From: 'George (Cloud Platform Support)' via Google App Engine
Sent: Thursday, December 6, 2018 3:43 PM
To: Google App Engine
Subject: Re: [google-appengine] Re: GCP ARCHITECTS: GCF + GAE + CloudSQL==commonlibrary??

Hello Yanay, 

What concerns your use-case: no web page, just trigger it with an HTTP call, I am happy to signal to you that the scenario maps closely, and seems well-suited for Google Cloud Functions. [1] You are encouraged to have a look, and ascertain this is what you were seeking. 

[1] https://cloud.google.com/functions/
--
You received this message because you are subscribed to a topic in the Google Groups "Google App Engine" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-appengine/qpFWofURom0/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-appengine+***@googlegroups.com.
To post to this group, send email to google-***@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-appengine/8f80a045-773d-46f6-bcc5-b54655a229c7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-appengine+***@googlegroups.com.
To post to this group, send email to google-***@googlegroups.com.
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-appengine/5c09ba45.1c69fb81.e1e7b.5a51%40mx.google.com.
For more options, visit https://groups.google.com/d/optout.
Loading...