Hey friends, you know Azure Cache for Redis. It's a fully
managed hosting service for Redis, which is an open
source in-memory data structure. It enables you to
create applications on Azure that handle millions of
requests per seconds with sub millisecond latency. Ye is
here to show me how it works, today on Azure Friday.
Hey friends, I'm Scott Hanselman. It's Azure Friday.
I'm here with Ye. Who's going to talk to me about Azure Cache for
Redis. How are you Sir? Good thank you Scott. And thank you
for having me to your show. Yeah, absolutely. You know, I
like scaling things and I love Redis because it is just so fast
and Azure Cache for Redis really lets us have kind of Redis as a
service isn't it? Yes it does. So let's talk about
Redis itself for a moment before we jump into Azure
Cache for Redis. Redis is is an in-memory database
technology.
It's very popular, you know, because it started as an
open source project an over the years. You know it has received
a lot of community adoptions. In fact, you know according to the
StackOverflow Annual developer survey for the last four years
in a row, readers has been ranked as the number one most
loved database. Of all database technologies? Wow, that's great.
Yeah, it's it's pretty remarkable. Now, of course,
database covers a very broad category of technologies. Readus
really is is a key value pair system, so in that sense you
know it does not support the rich query that you typically
expect from product such as SQL Server or Cosmos DB. On the
other hand, you can either.
Scale that on the sequel sequel here, which means typically that
you have to add more cores so that it can handle more
transactions. An that comes at a cost. Putting a cash in front of
that SQL Server and you know, put your common query results
into the cache allows you to off load all the all those
transaction processing from the SQL Server itself an.
You know, again, you know in this particular setup you will
be leveraging the Redis performance so that you can get
to the data that you need for your application. Very, very
quickly. Yeah, I always encourage people to ask
themselves when they say we need real time access to this data.
What does that really mean? Because it's never really real
time, right? Even caching for five or 10 minutes can make all
the difference. And if you're talking about a product catalog
or inventory or something like that where a call to a database
might be very expensive.
Even a short lived cash can make all the difference in scaling.
It's massive, absolutely. In fact, recently we just sponsored
a study through giggle where the typical web application setup
and compared the performance. You know when you only using a
database and scale that database versus using a Redis cache in a
leukocyte pattern. And what we find is that interesting enough.
Yeah, in terms of both throughput and latency, you see
an order of magnitude performance improvement just by
having a cash next to your database. Yeah, in fact you can.
You can actually use less course in your database an and still
achieve those results. Yeah, absolutely. Do you have demo for
me? Actually, before we get to the devil there are couple of
things that I like to point out. Redis is, as I said, is an open
source. That means that you know you can self Redis if you choose
to. Azure Cache for Redis is a fully managed service that
Microsoft provides that really takes care of all the complexity
around managing and scaling Redis for you. It's it's
turnkey, it's it's a service that you know you can. You can
set up an bring into your application. They only within a
few minutes so it's super quick and it's very easy to get
started with an. Also it grows with you along the way.
What are the really neat feature that it gives you? Is the
ability to actually scale out your cache size on the fly so
that when you need a bigger cache you can simply do that
within our service without suffering any countdown.
Historically we have been hosting the open source version
of the readers. Most recently, however, we have struck a
partnership with Redis Labs. Redis Labs is third party
company. They are also the
corporate custodian. For the open source and the main
contributor to that project. Now of course you know being a
commercial company, they also need a way to make money. The so
for that they have a special version of Redis which they have
built on top of open source. But it offers a number of
differentiating features. More of them is to support relative
modules. Rest Modules is a technology that bread slap built
a couple years ago that actually
allows users. To be able to extend the type of data
structures that readers can support. So it's a way to
actually customize the Redis capabilities. With Redis
Enterprise, you have a way to actually add modules as plugins,
and now as part of our hosted service you can also use module
with Azure Cache for Redis and you know we yeah we believe that
you know this. This opens up a number of new possibilities for
our customers. So yeah, like I had asked the naive question
about serializing Jason Obj.
Yes, but now by opening it up to new data types and more
sophisticated data types, that's going to be more powerful for
enterprises and it will turn it into much more than a
distributed hash table. Absolutely, that way you know,
as you said, customers can choose what additional data
types that they they want to be able to store in Redis. So I
have a quick demo here to show you cool. This demo illustrates
Redis Enterprise running as part
of our. Offerings here we're going to see is the familiar
Azure portal and what I have here is a view that the filters
to the caches that I have so to provision of Redis enterprise
cash you use the same UI that you would otherwise for the open
source version. So here I simply
come too. Add a cache and of course I'll have to pick
a resource group an give this name.
Anne, I need to choose.
The Azure region that I want to create the caching.
And now when I come to this dropdown will you see are all
the available options that you can have within our service?
Now there are actually two tiers that are built on top of the
Redis Enterprise software. The first one is called the
Enterprise Flash Enterprise. Flashes is interesting in the
sense that he not only uses the DRAM that's available on VM, but
it also memory extend that into any SSD or other type of non
volatile memory that you may have on our VM. So that way you
can actually create.
A much larger cash at a much lower cost, and again, this is
leveraging a proprietary technology that the red slab has
implemented within their soft. The second set are called
Enterprise, so enterprise are also built on the software from
Redis Labs. So Enterprise gives you the ability to have module
support that we talked about earlier along with other
benefits. And of course you also see our current ears that are
built on. Top of open source, so for this demo I'm going to pick
one of the newer tears. I'm going to choose the enterprise E
10 skew. So this is a 12 gigabyte cache in a replicated
configuration there actually fans across multiple
availability zones so that you can get 49 SLA. You know with
this particular set up an all that configuration is done for
you automatically. The other thing I want to point out
quickly is that.
In a very first we have actually integrated with the Azure
marketplace as a way for customers to acquire an
purchase. The Redis Labs software. This way we have a way
to integrate the billing directly into these new
offerings, so the terms that you see down here. This actually
comes from the marketplace because again, you know this is
third party software and we want to make sure that the customers
are consenting to use this
software. So I'm going to say
yes. Next, you have a couple of options for connecting to two
disk cache. You can use a public endpoint, which means that
you'll be routing traffic through the Internet. Now in
that case, by default we secure the traffic using using TLS. You
also have the option to create a
private endpoint. This is using the Azure Private Link
technology which allows you to securely connect your custom
virtual network to be there on our site using a secure
tunnel. Now for the purpose of this demo I'm going to stay
with the public endpoint.
Anne next on the Advanced tab. This is actually where you can
select which of the custom module that you wanted to
install with this particular cache. So for the purpose of
this demo because I'm actually going to use Redis as a search
engine, I'm going to choose the reader search option. Also just
to speed up the demo set up, I'm going to also allow non TLS
traffic to this. Again, you know even in this case.
In a post GIS, an Nokia as options are available on the
cash from the application side you can decide how you
want to connect to you.
I'm going to skip tags and then finally I come to the review and
create. So here you can look at everything that has been
configured for this particular cash. If you're happy with this
configuration, then you simply hit create an off. We go so one
of the first thing it's going to do is it's going to actually
reach out to the marketplace and acquire the proper license to
use the Redis Labs software. So
when. When you get to this screen, that step has already
succeeded. Now it is in the process of actually provision of
cash. Now creating a cash does take a few minutes. So what I'm
going to do is I'm going to actually switch to a cash that
we have already set up for this demo. So here I have another
instance of the Redis Enterprise cash, same size, same setup for
the demo. What I'm going to show you is as a web application
that's. Built on top of the Java Spring boot as as a back end as
well as Angular as as a front end. So in this case what we we
were using is the web application connecting to the
Redis server as a data store. So for the Spring boot application
what we're doing is that we're actually hosting that on a brand
new service from Azure. This is the Azure spring cloud.
Which is another managed service for running spring applications,
so I'm going to show you what that looks like very, very
quickly. So here what I have are all the different resources that
I have created for the purpose of this application an what you
see here is the spring cloud service. I have an application
that has already been deployed for this demo.
And here what I want to show you very quickly is that this is
actually a demo application that we have published on GitHub as
an open source an you can run this application in any spring
environment connecting to your readers and what's really neat
about. You know this entire setup is that to make this same
application work with our managed service, all you have to
do is to provide the special endpoint through our service.
And you can do that. In fact, through the standard
environments that's recommended for running these applications.
So what I have here are configuration settings for the
Redis host as well as secrets that's needed to access their
host. And again, all these are configured and passing through
the environment variables and of course with Sprint you can also
set up your own configuration server to achieve the same
thing, and if I may ask.
Worth pointing out of course that read it supports any
language, there's libraries for everything you're doing. A demo
in Java and spring, but certainly C Sharp or Python or
PHP. Whatever Redis is is non denominational in ITS support
for languages. Absolutely, there's actually a rich
community around Redis clients and at this point there are some
three dozen different clients for different languages. OK, so
even within each language you have your choice of.
A client library to use, so I'm going to just switch back to the
to the demo so this is the demo application running again out of
the spring cloud, connecting to Redis and what you see here is a
simple page where in this case this is a beer application. We
have collected a large catalog of the different bit producers,
so to look up a beer producer
near me. All I have to do is simply type in a search query.
And what this is going to do is that it's actually issuing a
search command to the Redis server and the Redis server in
this case will look up the search keywords and return all
the results to the web application. So here I have just
typing logger and as you can see
it. Has found you know many many choices and one things that you
probably notice is you know how quickly it is able to to bring
up this page. So as you can see, you know this comes up in in
less than 100 milliseconds, which is really, really fast for
this many results. Yeah, it's basically just right there. The
data is actually closer to the user, which is another great
thing. If you've got a slower database. If you've got a high
latency database, Redis can turn
that into. Sub millisecond results absolutely. So here it
is and the Redis Labs partnership is all available to
us now in preview. Is that correct? That's right, so this
is available to anybody. Anybody was in Azure subscription to try
out. Very cool and as a fan of the feature myself, I also want
to point out to folks that there's the enterprise SKU and
you saw you know many, many, many gigabytes sized reddish cat
is available. But for regular folks or small businesses like
myself, there are also smaller
ones so. It is for everyone. There's a slider ball that goes
all the way up to cash everything or even cash small
amounts so it read it and Redis Cache for Azure is for everyone.
Absolutely fantastic. I am learning all about how to scale
my cloud app with Azure cache for Redis today on Azure Friday.
Hey, thanks for watching this episode of Azure Friday. Now I
need you to like it. Comment on it, tell your friends, retweet
it. Watch more Azure Friday.