MySQL Forums
Forum List  »  InnoDB clusters

Re: Cluster and AutoIncrement
Posted by: Frederic Descamps
Date: October 19, 2016 02:48PM

Hi Steffan,

With MySQL InnoDB Cluster, the auto_increment is managed by the cluster. But if you one to use only one Primary master (so it means write only on one member and only if that one dies, you write on another one), you can override that value and set it to 1. I don't really recommend to change the behavior but sometimes there are applications that uses the auto_increment value for other purpose than a simple primary key... and this is bad design... but it exists.

Instead of building an opensource load balancer, I would have a look to the very popular ProxySQL (https://github.com/sysown/proxysql & http://proxysql.com).

You can also read this article that explains how to use it with Group Replication (MySQL InnoDB Cluster): http://lefred.be/content/ha-with-mysql-group-replication-and-proxysql/

Regards,

lefred

Options: ReplyQuote


Subject
Views
Written By
Posted
2233
October 19, 2016 07:36AM
Re: Cluster and AutoIncrement
1057
October 19, 2016 02:48PM
837
October 19, 2016 11:48PM
765
October 20, 2016 12:39AM
672
October 20, 2016 10:55AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.