CacheKeys.cs 1.8 KB

1234567891011121314151617181920212223242526272829303132
  1. namespace Application.Abstractions.Cache;
  2. public static class CacheKeys
  3. {
  4. public const string Config = "config";
  5. public const string FaqCategoryActive = "faq:category:active";
  6. public const string PopupPositionActive = "popup:position:active";
  7. public static string FaqItemByCode(string code) => $"faq:item:{code}";
  8. public static string PopupByCode(string code) => $"popup:{code}";
  9. public static string BannerByCode(string code) => $"banner:{code}";
  10. public static string DocumentByCode(string code) => $"document:{code}";
  11. public static string BoardMeta(int boardID) => $"board:meta:{boardID}";
  12. public const string CryptoCategoryActive = "crypto:category:active";
  13. public static string CoinBySymbol(string symbol) => $"crypto:coin:{symbol.ToLower()}";
  14. // Crypto Ticker
  15. public const string CryptoTickers = "crypto:tickers";
  16. public static string CryptoTicker(string symbol) => $"crypto:ticker:{symbol.ToLower()}";
  17. public static string CryptoCandle(string symbol, string type) => $"crypto:candle:{symbol.ToLower()}:{type}";
  18. // Crypto REST (초기 로딩용)
  19. public const string CryptoMarkets = "crypto:markets";
  20. public static string CryptoTickerDetail(string symbol) => $"crypto:ticker:detail:{symbol.ToLower()}";
  21. public static string CryptoTrades(string symbol) => $"crypto:trades:{symbol.ToLower()}";
  22. public static string CryptoOrderbook(string symbol) => $"crypto:orderbook:{symbol.ToLower()}";
  23. // Crypto WebSocket Live (실시간용)
  24. public static string CryptoCandleLive(string symbol, string interval) => $"crypto:candle:live:{symbol.ToLower()}:{interval}";
  25. public static string CryptoTradeLive(string symbol) => $"crypto:trade:live:{symbol.ToLower()}";
  26. public static string CryptoOrderbookLive(string symbol) => $"crypto:orderbook:live:{symbol.ToLower()}";
  27. }