Enrich flowfile with in memory look-up dataset
I have a flow file that I want to enrich with the contents from a list of JSON values based on the "id". Basically perform an inner join of the flow file with this look-up data set. However, I need the look-up dataset to be in memory, then using the "id", query the look-up dataset and append the results to the current flow file. Here is an example:
Incoming flow file:
{
"id": "abc123",
"fname": "The",
"lname": "Rock"
}
Contents of the look-up data set:
[
{
"id": "abc123",
"dob": "03/09/1977",
"phone": "987-654-0001"
},
{
"id": "def765",
"dob": "04/08/1976",
"phone": "789-654-0001"
},
{
"id": "hij765",
"dob": "05/06/1975",
"phone": "456-654-0001"
}
]
Enriched flow file:
{
"id": "abc123",
"fname": "The",
"lname": "Rock",
"dob": "03/09/1977",
"phone": "987-654-0001"
}
I need to be able to look up the correct record in the look-up dataset based on the "id" then append the values to the current flow file.
The key here is that I need the look-up dataset to reside in memory (can't be a file or a database)
Thanks for reading and look forward to hearing back with ideas.

