I have 2 servers running tokyo cabinet in a cluster (2 hard drives so 4 instances of Tokyo Cabinet). if it's just one instance of tokyo cabinet it's fairly straight forward to use php memcache protocol to communicate. My question is how do you connect php if it's cluster?
Option 1: $memcache->connect('memcache_host', 11211); Using this option you can only connect to on instance of tokyo cabinet.
Option 2: $memcache = new Memcache; $memcache->addServer('memcache_host', 11211); $memcache->addServer('memcache_host2', 11211); Using this, you can connect to multiple, but are the data stored correctly in the cluster?
Thank you!