Redis itself is an in-memory database, and the data will be loaded into the memory, and the data will be updated to the disk according to the customized persistence strategy. So you don’t have to worry about disk IO caused by a large number of DML operations
It depends on the specific business. You can cache only the ID of a single piece of data in the list, and then you don’t need to worry about the update. When deleting a single piece of data, there must be a mechanism to delete the piece of data in the list cache, and the deletion operation should be infrequent. If so, you can delete them all.
Redis itself is an in-memory database, and the data will be loaded into the memory, and the data will be updated to the disk according to the customized persistence strategy.
So you don’t have to worry about disk IO caused by a large number of DML operations
It depends on the specific business.
You can cache only the ID of a single piece of data in the list, and then you don’t need to worry about the update.
When deleting a single piece of data, there must be a mechanism to delete the piece of data in the list cache, and the deletion operation should be infrequent. If so, you can delete them all.