hollow/src/main/java/com/netflix/hollow/api/producer/HollowIncrementalProducer.java
public long runCycle() {
        long recordsRemoved = countRecordsToRemove();
        long recordsAddedOrModified = this.mutations.values().size() - recordsRemoved;
        try {
            long version = producer.runCycle(populator);
            if(version == lastSucessfulCycle) {
                return version;
            }
            listeners.fireIncrementalCycleComplete(version, recordsAddedOrModified, recordsRemoved, new HashMap<String, Object>(cycleMetadata));
            //Only clean changes when the version is new.
            clearChanges();
            lastSucessfulCycle = version;
            return version;
        } catch (Exception e) {
            listeners.fireIncrementalCycleFail(e, recordsAddedOrModified, recordsRemoved, new HashMap<String, Object>(cycleMetadata));
            return FAILED_VERSION;
        } finally {
            clearCycleMetadata();
        }
    }
public long runCycle() {
        long recordsRemoved = countRecordsToRemove();
        long recordsAddedOrModified = this.mutations.values().size() - recordsRemoved;
        try {
            long version = producer.runCycle(populator);
            if(version == lastSucessfulCycle) {
                return version;
            }
            listeners.fireIncrementalCycleComplete(version, recordsAddedOrModified, recordsRemoved, new HashMap<String, Object>(cycleMetadata));
            //Only clean changes when the version is new.
            clearChanges();
            lastSucessfulCycle = version;
            return version;
        } catch (Exception e) {
            listeners.fireIncrementalCycleFail(e, recordsAddedOrModified, recordsRemoved, new HashMap<String, Object>(cycleMetadata));
            return FAILED_VERSION;
        } finally {
            clearCycleMetadata();
        }
    }
public long runCycle ( ) { long recordsRemoved = countRecordsToRemove ( ) ; long recordsAddedOrModified = this . mutations . values ( ) . size ( ) - recordsRemoved ; try { long version = producer . runCycle ( populator ) ; if ( version == lastSucessfulCycle ) { return version ; } listeners . fireIncrementalCycleComplete ( version , recordsAddedOrModified , recordsRemoved , new HashMap < String , Object > ( cycleMetadata ) ) ; //Only clean changes when the version is new. clearChanges ( ) ; lastSucessfulCycle = version ; return version ; } catch ( Exception e ) { listeners . fireIncrementalCycleFail ( e , recordsAddedOrModified , recordsRemoved , new HashMap < String , Object > ( cycleMetadata ) ) ; return FAILED_VERSION ; } finally { clearCycleMetadata ( ) ; } }
Runs a Hollow Cycle, if successful, cleans the mutations map.

@return the version of the cycle if successful, otherwise the {@link #FAILED_VERSION}
@since 2.9.9
Runs a Hollow Cycle if successful cleans the mutations map .