AWS: Change Default environment values

I've faced the "The key must start with a letter and can only contain letters, numbers, and underscores." issue in the AWS lambda. So both _HANDLER and spring.cloud.function.definition were not enabled to be added as environment variables. Let me know your thoughts.
This commit is contained in:
pguti778
2021-03-02 22:09:41 -03:00
committed by GitHub
parent ebc7bbd692
commit d8d41cbdcd

View File

@@ -122,7 +122,7 @@ public class CustomRuntimeEventLoop {
}
private static FunctionInvocationWrapper locateFunction(FunctionCatalog functionCatalog, MediaType contentType) {
String handlerName = System.getenv("_HANDLER");
String handlerName = System.getenv("DEFAULT_HANDLER");
FunctionInvocationWrapper function = functionCatalog.lookup(handlerName, contentType.toString());
if (function == null) {
handlerName = System.getenv("spring.cloud.function.definition");