@Log @Logs,生成一个日志对象. package com.huey.lombok; import lombok.extern.java.Log; @Log public class LogExample { public static void main(String[] args) { log.info("This is an info message."); } } 除了,Log还有其他annotation来封装一些主流的日志类库:@CommonsLogCreates pr
lombok.extern.slf4j 代码: @Slf4j public class LogExample { } 产生以下代码: public class LogExample { private static final org.slf4j.Logger log = org.slf4j.LoggerFactory.getLogger(LogExample.class); } 该注解对类和枚举有效.
Problem How do you determine what SQL query is being executed by Hibernate? How can you see the Hibernate’ internal workings? How do you enable logging to troubleshoot complex issues related to Hibernate? Solution You have to enable Hibernate logging