org.jgroups.protocols.UDP - 未能将消息发送到 null
[hannel,192.168.0.46:40014] 15:08:03,642 - ERROR - org.jgroups.protocols.UDP - failed sending message to null (61 bytes)
java.lang.Exception: dest=/225.1.2.46:30446 (64 bytes)
at org.jgroups.protocols.UDP._send(UDP.java:333)
at org.jgroups.protocols.UDP.sendToAllMembers(UDP.java:283)
at org.jgroups.protocols.TP.doSend(TP.java:1327)
at org.jgroups.protocols.TP.send(TP.java:1317)
at org.jgroups.protocols.TP.down(TP.java:1038)
at org.jgroups.protocols.PING.sendMcastDiscoveryRequest(PING.java:220)
at org.jgroups.protocols.PING.sendGetMembersRequest(PING.java:214)
at org.jgroups.protocols.Discovery$PingSenderTask$1.run(Discovery.java:385)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:417)
at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:280)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:135)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:65)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:142)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:166)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
at java.lang.Thread.run(Thread.java:595)
Caused by: java.io.InterruptedIOException: operation interrupted
at java.net.PlainDatagramSocketImpl.send(Native Method)
at java.net.DatagramSocket.send(DatagramSocket.java:612)
at org.jgroups.protocols.UDP._send(UDP.java:324)
... 16 more
这是在服务器上进行负载测试期间发生的。 我应该担心吗? 除了在日志中获取该消息之外,一切似乎都正常。
[hannel,192.168.0.46:40014] 15:08:03,642 - ERROR - org.jgroups.protocols.UDP - failed sending message to null (61 bytes)
java.lang.Exception: dest=/225.1.2.46:30446 (64 bytes)
at org.jgroups.protocols.UDP._send(UDP.java:333)
at org.jgroups.protocols.UDP.sendToAllMembers(UDP.java:283)
at org.jgroups.protocols.TP.doSend(TP.java:1327)
at org.jgroups.protocols.TP.send(TP.java:1317)
at org.jgroups.protocols.TP.down(TP.java:1038)
at org.jgroups.protocols.PING.sendMcastDiscoveryRequest(PING.java:220)
at org.jgroups.protocols.PING.sendGetMembersRequest(PING.java:214)
at org.jgroups.protocols.Discovery$PingSenderTask$1.run(Discovery.java:385)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:417)
at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:280)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:135)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:65)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:142)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:166)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675)
at java.lang.Thread.run(Thread.java:595)
Caused by: java.io.InterruptedIOException: operation interrupted
at java.net.PlainDatagramSocketImpl.send(Native Method)
at java.net.DatagramSocket.send(DatagramSocket.java:612)
at org.jgroups.protocols.UDP._send(UDP.java:324)
... 16 more
This is happening during load testing on the server. Should I worry about it. Aside from getting that message in the log, everything seem to work OK.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
响应 matt b,“无法将消息发送到 null”消息具有误导性。 真正的问题是 InterruptedIOException。 这意味着有人在发送 UDP 的线程上调用了interrupt()。 中断很可能是在 JGroups 内生成的。 (除非您启动然后停止了 JGroups 通道。)
查看堆栈跟踪,中断的 I/O 来自 Discovery 协议。 它试图发现其他集群成员。 因此,您的任何消息都不会因该异常而丢失。
我们必须了解更多才能真正解决这个问题。
In response to matt b, the "failed sending message to null" message is misleading. The true problem is the InterruptedIOException. This means that someone called interrupt() on the Thread that was sending UDP. Most likely, the interrupt is generated within JGroups. (Unless you started, and then stopped the JGroups channel.)
Looking at the stack trace, the interrupted I/O was from a Discovery protocol. It was trying to discover other cluster members. Thus, no message of yours was lost from this Exception.
We would have to know more to really figure this one out.
发送到“null”意味着发送到整个集群,而不是发送消息到单个成员。 我同意,这有点误导,所以我在以后的版本中对此进行了更改:IIRC“null”被替换为“cluster”或“group”。
这里的“null”指的是目的地:空的目的地地址意味着发送到整个集群。
InterruptedIOException 来自发送者线程被 JGroups 停止; 例如,当我们在发现阶段已经有足够的响应返回时,就会发生这种情况,因此发送任务停止(即中断)。
在 JGroups 的更高版本中也修复了这个问题。
贝拉
Sending to "null" means sending to the entire cluster, versus sending a message to a single member. I agree, this is a bit misleading, so I changed this in later version: IIRC "null" was replaced to with "cluster" or "group".
"null" here referred to the destination: a null destination address means send to the entire cluster.
The InterruptedIOException comes from the sender thread being stopped by JGroups; this happens for example when we already have enough responses in the discovery phase to return, and so the send task is stopped (ie., interrupted).
This was also fixed in later versions of JGroups.
Bela
您是否可能因为向“null”发送消息而收到错误?
否则,如果没有代码示例、网络信息、问题发生的具体情况等,其他人可能很难帮助您解决问题。
Is it possible you are getting an error because you are sending a message to "null"?
Otherwise this is probably pretty hard for anyone else to help you out with without code samples, information on your network, the specific situation where your problem occurs, etc.