
[#enabling-logging_{context}]
= Enabling logging

Each {Thorntail} fraction is dependent on the Logging fraction, which means that if you use any {Thorntail} fraction in your application, logging is automatically enabled on the `INFO` level and higher.
If you want to enable logging explicitly, add the Logging fraction to the POM file of your application.

.Prerequisites

* A Maven-based application

.Procedure

. Find the `<dependencies>` section in the `pom.xml` file of your application.
Verify it contains the following coordinates. If it does not, add them.
+
[source,xml]
----
<dependency>
  <groupId>io.thorntail</groupId>
  <artifactId>logging</artifactId>
</dependency>
----

. If you want to log messages of a level other than `INFO`, launch the application while specifying the `thorntail.logging` system property:
+
--
[source,bash]
----
$ mvn thorntail:run -Dthorntail.logging=FINE
----

See the link:https://thorntail.github.io/javadocs/{communityVersion}/apidocs/org/wildfly/swarm/config/logging/Level.html[`org.wildfly.swarm.config.logging.Level`] class for the list of available levels.
--
