[jbossws-issues] [JBoss JIRA] Created: (JBWS-2662) WebServiceContext injection into WS Provider leads to memory leaks

Sergey Graschenko (JIRA) jira-events at lists.jboss.org
Fri May 29 11:58:56 EDT 2009


WebServiceContext injection into WS Provider leads to memory leaks
------------------------------------------------------------------

                 Key: JBWS-2662
                 URL: https://jira.jboss.org/jira/browse/JBWS-2662
             Project: JBoss Web Services
          Issue Type: Bug
      Security Level: Public (Everyone can see)
          Components: jbossws-native
    Affects Versions: jbossws-native-3.0.5
         Environment: Debian Linux 2.6.18-4-686, Java HotSpot(TM) Server VM (build 14.0-b13, mixed mode), JBoss AS 5.0.1.GA

            Reporter: Sergey Graschenko


JBoss AS going out of memory after a few hrs of mild load (~100 request/minute) having the following code

@WebServiceProvider(serviceName = "SampleService", portName = "SamplePort", wsdlLocation = "WEB-INF/wsdl/sample.wsdl")
@BindingType(value = HTTPBinding.HTTP_BINDING)
@ServiceMode(value = Service.Mode.PAYLOAD)
public class SampleProvider extends AbstractServiceProvider implements Provider<Source> {

  @Resource(type = Object.class)
  protected WebServiceContext wsContext;
  
  public Source invoke(Source req) {
    MessageContext mc = wsContext.getMessageContext();
    String path = ((String) mc.get(MessageContext.PATH_INFO)).substring(1);

    JAXBSource result;
    //
    // whatever
    //
    return result;
  }
}

As I mentioned in referenced forum thread, if I set wsContext to null after use, memory leak goes away.


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jbossws-issues mailing list