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:
Learning Redis
By :
Learning Redis
By:
Overview of this book
Table of Contents (16 chapters)
Learning Redis
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Free Chapter
Introduction to NoSQL
Getting Started with Redis
Data Structures and Communicating Protocol in Redis
Functions in the Redis Server
Handling Data in Redis
Redis in Web Applications
Redis in Business Applications
Clustering
Maintaining Redis
Index
Customer Reviews