You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by "N. Sean Timm" <st...@mailgo.com> on 2000/07/14 14:11:20 UTC

Re: Building Cocoon 2 - warnings, exceptions and errors

Jon Lancelle wrote:
>Should the classpath of a Cocoon2 build include jaxp.jar, parser.jar, or
xml.jar?
You can use any JAXP-compliant parser (such as the latest build of Xerces
which is included in the C2/lib directory), or you can use jaxp.jar and
parser.jar (Sun's implementation).  I'd suggest getting rid of xml.jar from
as many places as possible.  :)

>These  are a few noted anomilies when attempting to get Cocoon 2 latest cvs
download running on a Pentium III running Redhat 6.2 with latest Tomcat
build...

>* Can't build docs.

I'm having problems with this, too.  There were some problems with the
sitemap.xml file which I'll include as a patch in a separate message, but
they still don't seem to build successfully...now I'm getting a duplicate
resource error on sitemap-header.jpg (which I can't seem to find a reference
to anywhere).

>* Keep getting warnings regarding deprecated methods, mostly involving
org.xml.sax... classes when doing the actual build of cocoon.jar

These are SAX1 methods that have been deprecated in SAX2.  I believe someone
was working on getting these out of the code (and did for the most part),
but it looks like FO2PDFSerializer and XalanTransformer still require the
use of the DocumentHandlerWrapper (a wrapper that makes SAX1 look like
SAX2).

>* When trying to access *.xml pages, get this:
...org/apache/cocoon/Cocoon - java.lang.IllegalAccessException:
>org/apache/cocoon/Cocoon...

Not sure on this one...

- Sean T.


Re: Building Cocoon 2 - warnings, exceptions and errors

Posted by Conny Krappatsch <co...@softwarebuero.de>.
N. Sean Timm wrote:
> Jon Lancelle wrote:
> >Should the classpath of a Cocoon2 build include jaxp.jar, parser.jar, or
> xml.jar?
> You can use any JAXP-compliant parser (such as the latest build of Xerces
> which is included in the C2/lib directory), or you can use jaxp.jar and
> parser.jar (Sun's implementation).  I'd suggest getting rid of xml.jar from
> as many places as possible.  :)
> 
> >These  are a few noted anomilies when attempting to get Cocoon 2 latest cvs
> download running on a Pentium III running Redhat 6.2 with latest Tomcat
> build...
> 
> >* Can't build docs.
> 
> I'm having problems with this, too.  There were some problems with the
> sitemap.xml file which I'll include as a patch in a separate message, but
> they still don't seem to build successfully...now I'm getting a duplicate
> resource error on sitemap-header.jpg (which I can't seem to find a reference
> to anywhere).

I encountered this problem, too. I fixed sitemap.xml and I came to the
duplicate resource problem. After digging a bit in the xdoc sources I found
something in doc-book.xml. There are two "page" elements with the id "sitemap".
After removing on of them, everthing worked fine.

Conny

________________________________________________________________
Conny Krappatsch                     conny@softwarebuero.de
SMB GmbH                             http://www.softwarebuero.de


Re: Building Cocoon 2 - warnings, exceptions and errors

Posted by Jon Lancelle <jk...@knosys.com>.
Thanks,

I'll try your suggestions as soon as summer activities have concluded
here...must keep the kids happy!

Jon Lancelle


Berin Loritsch wrote:

> "N. Sean Timm" wrote:
> > >* When trying to access *.xml pages, get this:
> > ...org/apache/cocoon/Cocoon - java.lang.IllegalAccessException:
> > >org/apache/cocoon/Cocoon...
> >
> > Not sure on this one...
>
> Check the permissions of the jar file and the directories it's in.
> UNIX will not allow you access to many files if it was created by
> root and used by another user.
>
> Try 'ls -l' to get the permissions on the jar and surrounding
> directory.  If you get a result that looks like this:
>
> -rwxr-x--- root root  9287532  cocoon.jar
>
> that means that the user 'root' has read/write/execute privilege,
> the group 'root' has read/execute privilege, and nobody else has
> any privilege at all.
>
> Something more useful would be to change it's mode like this:
>
> chmod 755 cocoon.jar
>
> Which still only allows the user and root to delete/modify the
> file, but everyone else can read and execute.
>
> Do that for the surrounding directory too, because sometimes
> you can't read the directory which will also give you the
> IllegalAccessException even if the file itself is OK.
>
> And lastly, did you do _anything_ to the java.policy file?

Re: Building Cocoon 2 - warnings, exceptions and errors

Posted by Giacomo Pati <Gi...@pwr.ch>.
Jon Lancelle wrote:
> 
> Went back to Tomcat 3.1 (not latest build) and am starting to get
> somewhere. Maybe that is the source of the problem below.

No, I don't think ist a Tomcat problem. The Sitemap engine supposes the
components are thread save but as soon as you put your second request to
Cocoon 2 you get that IllegalAccessException from
DocumenthandlerWrapper.

Giacomo

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

Re: Building Cocoon 2 - warnings, exceptions and errors

Posted by Jon Lancelle <jk...@knosys.com>.
Went back to Tomcat 3.1 (not latest build) and am starting to get
somewhere. Maybe that is the source of the problem below.




Jon Lancelle wrote:

> Downloaded the latest cvs version, and got the docs to create. But still
> get IllegalAccessException when trying to access an xml file which was
> accessible under Cocoon 1.
>
> I have changed all the permissions on the *.jar files to chmod 755, and
> still no luck. I have java installed under root, and all other packages
> (tomcat,cocoon,ant, etc.) under a user. I start the server from root,
> and tomcat from the user shell. Of course, I have tried starting tomcat
> from root also, with the same results.
>
> Haven't touched the java.policy file...don't even know what it is. I'll
> look at it.
>
> Also, I have created links to all needed *.jar files under the
> tomcat_home/lib directory. Links used to work fine with cocoon 1. Could
> this be a problem?
>
> Jon Lancelle
>
> Berin Loritsch wrote:
>
> > "N. Sean Timm" wrote:
> > > >* When trying to access *.xml pages, get this:
> > > ...org/apache/cocoon/Cocoon - java.lang.IllegalAccessException:
> > > >org/apache/cocoon/Cocoon...
> > >
> > > Not sure on this one...
> >
> > Check the permissions of the jar file and the directories it's in.
> > UNIX will not allow you access to many files if it was created by
> > root and used by another user.
> >
> > Try 'ls -l' to get the permissions on the jar and surrounding
> > directory.  If you get a result that looks like this:
> >
> > -rwxr-x--- root root  9287532  cocoon.jar
> >
> > that means that the user 'root' has read/write/execute privilege,
> > the group 'root' has read/execute privilege, and nobody else has
> > any privilege at all.
> >
> > Something more useful would be to change it's mode like this:
> >
> > chmod 755 cocoon.jar
> >
> > Which still only allows the user and root to delete/modify the
> > file, but everyone else can read and execute.
> >
> > Do that for the surrounding directory too, because sometimes
> > you can't read the directory which will also give you the
> > IllegalAccessException even if the file itself is OK.
> >
> > And lastly, did you do _anything_ to the java.policy file?

Re: Building Cocoon 2 - warnings, exceptions and errors

Posted by Giacomo Pati <Gi...@pwr.ch>.
Jon Lancelle wrote:
> 
> Downloaded the latest cvs version, and got the docs to create. But still
> get IllegalAccessException when trying to access an xml file which was
> accessible under Cocoon 1.

Yes, the current cvs is broken because the new sitemap engine has some
incompatabilities with existing components and is still undergoing API
changes. 

Giacomo

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

Re: Building Cocoon 2 - warnings, exceptions and errors

Posted by Jon Lancelle <jk...@knosys.com>.
Downloaded the latest cvs version, and got the docs to create. But still
get IllegalAccessException when trying to access an xml file which was
accessible under Cocoon 1.

I have changed all the permissions on the *.jar files to chmod 755, and
still no luck. I have java installed under root, and all other packages
(tomcat,cocoon,ant, etc.) under a user. I start the server from root,
and tomcat from the user shell. Of course, I have tried starting tomcat
from root also, with the same results.

Haven't touched the java.policy file...don't even know what it is. I'll
look at it.

Also, I have created links to all needed *.jar files under the
tomcat_home/lib directory. Links used to work fine with cocoon 1. Could
this be a problem?

Jon Lancelle



Berin Loritsch wrote:

> "N. Sean Timm" wrote:
> > >* When trying to access *.xml pages, get this:
> > ...org/apache/cocoon/Cocoon - java.lang.IllegalAccessException:
> > >org/apache/cocoon/Cocoon...
> >
> > Not sure on this one...
>
> Check the permissions of the jar file and the directories it's in.
> UNIX will not allow you access to many files if it was created by
> root and used by another user.
>
> Try 'ls -l' to get the permissions on the jar and surrounding
> directory.  If you get a result that looks like this:
>
> -rwxr-x--- root root  9287532  cocoon.jar
>
> that means that the user 'root' has read/write/execute privilege,
> the group 'root' has read/execute privilege, and nobody else has
> any privilege at all.
>
> Something more useful would be to change it's mode like this:
>
> chmod 755 cocoon.jar
>
> Which still only allows the user and root to delete/modify the
> file, but everyone else can read and execute.
>
> Do that for the surrounding directory too, because sometimes
> you can't read the directory which will also give you the
> IllegalAccessException even if the file itself is OK.
>
> And lastly, did you do _anything_ to the java.policy file?

Re: Building Cocoon 2 - warnings, exceptions and errors

Posted by Berin Loritsch <bl...@infoplanning.com>.
"N. Sean Timm" wrote:
> >* When trying to access *.xml pages, get this:
> ...org/apache/cocoon/Cocoon - java.lang.IllegalAccessException:
> >org/apache/cocoon/Cocoon...
> 
> Not sure on this one...

Check the permissions of the jar file and the directories it's in.
UNIX will not allow you access to many files if it was created by
root and used by another user.

Try 'ls -l' to get the permissions on the jar and surrounding
directory.  If you get a result that looks like this:

-rwxr-x--- root root  9287532  cocoon.jar

that means that the user 'root' has read/write/execute privilege,
the group 'root' has read/execute privilege, and nobody else has
any privilege at all.

Something more useful would be to change it's mode like this:

chmod 755 cocoon.jar

Which still only allows the user and root to delete/modify the
file, but everyone else can read and execute.

Do that for the surrounding directory too, because sometimes
you can't read the directory which will also give you the
IllegalAccessException even if the file itself is OK.

And lastly, did you do _anything_ to the java.policy file?