Redis as a NOSQL data store provides a loose sense of transaction. As in a traditional RDBMS, the transaction starts with a BEGIN
and ends with either COMMIT
or ROLLBACK
. All these RDBMS servers are multithreaded, so when a thread locks a resource, it cannot be manipulated by another thread unless and until the lock is released. Redis by default has MULTI
to start and EXEC
to execute the commands. In case of a transaction, the first command is always MULTI
, and after that all the commands are stored, and when EXEC
command is received, all the stored commands are executed in sequence. So inside the hood, once Redis receives the EXEC
command, all the commands are executed as a single isolated operation. Following are the commands that can be used in Redis for transaction:
- Tech Categories
- Best Sellers
- New Releases
- Books
- Videos
- Audiobooks
Tech Categories Popular Audiobooks
- Articles
- Newsletters
- Free Learning
You're reading from Learning Redis
Vinoo Das has 16 years of experience in the software industry and has worked in various domains, such as telecom, banking, payment gateways, information management, and so on. He is highly motivated and loves to work on new and upcoming technologies. He is currently architecting a platform for an information technology giant, which will enable the company to position the platform at an enterprise level as well as a cloud solution.
Read more about Vinoo Das
Unlock this book and the full library FREE for 7 days
Author (1)
Vinoo Das has 16 years of experience in the software industry and has worked in various domains, such as telecom, banking, payment gateways, information management, and so on. He is highly motivated and loves to work on new and upcoming technologies. He is currently architecting a platform for an information technology giant, which will enable the company to position the platform at an enterprise level as well as a cloud solution.
Read more about Vinoo Das