Greetings all, First time to post to this forum. So I have a service implemented in Python-Flask which I am currently running in App Engine. I decided to add a short block of mysql code to connect and insert into a mysql database. In this case I know the mysql database and related user account are working as I have the database configured to accept outside request and the user account I have configured to not be bound to specific incoming IP address. This has been fully tested from multiple outside servers and the problem is definately inside App Engine.
The dump from inside Google Cloud log view shows the failure point. This is when the connection is attempted. File "/base/data/home/runtimes/python27_experiment/python27_lib/versions/third_party/MySQLdb-1.2.5/MySQLdb/connections.py", line 193, in __init__ super(Connection, self).__init__(*args, **kwargs2) *OperationalError: (2004, "Can't create TCP/IP socket (-1)")* This led me to do some digging and found another user who had the same problem with no resolve. https://code.google.com/p/googleappengine/issues/detail?id=11971 Responses from others on that thread indicate that indicate that there is a problem with using TCP/IP sockets and the MySQLdb library inside App Engine. So I'm hoping to get confirmation this is true and curious about best work around approaches. It seems odd the MySQL library would be officially supported in App Engine only to be blocked because TCP IP connections made from MySQLDB calls are not supported. I am adding MySQL support by including it in my App.yaml using version 1.5.2 https://cloud.google.com/appengine/docs/python/tools/using-libraries-python-27 At first I was thinking that hosted in App Engine Flask could only communicate with Google SQL (managed MySQL) but In the GCS documentation it states explicitly that MySQL databases hosted outside GCS are supported. Although it shouldn't make a difference, in this case the MySQL database I'm connecting to is hosted in a Compute Engine VM inside the same GCS account where the App Engine instance is running. Thanks, Jeremy -- 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 [email protected]. To post to this group, send email to [email protected]. 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/5ad59d25-cb23-40e8-8cd4-fc4103549c54%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
