hash형태 수정및 다음 작업 메모 추가
This commit is contained in:
parent
cc08ad8126
commit
d2e5617198
|
|
@ -16,7 +16,9 @@ namespace Server.Service
|
||||||
|
|
||||||
public override string Process()
|
public override string Process()
|
||||||
{
|
{
|
||||||
|
//string uniqueSessionId = Guid.NewGuid().ToString(); 이러한 형태를 사용해 key값을 저장
|
||||||
|
//서버에서 데이터를 받아 user의 데이터들을 redis에 저장
|
||||||
|
//이러한 형태로 세션을 관리.
|
||||||
User user;
|
User user;
|
||||||
bool newUser = false;
|
bool newUser = false;
|
||||||
#region 로그인
|
#region 로그인
|
||||||
|
|
|
||||||
|
|
@ -193,7 +193,7 @@ namespace Server.System
|
||||||
SetHash(item.Key, item.Value, keys);
|
SetHash(item.Key, item.Value, keys);
|
||||||
}
|
}
|
||||||
|
|
||||||
public Dictionary<string, object> GetHash(params string[] keys)
|
public Dictionary<string, object> GetAllHash(params string[] keys)
|
||||||
{
|
{
|
||||||
Dictionary<string, object> hash = new Dictionary<string, object>();
|
Dictionary<string, object> hash = new Dictionary<string, object>();
|
||||||
if (local)
|
if (local)
|
||||||
|
|
@ -211,6 +211,17 @@ namespace Server.System
|
||||||
return hash;
|
return hash;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public object GetHash(string field ,params string[] keys)
|
||||||
|
{
|
||||||
|
if (local)
|
||||||
|
{
|
||||||
|
Dictionary<string, string> hashs = new Dictionary<string, string>(hashType[KeySet(keys)]);
|
||||||
|
return hashs[field];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
return db.HashGet(KeySet(keys), field);
|
||||||
|
}
|
||||||
|
|
||||||
private string KeySet(string[] keys)
|
private string KeySet(string[] keys)
|
||||||
{
|
{
|
||||||
return string.Join(":", keys);
|
return string.Join(":", keys);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue