package Log::Log4perl::Layout::JSON;
$Log::Log4perl::Layout::JSON::VERSION = '0.61';
# ABSTRACT: Layout a log message as a JSON hash, including MDC data
use 5.010;
use strict;
use warnings;
use pare
nt qw(Log::Log4perl::Layout);
use Carp;
use JSON::MaybeXS;
use Log::Log4perl ();
use Log::Log4perl::Layout::PatternLayout;
use Log::Log4perl::Level;
use Scalar::Util qw(blessed);
# TODO
# add eval
use Class::Tiny {
prefix => "",
format_prefix => 0,
codec => sub {
return JSON::MaybeXS->new
->indent(0) # to prevent newlines (and save space)