Closed
Description
I'm geting an exception during an integration test where my Lambda function accepts a ScheduledEvent. When I set a value for "time", I get the following exception:
An error occurred during JSON parsing: java.lang.RuntimeException
java.lang.RuntimeException: An error occurred during JSON parsing
Caused by: java.io.UncheckedIOException: com.fasterxml.jackson.databind.JsonMappingException: java.lang.reflect.InvocationTargetException (through reference chain: com.amazonaws.services.lambda.runtime.events.ScheduledEvent["time"])
Caused by: com.fasterxml.jackson.databind.JsonMappingException: java.lang.reflect.InvocationTargetException (through reference chain: com.amazonaws.services.lambda.runtime.events.ScheduledEvent["time"])
at com.fasterxml.jackson.databind.JsonMappingException.wrapWithPath(JsonMappingException.java:210)
at com.fasterxml.jackson.databind.JsonMappingException.wrapWithPath(JsonMappingException.java:177)
at com.fasterxml.jackson.databind.deser.BeanDeserializerBase.wrapAndThrow(BeanDeserializerBase.java:1474)
at com.fasterxml.jackson.databind.deser.BeanDeserializer.vanillaDeserialize(BeanDeserializer.java:260)
at com.fasterxml.jackson.databind.deser.BeanDeserializer.deserialize(BeanDeserializer.java:125)
at com.fasterxml.jackson.databind.ObjectReader._bindAndClose(ObjectReader.java:1511)
at com.fasterxml.jackson.databind.ObjectReader.readValue(ObjectReader.java:1102)
Caused by: lambdainternal.util.ReflectUtil$ReflectException: java.lang.reflect.InvocationTargetException
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
Caused by: java.lang.NullPointerException
at org.joda.time.format.DateTimeFormatterBuilder$CharacterLiteral.parseInto(DateTimeFormatterBuilder.java:1224)
at org.joda.time.format.DateTimeFormatterBuilder$Composite.parseInto(DateTimeFormatterBuilder.java:2490)
at org.joda.time.format.InternalParserDateTimeParser.parseInto(InternalParserDateTimeParser.java:52)
at org.joda.time.format.DateTimeFormatterBuilder$MatchingParser.parseInto(DateTimeFormatterBuilder.java:2584)
at org.joda.time.format.DateTimeFormatter.parseDateTime(DateTimeFormatter.java:925)
at org.joda.time.DateTime.parse(DateTime.java:160)
at org.joda.time.DateTime.parse(DateTime.java:149)
... 4 more
`