improve replication compatibility for redis