ISPN-4856 ISPN-4852 PartitionHandling: fix majority check and support replicated caches

https://issues.jboss.org/browse/ISPN-4856
https://issues.jboss.org/browse/ISPN-4852

Depends on https://github.com/infinispan/infinispan/pull/2964 (https://issues.jboss.org/browse/ISPN-4673)