@Override
    public void process(ComplexEventChunk complexEventChunk) {
        List<ComplexEventChunk> outputEventChunks = new LinkedList<>();
        complexEventChunk.reset();
        RateLimiterState state = stateHolder.getState();
        try {
            synchronized (state) {
                complexEventChunk.reset();
                while (complexEventChunk.hasNext()) {
                    ComplexEvent event = complexEventChunk.next();
                    if (event.getType() == ComplexEvent.Type.TIMER) {
                        tryFlushEvents(outputEventChunks, event, state);
                    } else if (event.getType() == ComplexEvent.Type.CURRENT) {
                        complexEventChunk.remove();
                        tryFlushEvents(outputEventChunks, event, state);
                        GroupedComplexEvent groupedComplexEvent = ((GroupedComplexEvent) event);
                        state.groupByKeyEvents.put(groupedComplexEvent.getGroupKey(),
                                groupedComplexEvent.getComplexEvent());
                    }
                }
            }
        } finally {
            stateHolder.returnState(state);
        }
        sendToCallBacks(outputEventChunks);
    }
Sends the collected unique outputs per group by key upon arrival of timer event from scheduler.

@param complexEventChunk Incoming {@link ComplexEventChunk}
modules/siddhi-core/src/main/java/io/siddhi/core/query/output/ratelimit/snapshot/GroupByPerSnapshotOutputRateLimiter.java