java - How to use log4j2 JMSAppender with ActiveMQ -
i struggling write simple poc program logs messages queue. tutorials , q&as find ( here , here ) use log4j version 1.2 , put messages onto topic , not onto queue. requirement log queue. i followed documentation mentioned on official site , not able working. i have log4j2 , activemq jars on classpath, have created queue "logqueue", able see queue in activemq web console , when try execute program write logs, following error: error error creating jmsmanager using connectionfactory [connectionfactory] , destination [logqueue]. javax.naming.noinitialcontextexception: need specify class name in environment or system property, or applet parameter, or in application resource file: java.naming.factory.initial @ javax.naming.spi.namingmanager.getinitialcontext(namingmanager.java:662) @ javax.naming.initialcontext.getdefaultinitctx(initialcontext.java:313) it looks jndi issue, not able figure out what. per log4j 1.2 tutorials, added jndi.properties file classp...