Auditing a project with a remote CommandLine


When auditing a project using a remote CommandLine that doesn't have access to the H2 audit database, a NullPointerException will be returned.



Below is the exception returned while fetching an audit report for a project where a remote CommandLine is used and where the audit database location is not on a shared location:


java.lang.RuntimeException: java.lang.NullPointerException
   at org.talend.commandline.command.ExtensionCommandSwitch.caseExtensionServerCommand(
   at org.talend.commandline.client.command.extension.AbstractExtensionCommandSwitch.doSwitch(
   at org.talend.commandline.command.CommandProcessorSwitch.caseExtensionCommand(
   at org.talend.commandline.client.util.CommandAbstractSwitch.doSwitch(
   at org.talend.commandline.command.CommandConsumer.executeCommand(
   at org.talend.commandline.command.CommandConsumer.execute(
   at org.talend.commandline.mode.ServerCommandLine$
   at Source)
Caused by: java.lang.NullPointerException
   at org.talend.commandline.audit.datasource.HibernateUtils.checkAuditDB(
   at org.talend.commandline.audit.datasource.HibernateUtils.init(
   at org.talend.commandline.audit.TalendAuditSelectMode2.createHibernateSessionFactory(
   at org.talend.commandline.audit.command.PopulateAuditExecuteCommand.execute(
   at org.talend.commandline.command.ExtensionCommandSwitch.caseExtensionServerCommand(
   ... 7 more


With a remote CommandLine, ensure that the H2 audit database location is shared so that both tomcat and commandline can access it.

This error can also be reported if a CommandLine local to TAC is used without enough permissions on the audit database directory.

Ensure that the CommandLine user has sufficient permissions on H2 audit database directory and is able to read and write files.

The exact cause of the error can be found in the .log file of the CommandLine directory available at CMD_LINE/commandline-workspace/.metadata


Documentation suggests using the same user to start the CommandLine and Tomcat: to ensure correct management, make sure to launch Tomcat using the same administrator account as for the CommandLine.


For example: Create an account TISAdmin for both Tomcat and CommandLine.

Version history
Revision #:
9 of 9
Last update:
‎09-29-2018 12:12 AM
Updated by: