cloudwatch-logback-appender icon indicating copy to clipboard operation
cloudwatch-logback-appender copied to clipboard

Use shutdown hook to write the remaining events

Open borisbsu opened this issue 2 years ago • 2 comments

Use shutdown hook to write the remaining events to CloudWatch when JVM shuts down.

borisbsu avatar Mar 10 '22 23:03 borisbsu

Thanks for this. I don't like making this a default. Making network connections while the JVM is shutting down seems like something the user can opt into. Maybe add a boolean to the configuration and default it to false?

j256 avatar Mar 11 '22 18:03 j256

@j256 I have added a new flushEventsOnShutdown param to control this behavior.

borisbsu avatar Mar 29 '22 14:03 borisbsu