Questions tagged [ttl]

Time to live (TTL) is a mechanism that limits the lifespan or lifetime of data in a computer or network

Time to live (TTL) is a mechanism that limits the lifespan or lifetime of data in a computer or network

Wikipedia

598 questions
7
votes
2 answers

Mongodb TTL expires documents early

I am trying insert a document into a Mongo database and have it automatically expire itself after a predetermine time. So far, my document get inserted but always get deleted from the database from 0 - 60 seconds even though I set the…
fat fantasma
  • 7,483
  • 15
  • 48
  • 66
7
votes
2 answers

mongodb TTL not removing documents

I have a simple schema like: { _id: String, // auto generated key: String, // there is a unique index on this field timestamp: Date() // set to current time } Then I set the TTL index like so: db.sess.ensureIndex( {…
jckdnk111
  • 2,280
  • 5
  • 33
  • 43
6
votes
1 answer

Time expiry dictionary in memory in Python

I was just wondering how one might efficiently implement a time expiry dictionary in memory in Python such that key-value pairs expire after a specified time interval.
kir bak
  • 91
  • 2
  • 5
6
votes
1 answer

Why are IP_TTL and IP_MULTICAST_TTL separate socket options?

When sending UDP multicast you can use IP_MULTICAST_TTL to set the TTL. But otherwise you would use IP_TTL. Why are these two different options in the eyes of setsockopt() and getsockopt()? Is there any situation in which setting them separately…
John Zwinck
  • 239,568
  • 38
  • 324
  • 436
6
votes
2 answers

How to get TTL of a UDP packet in Java?

I am using a Java application to send UDP packets to an Android device. There I have another Java application that receives these UDP packets and displays its data - very simple. Now I am working on some routing algorithms - therefore it would be…
mreichelt
  • 12,359
  • 6
  • 56
  • 70
6
votes
1 answer

Where can I find the executed TTL commands in Mongo DB

I would like to know the logs of documents removed through TTL indexing. I tried using db.setProfileLevel(2) and searched the db.system.profile.find({op:"remove"}).pretty(), but It returned nothing. Can you please let me know the location of…
user4604434
  • 127
  • 9
6
votes
3 answers

Max value for TTL in cassandra

What is the maximum value we can assign to TTL ? In the java driver for cassandra TTL is set as a int. Does that mean it is limited to Integer.MAX (2,147,483,647 secs) ?
mob
  • 567
  • 5
  • 12
6
votes
2 answers

Redis - get values of keys that match a regex

I need to save for each key, some values with different TTL. e.g - for XXXX, values - val1(expiry time: 10),val2(expiry time: 20) Option 1: My best practice could be: Use hash/sets with per-member expiry. Unfortunately, Redis's containers ( lists,…
user2503775
  • 4,267
  • 1
  • 23
  • 41
6
votes
2 answers

Cassandra - Cqlengine - TTL Support

I need to use TTL via cqlengine; But there is no documentation about it. Can someone help me about it. Thanks
6
votes
3 answers

How to make elasticsearch document ttl work?

I installed debian package I am able to push data using curl: curl -XPUT 'http://mybox:9200/blog/user/dilbert' -d '{ "name": "Dilbert Brown" }' And fetch it curl -XGET 'http://mybox:9200/blog/user/dilbert' result: { "_index": "blog", …
Archibald
  • 1,305
  • 1
  • 14
  • 19
6
votes
1 answer

not getting all ICMP time-exceeded messages: why?

I'm using Scapy to replay some dumped packets in which I change the TTL value. I've been getting very odd results even with TTL=1. When I run my test hours apart from each other, I can get from roughly 40% to 95% of packets replied to with an…
Ricky Robinson
  • 21,798
  • 42
  • 129
  • 185
5
votes
2 answers

Is there any option like "Time to live" in SQL Server?

Is there any option like "Time to live" in SQL Server? Recently I learned about Time to Live in Scylla DB. I would like to know is the option same available across the databases especially SQL Server. I have searched in Internet but I couldn't get…
Noah
  • 77
  • 1
  • 1
  • 6
5
votes
2 answers

Add Mongo TTL Index to Large Collection

I have a large collection in Mongo. Around 1.7 billion records that take up around 5TB of storage space. I no longer need to keep this data indefinitely so I'm looking at options for getting rid of most of the data, preferably based on…
user2708122
  • 63
  • 1
  • 5
5
votes
1 answer

Adding TTL to DynamoDB records via Python3 & Boto3

I have the following Pyhton3/Boto3 script that connects to a AWS DynamoDB table and attempts to set a 19-day TTL on all its records by looping through them: #!/usr/bin/env python3 import boto3 import sys from datetime import datetime, timedelta from…
hotmeatballsoup
  • 385
  • 6
  • 58
  • 136
5
votes
2 answers

Update ttl for all records in aerospike

I was stuck in a situation that I have initialised a namesapce with default-ttl to 30 days. There was about 5 million data with that (30-day calculated) ttl-value. Actually, my requirement is that ttl should be zero(0), but It(ttl-30d) was kept…
chikku
  • 863
  • 1
  • 7
  • 19
1 2
3
39 40