Search icon CANCEL
Subscription
0
Cart icon
Cart
Close icon
You have no products in your basket yet
Save more on your purchases!
Savings automatically calculated. No voucher code required
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Learning Redis

You're reading from  Learning Redis

Product type Book
Published in Jun 2015
Publisher
ISBN-13 9781783980123
Pages 318 pages
Edition 1st Edition
Languages
Author (1):
Vinoo Das Vinoo Das
Profile icon Vinoo Das
Toc

Client node commands


The following is a list of commands that can be fired from client nodes:

  • The register command

  • The activate command

  • The set command

  • The get command

  • The status command

  • The del command

  • The passivate command

  • The reacyivate command

  • The archive command

  • The sync command

  • The reconnect command

Let's take a look at each command from a design and implementation perspective.

The register command

This command will register the node into the gossip server ecosystem. The precondition for executing this command is that the node name should be unique; otherwise, a response of failure will be sent to the Shell. The node name will be stored in the Registration holder, which is implemented as a Set data structure in Redis. Apart from this, when the registration process takes place, an archive file is created in the local machine of the node.

Sequence of flow of data in a Register command

The syntax for this command is: register. The following screenshot shows the response in the Shell console:

Implementation...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at ₹800/month. Cancel anytime}