public class EventBatcher extends Object
| Modifier and Type | Class and Description |
|---|---|
protected static class |
EventBatcher.BatchItem |
| Constructor and Description |
|---|
EventBatcher(com.fasterxml.jackson.databind.ObjectMapper objectMapper,
Consumer<List<EventBatcher.BatchItem>> publisher) |
| Modifier and Type | Method and Description |
|---|---|
void |
finish()
Publishes all events which were pushed and not yet published.
|
void |
pushEvent(EventLog eventLogEntry,
NakadiEvent nakadiEvent)
Pushes one event to be published.
|
public EventBatcher(com.fasterxml.jackson.databind.ObjectMapper objectMapper,
Consumer<List<EventBatcher.BatchItem>> publisher)
public void pushEvent(EventLog eventLogEntry, NakadiEvent nakadiEvent)
finish().eventLogEntry - The event log entry for this event.nakadiEvent - The Nakadi form of the event.public void finish()
Copyright © 2019. All rights reserved.