Package com.here.platform.dal.custom
Interface SimpleUDF
- All Superinterfaces:
UDF
The user of this interface has precise control over selecting indexing attributes with single value for each message.
- Since:
- 0.1.0
- See Also:
-
Method Summary
Methods inherited from interface com.here.platform.dal.custom.UDF
aggregate, open, transformForDeadLetter
-
Method Details
-
getKeys
Retrieve indexing attributes (keys) for the message. Data will be archived to index layer based on these keys. These indexing attributes can later be used to query the archived data from index layer with specific characteristics.Note that different messages having same indexing attributes will later be archived together in a single file.
If all messages are to have unique indexing attributes, the archival and query performance may be impacted. The single most important factor for archiving pipeline performance is the number of unique indexing attributes combination. See the "Best Practices" in Developer Guide for detail discussion.
For this method,
- The names of keys has to match the names of indexing attributes defined when creating index layer.
- User can select only one value for each key. The value cannot be a
Collection
. - The value type should be one of index layer supported types [
Integer
,Long
,Boolean
,String
, timewindow (Long
), heretile (Long
)]. - If a collection or an index layer incompatible type is selected for value type of any valid key name, then the message will not be archived.
- If an unchecked exception or null is returned, then the message will not be archived.
- Parameters:
metadata
- collection (Map
) containing metadata information. Any metadata information can also be used to select one/more indexing attributes for the message. The keys of the metadata map can be found hereMetadataName
.message
- message for which indexing attributes are supposed to be selected. The message is array of bytes which can also be deserialized to retrieve any specific characteristic for indexing.- Returns:
- the collection (
Map
) containing indexing attributes for the message.
-