Setting the Dgraph Gateway log level

Use the bdd-admin script with the set-log-levels command to set the log level for the Dgraph Gateway.

The WebLogic logger for Dgraph Gateway is configured with the type of information written to log files, by specifying the log level. When you specify the type, WebLogic returns all messages of that type, as well as the messages that have a higher severity. For example, if you set the message type to WARNING, WebLogic also returns messages of type ERROR and INCIDENT_ERROR.

The ENDECA_SERVER_LOG_LEVEL property in bdd.conf sets the log level for the Dgraph Gateway at start-up time. The set-log-levels command lets you change the current log-level setting. This change can be persisted for subsequent re-starts of the Dgraph Gateway.

The set-log-levels command syntax is:
./bdd-admin.sh set-log-levels --component gateway --level <level> [--non-persistent]
where:
  • --component (abbreviated -c) specifies gateway as the component to be modified.
  • --level (abbreviated -l) specifies the new log level. level is one of these log levels:
    • INCIDENT_ERROR
    • ERROR
    • WARNING
    • NOTIFICATION
    • TRACE
The new log level may persist into the next Dgraph Gateway re-start, depending on whether the command's --non-persistent option is used:
  • If --non-persistent is used, the change will not persist into the next Dgraph Gateway re-start, at which time the log level in the ENDECA_SERVER_LOG_LEVEL property is used.
  • If --non-persistent is omitted, the new setting is persisted by being written to the ENDECA_SERVER_LOG_LEVEL property in bdd.conf. This means that the next Dgraph Gateway re-start will use the changed the log level in the bdd.conf file.

For additional usage information, see set-log-levels.

To set the Dgraph Gateway log level:

  1. Navigate to the $BDD_HOME/BDD_manager/bin directory.
  2. Run the bdd-admin script with the set-log-levels command. For example:
    ./bdd-admin.sh set-log-levels --component gateway --level WARNING

Note that the set-log-levels command cannot change the setting of the log4j.logger.org.apache.zookeeper package. For information on setting this package, see Changing the ZooKeeper client log level.