Skip to content

Commit

Permalink
adjust log messages and comments with new cache server
Browse files Browse the repository at this point in the history
  • Loading branch information
amirreza8002 committed Nov 3, 2024
1 parent 22ed532 commit 3cf2dbe
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions panther/caching.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ async def set_response_in_cache(*, request: Request, response: Response, cache_e

if cache_exp_time is None:
logger.warning(
'your response are going to cache in redis forever '
'your response are going to cache in server forever '
'** set DEFAULT_CACHE_EXP in `configs` or set the `cache_exp_time` in `@API.get()` to prevent this **'
)
await cache.set(key, cache_data)
Expand All @@ -89,7 +89,7 @@ async def set_response_in_cache(*, request: Request, response: Response, cache_e
caches[key] = cache_data

if cache_exp_time:
logger.info('`cache_exp_time` is not very accurate when `redis` is not connected.')
logger.info('`cache_exp_time` is not very accurate when `redis/valkey` is not connected.')


async def get_throttling_from_cache(request: Request, duration: timedelta) -> int:
Expand Down

0 comments on commit 3cf2dbe

Please sign in to comment.