Search in sources :

Example 1 with GoodbyeMessage

use of tech.pegasys.teku.spec.datastructures.networking.libp2p.rpc.GoodbyeMessage in project teku by ConsenSys.

the class BeaconChainMethods method createGoodBye.

private static Eth2RpcMethod<GoodbyeMessage, GoodbyeMessage> createGoodBye(final AsyncRunner asyncRunner, final MetricsSystem metricsSystem, final PeerLookup peerLookup, final RpcEncoding rpcEncoding) {
    final GoodbyeMessageHandler goodbyeHandler = new GoodbyeMessageHandler(metricsSystem);
    final RpcContextCodec<?, GoodbyeMessage> contextCodec = RpcContextCodec.noop(GoodbyeMessage.SSZ_SCHEMA);
    return new SingleProtocolEth2RpcMethod<>(asyncRunner, BeaconChainMethodIds.GOODBYE, 1, rpcEncoding, GoodbyeMessage.SSZ_SCHEMA, false, contextCodec, goodbyeHandler, peerLookup);
}
Also used : SingleProtocolEth2RpcMethod(tech.pegasys.teku.networking.eth2.rpc.core.methods.SingleProtocolEth2RpcMethod) GoodbyeMessageHandler(tech.pegasys.teku.networking.eth2.rpc.beaconchain.methods.GoodbyeMessageHandler) GoodbyeMessage(tech.pegasys.teku.spec.datastructures.networking.libp2p.rpc.GoodbyeMessage)

Aggregations

GoodbyeMessageHandler (tech.pegasys.teku.networking.eth2.rpc.beaconchain.methods.GoodbyeMessageHandler)1 SingleProtocolEth2RpcMethod (tech.pegasys.teku.networking.eth2.rpc.core.methods.SingleProtocolEth2RpcMethod)1 GoodbyeMessage (tech.pegasys.teku.spec.datastructures.networking.libp2p.rpc.GoodbyeMessage)1