We have two Spring boot applications using the same Elasticsearch database. The queries work fine. But the console of the second spring boot application is always flooded with these warning messages as soon as it boots up. Is there any configuration we are missing, either in the Spring boot app or at Elasticsearch?
2021-02-16 16:15:03.757 INFO 19828 --- [main] o.s.d.e.c.TransportClientFactoryBean: Adding transport node : 127.0.0.1:9300
2021-02-16 16:15:04.760 WARN 19828 --- [ient_boss][T#1]] o.e.transport.TransportService: Transport response handler not found of id [1]
2021-02-16 16:15:04.932 WARN 19828 --- [ient_boss][T#2]] o.e.transport.TransportService: Transport response handler not found of id [3]
2021-02-16 16:15:08.104 WARN 19828 --- [ient_boss][T#7]] o.e.transport.TransportService: Transport response handler not found of id [9]
2021-02-16 16:15:13.232 WARN 19828 --- [ient_boss][T#8]] o.e.transport.TransportService: Transport response handler not found of id [59]
I downloaded the zip from https://activemq.apache.org/components/artemis/download/ and unzipped it. Then I ran
artemis.cmd create broker2
I changed to the bin folder of broker2 and ran
artemis.cmd run
I tried it a lot of time, I restarted several times and tried again, I tried as administrator, I ran netstat -anb and verified nothing is running on port 1883, still the result is always:
D:\apache-artemis-2.15.0\bin\broker2\bin>artemis.cmd run
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by com.sun.xml.bind.v2.runtime.reflect.opt.Injector$1 (file:/D:/apache-artemis-2.15.0/lib/jaxb-impl-2.2.7.jar) to method java.lang.ClassLoader.defineClass(java.lang.String,byte[],int,int)
WARNING: Please consider reporting this to the maintainers of com.sun.xml.bind.v2.runtime.reflect.opt.Injector$1
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
_ _ _
/ \ ____| |_ ___ __ __(_) _____
/ _ \| _ \ __|/ _ \ \/ | |/ __/
/ ___ \ | \/ |_/ __/ |\/| | |\___ \
/_/ \_\| \__\____|_| |_|_|/___ /
Apache ActiveMQ Artemis 2.15.0
Sep. 16, 2020 4:00:07 NACHM. java.lang.System$LoggerFinder lambda$accessProvider$0
WARNING: Failed to instantiate LoggerFinder provider; Using default.
2020-09-16 16:00:07,668 INFO [org.apache.activemq.artemis.integration.bootstrap] AMQ101000: Starting ActiveMQ Artemis Server
2020-09-16 16:00:08,288 INFO [org.apache.activemq.artemis.core.server] AMQ221000: live Message Broker is starting with configuration Broker Configuration (clustered=false,journalDirectory=data/journal,bindingsDirectory=data/bindings,largeMessagesDirectory=data/large-messages,pagingDirectory=data/paging)
2020-09-16 16:00:08,312 INFO [org.apache.activemq.artemis.core.server] AMQ221013: Using NIO Journal
2020-09-16 16:00:08,343 INFO [org.apache.activemq.artemis.core.server] AMQ221057: Global Max Size is being adjusted to 1/2 of the JVM max size (-Xmx). being defined as 536.870.912
2020-09-16 16:00:08,363 INFO [org.apache.activemq.artemis.core.server] AMQ221043: Protocol module found: [artemis-server]. Adding protocol support for: CORE
2020-09-16 16:00:08,365 INFO [org.apache.activemq.artemis.core.server] AMQ221043: Protocol module found: [artemis-amqp-protocol]. Adding protocol support for: AMQP
2020-09-16 16:00:08,366 INFO [org.apache.activemq.artemis.core.server] AMQ221043: Protocol module found: [artemis-hornetq-protocol]. Adding protocol support for: HORNETQ
2020-09-16 16:00:08,367 INFO [org.apache.activemq.artemis.core.server] AMQ221043: Protocol module found: [artemis-mqtt-protocol]. Adding protocol support for: MQTT
2020-09-16 16:00:08,367 INFO [org.apache.activemq.artemis.core.server] AMQ221043: Protocol module found: [artemis-openwire-protocol]. Adding protocol support for: OPENWIRE
2020-09-16 16:00:08,368 INFO [org.apache.activemq.artemis.core.server] AMQ221043: Protocol module found: [artemis-stomp-protocol]. Adding protocol support for: STOMP
2020-09-16 16:00:08,438 INFO [org.apache.activemq.artemis.core.server] AMQ221034: Waiting indefinitely to obtain live lock
2020-09-16 16:00:08,439 INFO [org.apache.activemq.artemis.core.server] AMQ221035: Live Server Obtained live lock
2020-09-16 16:00:09,607 INFO [org.apache.activemq.artemis.core.server] AMQ221080: Deploying address DLQ supporting [ANYCAST]
2020-09-16 16:00:09,669 INFO [org.apache.activemq.artemis.core.server] AMQ221003: Deploying ANYCAST queue DLQ on address DLQ
2020-09-16 16:00:09,750 INFO [org.apache.activemq.artemis.core.server] AMQ221080: Deploying address ExpiryQueue supporting [ANYCAST]
2020-09-16 16:00:09,774 INFO [org.apache.activemq.artemis.core.server] AMQ221003: Deploying ANYCAST queue ExpiryQueue on address ExpiryQueue
2020-09-16 16:00:10,542 INFO [org.apache.activemq.artemis.core.server] AMQ221020: Started NIO Acceptor at 0.0.0.0:61616 for protocols [CORE,MQTT,AMQP,STOMP,HORNETQ,OPENWIRE]
2020-09-16 16:00:10,553 INFO [org.apache.activemq.artemis.core.server] AMQ221020: Started NIO Acceptor at 0.0.0.0:5445 for protocols [HORNETQ,STOMP]
2020-09-16 16:00:10,564 INFO [org.apache.activemq.artemis.core.server] AMQ221020: Started NIO Acceptor at 0.0.0.0:5672 for protocols [AMQP]
2020-09-16 16:00:10,581 ERROR [org.apache.activemq.artemis.core.server] AMQ224104: Error starting the Acceptor mqtt {scheme=tcp, tcpReceiveBufferSize=1048576, port=1883, host=0.0.0.0, protocols=MQTT, useEpoll=true, tcpSendBufferSize=1048576}
2020-09-16 16:00:10,581 ERROR [org.apache.activemq.artemis.core.server] AMQ224000: Failure in initialisation: java.lang.IllegalStateException: AMQ229230: Failed to bind acceptor mqtt to 0.0.0.0:1883
at org.apache.activemq.artemis.core.remoting.impl.netty.NettyAcceptor.startServerChannels(NettyAcceptor.java:688) [artemis-server-2.15.0.jar:2.15.0]
at org.apache.activemq.artemis.core.remoting.impl.netty.NettyAcceptor.start(NettyAcceptor.java:456) [artemis-server-2.15.0.jar:2.15.0]
at org.apache.activemq.artemis.core.remoting.server.impl.RemotingServiceImpl.startAcceptors(RemotingServiceImpl.java:313) [artemis-server-2.15.0.jar:2.15.0]
at org.apache.activemq.artemis.core.server.impl.ActiveMQServerImpl.completeActivation(ActiveMQServerImpl.java:3090) [artemis-server-2.15.0.jar:2.15.0]
at org.apache.activemq.artemis.core.server.impl.LiveOnlyActivation.run(LiveOnlyActivation.java:78) [artemis-server-2.15.0.jar:2.15.0]
at org.apache.activemq.artemis.core.server.impl.ActiveMQServerImpl.internalStart(ActiveMQServerImpl.java:603) [artemis-server-2.15.0.jar:2.15.0]
at org.apache.activemq.artemis.core.server.impl.ActiveMQServerImpl.start(ActiveMQServerImpl.java:530) [artemis-server-2.15.0.jar:2.15.0]
at org.apache.activemq.artemis.integration.FileBroker.start(FileBroker.java:61) [artemis-cli-2.15.0.jar:2.15.0]
at org.apache.activemq.artemis.cli.commands.Run.execute(Run.java:90) [artemis-cli-2.15.0.jar:2.15.0]
at org.apache.activemq.artemis.cli.Artemis.internalExecute(Artemis.java:153) [artemis-cli-2.15.0.jar:2.15.0]
at org.apache.activemq.artemis.cli.Artemis.execute(Artemis.java:101) [artemis-cli-2.15.0.jar:2.15.0]
at org.apache.activemq.artemis.cli.Artemis.execute(Artemis.java:128) [artemis-cli-2.15.0.jar:2.15.0]
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [java.base:]
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) [java.base:]
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [java.base:]
at java.base/java.lang.reflect.Method.invoke(Method.java:567) [java.base:]
at org.apache.activemq.artemis.boot.Artemis.execute(Artemis.java:134) [artemis-boot.jar:2.15.0]
at org.apache.activemq.artemis.boot.Artemis.main(Artemis.java:50) [artemis-boot.jar:2.15.0]
Caused by: java.net.BindException: Address already in use: bind
at java.base/sun.nio.ch.Net.bind0(Native Method) [java.base:]
at java.base/sun.nio.ch.Net.bind(Net.java:455) [java.base:]
at java.base/sun.nio.ch.Net.bind(Net.java:447) [java.base:]
at java.base/sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:219) [java.base:]
at io.netty.channel.socket.nio.NioServerSocketChannel.doBind(NioServerSocketChannel.java:134) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannel$AbstractUnsafe.bind(AbstractChannel.java:550) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.DefaultChannelPipeline$HeadContext.bind(DefaultChannelPipeline.java:1334) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeBind(AbstractChannelHandlerContext.java:506) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.bind(AbstractChannelHandlerContext.java:491) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.DefaultChannelPipeline.bind(DefaultChannelPipeline.java:973) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannel.bind(AbstractChannel.java:248) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.bootstrap.AbstractBootstrap$2.run(AbstractBootstrap.java:356) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:164) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:472) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:500) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at org.apache.activemq.artemis.utils.ActiveMQThreadFactory$1.run(ActiveMQThreadFactory.java:118) [artemis-commons-2.15.0.jar:2.15.0]
2020-09-16 16:00:10,586 INFO [org.apache.activemq.artemis.core.server] AMQ221001: Apache ActiveMQ Artemis Message Broker version 2.15.0 [0.0.0.0, nodeID=edecc73f-f824-11ea-bed7-309c236ea6f2]
2020-09-16 16:00:10,857 INFO [org.apache.activemq.hawtio.branding.PluginContextListener] Initialized activemq-branding plugin
2020-09-16 16:00:10,956 INFO [org.apache.activemq.hawtio.plugin.PluginContextListener] Initialized artemis-plugin plugin
2020-09-16 16:00:11,936 INFO [io.hawt.HawtioContextListener] Initialising hawtio services
2020-09-16 16:00:11,961 INFO [io.hawt.system.ConfigManager] Configuration will be discovered via system properties
2020-09-16 16:00:11,962 INFO [io.hawt.jmx.JmxTreeWatcher] Welcome to hawtio 1.5.12 : http://hawt.io/ : Don't cha wish your console was hawt like me? ;-)
2020-09-16 16:00:11,969 INFO [io.hawt.jmx.UploadManager] Using file upload directory: D:\apache-artemis-2.15.0\bin\broker2\tmp\uploads
2020-09-16 16:00:11,982 INFO [io.hawt.web.AuthenticationFilter] Starting hawtio authentication filter, JAAS realm: "activemq" authorized role(s): "amq" role principal classes: "org.apache.activemq.artemis.spi.core.security.jaas.RolePrincipal"
2020-09-16 16:00:12,002 INFO [io.hawt.web.JolokiaConfiguredAgentServlet] Jolokia overridden property: [key=policyLocation, value=file:/D:/apache-artemis-2.15.0/bin/broker2/etc/\jolokia-access.xml]
2020-09-16 16:00:12,229 INFO [io.hawt.web.RBACMBeanInvoker] Using MBean [hawtio:type=security,area=jmx,rank=0,name=HawtioDummyJMXSecurity] for role based access control
2020-09-16 16:00:12,629 INFO [io.hawt.system.ProxyWhitelist] Initial proxy whitelist: [localhost, 127.0.0.1, 192.168.180.120, pc10.procheck24.de, 172.17.2.161, pc10.mshome.net]
2020-09-16 16:00:12,783 INFO [org.apache.activemq.artemis] AMQ241001: HTTP Server started at http://localhost:8161
2020-09-16 16:00:12,784 INFO [org.apache.activemq.artemis] AMQ241002: Artemis Jolokia REST API available at http://localhost:8161/console/jolokia
2020-09-16 16:00:12,785 INFO [org.apache.activemq.artemis] AMQ241004: Artemis Console available at http://localhost:8161/console
2020-09-16 16:00:13,086 INFO [io.hawt.HawtioContextListener] Destroying hawtio services
2020-09-16 16:00:13,088 INFO [io.hawt.web.AuthenticationFilter] Destroying hawtio authentication filter
2020-09-16 16:00:13,234 INFO [org.apache.activemq.hawtio.plugin.PluginContextListener] Destroyed artemis-plugin plugin
2020-09-16 16:00:13,245 INFO [org.apache.activemq.hawtio.branding.PluginContextListener] Destroyed activemq-branding plugin
2020-09-16 16:00:13,263 INFO [org.apache.activemq.artemis.core.server] AMQ221002: Apache ActiveMQ Artemis Message Broker version 2.15.0 [edecc73f-f824-11ea-bed7-309c236ea6f2] stopped, uptime 5.570 seconds
org.apache.activemq.artemis.component.WebTmpCleaner:Unable to read the logging configuration from 'file:../config/logging.properties' (java.io.FileNotFoundException: ..\config\logging.properties (Das System kann den angegebenen Pfad nicht finden))
What is missing to run a broker on a windows machine?
The root "Caused by" is this:
Caused by: java.net.BindException: Address already in use: bind
at java.base/sun.nio.ch.Net.bind0(Native Method) [java.base:]
at java.base/sun.nio.ch.Net.bind(Net.java:455) [java.base:]
at java.base/sun.nio.ch.Net.bind(Net.java:447) [java.base:]
at java.base/sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:219) [java.base:]
at io.netty.channel.socket.nio.NioServerSocketChannel.doBind(NioServerSocketChannel.java:134) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannel$AbstractUnsafe.bind(AbstractChannel.java:550) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.DefaultChannelPipeline$HeadContext.bind(DefaultChannelPipeline.java:1334) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.invokeBind(AbstractChannelHandlerContext.java:506) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannelHandlerContext.bind(AbstractChannelHandlerContext.java:491) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.DefaultChannelPipeline.bind(DefaultChannelPipeline.java:973) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.AbstractChannel.bind(AbstractChannel.java:248) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.bootstrap.AbstractBootstrap$2.run(AbstractBootstrap.java:356) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:164) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:472) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:500) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) [netty-all-4.1.48.Final.jar:4.1.48.Final]
at org.apache.activemq.artemis.utils.ActiveMQThreadFactory$1.run(ActiveMQThreadFactory.java:118) [artemis-commons-2.15.0.jar:2.15.0]
Here the JVM is working with the OS to bind a server socket to 0.0.0.0:1883. This operation is failing ostensibly because something is already bound to that address & port. This is an environmental issue between the JVM and the OS. It's not something the broker can overcome directly. The only thing you could do from the broker's perspective is to change the port, e.g.:
<acceptor name="mqtt">tcp://0.0.0.0:81883?protocols=MQTT</acceptor>
I have got this problem few times on my development machine (Windows 10).
No application working on port but AMQ could not acquire it.
I have no idea why problem occurred - I could not reproduce it on purpose.
For me restarting Windows has solved the issue.
I has been also trying logging out user as it (I think) it should kill user processes but with no effect.
Maybe there has been some issue with releasing port after improper AMQ closure?
<!-- MQTT Acceptor -->
<acceptor name="mqtt">tcp://0.0.0.0:4785?tcpSendBufferSize=1048576;tcpReceiveBufferSize=1048576;protocols=MQTT;useEpoll=true</acceptor>
I changed the port of MQTT in broker2/etc/broker.xml to a random number and it worked, the broker was able to start. I still have no clue why port 1883 was not accessible (I also tried 1884 and it did not work either).
I am truing to connect to ftp server using sftp but cannot seem to connect.
There is no error in connectivity or credentials
Camel Context.xml
<route>
<from id="_from1" uri="sftp://user#localhost:22/data/test/user?noop=true&password=XXXXXX"/>
<log id="_log1" message="downloading ${file:name}"/>
<to id="_to1" uri="file:ftpclient"/>
</route>
i have added the dependency:
<dependency>
<groupId>org.apache.camel</groupId>
<artifactId>camel-ftp</artifactId>
</dependency>
The logs are as follows:
[ Thread-4] RawBuilder INFO Copy thread finished.
[mel.test.blueprint.Main.main()] Activator INFO Camel activator starting
[mel.test.blueprint.Main.main()] Activator INFO Camel activator started
[ Blueprint Extender: 1] BlueprintContainerImpl INFO Bundle sftp_connect/1.0.0.SNAPSHOT is waiting for namespace handlers [http://camel.apache.org/schema/blueprint]
[ Blueprint Event Dispatcher: 1] BlueprintCamelContext INFO Attempting to start CamelContext: _context1
[ Blueprint Event Dispatcher: 1] BlueprintCamelContext INFO Apache Camel 2.21.0.fuse-710018-redhat-00001 (CamelContext: _context1) is starting
[ Blueprint Event Dispatcher: 1] BlueprintCamelContext INFO StreamCaching is enabled on CamelContext: _context1
[ Blueprint Event Dispatcher: 1] ManagedManagementStrategy INFO JMX is enabled
[ Blueprint Event Dispatcher: 1] DefaultManagementAgent INFO ManagementAgent detected JVM system properties: {org.apache.camel.jmx.createRmiConnector=true}
[KTOP-980NI68:1099/jmxrmi/camel] DefaultManagementAgent INFO JMX Connector thread started and listening at: service:jmx:rmi:///jndi/rmi://DESKTOP-980NI68:1099/jmxrmi/camel
[ Blueprint Event Dispatcher: 1] DefaultStreamCachingStrategy INFO StreamCaching in use with spool directory: C:\Users\Lenovo\AppData\Local\Temp\camel\camel-tmp-81aa83b2-0e29-4496-a4b9-17a9ff951952 and rules: [Spool > 128K body size]
[ Blueprint Event Dispatcher: 1] SftpEndpoint INFO Endpoint is configured with noop=true so forcing endpoint to be idempotent as well
[ Blueprint Event Dispatcher: 1] SftpEndpoint INFO Using default memory based idempotent repository with cache max size: 1000
[ Blueprint Event Dispatcher: 1] SftpOperations INFO Known host file not configured, using user known host file: C:\Users\Lenovo/.ssh/known_hosts
[ Blueprint Event Dispatcher: 1] BlueprintCamelContext INFO Route: _route1 started and consuming from: sftp://user#localhost:/data/test/user?&noop=true&password=xxxxxx
[ Blueprint Event Dispatcher: 1] BlueprintCamelContext INFO Total 1 routes, of which 1 are started
[ Blueprint Event Dispatcher: 1] BlueprintCamelContext INFO Apache Camel 2.21.0.fuse-710018-redhat-00001 (CamelContext: _context1) started in 1.320 seconds
any help would be appreciated.
EDIT:
when I make the JSCH log levels to info it gives:
[ Blueprint Event Dispatcher: 1] SftpOperations INFO JSCH -> Connection established
SFTP camel takes path relative to home/user folder instead of absolute path. Search if this path "data/test/user" is present somewhere in home/user folder, that will be the location it is picking files from. You can always enable debug logging while running the code for better understanding of what is happening. https://camel.apache.org/manual/latest/faq/how-do-i-enable-debug-logging.html
I have a Java EE project that ran with WF-8 w/ HornetMQ:
--- Sever side was deployed as an .ear package.
--- Client side is a Java GUI that communicated with the server via JMS messaging.
It all worked when put away.
I’m trying to resurrect it using WF-10 w/ ArtemisMQ, and it’s killing me.
After clearing all the Exceptions dealing with Hornet -> Artemis, here’s where I am:
--- WF Console confirms gotest.ear deploys with no Exceptions. (Console out put on startup pasted below)
--- Client’s Eclipse console output confirms it has a Connection and that it sent an Object Message. (my formatted output is pasted below)
--- Standalone-full.xml shows the Queue my MDB listens to configured. AND WF browser console double confirms it. (Info on WF’s configuration also pasted below)
But my MDB will not write or log to the WF console at all. I.e. not even from its constructor method. And there is no response at all from it's onMessage () to messages sent from the Client.
I’m helpless, because I don’t get Exceptions anywhere to hint at what’s wrong.
Can anyone point me in the right direction?
Help!!
MDB CODE
(I’ve cut it to the bone until I can get it to write or log to the WF console acknowledging it is hearing messages.)
import javax.annotation.PostConstruct;
import javax.annotation.PreDestroy;
import javax.annotation.Resource;
import javax.ejb.ActivationConfigProperty;
import javax.ejb.MessageDriven;
import javax.ejb.MessageDrivenContext;
import javax.enterprise.context.ApplicationScoped;
import javax.jms.Message;
import javax.jms.MessageListener;
import javax.persistence.Transient;
import org.apache.log4j.Logger;
#MessageDriven(
activationConfig ={
#ActivationConfigProperty(propertyName="destinationType", propertyValue="javax.jms.Queue"),
#ActivationConfigProperty(propertyName="destination", propertyValue="jms/queue/sendToServerQueue"),
#ActivationConfigProperty(propertyName="acknowledgeMode", propertyValue = "Auto-acknowledge"),
})
public class GoMsgBean implements MessageListener {
final Logger logger = Logger.getLogger(GoMsgBean.class.getName());
public GoMsgBean () {
System.out.println("System.out message FROM GoMsgBean Constructor");
logger.info("Logger message FROM GoMsgBean Constructor");
}
#PostConstruct
public void myInit () {
System.out.println("System.out message FROM GoMsgBean PostConstruct");
logger.info("Logger message FROM GoMsgBean PostConstruct");
}
public void onMessage(Message msg) {
System.out.println("System.out message FROM GoMsgBean onMessage()");
logger.info("Logger message FROM GoMsgBean onMessage()");
}
}
STANDALONE-FULL.XML
<subsystem xmlns="urn:jboss:domain:messaging-activemq:1.0">
<server name="default">
. . .
<jms-queue name="ExpiryQueue" entries="java:/jms/queue/ExpiryQueue"/>
<jms-queue name="DLQ" entries="java:/jms/queue/DLQ"/>
<jms-queue name="SendToServerQueue" entries="java:jboss/exported/jms/queue/sendToServerQueue"/>
<jms-queue name="SendToClientQueue2" entries="java:jboss/exported/jms/queue/sendToClientQueue2"/>
. . .
<connection-factory name="RemoteConnectionFactory" entries="java:jboss/exported/jms/RemoteConnectionFactory" connectors="http-connector"/>
<pooled-connection-factory name="activemq-ra" entries="java:/JmsXA java:jboss/DefaultJMSConnectionFactory" connectors="in-vm" transaction="xa"/>
</server>
</subsystem>
WFLY localhost :9990 Console Configuration Details
Queues/Topics
Name: SendToServerQueue
JNDINames: java:jboss/exported/jms/queue/sendToServerQueue
**Durable?: true**
Selector: <blank>
Connection Factories
Name InVmConnectionFactory
JNDI java:/ConnectionFactory
Name: RemoteConnectionFactory
JNDI java:jboss/exported/jms/RemoteConnectionFactory
Security Settings
Pattern #
Role guest
Address Settings
Pattern #
Diverts No Items!
ECLIPSE CONSOLE OUTPUT (when client GUI opens)
(I’ve added an insane number of System.out.printlns to track what’s happening line by line. Each output string is prefaced by the Class.method () that’s writing the line.)
ECLIPSE CONSOLE OUTPUT when Client is opened
MsgCtrSnd.run () beg
MsgCtrSnd.run () Requesting InitialContext
CONNECTION VARIABLES
key: java.naming.provider.url value: http-remoting://localhost:8080
key: java.naming.factory.initial value: org.jboss.naming.remote.client.InitialContextFactory
key: java.naming.security.principal value: jmsUser
key: java.naming.security.credentials value: jmsUser123!
MsgCtrSnd.run () InitialContext OK: javax.naming.InitialContext#4135c3b
MsgCtrSnd.run () Look up ConnectionFactory with: "jms/RemoteConnectionFactory"
MsgCtrSnd.run () ConnectionFactory: Ok:
org.apache.activemq.artemis.jms.client.ActiveMQJMSConnectionFactory
MsgCtrSnd.run () Instantiating Connection
MsgCtrSnd.run () JMS Connection OK:
org.apache.activemq.artemis.jms.client.ActiveMQConnection#4d5d943d
Instantiating Session
MsgCtrSnd.run () JMS Session OK:
ActiveMQSession->ClientSessionImpl
[name=212aa734-90f5-11e7-aa7a-a3fb7876c1f2, username=appUser, closed=false, factory = org.apache.activemq.artemis.core.client.impl.ClientSessionFactoryImpl#2a4fb17b, metaData=(jms-session=,)]#368f2016
MsgCtrSnd.run () Lookup Queue w/ JNDI name: ["jms/queue/sendToServerQueue"]
MsgCtrSnd.run () Queue secured:
ActiveMQQueue[SendToServerQueue]IS NOT NULL
MsgCtrSnd.run () Instantiating Message Producer
MsgCtrSnd.run () Message Producer [IS NOT NULL]
ActiveMQMessageProducer->org.apache.activemq.artemis.core.client.impl.ClientProducerImpl#59474f18
MsgCtrSnd.run () Starting jmsConnection
MsgCtrSnd.run () JMS Send Connection : Ok.
MsgCtrSnd.run () end
ECLIPSE CONOSOLE OUTPUT (when client GUI is used to send message to log in)
Cntrl.executeMenuAction () beg
Cntrl.executeMenuAction () Switching to: Log In
Cntrl.loginSend () beg
Cntrl.loginSend () calling DataDialog.collectData()
Cntrl.loginSend () EntityFieldsCollector ok
Cntrl.loginSend () returned from DataDialog.collectData()
Cntrl.loginSend () EntityFieldsCollector contains 2 entries.
Cntrl.loginSend () key: Member ID: 308486 value: ID
Cntrl.loginSend () key: Member PW 308487 value: PW
Cntrl.loginSend () message center connection ok
MsgCtrSnd.sendMsg () beg
MsgCtrSnd.sendMsg () Action: Log In
MsgCtrSnd.sendMsg () clientHash: aaaaaa
MsgCtrSnd.sendMsg () memberId : ID
MsgCtrSnd.sendMsg () memberPw : PW
MsgCtrSnd.sendMsg () clientUserId : null
MsgCtrSnd.sendMsg () clientUserPw : null
MsgCtrSnd.sendMsg () calling createObjectMessage ()
MsgCtrSnd.sendMsg () ObjectMessage instantiated.
MsgCtrSnd.sendMsg () Object Message object: java.util.ArrayList
MsgCtrSnd.sendMsg () message sent.
MsgCtrSnd.sendMsg () end
Cntrl.loginSend () end
Cntrl.executeMenuAction () end
WILDFLY CONSOLE OUTPUT WHEN GOTEST.EAR IS DEPLOYED ON STARTUP
Calling "C:\ProgramFilesGeo\Wildfly\wildfly-10.1.0.Final\bin\standalone.conf.bat"
Setting JAVA property to "C:\Program Files\Java\jdk1.8.0_121\bin\java"
===============================================================================
JBoss Bootstrap Environment
JBOSS_HOME: "C:\ProgramFilesGeo\Wildfly\wildfly-10.1.0.Final"
JAVA: "C:\Program Files\Java\jdk1.8.0_121\bin\java"
JAVA_OPTS: "-Dprogram.name=standalone.bat -Xms64M -Xmx512M -XX:MetaspaceSize=96M -XX:MaxMetaspaceSize=256m -Djava.net.preferIPv4Stack=true -Djboss.modules.system.pkgs=org.jboss.byteman"
===============================================================================
INFO [org.jboss.modules] (main) JBoss Modules version 1.5.2.Final
INFO [org.jboss.msc] (main) JBoss MSC version 1.2.6.Final
INFO [org.jboss.as] (MSC service thread 1-7) WFLYSRV0049: WildFly Full 10.1.0.Final (WildFly Core 2.2.0.Final) starting
INFO [org.jboss.as.server] (Controller Boot Thread) WFLYSRV0039: Creating http management service using socket-binding (management-http)
INFO [org.xnio] (MSC service thread 1-3) XNIO version 3.4.0.Final
INFO [org.xnio.nio] (MSC service thread 1-3) XNIO NIO Implementation Version 3.4.0.Final
INFO [org.wildfly.iiop.openjdk] (ServerService Thread Pool -- 42) WFLYIIOP0001: Activating IIOP Subsystem
INFO [org.jboss.as.clustering.infinispan] (ServerService Thread Pool -- 41) WFLYCLINF0001: Activating Infinispan subsystem.
INFO [org.jboss.as.jsf] (ServerService Thread Pool -- 48) WFLYJSF0007: Activated the following JSF Implementations: [main]
INFO [org.jboss.as.connector] (MSC service thread 1-4) WFLYJCA0009: Starting JCA Subsystem (WildFly/IronJacamar 1.3.4.Final)
INFO [org.jboss.as.naming] (ServerService Thread Pool -- 52) WFLYNAM0001: Activating Naming Subsystem
INFO [org.jboss.as.webservices] (ServerService Thread Pool -- 62) WFLYWS0002: Activating WebServices Extension
INFO [org.jboss.as.security] (ServerService Thread Pool -- 59) WFLYSEC0002: Activating Security Subsystem
INFO [org.wildfly.extension.io] (ServerService Thread Pool -- 40) WFLYIO001: Worker 'default' has auto-configured to 16 core threads with 128 task threads based on your 8 available processors
INFO [org.jboss.as.security] (MSC service thread 1-7) WFLYSEC0001: Current PicketBox version=4.9.6.Final
INFO [org.wildfly.extension.undertow] (MSC service thread 1-3) WFLYUT0003: Undertow 1.4.0.Final starting
INFO [org.jboss.remoting] (MSC service thread 1-5) JBoss Remoting version 4.0.21.Final
INFO [org.jboss.as.naming] (MSC service thread 1-8) WFLYNAM0003: Starting Naming Service
INFO [org.jboss.as.mail.extension] (MSC service thread 1-8) WFLYMAIL0001: Bound mail session [java:jboss/mail/Default]
INFO [org.jboss.as.connector.subsystems.datasources] (ServerService Thread Pool -- 36) WFLYJCA0004: Deploying JDBC-compliant driver class org.h2.Driver (version 1.3)
INFO [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-7) WFLYJCA0018: Started Driver service with driver-name = h2
INFO [org.jboss.as.connector.subsystems.datasources] (ServerService Thread Pool -- 36) WFLYJCA0005: Deploying non-JDBC-compliant driver class org.mariadb.jdbc.Driver (version 1.5)
INFO [org.jboss.as.connector.deployers.jdbc] (MSC service thread 1-2) WFLYJCA0018: Started Driver service with driver-name = mysql
INFO [org.jboss.as.ejb3] (MSC service thread 1-8) WFLYEJB0481: Strict pool slsb-strict-max-pool is using a max instance size of 128 (per class), which is derived from thread worker pool sizing.
INFO [org.jboss.as.ejb3] (MSC service thread 1-5) WFLYEJB0482: Strict pool mdb-strict-max-pool is using a max instance size of 32 (per class), which is derived from the number of CPUs on this host.
INFO [org.wildfly.extension.undertow] (ServerService Thread Pool -- 61) WFLYUT0014: Creating file handler for path 'C:\ProgramFilesGeo\Wildfly\wildfly-10.1.0.Final/welcome-content' with options [directory-listing: 'false', follow-symlink: 'false', case-sensitive: 'true', safe-symlink-paths: '[]']
INFO [org.wildfly.extension.undertow] (MSC service thread 1-1) WFLYUT0012: Started server default-server.
INFO [org.wildfly.extension.undertow] (MSC service thread 1-5) WFLYUT0018: Host default-host starting
INFO [org.wildfly.extension.undertow] (MSC service thread 1-8) WFLYUT0006: Undertow HTTP listener default listening on 127.0.0.1:8080
INFO [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-8) WFLYJCA0001: Bound data source [java:jboss/datasources/ExampleDS]
INFO [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-1) WFLYJCA0001: Bound data source [java:jboss/jdbc/gotestdb]
INFO [org.jboss.as.connector.subsystems.datasources] (MSC service thread 1-5) WFLYJCA0001: Bound data source [java:jboss/jdbc/tappdb]
INFO [org.wildfly.extension.messaging-activemq] (MSC service thread 1-4) WFLYMSGAMQ0001: AIO wasn't located on this platform, it will fall back to using pure Java NIO.
WARN [org.jboss.as.domain.management.security] (MSC service thread 1-2) WFLYDM0111: Keystore C:\ProgramFilesGeo\Wildfly\wildfly-10.1.0.Final\standalone\configuration\application.keystore not found, it will be auto generated on first use with a self signed certificate for host localhost
INFO [org.jboss.as.server.deployment] (MSC service thread 1-6) WFLYSRV0027: Starting deployment of "GoTest.ear" (runtime-name: "GoTest.ear")
INFO [org.jboss.as.server.deployment.scanner] (MSC service thread 1-1) WFLYDS0013: Started FileSystemDeploymentService for directory C:\ProgramFilesGeo\Wildfly\wildfly-10.1.0.Final\standalone\deployments
INFO [org.wildfly.iiop.openjdk] (MSC service thread 1-3) WFLYIIOP0009: CORBA ORB Service started
INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool -- 64) AMQ221000: live Message Broker is starting with configuration Broker Configuration (clustered=false,journalDirectory=C:\ProgramFilesGeo\Wildfly\wildfly-10.1.0.Final\standalone\data\activemq\journal,bindingsDirectory=C:\ProgramFilesGeo\Wildfly\wildfly-10.1.0.Final\standalone\data\activemq\bindings,largeMessagesDirectory=C:\ProgramFilesGeo\Wildfly\wildfly-10.1.0.Final\standalone\data\activemq\largemessages,pagingDirectory=C:\ProgramFilesGeo\Wildfly\wildfly-10.1.0.Final\standalone\data\activemq\paging)
INFO [org.infinispan.factories.GlobalComponentRegistry] (MSC service thread 1-6) ISPN000128: Infinispan version: Infinispan 'Chakra' 8.2.4.Final
INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool -- 64) AMQ221013: Using NIO Journal
INFO [org.infinispan.configuration.cache.EvictionConfigurationBuilder] (ServerService Thread Pool -- 66) ISPN000152: Passivation configured without an eviction policy being selected. Only manually evicted entities will be passivated.
INFO [org.infinispan.configuration.cache.EvictionConfigurationBuilder] (ServerService Thread Pool -- 72) ISPN000152: Passivation configured without an eviction policy being selected. Only manually evicted entities will be passivated.
INFO [org.infinispan.configuration.cache.EvictionConfigurationBuilder] (ServerService Thread Pool -- 66) ISPN000152: Passivation configured without an eviction policy being selected. Only manually evicted entities will be passivated.
INFO [org.infinispan.configuration.cache.EvictionConfigurationBuilder] (ServerService Thread Pool -- 71) ISPN000152: Passivation configured without an eviction policy being selected. Only manually evicted entities will be passivated.
INFO [org.infinispan.configuration.cache.EvictionConfigurationBuilder] (ServerService Thread Pool -- 72) ISPN000152: Passivation configured without an eviction policy being selected. Only manually evicted entities will be passivated.
INFO [org.infinispan.configuration.cache.EvictionConfigurationBuilder] (ServerService Thread Pool -- 71) ISPN000152: Passivation configured without an eviction policy being selected. Only manually evicted entities will be passivated.
INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) WFLYSRV0207: Starting subdeployment (runtime-name: "GoTest.jar")
INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool -- 64) AMQ221043: Protocol module found: [artemis-server]. Adding protocol support for: CORE
INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool -- 64) AMQ221043: Protocol module found: [artemis-amqp-protocol]. Adding protocol support for: AMQP
INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool -- 64) AMQ221043: Protocol module found: [artemis-hornetq-protocol]. Adding protocol support for: HORNETQ
INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool -- 64) AMQ221043: Protocol module found: [artemis-stomp-protocol]. Adding protocol support for: STOMP
INFO [org.wildfly.extension.undertow] (MSC service thread 1-6) WFLYUT0006: Undertow HTTPS listener https listening on 127.0.0.1:8443
INFO [org.jboss.ws.common.management] (MSC service thread 1-3) JBWS022052: Starting JBossWS 5.1.5.Final (Apache CXF 3.1.6)
INFO [org.jboss.as.jpa] (MSC service thread 1-8) WFLYJPA0002: Read persistence.xml for GoTestDataBase
INFO [org.jboss.as.jpa] (ServerService Thread Pool -- 71) WFLYJPA0010: Starting Persistence Unit (phase 1 of 2) Service 'GoTest.ear/GoTest.jar#GoTestDataBase'
INFO [org.jboss.weld.deployer] (MSC service thread 1-8) WFLYWELD0003: Processing weld deployment GoTest.ear
INFO [org.hibernate.jpa.internal.util.LogHelper] (ServerService Thread Pool -- 71) HHH000204: Processing PersistenceUnitInfo [
name: GoTestDataBase
...]
INFO [org.wildfly.extension.messaging-activemq] (MSC service thread 1-5) WFLYMSGAMQ0016: Registered HTTP upgrade for activemq-remoting protocol handled by http-acceptor acceptor
INFO [org.wildfly.extension.messaging-activemq] (MSC service thread 1-1) WFLYMSGAMQ0016: Registered HTTP upgrade for activemq-remoting protocol handled by http-acceptor acceptor
INFO [org.wildfly.extension.messaging-activemq] (MSC service thread 1-7) WFLYMSGAMQ0016: Registered HTTP upgrade for activemq-remoting protocol handled by http-acceptor-throughput acceptor
INFO [org.wildfly.extension.messaging-activemq] (MSC service thread 1-2) WFLYMSGAMQ0016: Registered HTTP upgrade for activemq-remoting protocol handled by http-acceptor-throughput acceptor
INFO [org.hibernate.validator.internal.util.Version] (MSC service thread 1-8) HV000001: Hibernate Validator 5.2.4.Final
INFO [org.hibernate.Version] (ServerService Thread Pool -- 71) HHH000412: Hibernate Core {5.0.10.Final}
INFO [org.hibernate.cfg.Environment] (ServerService Thread Pool -- 71) HHH000206: hibernate.properties not found
INFO [org.hibernate.cfg.Environment] (ServerService Thread Pool -- 71) HHH000021: Bytecode provider name : javassist
INFO [org.hibernate.annotations.common.Version] (ServerService Thread Pool -- 71) HCANN000001: Hibernate Commons Annotations {5.0.1.Final}
INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool -- 64) AMQ221007: Server is now live
INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool -- 64) AMQ221001: Apache ActiveMQ Artemis Message Broker version 1.1.0.wildfly-017 [nodeID=e2b89808-fdf2-11e6-9f54-3956fe24eb2d]
INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool -- 64) AMQ221003: trying to deploy queue jms.queue.SendToServerQueue
INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool -- 67) AMQ221003: trying to deploy queue jms.queue.DLQ
INFO [org.wildfly.extension.messaging-activemq] (ServerService Thread Pool -- 72) WFLYMSGAMQ0002: Bound messaging object to jndi name java:jboss/exported/jms/RemoteConnectionFactory
INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool -- 70) AMQ221003: trying to deploy queue jms.queue.SendToClientQueue2
INFO [org.wildfly.extension.messaging-activemq] (ServerService Thread Pool -- 65) WFLYMSGAMQ0002: Bound messaging object to jndi name java:/ConnectionFactory
INFO [org.apache.activemq.artemis.core.server] (ServerService Thread Pool -- 66) AMQ221003: trying to deploy queue jms.queue.ExpiryQueue
INFO [org.jboss.weld.deployer] (MSC service thread 1-8) WFLYWELD0003: Processing weld deployment GoTest.jar
INFO [org.jboss.as.ejb3.deployment] (MSC service thread 1-8) WFLYEJB0473: JNDI bindings for session bean named 'EnrollerBean' in deployment unit 'subdeployment "GoTest.jar" of deployment "GoTest.ear"' are as follows:
java:global/GoTest/GoTest/EnrollerBean!org.america3.gotest.server.sessionbeans.EnrollerBean
java:app/GoTest/EnrollerBean!org.america3.gotest.server.sessionbeans.EnrollerBean
java:module/EnrollerBean!org.america3.gotest.server.sessionbeans.EnrollerBean
java:global/GoTest/GoTest/EnrollerBean
java:app/GoTest/EnrollerBean
java:module/EnrollerBean
INFO [org.jboss.as.ejb3.deployment] (MSC service thread 1-8) WFLYEJB0473: JNDI bindings for session bean named 'ExiterBean' in deployment unit 'subdeployment "GoTest.jar" of deployment "GoTest.ear"' are as follows:
java:global/GoTest/GoTest/ExiterBean!org.america3.gotest.server.sessionbeans.ExiterBean
java:app/GoTest/ExiterBean!org.america3.gotest.server.sessionbeans.ExiterBean
java:module/ExiterBean!org.america3.gotest.server.sessionbeans.ExiterBean
java:global/GoTest/GoTest/ExiterBean
java:app/GoTest/ExiterBean
java:module/ExiterBean
INFO [org.jboss.as.ejb3.deployment] (MSC service thread 1-8) WFLYEJB0473: JNDI bindings for session bean named 'LoginerBean' in deployment unit 'subdeployment "GoTest.jar" of deployment "GoTest.ear"' are as follows:
java:global/GoTest/GoTest/LoginerBean!org.america3.gotest.server.sessionbeans.LoginerBean
java:app/GoTest/LoginerBean!org.america3.gotest.server.sessionbeans.LoginerBean
java:module/LoginerBean!org.america3.gotest.server.sessionbeans.LoginerBean
java:global/GoTest/GoTest/LoginerBean
java:app/GoTest/LoginerBean
java:module/LoginerBean
INFO [org.jboss.as.ejb3.deployment] (MSC service thread 1-8) WFLYEJB0473: JNDI bindings for session bean named 'LogouterBean' in deployment unit 'subdeployment "GoTest.jar" of deployment "GoTest.ear"' are as follows:
java:global/GoTest/GoTest/LogouterBean!org.america3.gotest.server.sessionbeans.LogouterBean
java:app/GoTest/LogouterBean!org.america3.gotest.server.sessionbeans.LogouterBean
java:module/LogouterBean!org.america3.gotest.server.sessionbeans.LogouterBean
java:global/GoTest/GoTest/LogouterBean
java:app/GoTest/LogouterBean
java:module/LogouterBean
INFO [org.jboss.as.ejb3.deployment] (MSC service thread 1-8) WFLYEJB0473: JNDI bindings for session bean named 'ReplierBean' in deployment unit 'subdeployment "GoTest.jar" of deployment "GoTest.ear"' are as follows:
java:global/GoTest/GoTest/ReplierBean!org.america3.gotest.server.sessionbeans.ReplierBean
java:app/GoTest/ReplierBean!org.america3.gotest.server.sessionbeans.ReplierBean
java:module/ReplierBean!org.america3.gotest.server.sessionbeans.ReplierBean
java:global/GoTest/GoTest/ReplierBean
java:app/GoTest/ReplierBean
java:module/ReplierBean
INFO [org.jboss.as.connector.deployment] (MSC service thread 1-5) WFLYJCA0007: Registered connection factory java:/JmsXA
INFO [org.apache.activemq.artemis.ra] (MSC service thread 1-5) Resource adaptor started
INFO [org.jboss.as.connector.services.resourceadapters.ResourceAdapterActivatorService$ResourceAdapterActivator] (MSC service thread 1-5) IJ020002: Deployed: file://RaActivatoractivemq-ra
INFO [org.jboss.as.connector.deployment] (MSC service thread 1-4) WFLYJCA0002: Bound JCA ConnectionFactory [java:/JmsXA]
INFO [org.wildfly.extension.messaging-activemq] (MSC service thread 1-2) WFLYMSGAMQ0002: Bound messaging object to jndi name java:jboss/DefaultJMSConnectionFactory
INFO [org.jboss.weld.Version] (MSC service thread 1-8) WELD-000900: 2.3.5 (Final)
INFO [org.infinispan.configuration.cache.EvictionConfigurationBuilder] (ServerService Thread Pool -- 71) ISPN000152: Passivation configured without an eviction policy being selected. Only manually evicted entities will be passivated.
INFO [org.infinispan.configuration.cache.EvictionConfigurationBuilder] (ServerService Thread Pool -- 71) ISPN000152: Passivation configured without an eviction policy being selected. Only manually evicted entities will be passivated.
INFO [org.jboss.as.jpa] (ServerService Thread Pool -- 66) WFLYJPA0010: Starting Persistence Unit (phase 2 of 2) Service 'GoTest.ear/GoTest.jar#GoTestDataBase'
INFO [org.jboss.as.ejb3] (MSC service thread 1-8) WFLYEJB0042: Started message driven bean 'GoMsgBean' with 'activemq-ra.rar' resource adapter
INFO [org.hibernate.dialect.Dialect] (ServerService Thread Pool -- 66) HHH000400: Using dialect: org.hibernate.dialect.MySQL5Dialect
INFO [org.hibernate.envers.boot.internal.EnversServiceImpl] (ServerService Thread Pool -- 66) Envers integration enabled? : true
INFO [org.jboss.as.clustering.infinispan] (ServerService Thread Pool -- 71) WFLYCLINF0002: Started client-mappings cache from ejb container
Member.<init>................................beg
Member.<init>................................Hello World. See! I can Log messages again.
Member.<init>................................end
INFO [org.hibernate.hql.internal.QueryTranslatorFactoryInitiator] (ServerService Thread Pool -- 66) HHH000397: Using ASTQueryTranslatorFactory
INFO [org.jboss.as.server] (ServerService Thread Pool -- 37) WFLYSRV0010: Deployed "GoTest.ear" (runtime-name : "GoTest.ear")
INFO [org.apache.activemq.artemis.ra] (default-threads - 1) AMQ151000: awaiting topic/queue creation jms/queue/sendToServerQueue
INFO [org.jboss.as] (Controller Boot Thread) WFLYSRV0060: Http management interface listening on http://127.0.0.1:9990/management
INFO [org.jboss.as] (Controller Boot Thread) WFLYSRV0051: Admin console listening on http://127.0.0.1:9990
INFO [org.jboss.as] (Controller Boot Thread) WFLYSRV0025: WildFly Full 10.1.0.Final (WildFly Core 2.2.0.Final) started in 5392ms - Started 691 of 931 services (430 services are lazy, passive or on-demand)
WILDFLY CONSOLE OUTPUT AFTER DEPLOYEMENT THAT SEEMS TO BE THE PROBLEM.
Note: the next INFO line says the jms/queue/sendToServerQueue is NOT durable, while WF Console says its configured to be durable)
INFO [org.apache.activemq.artemis.ra] (default-threads - 1) AMQ151001: Attempting to reconnect org.apache.activemq.artemis.ra.inflow.ActiveMQActivationSpec(ra=org.apache.activemq.artemis.ra.ActiveMQResourceAdapter#78712571 destination=jms/queue/sendToServerQueue destinationType=javax.jms.Queue ack=Auto-acknowledge durable=false clientID=null user=null maxSession=15)
This is in reference to J. R. Perkins below concerning whether there was a log4j.xml in the deployment. This is another excerpt from WF’s standalone-full.xml I use for logging if I can ever get my MDB to even write to System.out:
<profile>
<subsystem xmlns="urn:jboss:domain:logging:3.0">
<console-handler name="CONSOLE">
<level name="INFO"/>
<formatter><named-formatter name="COLOR-PATTERN"/></formatter>
</console-handler>
<console-handler name="MY-CONSOLE" autoflush="true">
<formatter><named-formatter name="MY-PATTERN"/></formatter>
<target name="System.out"/>
</console-handler>
<console-handler name="GOTEST-HANDLER">
<level name="INFO"/>
<formatter><named-formatter name="GOTEST-PATTERN"/></formatter>
</console-handler>
. . .
<logger category="org.america3.gotest" use-parent-handlers="false">
<level name="ALL"/>
<handlers><handler name="GOTEST-HANDLER"/></handlers>
</logger>
<logger category="com.arjuna">
<level name="WARN"/>
</logger>
<logger category="org.jboss.as.config">
<level name="DEBUG"/>
</logger>
<logger category="sun.rmi">
<level name="WARN"/>
</logger>
<root-logger>
<level name="INFO"/>
<handlers><handler name="CONSOLE"/><handler name="FILE"/></handlers>
</root-logger>
<formatter name="PATTERN">
<pattern-formatter pattern="%d{yyyy-MM-dd HH:mm:ss,SSS} %-5p [%c] (%t) %s%e%n"/>
</formatter>
<formatter name="COLOR-PATTERN">
<pattern-formatter pattern="%K{level}%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%e%n"/>
</formatter>
<formatter name="MY-PATTERN">
<pattern-formatter pattern="MeMeMe%s%n"/>
</formatter>
<formatter name="GOTEST-PATTERN">
<pattern-formatter pattern="%s%n"/>
</formatter>
</subsystem>
. . .
</profile>
I believe the problem is logged here:
INFO [org.apache.activemq.artemis.ra] (default-threads - 1) AMQ151000: awaiting topic/queue creation jms/queue/sendToServerQueue
In other words, the MDB is not fully activated because it can't find the destination "jms/queue/sendToServerQueue". I believe this is because you haven't defined the JNDI bindings properly (since you've only defined an "exported" entry). Try using this:
<jms-queue name="SendToServerQueue" entries="java:jboss/exported/jms/queue/sendToServerQueue java:/jms/queue/sendToServerQueue"/>
Things to do to diagnose issues like this:
Read the log carefully for helpful information.
Check the consumerCount of the queue from which the MDB is supposed to receive messages. If it's 0 then it means there's a problem with the MDB.
I am facing one strange problem , I am working on one batch application using below tech STACK
Spring (IOC container) , spring batch , Hibernate , camel and Log4J for logging
I have configured log4J for file appender only and my all application logs goes to my log file , but strange thing is that all Camel logs goes to console appender (I have no console apender configured on my log4J properties file)
Spring – Camel Integration is XMl element :
<camelContext xmlns="http://camel.apache.org/schema/spring">
<routeBuilder ref="smtBatchRouter" />
</camelContext>
My Log4J configuration:
log4j.rootLogger=TRACE, file
log4j.logger.org.apache=TRACE
log4j.logger.org.directwebremoting=OFF
log4j.logger.org.hibernate=OFF
log4j.logger.org.springframework=WARN
log4j.appender.file=org.apache.log4j.DailyRollingFileAppender
log4j.appender.file.file=myapp.log
log4j.appender.file.ImmediateFlush=true
log4j.appender.file.bufferedIO=false
log4j.appender.file.DatePattern='.' dd-MM-yyyy
log4j.appender.file.layout=org.apache.log4j.PatternLayout
log4j.appender.file.layout.ConversionPattern=%d [%-15.15t] %-5p %-30.30c{1} - %m%n
log4j.appender.file.threshold=TRACE
Sample Camel Log that I am getting in console :
[main] INFO org.apache.camel.spring.SpringCamelContext - Apache Camel 2.11.0 (CamelContext: camel-1) started in 4.009 seconds
[Camel (camel-1) thread #0 - sftp://xyz.com/smtDataFolder] INFO org.apache.camel.component.file.remote.SftpOperations - JSCH -> Connecting to localhost port 22
[Camel (camel-1) thread #0 - sftp://xyz.com/smtDataFolder] INFO org.apache.camel.component.file.remote.SftpOperations - JSCH -> Connection established
[Camel (camel-1) thread #0 - sftp://xyz.com/smtDataFolder] INFO org.apache.camel.component.file.remote.SftpOperations - JSCH -> Remote version string: SSH-1.99-OpenSSH_4.6
I had the same issue and solved it.
Run your application with the flag:
-Dlog4j.debug
It will add diagnostic information to your console. In my case it was
SLF4J: Class path contains multiple SLF4J bindings.
So I just deleted redundant slf4j-jdk14-1.7.9.jar and left only slf4j-log4j12-1.7.19.jar.