类 RequestProcessor

java.lang.Object
com.alibaba.nacos.consistency.RequestProcessor
直接已知子类:
RequestProcessor4AP, RequestProcessor4CP

public abstract class RequestProcessor extends Object
Can be discovered through SPI or Spring, This interface is just a function definition interface. Different consistency protocols have their own LogDispatcher. It is not recommended to directly implement this interface.
作者:
liaochuntao
  • 构造器详细资料

    • RequestProcessor

      public RequestProcessor()
  • 方法详细资料

    • onRequest

      public abstract Response onRequest(ReadRequest request)
      get data by key.
      参数:
      request - request ReadRequest
      返回:
      target type data
    • onApply

      public abstract Response onApply(WriteRequest log)
      Process Submitted Log.
      参数:
      log - WriteRequest
      返回:
      boolean
    • onError

      public void onError(Throwable error)
      Irremediable errors that need to trigger business price cuts.
      参数:
      error - Throwable
    • group

      public abstract String group()
      In order for the state machine that handles the transaction to be able to route the Log to the correct LogProcessor, the LogProcessor needs to have an identity information.
      返回:
      Business unique identification name