• Object Storage Service

  1. Help Center
  2. Object Storage Service
  3. Developer Guide (Java SDK)
  4. Initialization
  5. Configuring SDK Logging

Configuring SDK Logging

OBS Java SDK provides the logging function, based on the Apache Log4j2 open library. You can add log configuration files to configure logging based on your needs. The procedure is as follows:

  1. Find the log4j2.xml file in the OBS Java SDK development package.
  2. Save the log4j2.xml file to the classpath root directory.
  3. Modify log levels in the log4j2.xml file based on actual needs.
  • For details about SDK logs, see Log Analysis.
  • The save path of log files is the path represented by JDK system variable user.dir and can be modified in the log4j2.xml file.