So, I am a rookie in the process of migrating a binding into the new development environment, successfully following @hilbrand tutorial (using Eclipse IDE):
However, as I run the mvn clean install
, I get several errors pointing to a common issue throughout the code (not having issues in previous development environment):
[ERROR] org.openhab.binding.<MyBinding>.<MyJava.java>:[105]
Format should be constant. Use placeholder to reduce the needless cost of parameter construction. see http://www.slf4j.org/faq.html#logging_performance
All problems relate to logger.debug
, showing an example code below:
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
//
//
private final Logger logger = LoggerFactory.getLogger(My.class);
//
//
logger.debug(device.toString());
The error then points to the logger.debug(device.toString());
Any guidance/tips would be appreciated. I also see similar use of logger.debug
from other bindings.