Thursday, December 31, 2015

[google-cloud-sql-discuss] What does it cost to transfer data between Google Sheets (using Google Script) and Google Cloud SQL?

I want to develop a mobile application. For which I would like to use Google Cloud SQL as the database and I would like to use Google Scripts to retrieve the data from Google Cloud SQL and return the response as a JSON which can be read by my app.


So when I was going through Google Cloud SQL pricing it was little confusing about network egress. It mentions that network egress for Google products like Drive, YouTube and Maps is free. So if I am going to make a SQL call using JDBC on Google script to Google Cloud SQL, I shouldn't be charged.


Can any one please let me know the answer for my question?

--
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/9a3f86c3-7abc-4fe9-92ed-9b6dfbb0aeca%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Monday, December 28, 2015

Re: [google-cloud-sql-discuss] Re: 2nd Generation Failover documentation?

Never mind see the same Zone is grayed out.

On Mon, Dec 28, 2015, 8:16 AM Brian Wawok <bwawok@gmail.com> wrote:
This is great, thanks for the replies.

So it seems like letting me pick a failover replica in the same zone is pointless (and maybe should be removed in the GUI)?  Otherwise this all makes sense and just needs some documentation love :)


Brian

On Mon, Dec 28, 2015, 2:30 AM Jay Zhu <tingjiez@google.com> wrote:
Hi Brian,

This is Jay from the CloudSQL team. Thank a lot for these great questions. Let me try to help with clarifications as below. Please let me know if you have any further questions.

The failover feature is designed to provider higher than zonal availability for Cloud SQL 2nd Gen instances. Without failover replica instance a Cloud SQL 2nd Gen instance will be out of service in the unlikely event of a zone outage.  A failover replica instance is required in order to be able to failover to a different zone.  When the zone failure is detected, the master instance will be recreated in the zone where failover replica resides, with data from the failover replica, and the failover replica will be 'pushed out' to another healthy zone (The actual implementation under the hood is more complicated, but this is what the external user observes).  In this way, the metadata of the master instance keeps unchanged before and after the failover and there should be no action in application side to be taken for events like zone failure. 

You can try out the failover behavior by calling the API directly (API document: https://cloud.google.com/sql/docs/admin-api/v1beta4/instances/failover) to trigger a manual failover.  

In regard to your original questions:

1) In 1st gen, when there was a failure a new instance was automagically spun up and activated. In 2nd gen, is this no longer the case? Do I NEED to create a Failover Replica for the same behavior?
The failover is designed to provider higher than zonal availability for Cloud SQL 2nd Gen instances.  I don't think there is similar behavior implemented in 1st Gen instances.  

2) In the event of a failover, will my failover replica automatically become primary? Or do I need to trigger a failover by hand when something is down? 
In the event of a failover, what you'll observe is that your primary database instance will be moved to a healthy zone (the zone where failover replica resides), and the failover replica will be moved to another healthy zone. There is no change required at all in terms of how your application connects to database, assuming that your application handles database reconnection well.

Currently we triggers failover automatically when there is zone level failures. You can also try to call the failover API directly to try out failover behavior on a specific instance (https://cloud.google.com/sql/docs/admin-api/v1beta4/instances/failover).

3) How long of a bad event is there before the automatic failover process is started? 
As I explained in the previous question, currently we only triggers auto-failure in case of zone level failure.  The failover is triggered as soon as the zone failure is detected. 

4) My failover replica has an IP.. do I need to change my clients to use this IP, or will the old primary IP now start pointing at the failover replica? i.e. is this really a floating IP that gets moved?
No. There should be zero change required in your clients.  After the failover, your client still connects tot he old primary IP, which now points to the primary instance that is moved to a healthy zone.

5) Can I use my failover replica as a read slave, or must it just sit idle until an event?
Yes. A failover replica is perfectly capable of being served as a read replica.  

6) What happens to the old primary in a failover after it comes back. Does it become a failover replica for the new primary, or do I need to do something by hand?
The primary stays as primary before and after the failover process. It is just moved to a healthy zone. Therefore there is no such thing as "old primary comes back" as it always there, and there is nothing need to be done by hand.

7) How do I reset my original primary to be the real master after a failover event is complete?
Same as questions 6.

Regards,
Jay

On Thursday, December 24, 2015 at 2:11:17 PM UTC-8, Brian Wawok wrote:
I thought you just said cloud sql gen 2 will automatically fail over without a failover instance to another zone? So I ask again what do I gain by paying for a failover instance. 30 seconds vs 20 second failover? Or what?




On Thu, Dec 24, 2015, 5:03 PM George <gra...@google.com> wrote:
Hello Brian,

In order to deploy fault-tolerant applications that have high availability, Google recommends deploying applications across multiple zones in a region. This helps protect against unexpected failures of components, up to and including a single zone. You can configure a Cloud SQL Second Generation instance to be highly available by configuring replication to a failover replica instance in different zone than the master instance.


You can leverage the high-bandwidth, low-latency network connections between zones in the same region to set up a failover replica instance in a different zone than the master instance. In the event of failure of the master instance's zone, Google Cloud SQL automatically switches over to the failover replica.


I hope this helps.


Sincerely,

George


On Thursday, December 24, 2015 at 11:05:37 AM UTC-5, Brian Wawok wrote:
George:

So if gen2 has automatic failover baked in, what is the purpose of a failover replica?  Does it make failover faster, or what does it buy me?

Thanks,

Brian

On Thursday, December 24, 2015 at 11:02:58 AM UTC-5, grached wrote:
Hello Brian,

All Cloud SQL data is replicated in multiple zones. In the unlikely event of a zone outage, instances fail over to another, available, zone automatically. Failover is designed to be transparent to your applications, so that after failover, an instance has the same instance name, IP address, and firewall rules. During the failover there will typically be a few seconds downtime as the instance starts up in a new zone. However, in some cases, the InnoDB crash-recovery process may take longer, delaying the time before the instance is up. 

In a failover event, existing connections to instances are broken. You can test how your application responds to a failover by restarting your instance. For recommendations on managing connections that can help in failover events, see the FAQ entry How should I manage connections?

You can configure:

  • Cloud SQL instances that replicate from a Cloud SQL master instance.
  • Cloud SQL instances that replicate from an external master instance.
  • External MySQL instances that replicate from a Cloud SQL master instance.

  • Note that external read replica instances must:
  • Be able to connect to the Cloud SQL master instance with the MySQL wire protocol.
  • Support row-based replication.
  • Be the same (or later) version of the Cloud SQL instance being replicated.

For more information about read replicas, including use cases for each type, see Configuring Replication with Google Cloud SQL.


You can use the Google Cloud Platform Console to see all of your Cloud SQL instances, and whether an instance is a master or read replica instance. You can use the Cloud SDK to check whether an instance is a master or read replica. For more information, see Checking replication status.


I hope this helps.


Sincerely,

George




On Wednesday, December 23, 2015 at 12:51:36 PM UTC-5, Brian Wawok wrote:
Hi!

From reading the documentation and poking around, I am not entirely sure how the cloud SQL failover is setup. Can anyone point me to a more complete documentation, or answer a few questions for me?


1) In 1st gen, when there was a failure a new instance was automagically spun up and activated. In 2nd gen, is this no longer the case? Do I NEED to create a Failover Replica for the same behavior?

2) In the event of a failover, will my failover replica automatically become primary? Or do I need to trigger a failover by hand when something is down? 

3) How long of a bad event is there before the automatic failover process is started? 

4) My failover replica has an IP.. do I need to change my clients to use this IP, or will the old primary IP now start pointing at the failover replica? i.e. is this really a floating IP that gets moved?

5) Can I use my failover replica as a read slave, or must it just sit idle until an event?

6) What happens to the old primary in a failover after it comes back. Does it become a failover replica for the new primary, or do I need to do something by hand?

7) How do I reset my original primary to be the real master after a failover event is complete?


Thanks!


Brian

--
You received this message because you are subscribed to a topic in the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-cloud-sql-discuss/WwfY_CwFbVU/unsubscribe.
To unsubscribe from this group and all its topics, 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/df2058c4-ff71-4173-b1e7-7d16d2d97605%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-cloud-sql-discuss/WwfY_CwFbVU/unsubscribe.
To unsubscribe from this group and all its topics, 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/ad4a984a-1b1c-449c-bd18-377f76a2d5c6%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/CAJVyzE0PXe5Nya4OGuwMqcUA8bOfsiwqoh9b_ta8N5SQGAG_uA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Re: [google-cloud-sql-discuss] Re: 2nd Generation Failover documentation?

This is great, thanks for the replies.

So it seems like letting me pick a failover replica in the same zone is pointless (and maybe should be removed in the GUI)?  Otherwise this all makes sense and just needs some documentation love :)


Brian

On Mon, Dec 28, 2015, 2:30 AM Jay Zhu <tingjiez@google.com> wrote:
Hi Brian,

This is Jay from the CloudSQL team. Thank a lot for these great questions. Let me try to help with clarifications as below. Please let me know if you have any further questions.

The failover feature is designed to provider higher than zonal availability for Cloud SQL 2nd Gen instances. Without failover replica instance a Cloud SQL 2nd Gen instance will be out of service in the unlikely event of a zone outage.  A failover replica instance is required in order to be able to failover to a different zone.  When the zone failure is detected, the master instance will be recreated in the zone where failover replica resides, with data from the failover replica, and the failover replica will be 'pushed out' to another healthy zone (The actual implementation under the hood is more complicated, but this is what the external user observes).  In this way, the metadata of the master instance keeps unchanged before and after the failover and there should be no action in application side to be taken for events like zone failure. 

You can try out the failover behavior by calling the API directly (API document: https://cloud.google.com/sql/docs/admin-api/v1beta4/instances/failover) to trigger a manual failover.  

In regard to your original questions:

1) In 1st gen, when there was a failure a new instance was automagically spun up and activated. In 2nd gen, is this no longer the case? Do I NEED to create a Failover Replica for the same behavior?
The failover is designed to provider higher than zonal availability for Cloud SQL 2nd Gen instances.  I don't think there is similar behavior implemented in 1st Gen instances.  

2) In the event of a failover, will my failover replica automatically become primary? Or do I need to trigger a failover by hand when something is down? 
In the event of a failover, what you'll observe is that your primary database instance will be moved to a healthy zone (the zone where failover replica resides), and the failover replica will be moved to another healthy zone. There is no change required at all in terms of how your application connects to database, assuming that your application handles database reconnection well.

Currently we triggers failover automatically when there is zone level failures. You can also try to call the failover API directly to try out failover behavior on a specific instance (https://cloud.google.com/sql/docs/admin-api/v1beta4/instances/failover).

3) How long of a bad event is there before the automatic failover process is started? 
As I explained in the previous question, currently we only triggers auto-failure in case of zone level failure.  The failover is triggered as soon as the zone failure is detected. 

4) My failover replica has an IP.. do I need to change my clients to use this IP, or will the old primary IP now start pointing at the failover replica? i.e. is this really a floating IP that gets moved?
No. There should be zero change required in your clients.  After the failover, your client still connects tot he old primary IP, which now points to the primary instance that is moved to a healthy zone.

5) Can I use my failover replica as a read slave, or must it just sit idle until an event?
Yes. A failover replica is perfectly capable of being served as a read replica.  

6) What happens to the old primary in a failover after it comes back. Does it become a failover replica for the new primary, or do I need to do something by hand?
The primary stays as primary before and after the failover process. It is just moved to a healthy zone. Therefore there is no such thing as "old primary comes back" as it always there, and there is nothing need to be done by hand.

7) How do I reset my original primary to be the real master after a failover event is complete?
Same as questions 6.

Regards,
Jay

On Thursday, December 24, 2015 at 2:11:17 PM UTC-8, Brian Wawok wrote:
I thought you just said cloud sql gen 2 will automatically fail over without a failover instance to another zone? So I ask again what do I gain by paying for a failover instance. 30 seconds vs 20 second failover? Or what?




On Thu, Dec 24, 2015, 5:03 PM George <gra...@google.com> wrote:
Hello Brian,

In order to deploy fault-tolerant applications that have high availability, Google recommends deploying applications across multiple zones in a region. This helps protect against unexpected failures of components, up to and including a single zone. You can configure a Cloud SQL Second Generation instance to be highly available by configuring replication to a failover replica instance in different zone than the master instance.


You can leverage the high-bandwidth, low-latency network connections between zones in the same region to set up a failover replica instance in a different zone than the master instance. In the event of failure of the master instance's zone, Google Cloud SQL automatically switches over to the failover replica.


I hope this helps.


Sincerely,

George


On Thursday, December 24, 2015 at 11:05:37 AM UTC-5, Brian Wawok wrote:
George:

So if gen2 has automatic failover baked in, what is the purpose of a failover replica?  Does it make failover faster, or what does it buy me?

Thanks,

Brian

On Thursday, December 24, 2015 at 11:02:58 AM UTC-5, grached wrote:
Hello Brian,

All Cloud SQL data is replicated in multiple zones. In the unlikely event of a zone outage, instances fail over to another, available, zone automatically. Failover is designed to be transparent to your applications, so that after failover, an instance has the same instance name, IP address, and firewall rules. During the failover there will typically be a few seconds downtime as the instance starts up in a new zone. However, in some cases, the InnoDB crash-recovery process may take longer, delaying the time before the instance is up. 

In a failover event, existing connections to instances are broken. You can test how your application responds to a failover by restarting your instance. For recommendations on managing connections that can help in failover events, see the FAQ entry How should I manage connections?

You can configure:

  • Cloud SQL instances that replicate from a Cloud SQL master instance.
  • Cloud SQL instances that replicate from an external master instance.
  • External MySQL instances that replicate from a Cloud SQL master instance.

  • Note that external read replica instances must:
  • Be able to connect to the Cloud SQL master instance with the MySQL wire protocol.
  • Support row-based replication.
  • Be the same (or later) version of the Cloud SQL instance being replicated.

For more information about read replicas, including use cases for each type, see Configuring Replication with Google Cloud SQL.


You can use the Google Cloud Platform Console to see all of your Cloud SQL instances, and whether an instance is a master or read replica instance. You can use the Cloud SDK to check whether an instance is a master or read replica. For more information, see Checking replication status.


I hope this helps.


Sincerely,

George




On Wednesday, December 23, 2015 at 12:51:36 PM UTC-5, Brian Wawok wrote:
Hi!

From reading the documentation and poking around, I am not entirely sure how the cloud SQL failover is setup. Can anyone point me to a more complete documentation, or answer a few questions for me?


1) In 1st gen, when there was a failure a new instance was automagically spun up and activated. In 2nd gen, is this no longer the case? Do I NEED to create a Failover Replica for the same behavior?

2) In the event of a failover, will my failover replica automatically become primary? Or do I need to trigger a failover by hand when something is down? 

3) How long of a bad event is there before the automatic failover process is started? 

4) My failover replica has an IP.. do I need to change my clients to use this IP, or will the old primary IP now start pointing at the failover replica? i.e. is this really a floating IP that gets moved?

5) Can I use my failover replica as a read slave, or must it just sit idle until an event?

6) What happens to the old primary in a failover after it comes back. Does it become a failover replica for the new primary, or do I need to do something by hand?

7) How do I reset my original primary to be the real master after a failover event is complete?


Thanks!


Brian

--
You received this message because you are subscribed to a topic in the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-cloud-sql-discuss/WwfY_CwFbVU/unsubscribe.
To unsubscribe from this group and all its topics, 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/df2058c4-ff71-4173-b1e7-7d16d2d97605%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-cloud-sql-discuss/WwfY_CwFbVU/unsubscribe.
To unsubscribe from this group and all its topics, 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/ad4a984a-1b1c-449c-bd18-377f76a2d5c6%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/CAJVyzE2TG69tEZ_S35w6kA7F4dfe%3D596ZYcgEjWded-%3DOtrf8Q%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Sunday, December 27, 2015

Re: [google-cloud-sql-discuss] Re: 2nd Generation Failover documentation?

Hi Brian,

This is Jay from the CloudSQL team. Thank a lot for these great questions. Let me try to help with clarifications as below. Please let me know if you have any further questions.

The failover feature is designed to provider higher than zonal availability for Cloud SQL 2nd Gen instances. Without failover replica instance a Cloud SQL 2nd Gen instance will be out of service in the unlikely event of a zone outage.  A failover replica instance is required in order to be able to failover to a different zone.  When the zone failure is detected, the master instance will be recreated in the zone where failover replica resides, with data from the failover replica, and the failover replica will be 'pushed out' to another healthy zone (The actual implementation under the hood is more complicated, but this is what the external user observes).  In this way, the metadata of the master instance keeps unchanged before and after the failover and there should be no action in application side to be taken for events like zone failure. 

You can try out the failover behavior by calling the API directly (API document: https://cloud.google.com/sql/docs/admin-api/v1beta4/instances/failover) to trigger a manual failover.  

In regard to your original questions:

1) In 1st gen, when there was a failure a new instance was automagically spun up and activated. In 2nd gen, is this no longer the case? Do I NEED to create a Failover Replica for the same behavior?
The failover is designed to provider higher than zonal availability for Cloud SQL 2nd Gen instances.  I don't think there is similar behavior implemented in 1st Gen instances.  

2) In the event of a failover, will my failover replica automatically become primary? Or do I need to trigger a failover by hand when something is down? 
In the event of a failover, what you'll observe is that your primary database instance will be moved to a healthy zone (the zone where failover replica resides), and the failover replica will be moved to another healthy zone. There is no change required at all in terms of how your application connects to database, assuming that your application handles database reconnection well.

Currently we triggers failover automatically when there is zone level failures. You can also try to call the failover API directly to try out failover behavior on a specific instance (https://cloud.google.com/sql/docs/admin-api/v1beta4/instances/failover).

3) How long of a bad event is there before the automatic failover process is started? 
As I explained in the previous question, currently we only triggers auto-failure in case of zone level failure.  The failover is triggered as soon as the zone failure is detected. 

4) My failover replica has an IP.. do I need to change my clients to use this IP, or will the old primary IP now start pointing at the failover replica? i.e. is this really a floating IP that gets moved?
No. There should be zero change required in your clients.  After the failover, your client still connects tot he old primary IP, which now points to the primary instance that is moved to a healthy zone.

5) Can I use my failover replica as a read slave, or must it just sit idle until an event?
Yes. A failover replica is perfectly capable of being served as a read replica.  

6) What happens to the old primary in a failover after it comes back. Does it become a failover replica for the new primary, or do I need to do something by hand?
The primary stays as primary before and after the failover process. It is just moved to a healthy zone. Therefore there is no such thing as "old primary comes back" as it always there, and there is nothing need to be done by hand.

7) How do I reset my original primary to be the real master after a failover event is complete?
Same as questions 6.

Regards,
Jay

On Thursday, December 24, 2015 at 2:11:17 PM UTC-8, Brian Wawok wrote:
I thought you just said cloud sql gen 2 will automatically fail over without a failover instance to another zone? So I ask again what do I gain by paying for a failover instance. 30 seconds vs 20 second failover? Or what?




On Thu, Dec 24, 2015, 5:03 PM George <gra...@google.com> wrote:
Hello Brian,

In order to deploy fault-tolerant applications that have high availability, Google recommends deploying applications across multiple zones in a region. This helps protect against unexpected failures of components, up to and including a single zone. You can configure a Cloud SQL Second Generation instance to be highly available by configuring replication to a failover replica instance in different zone than the master instance.


You can leverage the high-bandwidth, low-latency network connections between zones in the same region to set up a failover replica instance in a different zone than the master instance. In the event of failure of the master instance's zone, Google Cloud SQL automatically switches over to the failover replica.


I hope this helps.


Sincerely,

George


On Thursday, December 24, 2015 at 11:05:37 AM UTC-5, Brian Wawok wrote:
George:

So if gen2 has automatic failover baked in, what is the purpose of a failover replica?  Does it make failover faster, or what does it buy me?

Thanks,

Brian

On Thursday, December 24, 2015 at 11:02:58 AM UTC-5, grached wrote:
Hello Brian,

All Cloud SQL data is replicated in multiple zones. In the unlikely event of a zone outage, instances fail over to another, available, zone automatically. Failover is designed to be transparent to your applications, so that after failover, an instance has the same instance name, IP address, and firewall rules. During the failover there will typically be a few seconds downtime as the instance starts up in a new zone. However, in some cases, the InnoDB crash-recovery process may take longer, delaying the time before the instance is up. 

In a failover event, existing connections to instances are broken. You can test how your application responds to a failover by restarting your instance. For recommendations on managing connections that can help in failover events, see the FAQ entry How should I manage connections?

You can configure:

  • Cloud SQL instances that replicate from a Cloud SQL master instance.
  • Cloud SQL instances that replicate from an external master instance.
  • External MySQL instances that replicate from a Cloud SQL master instance.

  • Note that external read replica instances must:
  • Be able to connect to the Cloud SQL master instance with the MySQL wire protocol.
  • Support row-based replication.
  • Be the same (or later) version of the Cloud SQL instance being replicated.

For more information about read replicas, including use cases for each type, see Configuring Replication with Google Cloud SQL.


You can use the Google Cloud Platform Console to see all of your Cloud SQL instances, and whether an instance is a master or read replica instance. You can use the Cloud SDK to check whether an instance is a master or read replica. For more information, see Checking replication status.


I hope this helps.


Sincerely,

George




On Wednesday, December 23, 2015 at 12:51:36 PM UTC-5, Brian Wawok wrote:
Hi!

From reading the documentation and poking around, I am not entirely sure how the cloud SQL failover is setup. Can anyone point me to a more complete documentation, or answer a few questions for me?


1) In 1st gen, when there was a failure a new instance was automagically spun up and activated. In 2nd gen, is this no longer the case? Do I NEED to create a Failover Replica for the same behavior?

2) In the event of a failover, will my failover replica automatically become primary? Or do I need to trigger a failover by hand when something is down? 

3) How long of a bad event is there before the automatic failover process is started? 

4) My failover replica has an IP.. do I need to change my clients to use this IP, or will the old primary IP now start pointing at the failover replica? i.e. is this really a floating IP that gets moved?

5) Can I use my failover replica as a read slave, or must it just sit idle until an event?

6) What happens to the old primary in a failover after it comes back. Does it become a failover replica for the new primary, or do I need to do something by hand?

7) How do I reset my original primary to be the real master after a failover event is complete?


Thanks!


Brian

--
You received this message because you are subscribed to a topic in the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-cloud-sql-discuss/WwfY_CwFbVU/unsubscribe.
To unsubscribe from this group and all its topics, 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/df2058c4-ff71-4173-b1e7-7d16d2d97605%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/ad4a984a-1b1c-449c-bd18-377f76a2d5c6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

[google-cloud-sql-discuss] Re: Will cloud sql support mysql 5.7 in the near future?


Hello Susan,

A feature request is already opened for this on Cloud SQL public issue tracker. I recommend starring the issue so you may be notified of changes and its implementation progresses.

Sincerely,


On Friday, December 25, 2015 at 4:20:46 PM UTC-5, Susan Lin wrote:
I was wondering if there were plans to support mysql 5.7? Mysql 5.7 has some great spatial features which I would like to utilize.

Cheers

--
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/24c2c2f0-2aae-4ebc-95ae-ce326b74b1a3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Saturday, December 26, 2015

Re: [google-cloud-sql-discuss] Re: Scaling writes google cloud sql

We would generally recommend you create read replicas, and then place as much read-only load that you can onto the replicas. That way you free up resources on your master (which is now only handling writes) and should now be able to handle more write traffic.

If you can live without an SLA and have the opportunity to migrate over, a second generation instance will be much faster at writes than a first generation instance will be.


On Sat, Dec 26, 2015, 11:19 AM Brian Wawok <bwawok@gmail.com> wrote:
Sharding?  How many writes are you looking at? How big of writes?

Etsy has a bunch of articles on Sharding MySQL.. for example:


You mostly deal with it in your app logic, so nothing to do with Cloud SQL.

Or if you don't want to do that, you may be too big for MySQL, but Etsy is pretty big...


Brian

On Sat, Dec 26, 2015 at 2:13 PM Susan Lin <susanlinsfu@gmail.com> wrote:
Thanks for the reply. What if the the performance needed exceeds that of the capbilities of a single instance and sharing is needed, is there a guide how go set this up on Google SQL.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-cloud-sql-discuss/wmjT35IOikk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-cloud-sql-discuss+unsubscribe@googlegroups.com.

--
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/CAJVyzE1yvJy7S68Rgp3eX0rZ2DH7Ccm69%3DMfd5Hi9uKDw%3DbkZA%40mail.gmail.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/CAAfRv6GooOCPB%3Df3koUfP7FqJcTDmu7mcoay70EvDuQd62bXdw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Re: [google-cloud-sql-discuss] Re: Scaling writes google cloud sql

Sharding?  How many writes are you looking at? How big of writes?

Etsy has a bunch of articles on Sharding MySQL.. for example:


You mostly deal with it in your app logic, so nothing to do with Cloud SQL.

Or if you don't want to do that, you may be too big for MySQL, but Etsy is pretty big...


Brian

On Sat, Dec 26, 2015 at 2:13 PM Susan Lin <susanlinsfu@gmail.com> wrote:
Thanks for the reply. What if the the performance needed exceeds that of the capbilities of a single instance and sharing is needed, is there a guide how go set this up on Google SQL.

--
You received this message because you are subscribed to a topic in the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-cloud-sql-discuss/wmjT35IOikk/unsubscribe.
To unsubscribe from this group and all its topics, 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/e9c482c8-108e-42c4-94cf-eadbb0d1c93c%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/CAJVyzE1yvJy7S68Rgp3eX0rZ2DH7Ccm69%3DMfd5Hi9uKDw%3DbkZA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

[google-cloud-sql-discuss] Re: Scaling writes google cloud sql

Thanks for the reply. What if the the performance needed exceeds that of the capbilities of a single instance and sharing is needed, is there a guide how go set this up on Google SQL.

--
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/e9c482c8-108e-42c4-94cf-eadbb0d1c93c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

[google-cloud-sql-discuss] Re: Scaling writes google cloud sql

Writes to your instance should be proportional to how much CPU and DISK IO you have, right?  So the bigger your instance and the bigger your storage, the more CPU and DISK IO you have.

Generally the more indexes you have, and the more complicated your Primary Key is, the slower your write will be..  A single autoinc primary key and no other indexes or FKs would maximize your performance...

Brian


On Friday, December 25, 2015 at 11:20:19 PM UTC-5, Susan Lin wrote:
Is there any guides how to scale writes in Google SQL? It would be great if there was a step by step tutorial how to scale writes using Google SQL.

--
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/d4d9cc9e-f1fa-4ba9-9516-99197a8a3c7d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Friday, December 25, 2015

[google-cloud-sql-discuss] Scaling writes google cloud sql

Is there any guides how to scale writes in Google SQL? It would be great if there was a step by step tutorial how to scale writes using Google SQL.

--
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/d4b0fc00-2a49-4cf2-9f73-ba17f0294512%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

[google-cloud-sql-discuss] Will cloud sql support mysql 5.7 in the near future?

I was wondering if there were plans to support mysql 5.7? Mysql 5.7 has some great spatial features which I would like to utilize.

Cheers

--
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/e94d11f3-bd0e-4ce8-b68a-58695b0c7810%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Thursday, December 24, 2015

Re: [google-cloud-sql-discuss] Re: 2nd Generation Failover documentation?

I thought you just said cloud sql gen 2 will automatically fail over without a failover instance to another zone? So I ask again what do I gain by paying for a failover instance. 30 seconds vs 20 second failover? Or what?




On Thu, Dec 24, 2015, 5:03 PM George <grached@google.com> wrote:
Hello Brian,

In order to deploy fault-tolerant applications that have high availability, Google recommends deploying applications across multiple zones in a region. This helps protect against unexpected failures of components, up to and including a single zone. You can configure a Cloud SQL Second Generation instance to be highly available by configuring replication to a failover replica instance in different zone than the master instance.


You can leverage the high-bandwidth, low-latency network connections between zones in the same region to set up a failover replica instance in a different zone than the master instance. In the event of failure of the master instance's zone, Google Cloud SQL automatically switches over to the failover replica.


I hope this helps.


Sincerely,

George


On Thursday, December 24, 2015 at 11:05:37 AM UTC-5, Brian Wawok wrote:
George:

So if gen2 has automatic failover baked in, what is the purpose of a failover replica?  Does it make failover faster, or what does it buy me?

Thanks,

Brian

On Thursday, December 24, 2015 at 11:02:58 AM UTC-5, grached wrote:
Hello Brian,

All Cloud SQL data is replicated in multiple zones. In the unlikely event of a zone outage, instances fail over to another, available, zone automatically. Failover is designed to be transparent to your applications, so that after failover, an instance has the same instance name, IP address, and firewall rules. During the failover there will typically be a few seconds downtime as the instance starts up in a new zone. However, in some cases, the InnoDB crash-recovery process may take longer, delaying the time before the instance is up. 

In a failover event, existing connections to instances are broken. You can test how your application responds to a failover by restarting your instance. For recommendations on managing connections that can help in failover events, see the FAQ entry How should I manage connections?

You can configure:

  • Cloud SQL instances that replicate from a Cloud SQL master instance.
  • Cloud SQL instances that replicate from an external master instance.
  • External MySQL instances that replicate from a Cloud SQL master instance.

  • Note that external read replica instances must:
  • Be able to connect to the Cloud SQL master instance with the MySQL wire protocol.
  • Support row-based replication.
  • Be the same (or later) version of the Cloud SQL instance being replicated.

For more information about read replicas, including use cases for each type, see Configuring Replication with Google Cloud SQL.


You can use the Google Cloud Platform Console to see all of your Cloud SQL instances, and whether an instance is a master or read replica instance. You can use the Cloud SDK to check whether an instance is a master or read replica. For more information, see Checking replication status.


I hope this helps.


Sincerely,

George




On Wednesday, December 23, 2015 at 12:51:36 PM UTC-5, Brian Wawok wrote:
Hi!

From reading the documentation and poking around, I am not entirely sure how the cloud SQL failover is setup. Can anyone point me to a more complete documentation, or answer a few questions for me?


1) In 1st gen, when there was a failure a new instance was automagically spun up and activated. In 2nd gen, is this no longer the case? Do I NEED to create a Failover Replica for the same behavior?

2) In the event of a failover, will my failover replica automatically become primary? Or do I need to trigger a failover by hand when something is down? 

3) How long of a bad event is there before the automatic failover process is started? 

4) My failover replica has an IP.. do I need to change my clients to use this IP, or will the old primary IP now start pointing at the failover replica? i.e. is this really a floating IP that gets moved?

5) Can I use my failover replica as a read slave, or must it just sit idle until an event?

6) What happens to the old primary in a failover after it comes back. Does it become a failover replica for the new primary, or do I need to do something by hand?

7) How do I reset my original primary to be the real master after a failover event is complete?


Thanks!


Brian

--
You received this message because you are subscribed to a topic in the Google Groups "Google Cloud SQL discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-cloud-sql-discuss/WwfY_CwFbVU/unsubscribe.
To unsubscribe from this group and all its topics, 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/df2058c4-ff71-4173-b1e7-7d16d2d97605%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/CAJVyzE0UeQb0iAG7KKE93u5VSYuQJQXAW07XPhFHNSnkJ1%3DV4w%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

[google-cloud-sql-discuss] Re: 2nd Generation Failover documentation?

Hello Brian,

In order to deploy fault-tolerant applications that have high availability, Google recommends deploying applications across multiple zones in a region. This helps protect against unexpected failures of components, up to and including a single zone. You can configure a Cloud SQL Second Generation instance to be highly available by configuring replication to a failover replica instance in different zone than the master instance.


You can leverage the high-bandwidth, low-latency network connections between zones in the same region to set up a failover replica instance in a different zone than the master instance. In the event of failure of the master instance's zone, Google Cloud SQL automatically switches over to the failover replica.


I hope this helps.


Sincerely,

George


On Thursday, December 24, 2015 at 11:05:37 AM UTC-5, Brian Wawok wrote:
George:

So if gen2 has automatic failover baked in, what is the purpose of a failover replica?  Does it make failover faster, or what does it buy me?

Thanks,

Brian

On Thursday, December 24, 2015 at 11:02:58 AM UTC-5, grached wrote:
Hello Brian,

All Cloud SQL data is replicated in multiple zones. In the unlikely event of a zone outage, instances fail over to another, available, zone automatically. Failover is designed to be transparent to your applications, so that after failover, an instance has the same instance name, IP address, and firewall rules. During the failover there will typically be a few seconds downtime as the instance starts up in a new zone. However, in some cases, the InnoDB crash-recovery process may take longer, delaying the time before the instance is up. 

In a failover event, existing connections to instances are broken. You can test how your application responds to a failover by restarting your instance. For recommendations on managing connections that can help in failover events, see the FAQ entry How should I manage connections?

You can configure:

  • Cloud SQL instances that replicate from a Cloud SQL master instance.
  • Cloud SQL instances that replicate from an external master instance.
  • External MySQL instances that replicate from a Cloud SQL master instance.

  • Note that external read replica instances must:
  • Be able to connect to the Cloud SQL master instance with the MySQL wire protocol.
  • Support row-based replication.
  • Be the same (or later) version of the Cloud SQL instance being replicated.

For more information about read replicas, including use cases for each type, see Configuring Replication with Google Cloud SQL.


You can use the Google Cloud Platform Console to see all of your Cloud SQL instances, and whether an instance is a master or read replica instance. You can use the Cloud SDK to check whether an instance is a master or read replica. For more information, see Checking replication status.


I hope this helps.


Sincerely,

George




On Wednesday, December 23, 2015 at 12:51:36 PM UTC-5, Brian Wawok wrote:
Hi!

From reading the documentation and poking around, I am not entirely sure how the cloud SQL failover is setup. Can anyone point me to a more complete documentation, or answer a few questions for me?


1) In 1st gen, when there was a failure a new instance was automagically spun up and activated. In 2nd gen, is this no longer the case? Do I NEED to create a Failover Replica for the same behavior?

2) In the event of a failover, will my failover replica automatically become primary? Or do I need to trigger a failover by hand when something is down? 

3) How long of a bad event is there before the automatic failover process is started? 

4) My failover replica has an IP.. do I need to change my clients to use this IP, or will the old primary IP now start pointing at the failover replica? i.e. is this really a floating IP that gets moved?

5) Can I use my failover replica as a read slave, or must it just sit idle until an event?

6) What happens to the old primary in a failover after it comes back. Does it become a failover replica for the new primary, or do I need to do something by hand?

7) How do I reset my original primary to be the real master after a failover event is complete?


Thanks!


Brian

--
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/df2058c4-ff71-4173-b1e7-7d16d2d97605%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

[google-cloud-sql-discuss] Re: 2nd Generation Failover documentation?

George:

So if gen2 has automatic failover baked in, what is the purpose of a failover replica?  Does it make failover faster, or what does it buy me?

Thanks,

Brian

On Thursday, December 24, 2015 at 11:02:58 AM UTC-5, grached wrote:
Hello Brian,

All Cloud SQL data is replicated in multiple zones. In the unlikely event of a zone outage, instances fail over to another, available, zone automatically. Failover is designed to be transparent to your applications, so that after failover, an instance has the same instance name, IP address, and firewall rules. During the failover there will typically be a few seconds downtime as the instance starts up in a new zone. However, in some cases, the InnoDB crash-recovery process may take longer, delaying the time before the instance is up. 

In a failover event, existing connections to instances are broken. You can test how your application responds to a failover by restarting your instance. For recommendations on managing connections that can help in failover events, see the FAQ entry How should I manage connections?

You can configure:

  • Cloud SQL instances that replicate from a Cloud SQL master instance.
  • Cloud SQL instances that replicate from an external master instance.
  • External MySQL instances that replicate from a Cloud SQL master instance.

  • Note that external read replica instances must:
  • Be able to connect to the Cloud SQL master instance with the MySQL wire protocol.
  • Support row-based replication.
  • Be the same (or later) version of the Cloud SQL instance being replicated.

For more information about read replicas, including use cases for each type, see Configuring Replication with Google Cloud SQL.


You can use the Google Cloud Platform Console to see all of your Cloud SQL instances, and whether an instance is a master or read replica instance. You can use the Cloud SDK to check whether an instance is a master or read replica. For more information, see Checking replication status.


I hope this helps.


Sincerely,

George




On Wednesday, December 23, 2015 at 12:51:36 PM UTC-5, Brian Wawok wrote:
Hi!

From reading the documentation and poking around, I am not entirely sure how the cloud SQL failover is setup. Can anyone point me to a more complete documentation, or answer a few questions for me?


1) In 1st gen, when there was a failure a new instance was automagically spun up and activated. In 2nd gen, is this no longer the case? Do I NEED to create a Failover Replica for the same behavior?

2) In the event of a failover, will my failover replica automatically become primary? Or do I need to trigger a failover by hand when something is down? 

3) How long of a bad event is there before the automatic failover process is started? 

4) My failover replica has an IP.. do I need to change my clients to use this IP, or will the old primary IP now start pointing at the failover replica? i.e. is this really a floating IP that gets moved?

5) Can I use my failover replica as a read slave, or must it just sit idle until an event?

6) What happens to the old primary in a failover after it comes back. Does it become a failover replica for the new primary, or do I need to do something by hand?

7) How do I reset my original primary to be the real master after a failover event is complete?


Thanks!


Brian

--
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/6136f688-4c54-4360-808a-8a24ca282b11%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.