@Override
        public void restore(Map<String, Object> state) {
            startTime = (long) state.get("StartTime");
            endTime = (long) state.get("EndTime");
            lastScheduledTime = (long) state.get("LastScheduledTime");
            lastCurrentEventTime = (long) state.get("LastCurrentEventTime");
            currentEventChunk.clear();
            currentEventChunk.add((StreamEvent) state.get("CurrentEventChunk"));
            if (expiredEventChunk != null) {
                expiredEventChunk.clear();
                expiredEventChunk.add((StreamEvent) state.get("ExpiredEventChunk"));
            } else {
                if (outputExpectsExpiredEvents || findToBeExecuted) {
                    expiredEventChunk = new ComplexEventChunk<>();
                }
                if (schedulerTimeout > 0) {
                    expiredEventChunk = new ComplexEventChunk<>();
                }
            }
            resetEvent = (StreamEvent) state.get("ResetEvent");
            flushed = (boolean) state.get("Flushed");
        }
Here an assumption is taken:
Parameter: timestamp: The time which the window determines as current time and will act upon,
the value of this parameter should be monotonically increasing.
from https://docs.wso2.com/display/CEP400/Inbuilt+Windows#InbuiltWindows-externalTime
modules/siddhi-core/src/main/java/io/siddhi/core/query/processor/stream/window/ExternalTimeBatchWindowProcessor.java