@Override
    public void add(ComplexEventChunk<StreamEvent> addingEventChunk) {
        List<Object[]> records = new ArrayList<>();
        addingEventChunk.reset();
        long timestamp = 0L;
        while (addingEventChunk.hasNext()) {
            StreamEvent event = addingEventChunk.next();
            records.add(event.getOutputData());
            timestamp = event.getTimestamp();
        }
        try {
            if (recordTableHandler != null) {
                recordTableHandler.add(timestamp, records);
            } else {
                add(records);
            }
        } catch (ConnectionUnavailableException | DatabaseRuntimeException e) {
            onAddError(addingEventChunk, e);
        }
    }
Initializing the Record Table

@param tableDefinition definition of the table with annotations if any
@param configReader    this hold the {@link AbstractRecordTable} configuration reader.
modules/siddhi-core/src/main/java/io/siddhi/core/table/record/AbstractRecordTable.java