enter image description hereI'm currently facing difficulties adding logger files for a specific Java class in AEM, and I'm unable to obtain the logger object due to missing dependencies. I'm uncertain about the appropriate steps to resolve this within the AEM environment. Can you guide me on how to correctly configure the logger for a specific class, considering the issue with missing logger object dependency?
Follow the following steps
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>{slf4j-version}</version>
</dependency>
import org.slf4j.Logger;
private static final Logger logger = LoggerFactory.getLogger(YourClass.class);
http://localhost:4502/system/console/slinglog
.You can directly inspect the log files in the crx-quickstart/logs directory to view all the logger files present. You can use a text editor or command-line tools to access these logs. Once you locate your logger's created file, you can open it to view the logger messages.