0

I'm trying Audit4J (2.4.1) and follow the docs, but my audit4j.conf.yml file seems to be wrong.

I use:

!Configuration
handlers:
- !org.audit4j.core.handler.ConsoleAuditHandler {}
layout: !org.audit4j.core.layout.SimpleLayout
  dateFormat: dd-MM-yyyy HH:mm:ss
metaData: !org.audit4j.core.DummyMetaData {}

This yields the following error:

org.audit4j.core.exception.InitializationException: initialization failed.!!
....
Caused by: org.audit4j.core.exception.ConfigurationException: Configuration Exception
....
Caused by: com.esotericsoftware.yamlbeans.YamlException: Error parsing YAML.
....
Caused by: com.esotericsoftware.yamlbeans.parser.Parser$ParserException: Line 7, column 13: Expected a 'block end' but found: block mapping start

Anyone any idea what's wrong here?

Regards, Gerard

g.verhaag
  • 139
  • 3
  • 11

1 Answers1

0

The correct format is:

layout: !org.audit4j.core.layout.SimpleLayout {
    dateFormat: "dd/MM/yyyy HH:mm:ss"
    }