- Subscribe to RSS Feed
- Mark Question as New
- Mark Question as Read
- Float this Question for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
NiFi put data in Distributed Cache
- Labels:
-
Apache NiFi
Created ‎12-10-2018 02:29 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am planning to store date value in Distributed cache. The date field is present in the flowfile as well as attribute. Currently, I am using PutDistributedMapCache processor with "Cache Entry Identifier" = ${max_date} and "Cache update strategy" = "Replace if present". This max_date is present in flowfile as attribute. When I get the cache data using FetchDistributedMapCache with "Cache Entry Identifier" = $.max_date and "Put Cache Value In Attribute" = maxdate, in the maxdate attribute, I am getting the entire avro data instead of something like "20-10-1992 00:02:00". The flowfile content is also of format "Content Type:application/octet-stream" and I am unable to view the content. Could someone explain how to update an attribute or field into cache and again get only that attribute from cache instead of entire avro data? Thanks for your help in advance
Created ‎12-10-2018 04:45 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@Gowthaman V check out this gist which has an example flow to properly use the distributed cache -
https://gist.github.com/ijokarumawak/8ba9a2a1b224603f877e960a942a6f2b
Also this might help you -
https://stackoverflow.com/questions/44590296/how-does-one-setup-a-distributed-map-cache-for-nifi
