类 RequestProcessor
- java.lang.Object
-
- com.alibaba.nacos.consistency.RequestProcessor
-
- 直接已知子类:
RequestProcessor4AP,RequestProcessor4CP
public abstract class RequestProcessor extends java.lang.ObjectCan 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()
-
方法概要
所有方法 实例方法 抽象方法 具体方法 修饰符和类型 方法 说明 abstract java.lang.Stringgroup()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.abstract ResponseonApply(WriteRequest log)Process Submitted Log.voidonError(java.lang.Throwable error)Irremediable errors that need to trigger business price cuts.abstract ResponseonRequest(ReadRequest request)get data by key.
-
-
-
方法详细资料
-
onRequest
public abstract Response onRequest(ReadRequest request)
get data by key.- 参数:
request- requestReadRequest- 返回:
- target type data
-
onApply
public abstract Response onApply(WriteRequest log)
Process Submitted Log.- 参数:
log-WriteRequest- 返回:
boolean
-
onError
public void onError(java.lang.Throwable error)
Irremediable errors that need to trigger business price cuts.- 参数:
error-Throwable
-
group
public abstract java.lang.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
-
-