Why won't a module write errors to the logs?

Tags: #<Tag:0x00007f0f1be9cd58> #<Tag:0x00007f0f1be9cc90>

Dear all,

I am working on module radiologydcm4chee and cannot see any log entries written into catalina.out/openmrs.log by the module.

For example in the modules Activator class, logging is set up as follows:

import org.apache.commons.logging.Log;

public class RadiologyActivator extends BaseModuleActivator {
    	
private static final Log log = LogFactory.getLog(RadiologyActivator.class);

I deployed the module in openmrs 1.9.7 and the logging is set to level info.

But I can never write to the log with for example:

log.info("Started MPPSScu : OpenMRS MPPS SCU Client (dcmof)");

The module also uses another logger

org.apache.log4j.Logger;

Could this be an issue? Could you please give me a hint on how to fix this.

Thanks a lot!!

1 Like

Found it.

To spare everyone else the trouble and humiliation, its very simple :grin:

I could not see any log messages from the radiology module since its log level was not specified.

My OpenMRS log settings where:

Settings --> Log, Log Level = “info”

which only sets the api’s log level. To define a log level for the radiology module I had to add:

org.openmrs.api:info, org.openmrs.module.radiology:debug

3 Likes