'How to activate Logback's timestamp variables for file names in Dropwizard

I would like to use Logback's uniquely named files feature from my Dropwizard application.

I was hoping to find something in the Dropwizard Configuration Reference for Logging, but it doesn't mention file timestamps or unique name patterns.

It looks like I can wrap up Dropwizard's FileAppenderFactory with my own AppenderFactory implementation and insert a timestamp into the logger configuration... but I'd rather use a technique and implementation that already exists.

  • Is there existing (or planned) support for timestamp elements in the logger context from Dropwizard?
  • Is there existing (or planned) support for a different technique for uniquely naming files from Dropwizard?


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source