What are the main differences between Redis Pub/Sub and Redis Stream?
问题 What are the pros and cons of each? Please advice when to use one and not the other. 回答1: Data storage Pub/Sub is a Publisher/Subscriber platform, it's not data storage. Published messages evaporate, regardless if there was any subscriber. In Redis Streams, stream is a data type, a data structure on its own right. Messages or entries are stored in memory and stay there until commanded to be deleted. Sync/Async communication Pub/Sub is synchronous communication. All parties need to be active