Troubleshooting : Using Java Logging (Salesforce) : Configuring Logging : Using the Driver

Using the Driver
If you want to configure logging using the driver, you can use either of the following approaches:
*
*
Use a different properties file for each embedded database. For example, if you have two embedded databases (johnsmith.xxx and pattijohnson.xxx, for example), you can load one properties file for the johnsmith.xxx database and load another properties file for the pattijohnson.xxx database.
Note:
By default, the name of the embedded database is the user ID specified for the connection. You can specify the name of the embedded database using the DatabaseName property. See Connection Properties for details about using the DatabaseName property.
By default, the driver looks for the file named ddlogging.properties in the current working directory to load for all Salesforce connections.
If a properties file is specified for the LogConfigFile connection property, the driver uses the following process to determine which file to load:
1.
2.
If the driver cannot find the file in Step 1, it looks for a properties file named database_name.logging.properties in the directory containing the embedded database for the connection, where database_name is the name of the embedded database.
3.
If the driver cannot find the file in Step 2, it looks for a properties file named ddlogging.properties in the current working directory.
4.
If the driver cannot find the file in Step 3, it abandons its attempt to load a properties file.
If any of these files exist, but the logging initialization fails for some reason while using that file, the driver writes a warning to the standard output (System.out), specifying the name of the properties file being used.
See Connection Properties for details on using the LogConfigFile property.
A sample properties file is installed in the installdir/testforjdbc and installdir/Examples/SforceSamples directories, where installdir is your product installation directory. The file is named ddlogging.properties. You can copy this file from either location to the current working directory of your application or embedded database directory, and modify it using a text editor for your needs.

© 2012 Progress Software Corporation and/or its subsidiaries or affiliates.