Logging output to an external file rather than stdout

I have a standalone Camunda set up in WebSphere, so I have the engine and a custom process application. It seems the logging always goes to stdout, even I configure log4j and logback in the custom process application. Could you please tell me where I can configure so that the logging will be outputed to rolling log files in a specific location and I can set logger level as well?

Hi @ginger,

please refer to

https://docs.camunda.org/manual/7.6/user-guide/logging/

Cheers,
Askar

I’ve read it a couple of times and it doesn’t help me. In my understanding, the process engine uses a preconfigured JUL logging in the standalone set up, so I should pass in the logging.properties file via JVM argument, e.g., -Djava.util.logging.config.file=logging.properties, however, it doesn’t work. The setting in the config file is ignored. Did I miss anything or is there anything special about WebSphere?

Hi @ginger,

could you try adding logback-classic as dependency and configure it via logback.xml?

Cheers,
Askar

According to the document, logback is for embedded set up. In embeded set up, I believe I can configure logging in any way I want. But in my case, I’ve standalone Camunda server set up, that means it use pre-configured java util logging (JUL). In websphere, what it means is that I have to configure logger through its admin console and I cannot change logging output file.

As I said earlier, I tried adding logback in custom process application (bpm diagram + listener) but doesn’t work. My question is, can I swap logback library into the process engine shared libraries and replaced the JUL logging library, and put logback.xml (where can I put it?) somewhere to make it work?

I’ve swaped JUL with logback in the shared libraries and add the logback.xml, and it WORKS!!!

Thank you Askar!

1 Like