As a Roblox developer, it is currently too hard/impossible to remove a specific item from a MemoryStoreQueue.
Currently the only way to remove an item from a MemoryStoreQueue is to remove it with a range of items using the string identifier returned by MemoryStoreQueue:ReadAsync(). This increases the likelihood that unimportant items later have to be processed as such. The strongest case for this in my mind right now is matchmaking, which is a case that memory stores are meant to cover.
When a player is added to a matchmaking queue, the only way to remove them from that queue right now is by doing so later when a server processes them. Sadly, there’s no quick and efficient way for any server but the server the player is in to understand if that player is still available. Players may become unavailable for a number of reasons, such as cancelling the join process themselves or leaving the game. In which case, it would be very useful to be able to remove them from the queue then and there.
The only way around this currently is by having the server the available queued players arrive in decide by some arbitrary logic that the queued player who left/cancelled is no longer going to land, and then pulling a new player in making the available players wait longer for their game to start.
If Roblox is able to address this issue, it would improve my development experience because it would allow me more control over my queues and the items I consider to be available or not.
I’ve ran into this problem. Currently there is no way to remove a value from the queue unless it has been read and processed. There are players that leave the matchmaking queue, but they still remain in the queue until the server has successfully processed reading the queue list. This causes unnecessary delays to having a queue system. If players were to re-queue once leaving a queue using a hacky method like yours, they would be in the queue twice, should their first queue not have been processed. While they may retain their original queue spot, they have added themselves at the end of the queue that is yet to be processed, which upon processing will fail since they are no longer actively in a queue.
Bump. My use case for this would be for updating the priority of the queue a player currently has by removing the current one and setting the new priority number. Though of course this would be better if there was a way to update the priority without removing it, but that’s another feature request lol.
My current feed system relies on Queues in order to process, you guessed it, feeds! Which is stored for about 3 days max, and whenever a player reads a single entry from the queue it will be invisible for about 5 minutes or so.
Now the problem arises whenever a player joins in a new server: that server has no way of knowing whether or not the player is already in the queue! It also wont be able to remove the player as the new server also does not know of the Queue ID. (Which can be resolved if I use a MemoryStoreHashmap that stores [userid] = queueid.)
TL;DR: Queue invisibility make feed easier to implement, but no ability to change priority, and if player join new server, new server doesn’t know when player is already in queue, duplicate entry happens