0

Does it makes any different if I was using mysql db and now I want to use Mysql cluster on my server. How will this affect my yii2 application ?? do I have to make any changes to db connection or just connect to any node ? does this affect Active Queries ?? Does it affect the active model relations ??

Thanks in advance.

Deena Samy
  • 503
  • 2
  • 7
  • 20

1 Answers1

1

You need to carefully read Known Limitations of NDB Cluster section in the MySQL docs.

Most important parts are:

  • column width limit for indexation,
  • TEXT and BLOB cannot be indexed,
  • BIT column cannot be a primary key, unique key, or index, nor can it be part of a composite primary key, unique key, or index,
  • you cannot have table with AUTO_INCREMENT column and no explicit primary key,
  • only READ COMMITTED transaction isolation level,
  • foreign keys are supported only in NDB Cluster 7.3 and later.

AR implementation in Yii 2 should be basically fine. You connect in the same way as usual.

Bizley
  • 17,392
  • 5
  • 49
  • 59
  • Thank you so much.. by reading the above points. It seems that it's not a right to choice to use. I'm going to just configure mysql Master Master Replication between two servers. – Deena Samy Aug 27 '17 at 10:06