I was trying to bulk insert data into my couchbase servers which i was able to do using "cbdocloader". But what about the TTL of the objects inserted?
Is there a way to set the properties like TTL, TTI, etc that we can set using the Java api?
The cbdocloader tool does not provide any official way to send a TTL.
Since cbdocloader is a python script you can modify it, obviously it is not a supported thing but it is working.
So what you can do is:
- edit the cbdocloader file located in $COUCHBASE_INSTALL/couchbase-core/lib/python
- go to line 129 ( self.bucket.set(dockey, 0, 0, raw_data) )
and replace the first 0 with you TTL
We have migrated this discussion to the Q&A section in our new User Communities Portal Here: http://www.couchbase.com/communities/q-and-a/how-set-ttl-json-objects-in.... Please head over there to continue your discussion; forums will become read-only on 06/27.
Your Couchbase Forum Team
© 2013 COUCHBASE All rights reserved.