Document expiry using PagingAndSorting Repository

I have an interface which extends PagingAndSorting repo and i have method like save and getuserbyId,getuserbyName .
I need to set expiration of these documents when saved,retrieved,update.
Can anyone help me ?

@sandeepkv054 welcome to the forums.
I am assuming that you are using Couchbase Java SDK 3.0 or later and you are using the KV operations ?
The documentation here will walk you through passing the expiry as an option