@Override
  public JsonRpcResponse response(final JsonRpcRequestContext requestContext) {
    checkState(
        validatorProvider.getVoteProviderAtHead().isPresent(), "Ibft requires a vote provider");
    final Address validatorAddress;
    try {
      validatorAddress = requestContext.getRequiredParameter(0, Address.class);
    } catch (JsonRpcParameterException e) {
      throw new InvalidJsonRpcParameters(
          "Invalid validator address parameter (index 0)", RpcErrorType.INVALID_ADDRESS_PARAMS, e);
    }
    LOG.trace("Received RPC rpcName={} address={}", getName(), validatorAddress);
    validatorProvider.getVoteProviderAtHead().get().discardVote(validatorAddress);

    return new JsonRpcSuccessResponse(requestContext.getRequest().getId(), true);
  }
Instantiates a new Ibft discard validator vote.

@param validatorProvider the validator provider
consensus/ibft/src/main/java/org/hyperledger/besu/consensus/ibft/jsonrpc/methods/IbftDiscardValidatorVote.java