When running a Stateless Webservice EJB, the glassfish domain will leak memory when the WSDL is accessed. The culprit appears to be the "com.sun.ejb.EjbInvocation" object, which does not get garbage collected. It appears that about 183 bytes are being leaked upon each invocation. After some time, this causes the domain to stop functioning due to OutOfMemory exceptions. Regardless of the heap size, this will occur.
I used 'jvisualvm' to monitor the memory and object allocations, and during profiling the EjbInvocation generations grew continuously. This can also be observed by doing the memory sampling, as well, and filtering for 'EjbInvocation'.
To test this, I deployed a simple web service, then ran a script to get the wsdl:
With my domain configuration (default), to 512MB heap space, it died after ~2.5 million 'wget's.