Automatically detect idle sageaker endoint

0

Hello, My aim is to detect if the sagemaker endpoint is idle for more than x hours and then delete the endpoint. I will then recreate the endpoint in my first call as part of my architecture. I could not find anyway how i can know from my lambda if the sagemaker endpoint is idle or not. Is there anyway, I can implement the same? Thanks

demandé il y a 2 ans738 vues
3 réponses
1

Hello, you could for example define a CloudWatch alarm to monitor the endpoint Invocations metric (metrics details on this link), so that an amount over a given period under a specific threshold could send a message to an SNS topic. Then you can have a Lambda function automatically triggered to consume that message to perform a specific action on the endpoint

A couple of references from AWS documentation:

AWS
répondu il y a 2 ans
profile pictureAWS
EXPERT
Chris_G
vérifié il y a 2 ans
  • If that answer helps you, please mark that as Accepted Answer

0
  • This only applies to SageMaker studio resources (eg. KernelGateways), in this case, the user is talking about SageMaker Real-time endpoints

0

This use case is better suited for SageMaker Serverless Inference. Serverless Inference is ideal for workloads which have idle periods between traffic spurts and can tolerate cold starts.

You might also consider SageMaker Asynchronous Inference, which enables you to save on costs by autoscaling the instance count to zero when there are no requests to process, so you only pay when your endpoint is processing requests.

AWS
répondu il y a un an

Vous n'êtes pas connecté. Se connecter pour publier une réponse.

Une bonne réponse répond clairement à la question, contient des commentaires constructifs et encourage le développement professionnel de la personne qui pose la question.

Instructions pour répondre aux questions