All Projects → actix → Actix Redis

actix / Actix Redis

Licence: other
Redis actor and middleware for Actix

Programming Languages

rust
11053 projects

Labels

Projects that are alternatives of or similar to Actix Redis

Craftcms Docker
Craft3/Craft2 CMS Docker base (Nginx, PHP-FPM 8, PostgreSQL/MariaDB, Redis)
Stars: ✭ 99 (-4.81%)
Mutual labels:  redis
Springboot Link Admin
Vue Springboot Project | Link Admin后端,适用于小型项目
Stars: ✭ 100 (-3.85%)
Mutual labels:  redis
Seckill
Spring Boot+MySQL+Redis+RabbitMQ的高性能高并发商品秒杀系统设计与优化
Stars: ✭ 103 (-0.96%)
Mutual labels:  redis
Vue Family Bucket Ssr Koa2 Full Stack Development From Meituan
🚀🚀2020最新Vue全家桶+SSR+Koa2全栈开发☁
Stars: ✭ 100 (-3.85%)
Mutual labels:  redis
Perl Redis
Perl binding for Redis database
Stars: ✭ 100 (-3.85%)
Mutual labels:  redis
Bojack
🐴 The unreliable key-value store
Stars: ✭ 101 (-2.88%)
Mutual labels:  redis
Redismock
🕋 Mocking Redis in unit tests in Go.
Stars: ✭ 99 (-4.81%)
Mutual labels:  redis
Emkc
Engineer Man Knowledge Center
Stars: ✭ 104 (+0%)
Mutual labels:  redis
Fastapi cache
FastAPI simple cache
Stars: ✭ 96 (-7.69%)
Mutual labels:  redis
Ohm
Object-Hash Mapping for Redis
Stars: ✭ 1,386 (+1232.69%)
Mutual labels:  redis
Springboot Templates
springboot和dubbo、netty的集成,redis mongodb的nosql模板, kafka rocketmq rabbit的MQ模板, solr solrcloud elasticsearch查询引擎
Stars: ✭ 100 (-3.85%)
Mutual labels:  redis
Foundatio
Pluggable foundation blocks for building distributed apps.
Stars: ✭ 1,365 (+1212.5%)
Mutual labels:  redis
Production Ready Expressjs Server
Express.js server that implements production-ready error handling and logging following latest best practices.
Stars: ✭ 101 (-2.88%)
Mutual labels:  redis
Django Rq
A simple app that provides django integration for RQ (Redis Queue)
Stars: ✭ 1,361 (+1208.65%)
Mutual labels:  redis
Pythonstudy
Python related technologies used in work: crawler, data analysis, timing tasks, RPC, page parsing, decorator, built-in functions, Python objects, multi-threading, multi-process, asynchronous, redis, mongodb, mysql, openstack, etc.
Stars: ✭ 103 (-0.96%)
Mutual labels:  redis
Blog
Welcome to ansheng’s blog!
Stars: ✭ 99 (-4.81%)
Mutual labels:  redis
Redis Cui
Simple, visual command line tool for redis
Stars: ✭ 101 (-2.88%)
Mutual labels:  redis
Spring Boot 2.x Examples
Spring Boot 2.x code examples
Stars: ✭ 104 (+0%)
Mutual labels:  redis
Whatsmars
Java生态研究(Spring Boot + Redis + Dubbo + RocketMQ + Elasticsearch)🔥🔥🔥🔥🔥
Stars: ✭ 1,389 (+1235.58%)
Mutual labels:  redis
Docker Laravel
🐳 Docker Images for Laravel development
Stars: ✭ 101 (-2.88%)
Mutual labels:  redis

Actix redis Build Status codecov crates.io

Redis integration for actix framework.

NOTICE: This repository has been archived. Please visit https://github.com/actix/actix-extras instead.

Documentation

Redis session backend

Use redis as session storage.

You need to pass an address of the redis server and random value to the constructor of RedisSessionBackend. This is private key for cookie session, When this value is changed, all session data is lost.

Note that whatever you write into your session is visible by the user (but not modifiable).

Constructor panics if key length is less than 32 bytes.

use actix_web::{App, HttpServer, web, middleware};
use actix_web::middleware::session::SessionStorage;
use actix_redis::RedisSessionBackend;

#[actix_rt::main]
async fn main() -> std::io::Result {
    HttpServer::new(|| App::new()
        // enable logger
        .middleware(middleware::Logger::default())
        // cookie session middleware
        .middleware(SessionStorage::new(
            RedisSessionBackend::new("127.0.0.1:6379", &[0; 32])
        ))
        // register simple route, handle all methods
        .service(web::resource("/").to(index))
    )
    .bind("0.0.0.0:8080")?
    .start()
    .await
}

License

This project is licensed under either of

at your option.

Code of Conduct

Contribution to the actix-redis crate is organized under the terms of the Contributor Covenant, the maintainer of actix-redis, @fafhrd91, promises to intervene to uphold that code of conduct.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].