How can I configure Mongodb schema to delete mongodb record automatically in a collection using TTL property from another collection
I’m using Nestjs with Mongodb and want to delete record automatically from api-hit logs collection after the TTL is expired. I know how to configure the schema for auto – deletion of records using expiresAfterSeconds but the scenario is: