Dear all,
How can I get the log object? (outside of a specific route)
I have this Dancer2 application that is an interface to a backend.
If I could handover the Dancer2 log object to the backend, it could
write to the same log.
What I would like to do is something like:
use Dancer2;
my $dancer2_log = XXX->get_dancer2_logger;
my $backend_environment = Backend::Env->new({
log => $dancer2_log,
});
get '/' => sub {
my $env = $env;
...
Is it possible to obtain the log object somehow, or do I have
to instantiate Dancer2::Core::Role::Logger myself, and hand it all
the config information myself?
Kind regards,
Arjan.