public class DateAdditionalValue extends Object implements IAdditionalValue, Serializable
This is used by the elasticsearch bolt to efficiently add timestamp as part of indexed documents.
| Constructor and Description |
|---|
DateAdditionalValue(String format,
String name,
String tupleField) |
| Modifier and Type | Method and Description |
|---|---|
String |
getAdditionalValue(org.apache.storm.tuple.Tuple t)
This method returns a ready to be inserted timestamp json line.
|
String |
getKey() |
public DateAdditionalValue(String format, String name, String tupleField)
format - the data format. "iso" is accepted.name - the target elasticsearch document field nametupleField - the storm input field where to take that date, if null the current time will be usedpublic String getAdditionalValue(org.apache.storm.tuple.Tuple t)
getAdditionalValue in interface IAdditionalValuet - the tuplepublic String getKey()
getKey in interface IAdditionalValueCopyright © 2023. All rights reserved.