如何配置redis缓存服务器来存储和管理应用程序中的缓存数据? [英] How to configure redis cache server to store and manage cached data in our application?

查看:421
本文介绍了如何配置redis缓存服务器来存储和管理应用程序中的缓存数据?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我阅读了很多博客文章和文档。但我无法继续进行redis实施。



我尝试了什么:



我已在本地安装了redis。在servicestack驱动程序的帮助下,使用c#代码中的web api插入数据和检索数据。

我想配置redis服务器来缓存数据并对其进行管理。

由于我是新手,我不知道它,也没有在网上发现任何帖子。

如果你可以帮助我,请提供一些链接或解释。这将是非常有用的。

解决方案

要管理缓存数据,我们必须指定配置参数及其值。

redis的一个例子。 conf文件可在 redislink 中找到



当redis用作缓存服务器时,它使用近似LRU(最近最少使用)技术来驱逐缓存数据。

数据可以通过使用任何7个t来逐出他支持LRU的驱逐政策。

LRU缓存



我们可以通过使用TTL(离开时间)设置钥匙的时间。



欲了解更多信息,请参阅:

Link1

链路2

I read through many blog posts and documentation . But am unable to proceed further with redis implementation.

What I have tried:

I have installed redis locally .Inserted data and retrieved data using web api in c# code with help of servicestack drivers.
I want to configure the redis server to cache the data and manage it.
Since i am new to this i have no idea about it and found no posts regarding on web.
If you could help me out , please provide some links or explain .It would be of great help.

解决方案

To manage cached data we must specify configuration parameter and its values.
An example of redis.conf file is available in redislink

When redis is used as a cache server, it uses an approximated LRU(Least Recently Used)technique to evict cached data.
Data can be evicted by using any 7 of the supported eviction policies of LRU.
LRU cache

We can set time for a key to evict by using TTL(time to leave).

For more information refer:
Link1
Link2


这篇关于如何配置redis缓存服务器来存储和管理应用程序中的缓存数据?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆