You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Stefano Mazzocchi <st...@apache.org> on 2000/09/12 23:16:57 UTC

Getting jiggy with it...

Another weird bug... this time IBM JDK 1.3 on Linux.

vaio:/code/build/tomcat-4.0 # ./bin/catalina.sh run
local (stream): org/apache/catalina/core/LocalStrings.properties
org/apache/catalina/core/LocalStrings.properties: found
local (stream): org/apache/catalina/core/LocalStrings_en.properties
system (stream): org/apache/catalina/core/LocalStrings_en.properties
org/apache/catalina/core/LocalStrings_en.properties: not found
local (stream): org/apache/catalina/core/LocalStrings_en_US.properties
system (stream): org/apache/catalina/core/LocalStrings_en_US.properties
org/apache/catalina/core/LocalStrings_en_US.properties: not found
local (stream):
org/apache/catalina/connector/http/LocalStrings.properties
org/apache/catalina/connector/http/LocalStrings.properties: found
local (stream):
org/apache/catalina/connector/http/LocalStrings_en.properties
system (stream):
rg/apache/catalina/connector/http/LocalStrings_en.properties
org/apache/catalina/connector/http/LocalStrings_en.properties: not found
local (stream):
org/apache/catalina/connector/http/LocalStrings_en_US.properties
system (stream):
org/apache/catalina/connector/http/LocalStrings_en_US.properties
org/apache/catalina/connector/http/LocalStrings_en_US.properties: not
found
ERROR reading /code/build/tomcat-4.0/conf/server.xml
At Line 3 /Server/Connector/
className=org.apache.catalina.connector.http.HttpConnector port=8000
minProcessors=5 maxProcessors=75 acceptCount=10 debug=0

Catalina.start: java.util.MissingResourceException: Can't find bundle
for base name org.apache.catalina.connector.http.LocalStrings, locale
en_US
java.util.MissingResourceException: Can't find bundle for base name
org.apache.catalina.connector.http.LocalStrings, locale en_US
         at java.lang.Throwable.<init>(Throwable.java:96)
         at java.lang.Exception.<init>(Exception.java:44)
         at java.lang.RuntimeException.<init>(RuntimeException.java:49)
         at
java.util.MissingResourceException.<init>(MissingResourceException.java:31)
         at
java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java:695
         at
java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:667)
         at java.util.ResourceBundle.getBundle(ResourceBundle.java:534)
         at
org.apache.catalina.util.StringManager.<init>(StringManager.java:115)
         at
org.apache.catalina.util.StringManager.getManager(StringManager.java:260)
         at
org.apache.catalina.connector.http.HttpConnector.<init>(HttpConnector.java:219)
         at java.lang.Class.newInstance0(Native Method)
         at java.lang.Class.newInstance(Class.java:254)
         at
org.apache.catalina.util.xml.ObjectCreate.start(XmlMapper.java:578
         at
org.apache.catalina.util.xml.XmlMapper.matchStart(XmlMapper.java:384)
         at
org.apache.catalina.util.xml.XmlMapper.startElement(XmlMapper.java:81)
         at com.sun.xml.parser.Parser.maybeElement(Parser.java:1391)
         at com.sun.xml.parser.Parser.content(Parser.java:1499)
         at com.sun.xml.parser.Parser.maybeElement(Parser.java:1400)
         at com.sun.xml.parser.Parser.parseInternal(Parser.java:492)
         at com.sun.xml.parser.Parser.parse(Parser.java:284)
         at javax.xml.parsers.SAXParser.parse(SAXParser.java:155)
         at javax.xml.parsers.SAXParser.parse(SAXParser.java:126)
         at
org.apache.catalina.util.xml.XmlMapper.readXml(XmlMapper.java:214)
         at
org.apache.catalina.startup.Catalina.start(Catalina.java:518)
         at
org.apache.catalina.startup.Catalina.execute(Catalina.java:502)
         at
org.apache.catalina.startup.Catalina.process(Catalina.java:160)
         at java.lang.reflect.Method.invoke(Native Method)
         at
org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:135)

The first lines are given to my own logging code in FileClassLoader
where I change

    public InputStream getResourceAsStream(String name) {

with

    public InputStream getResourceAsStream(String name) {
InputStream s = getResourceAsStreamNext(name);
System.out.println(name + ": " + ((s != null) ? "found" : "not found"));
return s; }
public InputStream getResourceAsStreamNext(String name) {


and from the lines above it tells you that it DOES find the requested
resource (in fact, the previous resource boundle is loaded ok)

But the most interesting thing is at the line 667 of
java.util.ResourceBoundle (the point where the exception is generated)

            //We should never get here unless there has been a change
            //to the code that doesn't catch it's own exceptions.
            cleanUpConstructionList();
            throwMissingResourceException(baseName, locale);

Now, since I don't have a JDK 1.2 for Linux, I can't really tell if this
is a bug in JDK 1.3 or a problem with Catalina's classloader. But still,
this is pretty nasty indeed and I don't even know what's happening into
ResourceBoundle since the exception is swallen by the catch and not
passed on.

Shit, this might be the first time in my long Java experience I need to
use a stupid debugger... damn... getting all this lined up if getting
too hard... on windows, at least, I could run Catalina...

I try to switch to Linux, you see?, but Linux just doesn't seem to like
me :)

-- 
Stefano Mazzocchi      One must still have chaos in oneself to be
                          able to give birth to a dancing star.
<st...@apache.org>                             Friedrich Nietzsche
--------------------------------------------------------------------
 Missed us in Orlando? Make it up with ApacheCON Europe in London!
------------------------- http://ApacheCon.Com ---------------------


Re: Getting jiggy with it...

Posted by Stefano Mazzocchi <st...@apache.org>.
Giacomo Pati wrote:

> > Shit, this might be the first time in my long Java experience I need to
> > use a stupid debugger... damn... getting all this lined up if getting
> > too hard... on windows, at least, I could run Catalina...
> 
> If you say Catalina you mean tomcat-4.0 or tomcat-3.x/proposal/catalina?

Sorry, I mean tomcat-4.0 (craig, you should remove the
tomcat-3.x/proposal/catalina stuff to avoid confusion ASAP)
 
> > I try to switch to Linux, you see?, but Linux just doesn't seem to like
> > me :)
> 
> I don't think it Linux that doesn't likes you. I recall having the same
> problem with jdk 1.3 and switched back to 1.2.2 :)

Did you try Sun's JDK 1.3 for linux?

-- 
Stefano Mazzocchi      One must still have chaos in oneself to be
                          able to give birth to a dancing star.
<st...@apache.org>                             Friedrich Nietzsche
--------------------------------------------------------------------
 Missed us in Orlando? Make it up with ApacheCON Europe in London!
------------------------- http://ApacheCon.Com ---------------------



Re: Getting jiggy with it...

Posted by Giacomo Pati <Gi...@pwr.ch>.

Stefano Mazzocchi schrieb:
> 
> Another weird bug... this time IBM JDK 1.3 on Linux.
> 
> vaio:/code/build/tomcat-4.0 # ./bin/catalina.sh run
> local (stream): org/apache/catalina/core/LocalStrings.properties
> org/apache/catalina/core/LocalStrings.properties: found
> local (stream): org/apache/catalina/core/LocalStrings_en.properties
> system (stream): org/apache/catalina/core/LocalStrings_en.properties
> org/apache/catalina/core/LocalStrings_en.properties: not found
> local (stream): org/apache/catalina/core/LocalStrings_en_US.properties
> system (stream): org/apache/catalina/core/LocalStrings_en_US.properties
> org/apache/catalina/core/LocalStrings_en_US.properties: not found
> local (stream):
> org/apache/catalina/connector/http/LocalStrings.properties
> org/apache/catalina/connector/http/LocalStrings.properties: found
> local (stream):
> org/apache/catalina/connector/http/LocalStrings_en.properties
> system (stream):
> rg/apache/catalina/connector/http/LocalStrings_en.properties
> org/apache/catalina/connector/http/LocalStrings_en.properties: not found
> local (stream):
> org/apache/catalina/connector/http/LocalStrings_en_US.properties
> system (stream):
> org/apache/catalina/connector/http/LocalStrings_en_US.properties
> org/apache/catalina/connector/http/LocalStrings_en_US.properties: not
> found
> ERROR reading /code/build/tomcat-4.0/conf/server.xml
> At Line 3 /Server/Connector/
> className=org.apache.catalina.connector.http.HttpConnector port=8000
> minProcessors=5 maxProcessors=75 acceptCount=10 debug=0
> 
> Catalina.start: java.util.MissingResourceException: Can't find bundle
> for base name org.apache.catalina.connector.http.LocalStrings, locale
> en_US
> java.util.MissingResourceException: Can't find bundle for base name
> org.apache.catalina.connector.http.LocalStrings, locale en_US
>          at java.lang.Throwable.<init>(Throwable.java:96)
>          at java.lang.Exception.<init>(Exception.java:44)
>          at java.lang.RuntimeException.<init>(RuntimeException.java:49)
>          at
> java.util.MissingResourceException.<init>(MissingResourceException.java:31)
>          at
> java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java:695
>          at
> java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:667)
>          at java.util.ResourceBundle.getBundle(ResourceBundle.java:534)
>          at
> org.apache.catalina.util.StringManager.<init>(StringManager.java:115)
>          at
> org.apache.catalina.util.StringManager.getManager(StringManager.java:260)
>          at
> org.apache.catalina.connector.http.HttpConnector.<init>(HttpConnector.java:219)
>          at java.lang.Class.newInstance0(Native Method)
>          at java.lang.Class.newInstance(Class.java:254)
>          at
> org.apache.catalina.util.xml.ObjectCreate.start(XmlMapper.java:578
>          at
> org.apache.catalina.util.xml.XmlMapper.matchStart(XmlMapper.java:384)
>          at
> org.apache.catalina.util.xml.XmlMapper.startElement(XmlMapper.java:81)
>          at com.sun.xml.parser.Parser.maybeElement(Parser.java:1391)
>          at com.sun.xml.parser.Parser.content(Parser.java:1499)
>          at com.sun.xml.parser.Parser.maybeElement(Parser.java:1400)
>          at com.sun.xml.parser.Parser.parseInternal(Parser.java:492)
>          at com.sun.xml.parser.Parser.parse(Parser.java:284)
>          at javax.xml.parsers.SAXParser.parse(SAXParser.java:155)
>          at javax.xml.parsers.SAXParser.parse(SAXParser.java:126)
>          at
> org.apache.catalina.util.xml.XmlMapper.readXml(XmlMapper.java:214)
>          at
> org.apache.catalina.startup.Catalina.start(Catalina.java:518)
>          at
> org.apache.catalina.startup.Catalina.execute(Catalina.java:502)
>          at
> org.apache.catalina.startup.Catalina.process(Catalina.java:160)
>          at java.lang.reflect.Method.invoke(Native Method)
>          at
> org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:135)
> 
> The first lines are given to my own logging code in FileClassLoader
> where I change
> 
>     public InputStream getResourceAsStream(String name) {
> 
> with
> 
>     public InputStream getResourceAsStream(String name) {
> InputStream s = getResourceAsStreamNext(name);
> System.out.println(name + ": " + ((s != null) ? "found" : "not found"));
> return s; }
> public InputStream getResourceAsStreamNext(String name) {
> 
> and from the lines above it tells you that it DOES find the requested
> resource (in fact, the previous resource boundle is loaded ok)
> 
> But the most interesting thing is at the line 667 of
> java.util.ResourceBoundle (the point where the exception is generated)
> 
>             //We should never get here unless there has been a change
>             //to the code that doesn't catch it's own exceptions.
>             cleanUpConstructionList();
>             throwMissingResourceException(baseName, locale);
> 
> Now, since I don't have a JDK 1.2 for Linux, I can't really tell if this
> is a bug in JDK 1.3 or a problem with Catalina's classloader. But still,
> this is pretty nasty indeed and I don't even know what's happening into
> ResourceBoundle since the exception is swallen by the catch and not
> passed on.
> 
> Shit, this might be the first time in my long Java experience I need to
> use a stupid debugger... damn... getting all this lined up if getting
> too hard... on windows, at least, I could run Catalina...

If you say Catalina you mean tomcat-4.0 or tomcat-3.x/proposal/catalina?

> I try to switch to Linux, you see?, but Linux just doesn't seem to like
> me :)

I don't think it Linux that doesn't likes you. I recall having the same
problem with jdk 1.3 and switched back to 1.2.2 :)

> 
> --
> Stefano Mazzocchi      One must still have chaos in oneself to be
>                           able to give birth to a dancing star.
> <st...@apache.org>                             Friedrich Nietzsche
> --------------------------------------------------------------------
>  Missed us in Orlando? Make it up with ApacheCON Europe in London!
> ------------------------- http://ApacheCon.Com ---------------------

-- 
PWR GmbH, Organisation & Entwicklung      Tel:   +41 (0)1  856 2202
Giacomo Pati, CTO/CEO                     Fax:   +41 (0)1  856 2201
Hintereichenstrasse 7                     Mobil: +41 (0)78 759 7703 
CH-8166 Niederweningen                    Mailto:Giacomo.Pati@pwr.ch 
                                          Web:   http://www.pwr.ch