‏إظهار الرسائل ذات التسميات Logging. إظهار كافة الرسائل
‏إظهار الرسائل ذات التسميات Logging. إظهار كافة الرسائل

الخميس، 3 ديسمبر 2020

Java Util Logging - Loading logging.properties With Log Levels

1. Overview

In this article, You'll learn how to load and set up the logging.properties file in java using Java Util Logging Library. Basically, Logging api helps to write the application activities and several variables values into a file as per the application.


Basically, The logging concepts works based on the log levels and mainly configuration given inside the logging.properties.


Logs information is displayed based on the log levels propery. If you give log level "debug" then all the info such as debug, info, warn, error and fatal. All log content is written to the log file or console.


Typically, the application log file name will be as "application.log" or "app.log" or "server.log". This file naming convention will be changing from company to company.

Java 8 added easy trick to use Java Logging api instantly. All application uses the log4j api for logging.

Java 8 Util Logging - Loading logging.properties With Log Levels