users@glassfish.java.net

Re: A warning that I can't get rid of

From: Bhavanishankar <bshankar_at_sun.com>
Date: Thu, 10 Feb 2011 23:54:46 +0530

I think it is an issue with the app you have deployed on embedded GlassFish.

Ideally the app should be fixed. But if you desperately want to turn off
the logging, my blog about setting log levels in embedded GlassFish
might be helpful :
http://weblogs.java.net/blog/bhavanishankar/archive/2010/12/14/changing-log-levels-embedded-glassfish

If you are using the embedded maven plugin, please set
MAVEN_OPTS="-Djava.util.logging.config.file=customlogging.properties",
with contents of customlogging.properties as:

handlers= java.util.logging.ConsoleHandler
java.util.logging.ConsoleHandler.level = INFO
javax.enterprise.system.core.classloading.level = OFF

HTH,

_Bhavani.

On 02/10/2011 10:02 PM, Laird Nelson wrote:
> I have java.util.logging turned down to INFO.
>
> Running embedded glassfish 3.1-b41, I am getting thousands upon
> thousands of enormous stack trace printouts in b41 like this:
>
> WARNING: Input stream has been finalized or forced closed without
> being explicitly closed; stream instantiation reported in following
> stack trace
> java.lang.Throwable
> at
> com.sun.enterprise.loader.ASURLClassLoader$SentinelInputStream.<init>(ASURLClassLoader.java:1230)
> at
> com.sun.enterprise.loader.ASURLClassLoader.getResourceAsStream(ASURLClassLoader.java:878)
> at
> org.drools.rule.CompositeClassLoader.getResourceAsStream(CompositeClassLoader.java:86)
> [snip]
>
> Those of you with long memories will recall that I've reported this
> bug many times before, and that various classloader changes had made
> it disappear. It is related to the way that JBoss' Drools gets resources.
>
> Now it's back.
>
> I don't really care at this point; I just want to turn off the warning
> so that if there's an infinite loop somewhere I can find it. :-)
>
> How do I stop embedded Glassfish from logging this warning to the console?
>
> Best,
> Laird