INNER CODE UNIT · Python
__init__
aws-samples/aws-health-aware · handler.py:29
def __init__(self, client):
self.client = client
@lru_cache
def get_secret_value(self, *args, **kwargs):
logger.debug(f"Getting secret {kwargs}")
return self.client.get_secret_value(*args, **kwargs)
class AWSApi:
@lru_cache
def client(self, *args, **kwargs):
logger.debug(f"Returning new boto3 client for: {args}")
return boto3.client(*args, **kwargs)
@lru_cache
def resource(self, resource_name):
logger.debug(f"Returning new boto3 resource for: {resource_name}")