PartitionReceiveHandler Interface
public interface PartitionReceiveHandler
The handler to invoke after receiving EventDatas from Microsoft Azure EventHubs. Use any implementation of this abstract class to specify user action when using PartitionReceiver's setReceiveHandler().
Method Summary
Modifier and Type | Method and Description |
---|---|
abstract int |
getMaxEventCount()
Maximum number of EventData to supply while invoking onReceive(Iterable<EventData> events) |
abstract void |
onError(Throwable error)
Implement this method to Listen to errors which lead to Closure of the PartitionReceiveHandler pump. |
abstract void |
onReceive(Iterable<EventData> events)
user should implement this method to specify the action to be performed on the received events. |
Method Details
getMaxEventCount
public abstract int getMaxEventCount()
Maximum number of EventData to supply while invoking onReceive(Iterable<EventData> events)
Ensure that the value should be less than or equal to the value of getPrefetchCount()
Returns:
onError
public abstract void onError(Throwable error)
Implement this method to Listen to errors which lead to Closure of the PartitionReceiveHandler pump.
Parameters:
onReceive
public abstract void onReceive(Iterable
user should implement this method to specify the action to be performed on the received events.
Parameters:
Applies to
Azure SDK for Java
피드백
https://aka.ms/ContentUserFeedback
출시 예정: 2024년 내내 콘텐츠에 대한 피드백 메커니즘으로 GitHub 문제를 단계적으로 폐지하고 이를 새로운 피드백 시스템으로 바꿀 예정입니다. 자세한 내용은 다음을 참조하세요.다음에 대한 사용자 의견 제출 및 보기