13.4.3 Enable Logs for MicroTx Node.js Library

By default, logging is enabled for the MicroTx Coordinator and Java applications that use the MicroTx client library. However, for Node.js applications that use the MicroTx client libraries, you must enable logging.

In the tmm.properties file, where you have provided values to configure the MicroTx library, specify values for the following properties to enable logging for the Node.js application:
  1. Set oracle.tmm.EnableDebugLogs as true.
    The default value is false. If you set this value to false, MicroTx client libraries logs messages only when there is an error.
  2. Set oracle.tmm.enableLogTimestamp as true if you want the the time stamp to be displayed in YYYY-MM-DD HH:MM:SS.SSS format.
    The default value is false, so the time stamp is not displayed by default.

You can also provide these configuration values as environment variables. Note that if you specify values in both the tmm.properties file as well as the environment variables, then the values set in the environment variables override the values in the properties file.

The following example provides sample values to configure the environment variables.

export ENABLE_DEBUG_LOGS=true
export ENABLE_LOG_TIMESTAMP=true

Note that the environment variables names are case-sensitive.