Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases now! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Learning Redis

You're reading from   Learning Redis Design efficient web and business solutions with Redis

Arrow left icon
Product type Paperback
Published in Jun 2015
Publisher
ISBN-13 9781783980123
Length 318 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
Vinoo Das Vinoo Das
Author Profile Icon Vinoo Das
Vinoo Das
Arrow right icon
View More author details
Toc

Scripting in Redis


Lua is a high performing scripting language with interpreter written in C. Redis provides mechanism to extend the functionality of Redis by providing support for Lua in the server side. Since Redis is implemented in C, it gives a natural synergy for Lua to be offered along with Redis as a server add on. The Lua interpreter shipped along with Redis is with limited capability and following libraries are shipped along with it:

  • The base library

  • The table library

  • The string library

  • The math library

  • The debug library

  • The cjson library

  • The cmsgpack library

    Note

    Libraries which can do File I/O and Networking are not included, so you cannot send a message from LUA script in REDIS to another external system.

Before we start with fun stuff, it's always better to have a hang of the language. LUA has its own dedicated site and tons of resources are available to LUA, but the next section concentrates on just enough LUA to get started for Redis.

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 €18.99/month. Cancel anytime