Open
Description
When using envCreationTime = System.currentTimeMillis();
invocation in the constructor of the Lambda function
I get the finding of type AWS_LAMBDA_SNAP_START_BUG in the category CORRECTNESS.
But I didn't get the same finding invoking one of the following in the consturctor instead:
currentDateTime = LocalDateTime.now(); currentDate = LocalDate.now(); currentTime = LocalTime.now(); currentZonedDateTime = ZonedDateTime.now();
I totally understand that using System.currentTimeMillis() is the simplest way to get the current time in millis , but using java.time.Local* abstractions also belongs the standard sicne Java 8.
Metadata
Metadata
Assignees
Labels
No labels