2017-06-06 17 views
0

私はGlassfishサーバー(4.1.2)以降を持っていますthis tutorial私はApache ActiveMQをサーバーに統合しました。その後、私はthis part of the same tutorialに従ってメッセージングのためのスタンドアロンクライアントを開発しました。これで私はlast part of this tutorialの手順に従って、前の手順で使用されたキューをリスンするMessageDrivenBeanを開発しました。JMSブローカへの接続に失敗しました

すべてがうまくコンパイルされました。 ActiveMQも実行されています。私は以下のが私のGFサーバログに記録されたEJBを展開するたびしかし:同じエラーが再接続の試行を30秒ごとに来るので

Info: visiting unvisited references 
Info: visiting unvisited references 
Info: JTS5014: Recoverable JTS instance, serverId = [3700] 
Warning: RAR8000 : The method setDestinationLookup is not present in the class : org.apache.activemq.ra.ActiveMQActivationSpec 
Warning: RAR7097: No setter method present for the property destinationLookup in the class org.apache.activemq.ra.ActiveMQActivationSpec 
Info: 2017-06-06 11:43:00,675 [min-listener(1)] INFO ActiveMQEndpointWorker   - Starting 
Info: 2017-06-06 11:43:00,682 [ad-pool-1; w: 4] INFO ActiveMQEndpointWorker   - Establishing connection to broker [vm://0.0.0.0:6616] 
Info: WELD-000900: 2.2.13 (Final) 
WARN: WELD-001700: Interceptor annotation class javax.ejb.PostActivate not found, interception based on it is not enabled 
WARN: WELD-001700: Interceptor annotation class javax.ejb.PrePassivate not found, interception based on it is not enabled 
WARN: WELD-000411: Observer method [BackedAnnotatedMethod] public org.glassfish.jms.injection.JMSCDIExtension.processAnnotatedType(@Observes ProcessAnnotatedType<Object>) receives events for all annotated types. Consider restricting events using @WithAnnotations or a generic type with bounds. 
WARN: WELD-000411: Observer method [BackedAnnotatedMethod] org.glassfish.sse.impl.ServerSentEventCdiExtension.processAnnotatedType(@Observes ProcessAnnotatedType<Object>, BeanManager) receives events for all annotated types. Consider restricting events using @WithAnnotations or a generic type with bounds. 
WARN: WELD-000411: Observer method [BackedAnnotatedMethod] private org.glassfish.jersey.ext.cdi1x.internal.CdiComponentProvider.processAnnotatedType(@Observes ProcessAnnotatedType<Object>) receives events for all annotated types. Consider restricting events using @WithAnnotations or a generic type with bounds. 
Info: AmdMDB was successfully deployed in 5.290 milliseconds. 
Info: 2017-06-06 11:43:31,695 [ad-pool-1; w: 4] ERROR ActiveMQEndpointWorker   - Failed to connect to broker [vm://0.0.0.0:6616]: Could not create Transport. Reason: java.net.URISyntaxException: Illegal character in scheme name at index 0: 0.0.0.0:6616 
javax.jms.JMSException: Could not create Transport. Reason: java.net.URISyntaxException: Illegal character in scheme name at index 0: 0.0.0.0:6616 
    at org.apache.activemq.util.JMSExceptionSupport.create(JMSExceptionSupport.java:36) 
    at org.apache.activemq.ActiveMQConnectionFactory.createTransport(ActiveMQConnectionFactory.java:260) 
    at org.apache.activemq.ActiveMQConnectionFactory.createActiveMQConnection(ActiveMQConnectionFactory.java:273) 
    at org.apache.activemq.ActiveMQConnectionFactory.createConnection(ActiveMQConnectionFactory.java:194) 
    at org.apache.activemq.ra.ActiveMQResourceAdapter.makeConnection(ActiveMQResourceAdapter.java:132) 
    at org.apache.activemq.ra.ActiveMQEndpointWorker$1.run(ActiveMQEndpointWorker.java:109) 
    at com.sun.enterprise.connectors.work.OneWork.doWork(OneWork.java:107) 
    at com.sun.corba.ee.impl.threadpool.ThreadPoolImpl$WorkerThread.performWork(ThreadPoolImpl.java:497) 
    at com.sun.corba.ee.impl.threadpool.ThreadPoolImpl$WorkerThread.run(ThreadPoolImpl.java:540) 
Caused by: java.net.URISyntaxException: Illegal character in scheme name at index 0: 0.0.0.0:6616 
    at java.net.URI$Parser.fail(URI.java:2848) 
    at java.net.URI$Parser.checkChars(URI.java:3021) 
    at java.net.URI$Parser.checkChar(URI.java:3031) 
    at java.net.URI$Parser.parse(URI.java:3047) 
    at java.net.URI.<init>(URI.java:588) 
    at org.apache.activemq.util.URISupport.parseComposite(URISupport.java:390) 
    at org.apache.activemq.util.URISupport.parseComposite(URISupport.java:279) 
    at org.apache.activemq.transport.vm.VMTransportFactory.doCompositeConnect(VMTransportFactory.java:63) 
    at org.apache.activemq.transport.vm.VMTransportFactory.doConnect(VMTransportFactory.java:54) 
    at org.apache.activemq.transport.TransportFactory.connect(TransportFactory.java:64) 
    at org.apache.activemq.ActiveMQConnectionFactory.createTransport(ActiveMQConnectionFactory.java:258) 
    ... 7 more 
Info: 2017-06-06 11:43:31,697 [ad-pool-1; w: 4] ERROR ActiveMQEndpointWorker   - Endpoint will try to reconnect to the JMS broker in 30 seconds 
Info: 2017-06-06 11:43:40,060 [jb-thread-pool1] INFO ActiveMQEndpointWorker   - Stopping 

エンドで停止は、私がやったアンデプロイメントによるものです。

エラーがどこにあるのかよく分かりません。ポートは6616ですが、タイプミスではありません。ポート61616が別のプロセスで使用されているため、ActiveMQが実行されている実際のポートです。

私は間違いをどこで検索するのかヒントを教えてください。

ところで、スタンドアロンクライアントでキューにメッセージを送信しても、例外はスローされません(これは動作しているようです)。しかし、ActiveMQ管理コンソールからメッセージを送信することもできません。サーバー。 ActiveMQのVM tranportを使用した場合

おかげでたくさん...

答えて

1

http://activemq.apache.org/vm-transport-reference.htmlによると、それは ":// VM" の後にブローカーの名前でなければなりません。

の場合はこの方法で設定ファイル、IPアドレスとポートを使用したい:助け

vm:(broker:(tcp://localhost:6000)?persistent=false)?marshal=false 
+0

オーケー感謝を。これで、ログに 'Broker [vm:broker:(tcp://0.0.0.0))]]への接続が正常に確立されたことが伝えられます。私はメッセージを受け取ります。あなたは生き方です:) –

+0

activemq管理コンソールからサーバログにメッセージが届くまで約1分待たなければならない理由はありますか? –

+0

@FabianSchneider正常ではないようです。しかし、私はなぜ今1分遅れているのか理解できません。多分いくつかの非常に詳細な理由。 – Solo

関連する問題