Search in sources :

Example 1 with SortedLocalResult

use of com.actiontech.dble.backend.mysql.store.SortedLocalResult in project dble by actiontech.

the class OrderByHandler method fieldEofResponse.

@Override
public void fieldEofResponse(byte[] headerNull, List<byte[]> fieldsNull, final List<FieldPacket> fieldPackets, byte[] eofNull, boolean isLeft, final BackendConnection conn) {
    if (terminate.get())
        return;
    if (this.pool == null)
        this.pool = DbleServer.getInstance().getBufferPool();
    this.fieldPackets = fieldPackets;
    RowDataComparator cmp = new RowDataComparator(this.fieldPackets, orders, isAllPushDown(), type());
    localResult = new SortedLocalResult(pool, fieldPackets.size(), cmp, CharsetUtil.getJavaCharset(conn.getCharset().getResults())).setMemSizeController(session.getOrderBufferMC());
    nextHandler.fieldEofResponse(null, null, fieldPackets, null, this.isLeft, conn);
    startOwnThread(conn);
}
Also used : SortedLocalResult(com.actiontech.dble.backend.mysql.store.SortedLocalResult) RowDataComparator(com.actiontech.dble.backend.mysql.nio.handler.util.RowDataComparator)

Aggregations

RowDataComparator (com.actiontech.dble.backend.mysql.nio.handler.util.RowDataComparator)1 SortedLocalResult (com.actiontech.dble.backend.mysql.store.SortedLocalResult)1