1
A
답변
2
3
나는 어떤 MVC 프레임 워크는 데이터베이스에 연결하는 기대하지 않을 것이다. 모델을 구현하면 어떤 백업 저장소 (직접 또는 하나 이상의 계층을 통해)가 적절했는지에 대한 액세스가 제공됩니다. Redis가 지원하는 clients을보고 있어야하며 지원 클라이언트 플랫폼에서 MVC 프레임 워크를 사용할 수 있어야합니다.
1
cqrs architecture with event sourcing을 조사해보십시오. 그리고 github에서 예제를 다운로드 할 수 있습니다. Redit DB가있는 Ruby on Rails 응용 프로그램입니다.
0
grails는 redis 플러그인을 통해 GORM에서 redis를 지원합니다. 모든 도메인 클래스는 관계형 데이터베이스 대신 redis (또는 지원되는 다른 nosql 저장소 중 하나)에 저장할 수 있습니다.
1
확실히 C# ServiceStack.Redis 클라이언트를 확인해야합니다. 클라이언트는 그것으로 구축 된 미니 clone of Stack Overflow이 only one page of C#을 사용하고있어 모든 유형과 다른 높은 수준의 기능, 즉 강력한 형식의 메시징 API, 트랜잭션 지원, 파이프 라인 등이 여기에
를 저장할 수있는 입력 된 API를 제공합니다
레디 스에 StackOverflow에서샘플 코드 : 대부가에 대한
public User GetOrCreateUser(User user)
{
if (user.DisplayName.IsNullOrEmpty())
throw new ArgumentNullException("DisplayName");
var userIdAliasKey = "id:User:DisplayName:" + user.DisplayName.ToLower();
using (var redis = RedisManager.GetClient())
{
//Get a typed version of redis client that works with <User>
var redisUsers = redis.As<User>();
//Find user by DisplayName if exists
var userKey = redis.GetValue(userIdAliasKey);
if (userKey != null)
return redisUsers.GetValue(userKey);
//Generate Id for New User
if (user.Id == default(long))
user.Id = redisUsers.GetNextSequence();
redisUsers.Store(user);
//Save reference to User key using the DisplayName alias
redis.SetEntry(userIdAliasKey, user.CreateUrn());
return redisUsers.GetById(user.Id);
}
}
3
파이썬 세계에는 옴에 의해 영감을 얻은 리 디스코가 있습니다. – Shekhar
이것이 OP의 질문에 어떻게 대답합니까? – Lazarus
Padrino는 MVC 프레임 워크입니다. 데이터베이스로 Redis를 사용하는 ORM 인 Ohm과 함께 사용할 수 있습니다. – seppo0010