use of org.neo4j.bolt.transport.pipeline.MessageAccumulator 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)));
}
Aggregations