| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.flume.sink.solr.morphline.MorphlineHandlerImpl
public class MorphlineHandlerImpl
A MorphlineHandler that processes it's events using a morphline Command chain.
| Field Summary | |
|---|---|
| static String | MORPHLINE_FILE_PARAM | 
| static String | MORPHLINE_ID_PARAM | 
| static String | MORPHLINE_VARIABLE_PARAMMorphline variables can be passed from flume.conf to the morphline, e.g.: agent.sinks.solrSink.morphlineVariable.zkHost=127.0.0.1:2181/solr | 
| Constructor Summary | |
|---|---|
| MorphlineHandlerImpl() | |
| Method Summary | |
|---|---|
|  void | beginTransaction()Begins a transaction | 
|  void | commitTransaction()Sends any outstanding documents to Solr and waits for a positive or negative ack (i.e. | 
|  void | configure(Context context)Request the implementing class to (re)configure itself. | 
|  void | process(Event event)Loads the given event into Solr | 
|  void | rollbackTransaction()Performs a rollback of all non-committed documents pending. | 
|  void | stop()Releases allocated resources | 
| Methods inherited from class java.lang.Object | 
|---|
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Field Detail | 
|---|
public static final String MORPHLINE_FILE_PARAM
public static final String MORPHLINE_ID_PARAM
public static final String MORPHLINE_VARIABLE_PARAM
| Constructor Detail | 
|---|
public MorphlineHandlerImpl()
| Method Detail | 
|---|
public void configure(Context context)
ConfigurableRequest the implementing class to (re)configure itself.
When configuration parameters are changed, they must be reflected by the component asap.
There are no thread safety guarrantees on when configure might be called.
configure in interface Configurablepublic void process(Event event)
MorphlineHandler
process in interface MorphlineHandlerpublic void beginTransaction()
MorphlineHandler
beginTransaction in interface MorphlineHandlerpublic void commitTransaction()
MorphlineHandler
commitTransaction in interface MorphlineHandlerpublic void rollbackTransaction()
MorphlineHandlerNote that this is not a true rollback as in databases. Content you have previously added to Solr may have already been committed due to autoCommit, buffer full, other client performing a commit etc. So this is only a best-effort rollback.
rollbackTransaction in interface MorphlineHandlerpublic void stop()
MorphlineHandler
stop in interface MorphlineHandler| 
 | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||