i have an existing elastic data source with around 42000 rows. and also i am updating it daily.I want to add a custom filed , whose value will depend on two other fields .
e.g i have 2 existing field P and Q
i want to add R which ll depend on values of P and Q ,
i know i can do it by If ..else mutate in logstash filter while adding or updating data . But the problem is, i have more than 100 different conditions to be taken care. so writing 100 if..else statement is time consuming and bad idea.
is there any way to it from python, so that i can use list or dictionary to do mapping or
Is there any better solution to it?
Any help ll be appreciated !!