Merge pull request #4703 from BerriAI/litellm_only_use_internal_use_cache

[Fix Memory Usage] - only use per request tracking if slack alerting is being used
This commit is contained in:
Ishaan Jaff 2024-07-13 18:40:22 -07:00 committed by GitHub
commit ed5114c680
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -280,6 +280,10 @@ class ProxyLogging:
async def update_request_status(
self, litellm_call_id: str, status: Literal["success", "fail"]
):
# only use this if slack alerting is being used
if self.alerting is None:
return
await self.internal_usage_cache.async_set_cache(
key="request_status:{}".format(litellm_call_id),
value=status,