Detail
Even though a set has stop-writes-count set, more records than that limit can exist on an individual node, and many more can exist across the entire cluster. How is this possible?
Answer
Firstly, the stop-writes-count limit is calculated and enforced on a per-node basis (as are all config parameters, in accord with Aerospike's shared-nothing architecture). If it's configured to 100 for a given set, and the cluster has 20 nodes, then you should expect up to a total of 2000 records in that set across the cluster.Secondly, the enforcement of stop-writes-count is only calculated when writing the master copy of the record. If the node where the master copy of the partition to which the record belongs has fewer than the specified number of records in that set, the write will succeed, and the record will be written to the master copy of the partition (which won't breach the limit on that node) and also to any prole copies of the partition (which are not checked, and therefore may breach the limit on their respective nodes). In normal usage the number of records in excess of the limit won't be large, but it stop-writes-count cannot be relied on for a hard, exact limit.