public class ElasticSearchInlineListener extends IndexingCommandsStacker implements EventListener, Synchronization
Modifier and Type | Field and Description |
---|---|
protected static ThreadLocal<Boolean> |
isEnlisted |
protected static ThreadLocal<Map<String,IndexingCommands>> |
transactionCommands |
static ThreadLocal<Boolean> |
useSyncIndexing |
Constructor and Description |
---|
ElasticSearchInlineListener() |
Modifier and Type | Method and Description |
---|---|
void |
afterCompletion(int status) |
void |
beforeCompletion() |
protected Map<String,IndexingCommands> |
getAllCommands() |
void |
handleEvent(Event event)
Handle the given event.
|
protected boolean |
isSyncIndexingByDefault() |
protected boolean |
registerSynchronization(Synchronization sync) |
getCommands, getDocKey, getOrCreateCommands, isSynchronous, stackCommand, stackCommand
protected static ThreadLocal<Map<String,IndexingCommands>> transactionCommands
protected static ThreadLocal<Boolean> isEnlisted
public static ThreadLocal<Boolean> useSyncIndexing
public ElasticSearchInlineListener()
protected Map<String,IndexingCommands> getAllCommands()
getAllCommands
in class IndexingCommandsStacker
protected boolean isSyncIndexingByDefault()
isSyncIndexingByDefault
in class IndexingCommandsStacker
public void handleEvent(Event event)
EventListener
Event.cancel()
handleEvent
in interface EventListener
event
- the eventpublic void beforeCompletion()
beforeCompletion
in interface Synchronization
public void afterCompletion(int status)
afterCompletion
in interface Synchronization
protected boolean registerSynchronization(Synchronization sync)
Copyright © 2015 Nuxeo SA. All rights reserved.