I am using log4j2 and slf4j in my project & using maven for the build. I am using the following pom file (releveant dependencies shown only) but I am getting the error
I think your first pom.xml is correct, (dependency is correct), maybe config file location is wrong
pom.xml
org.slf4j slf4j-api 1.7.25 org.apache.logging.log4j log4j-api 2.7 org.apache.logging.log4j log4j-core 2.7