Hashing index fields using elasticsearch

Hi all, I have a question.
In my index I have two fields that I want merge into a third field and than I whish to hash this "new field" using elasticsearch' script processor.

For exemple:
My index:
field1: foo1
field2: foo2

After running the script I would like to have a new field which is the sha1 hash of the merge of field1 and field2

field3: 89b6374dca999b98c9f787f0d7a7c98854dba7c9

It is possible to do that without reindex? Or a reindex is needed?

A simple 32 bit hashing is enough to save the performances of es, sha1 is just for explain the example

Can someone help me please?

My version of elasticsearch is 7.1.1

Thank you

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.