ParamsAndSecretsLogLevel
- class aws_cdk.aws_lambda.ParamsAndSecretsLogLevel(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)
Bases:
Enum
Logging levels for the Parametes and Secrets Extension.
- ExampleMetadata:
infused
Example:
import aws_cdk.aws_secretsmanager as sm import aws_cdk.aws_ssm as ssm secret = sm.Secret(self, "Secret") parameter = ssm.StringParameter(self, "Parameter", parameter_name="mySsmParameterName", string_value="mySsmParameterValue" ) params_and_secrets = lambda_.ParamsAndSecretsLayerVersion.from_version(lambda_.ParamsAndSecretsVersions.V1_0_103, cache_size=500, log_level=lambda_.ParamsAndSecretsLogLevel.DEBUG ) lambda_function = lambda_.Function(self, "MyFunction", runtime=lambda_.Runtime.NODEJS_18_X, handler="index.handler", architecture=lambda_.Architecture.ARM_64, code=lambda_.Code.from_asset(path.join(__dirname, "lambda-handler")), params_and_secrets=params_and_secrets ) secret.grant_read(lambda_function) parameter.grant_read(lambda_function)
Attributes
- DEBUG
Debug.
- ERROR
Error.
- INFO
Info.
- NONE
No logging.
- WARN
Warn.