TTL for Documents with Hook for automatic Clean Up Code [moved]
See original GitHub issueHi
A requested feature in the Orient Group was a TTL / Tombstone Feature in OrientDB. This would be a great functionality and should at least have following possibilities:
Define TTL while Document Creation
Set TTL after Document Creation
Set TTL to "Tombstone" Value (ex. -1) for automatic
Have a hook - which could be used to access this feature - so different use cases are possible:
Archiving Doc - to another database (out of hot "Data")
Search for linked "Docs" to this Record - to not break Integrity
Flag Doc for Cleaning
Track Doc "Deletion" for compress the database while online
Hope this is enough information on this Michael
Issue Analytics
- State:
- Created 11 years ago
- Reactions:1
- Comments:8 (2 by maintainers)
Top Results From Across the Web
How to implement TTL-based cleanup to expire data in a KTable
In this tutorial, learn how to implement TTLs to expire data in a KTable using Kafka Streams, with step-by-step instructions and examples.
Read more >Set up Automatic Removal for Time Series Collections (TTL)
The background task that removes expired buckets runs every 60 seconds. Therefore, documents may remain in a collection during the period between the...
Read more >Examples of S3 Lifecycle configuration - AWS Documentation
When you specify the Days tag, Amazon S3 automatically performs ExpiredObjectDeleteMarker cleanup when the delete markers are old enough to satisfy the age ......
Read more >TTL Documents, Shield and Found | Elastic Blog
This means that setting the _ttl for a document to anything under 60 seconds won't actually delete the document until 60 seconds has...
Read more >Optimize costs by automatically managing the data lifecycle
Use Azure Storage lifecycle management policies to create automated rules for moving data between hot, cool, and archive tiers.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
👍 for this
Another way to implement it is to only delete the document when reading it. So:
This way there are no tasks running continuously. Though we could probably have a task running every few hours to delete expired tokens with the purpose of saving space.
As a heavy user of NoSQL this feature is not at ‘low priority’ for me 😉
Simple example working with User Session. Having TTL in OrientDB make it quite a pleasure, just create a Session document with User as a linked field when login succeed. When a request arrive check for the session asking directly to OrientDB. Yeah Quick WIN !
Without OrientDB 😕
1 -> put a non distributed session cache in your application -> no more stateless app 2 -> install a distributed cache with TTL : Redis, HBase, EHCache, whatever Go apps, etc. Duplicate repositories and administration 3 -> ‘easily’ implement it in OrientDB, more logic that do not belongs to my business
The implementation need to provide events listeners so we can follow what’s going on.
I love OrientDB and use it in production right now but this feature is really missing. Thank you for you attention.