I’m following the couchbase jdk document to set expiry.
int expiry = 180;
bucket.upsert(JsonDocument.create(documentId, expiry, data));
Key:270006254971 value:JsonDocument{id=‘testing0’, cas=12707951742556403, expiry=0, content={“creationDate”:“2016-07-25T14:46:08-0700”,“siteId”:0,“review_count”:2,“expireDate”:“2016-09-23T14:46:08-0700”,“domain”:“review”,“itemId”:“270006254971”,“autoTagProductId”:“1602901284”,“caseName”:“AddReviews_testing”}, mutationToken=null}
When I get the document.content. the expiry is always 0. However, after 3 minutes. The data is gone. I’m not sure if it’s a bug.
Thanks