Friday, September 25, 2015

Re: [google-cloud-sql-discuss] Replication from in-house MySQL (master) to Google SQL (slave)

Hi Mike,

Super exciting to hear about Google Cloud Platform being used for such valuable purposes. Publicly sharing real-time weather data? So cool.

Unfortunately as you noticed replication to Cloud SQL instances from outside is not supported. Some alternatives are:
  • If you run MySQL on a GCE instance you can make that instance the slave, but then you loose the advantages of Cloud SQL.
  • If you are willing to suffer some lag you could replace your federation & trigger solution with a periodic export & import.
  • If you don't need your public dataset to be queriable you could also share it as static files over GCS, for example as a SQL dump (or even csv).
Yours,
David

On Fri, Sep 25, 2015 at 4:37 AM, Mike Dorfman <mdorfman@mountwashington.org> wrote:
I have a setup where data flows from various remote sensing sites to a centralized linux (centos) server with a MySQL database.  I want to then replicate this database out to Google SQL so the data can be publicly available (read-only).  I see that replication is not supported with the master being an in-house MySQL database and slave being Google SQL, but I was wondering what alternatives there may be.  I've set up a federated table on my in-house server (essentially a link to the Google SQL table), and I've created a trigger to write to both this federated table as well as our in-house table.  This is far from an ideal solution, as it's unbearably slow and has some pretty critical limitations (for example, it doesn't support INSERT...ON DUPLICATE KEY UPDATE, which is very important for my application).  This data is critical for the functioning of our organization (whether or not we have internet access), so I don't feel comfortable writing directly to Google SQL and replicating back to our internal MySQL database in case we lose internet access.  Are there any alternatives for a setup like this?  Have people run into this in the past?  

--
You received this message because you are subscribed to the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-discuss+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/b73d07fd-ceae-4ac2-a146-9694466b5299%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 Cloud SQL discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-sql-discuss+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-sql-discuss/CAJZK_ba443smrtS2J1RXD8PV-LDbQ0-Dj97wj%2B01STDVbdA3%3Dg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment