I have 2 nodes, one gateway and one worker.
Data must be passed from gateway to worker (without direct connection).
I would like to store a Key into a database identified with an ID and a Time To Live of 30 seconds.
The protocol is very simple :
- Gateway stores (Id, Key) to the database with a 30s TTL - Worker will fetch (if needed) the key with the Id it has in it's possession and remove it directly - If The key is not needed within 30 sec. it is deleted by the database (90% of the keys should be retrieved)
The insert, retrieve and delete must be really fast, and handle something like 30.000 per seconds easily. (With a quit descent configuration of course)
Data does not have to be permanent, if something goes wrong I don't care about data.
Would be nice if the TTL actually delete the row since it might become huge if not.
Id and Key are simple strings.
Which system would you recommend ? Knowing that I'm using Erlang for both gateway and worker
I'm not looking for message passing system like RabbitMQ or anything, since it seems impossible to get a specific key, without retrieving others.