Client-Side Field Level Encryption | Dedupe failing on encrypted field

Hi Everyone,

I implemented mongo field level encryption in spring boot in one of my project. My data encryption keys were kind of rotating with each deployment. Now lately i noticed that for the same field value (say m) for which i was manually checking whether that is present in my db or not, I see multiple entries got created.

To my understanding, i feel that this is due to the rotating key strategy that i used here and using single data-encryption key might solve the issue.

But is there any better approach to this. I want to use rotating key for security purpose.

Reference Material:

Any help is much appreciated. Thanks