rmi.transport.tcp.tcptransport Connectionhandler消耗大量CPU [英] rmi.transport.tcp.tcptransport Connectionhandler consumes much CPU

查看:892
本文介绍了rmi.transport.tcp.tcptransport Connectionhandler消耗大量CPU的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在运行第三方RMI-Server应用程序,只提供一种方法(getImage()将图像返回为byte [])。此方法的实现(通过SOAP-WS获取图像)由我提供。

i am running an third party RMI-Server app providing exactly one method ("getImage()" returns an image as byte[]). The implementation of this method (getting the image via a SOAP-WS) is provide by me.

运行此RMI服务器的问题是CPU消耗高(使用jvisualvm测量):65 cpu时间的百分比进入sun.rmi.transport.tcp.TCPTransport $ ConnectionHandler.run()和第二名,15%是 sun.net.www.http.KeepAliveCache.run()。 真正的工作(缩放图像)排在第4位。
服务器在win 2003服务器上运行。我猜资源/连接处理有问题?但这是一个实现问题还是Windows配置问题?

The problem on running this RMI-Server is the high CPU consumption (measured with jvisualvm): 65% of cpu time go into "sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run()" and on second place with 15% is "sun.net.www.http.KeepAliveCache.run()". The "real" work (scaling the image) comes on 4th place. The server is running on win 2003 server. i guess there is something wrong with resource/connection handling?? but is this an implementation problem or a windows configuration-problem?

另一个观察结果是:如果cpu利用率很高,内存利用率也会上升 - 问题是:这是因为gc无法完成其工作或许多图像等待交付。所有我可以说内存用于 byte []

another observation is: if cpu utilization is high the memory utilization goes also up - the question is: is this because the gc can't do its work or many images waiting to be delivered. all i can say the memoryis used for byte[].

所以任何想法该怎么办?

so any ideas what to do?

提前thx

推荐答案

我只能推测字节数组可能是图像,但它可以是任何数量的东西。

I can only speculate that the byte array could be the image but it could be any number of things.

BTW你在运行多核机器吗?我也遇到了这个问题,发现VisualVM指出同样的罪魁祸首是四核Win7机器上CPU利用率约为50%,单核winXP上CPU利用率为100%。我正在为服务器运行Jetty。

BTW are you running a multi core machine? I am also having this problem and found that VisualVM pointed at that same culprit at around 50% CPU utilization on the quad core Win7 machine and 100% on single core winXP. I am running Jetty for the server.

对不起我还不能回答真正的问题,但希望能在这里听到解决方案,或者希望能尽快在这里分享。几个月前你遇到过这个问题,也许你已经找到了一个并且可以分享?

Sorry I can't answer the real question yet, but hope to hear a solution here or to be able to share one here soon. Since you ran into this a few months back maybe you already found one and can share?

这篇关于rmi.transport.tcp.tcptransport Connectionhandler消耗大量CPU的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆