DS-9999: limiting count of events to valid ones