From 1db6e3b3897888da5f8f5e959f0d6b9c8e9c41f3 Mon Sep 17 00:00:00 2001 From: withchao <993506633@qq.com> Date: Mon, 15 Jan 2024 16:33:25 +0800 Subject: [PATCH] feat: local cache --- pkg/common/cachekey/user.go | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 pkg/common/cachekey/user.go diff --git a/pkg/common/cachekey/user.go b/pkg/common/cachekey/user.go new file mode 100644 index 000000000..fbea5168b --- /dev/null +++ b/pkg/common/cachekey/user.go @@ -0,0 +1,14 @@ +package cachekey + +const ( + userInfoKey = "USER_INFO:" + userGlobalRecvMsgOptKey = "USER_GLOBAL_RECV_MSG_OPT_KEY:" +) + +func GetUserInfoKey(userID string) string { + return userInfoKey + userID +} + +func GetUserGlobalRecvMsgOptKey(userID string) string { + return userGlobalRecvMsgOptKey + userID +}