Search in sources :

Example 1 with ChunkDecoder

use of org.neo4j.bolt.transport.pipeline.ChunkDecoder in project neo4j by neo4j.

the class AbstractBoltProtocol method install.

/**
 * Install chunker, packstream, message reader, message handler, message encoder for protocol v1
 */
@Override
public void install() {
    BoltStateMachine stateMachine = stateMachineFactory.newStateMachine(version(), channel, connectionHints, memoryTracker);
    var neo4jPack = createPack(memoryTracker);
    var messageWriter = createMessageWriter(neo4jPack, logging, memoryTracker);
    var connection = connectionFactory.newConnection(channel, stateMachine, messageWriter);
    var messageReader = createMessageReader(connection, messageWriter, bookmarksParser, logging, channelProtector, memoryTracker);
    memoryTracker.allocateHeap(ChunkDecoder.SHALLOW_SIZE + MessageAccumulator.SHALLOW_SIZE + MessageDecoder.SHALLOW_SIZE + HouseKeeper.SHALLOW_SIZE);
    channel.installBoltProtocol(new ChunkDecoder(), new MessageAccumulator(config), new MessageDecoder(neo4jPack, messageReader, logging), new HouseKeeper(connection, logging.getInternalLog(HouseKeeper.class)));
}
Also used : MessageDecoder(org.neo4j.bolt.transport.pipeline.MessageDecoder) ChunkDecoder(org.neo4j.bolt.transport.pipeline.ChunkDecoder) BoltStateMachine(org.neo4j.bolt.runtime.statemachine.BoltStateMachine) MessageAccumulator(org.neo4j.bolt.transport.pipeline.MessageAccumulator) HouseKeeper(org.neo4j.bolt.transport.pipeline.HouseKeeper)

Aggregations

BoltStateMachine (org.neo4j.bolt.runtime.statemachine.BoltStateMachine)1 ChunkDecoder (org.neo4j.bolt.transport.pipeline.ChunkDecoder)1 HouseKeeper (org.neo4j.bolt.transport.pipeline.HouseKeeper)1 MessageAccumulator (org.neo4j.bolt.transport.pipeline.MessageAccumulator)1 MessageDecoder (org.neo4j.bolt.transport.pipeline.MessageDecoder)1