0

JAXWSを使用してWebサービスを作成し、jboss6でステートレスセッションBeanとしてホストしました。Webサービスコードは次のとおりです。

@Stateless
@WebService(serviceName = "CommonSmsServices", name = "CommonSmsServices", wsdlLocation = "META-INF/wsdl/CommonSmsServices.wsdl", endpointInterface = "com.sms.webservice.common.CommonServices")
public class CommonServicesImpl implements CommonServicesLocal,CommonServicesRemote {
      //.....
      // methods
      //.....

}

This works fine with a single Http session. Now I am facing the problem while running multiple sessions, that the response time becomes very slow. I did YourKit porfiling for memory and threading sampling. Memory utilization look good. but in thread section it shows one htpp thread is waiting for other to complete.

I have also gone through the Java EE session bean documentation. It says session bean are single threaded. Is there a performance issue with session beans that handle multiple Http session concurrently?

Is there a way or configuration in JBoss AS 6 to improve my web service performance?

4

1 に答える 1

1

EJB(ステートレスのものを含む)では、マルチスレッドはコンテナーによってサポートされます。データを個別の呼び出しの間に保存する場合は、代わりにStatefullBeanを使用する必要があります。これはマルチスレッドもサポートします。

于 2012-11-08T11:58:36.413 に答える