I have faced a strange issue.
Suddenly Aerospike data has been erased. Provided i have not executed any command to delete the data from the Aerospike.
namespace test {
replication-factor 2
memory-size 4G
default-ttl 30d # 30 days, use 0 to never expire/evict.
storage-engine memory
}
I haven’t configured the ttl here but few days back I ran one UDF to set the ttl of all the records to -1 so that it never expires. The sets were being updated periodically, so even then it should not expire after 30 days. I lost all at once which should not be the case.
I am stuck in this since 2 days. Any help is appreciated.
You're using a namespace that is basically defined to be a cache. It is in-memory with no persistence. For example, a restart of the node will cause the namespace to start empty.
The Namespace Storage Configuration article in the deployment guide gives recipes for storage engine configuration. You can set the storage of a specific namespace to be one of the following:
There is a special case of data in-memory for counters, data-in-index. This is done with persistence.