You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Oskar Casquero Oiarzabal <jt...@bi.ehu.es> on 2003/09/30 10:51:13 UTC

problems with castor transformer example

Hello,

    I'm trying to see the usage of the CastorTransformer with the
    example included in Cocoon-2.1, but I can't see any result
  ( <zoo xmlns:castor="http://castor.exolab.org/cocoontransfomer" /> ).
  I looked log files and in sitemap.log I get the following error
  
WARN    (2003-09-30) 10:30.59:161   [sitemap] (/cocoon/samples/castor/) Thread-18/CastorTransformer: Failed to marshal bean Mouse
org.xml.sax.SAXException: System property org.xml.sax.parser not specified
        at org.xml.sax.helpers.ParserAdapter.<init>(ParserAdapter.java:104)

        Has anybody tried to solve this? Is this a problem of the
        castor example, or a cocoon bug in castor configuration?

Best regards,
 Oskar



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: problems with castor transformer example

Posted by Joerg Heinicke <jh...@virbus.de>.
Hello Oskar,

Oskar Casquero Oiarzabal wrote:
> Hi,
> 
> Thank you for the explanation and for the solution. Now the example is
> working properly. But why it is not added to the catalina.sh/.bat
> during the build process? Is there any option I forgot to add when I built cocoon
> from sources?

No, you missed nothing. catalina.sh/.bat is Tomcat and Cocoon is ...
Cocoon. Be sure we will never manipulate your servlet container's start
scripts. Furthermore I wasn't aware of such a need for configuration.

Does anybody else know, if it is possible to configure this thing in
cocoon.xconf when specifying the parser?

Joerg

> Tuesday, September 30, 2003, 12:29:36 PM, you wrote:
> 
> WG> Oskar,
> 
> WG> it isn't. For historic reasons, the CastorTransformer internally uses the 
> WG> SAXAdaptor class to map between SAX1 and SAX2 events. As such, it is a 
> WG> requirement to specify the XML parser you are using.
> 
> WG> I do not know what web container you are using, but with e.g. Tomcat it would 
> WG> be sufficient to specify the environment varaiable JAVA_OPTS as follows: 
> 
> WG> JAVA_OPTS=-Dorg.xml.sax.parser=org.apache.xerces.parsers.SAXParser
> 
> WG> Please be aware that in my case, I am using Xerces. If you are using another 
> WG> parser, please amend the above configuration accordingly.
> 
> WG> If you are not using Tomcat (Catalina), please try to include the above 
> WG> property with the JVM that's responsible for starting the conatiner.
> 
> WG> I hope this hepls
> WG> Werner
> 
> WG> On Tuesday 30 September 2003 10:51, Oskar Casquero Oiarzabal wrote:
> 
>>>Hello,
>>>
>>>    I'm trying to see the usage of the CastorTransformer with the
>>>    example included in Cocoon-2.1, but I can't see any result
>>>  ( <zoo xmlns:castor="http://castor.exolab.org/cocoontransfomer" /> ).
>>>  I looked log files and in sitemap.log I get the following error
>>>
>>>WARN    (2003-09-30) 10:30.59:161   [sitemap] (/cocoon/samples/castor/)
>>>Thread-18/CastorTransformer: Failed to marshal bean Mouse
>>>org.xml.sax.SAXException: System property org.xml.sax.parser not specified
>>>at org.xml.sax.helpers.ParserAdapter.<init>(ParserAdapter.java:104)
>>>
>>>        Has anybody tried to solve this? Is this a problem of the
>>>        castor example, or a cocoon bug in castor configuration?
>>>
>>>Best regards,
>>> Oskar




---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: Re[2]: problems with castor transformer example

Posted by Werner Guttmann <we...@gmx.net>.
Oskar,

I am afraid there is not a simple answer to your question ... 8-(. But let me try a couple of things to give you an idea:

a) Modifying catalina.sh as part of building/installing Cocoon is not really an option. First of all, not everybody uses 
Tomcat/Catalina, and even with Tomcat there's many ways to achieve the same. I've pointed you to the use of the 
JAVA_OPTS environment variable, others might want literally modify catalina.sh, etc. 

b) The CastorTransformer is still part of the scratchpad block, and has been there for quite a while. I am thinking of 
moving the transformer to its own block, but I am quite uneducated when it comes to actually doing this. So this 
might take some time ... 8-(.

In other words, you didn't miss an option when istalling Cocoon, and yes, documentation could definitely be made 
better. And I guess this will be part of exercise b).

Werner

On Tue, 30 Sep 2003 13:30:20 +0200, Oskar Casquero Oiarzabal wrote:

>Hi,
>
>Thank you for the explanation and for the solution. Now the example is
>working properly. But why it is not added to the catalina.sh/.bat
>during the build process? Is there any option I forgot to add when I built cocoon
>from sources?
>
>Oskar
>
>Tuesday, September 30, 2003, 12:29:36 PM, you wrote:
>
>WG> Oskar,
>
>WG> it isn't. For historic reasons, the CastorTransformer internally uses the 
>WG> SAXAdaptor class to map between SAX1 and SAX2 events. As such, it is a 
>WG> requirement to specify the XML parser you are using.
>
>WG> I do not know what web container you are using, but with e.g. Tomcat it would 
>WG> be sufficient to specify the environment varaiable JAVA_OPTS as follows: 
>
>WG> JAVA_OPTS=-Dorg.xml.sax.parser=org.apache.xerces.parsers.SAXParser
>
>WG> Please be aware that in my case, I am using Xerces. If you are using another 
>WG> parser, please amend the above configuration accordingly.
>
>WG> If you are not using Tomcat (Catalina), please try to include the above 
>WG> property with the JVM that's responsible for starting the conatiner.
>
>WG> I hope this hepls
>WG> Werner
>
>WG> On Tuesday 30 September 2003 10:51, Oskar Casquero Oiarzabal wrote:
>>> Hello,
>>>
>>>     I'm trying to see the usage of the CastorTransformer with the
>>>     example included in Cocoon-2.1, but I can't see any result
>>>   ( <zoo xmlns:castor="http://castor.exolab.org/cocoontransfomer" /> ).
>>>   I looked log files and in sitemap.log I get the following error
>>>
>>> WARN    (2003-09-30) 10:30.59:161   [sitemap] (/cocoon/samples/castor/)
>>> Thread-18/CastorTransformer: Failed to marshal bean Mouse
>>> org.xml.sax.SAXException: System property org.xml.sax.parser not specified
>>> at org.xml.sax.helpers.ParserAdapter.<init>(ParserAdapter.java:104)
>>>
>>>         Has anybody tried to solve this? Is this a problem of the
>>>         castor example, or a cocoon bug in castor configuration?
>>>
>>> Best regards,
>>>  Oskar
>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>>> For additional commands, e-mail: users-help@cocoon.apache.org
>
>
>WG> ---------------------------------------------------------------------
>WG> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>WG> For additional commands, e-mail: users-help@cocoon.apache.org
>
>
>
>-- 
>Best regards,
> Oskar                            mailto:jtacaoio@bi.ehu.es
>
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>For additional commands, e-mail: users-help@cocoon.apache.org
>




---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re[2]: problems with castor transformer example

Posted by Oskar Casquero Oiarzabal <jt...@bi.ehu.es>.
Hi,

Thank you for the explanation and for the solution. Now the example is
working properly. But why it is not added to the catalina.sh/.bat
during the build process? Is there any option I forgot to add when I built cocoon
from sources?

Oskar

Tuesday, September 30, 2003, 12:29:36 PM, you wrote:

WG> Oskar,

WG> it isn't. For historic reasons, the CastorTransformer internally uses the 
WG> SAXAdaptor class to map between SAX1 and SAX2 events. As such, it is a 
WG> requirement to specify the XML parser you are using.

WG> I do not know what web container you are using, but with e.g. Tomcat it would 
WG> be sufficient to specify the environment varaiable JAVA_OPTS as follows: 

WG> JAVA_OPTS=-Dorg.xml.sax.parser=org.apache.xerces.parsers.SAXParser

WG> Please be aware that in my case, I am using Xerces. If you are using another 
WG> parser, please amend the above configuration accordingly.

WG> If you are not using Tomcat (Catalina), please try to include the above 
WG> property with the JVM that's responsible for starting the conatiner.

WG> I hope this hepls
WG> Werner

WG> On Tuesday 30 September 2003 10:51, Oskar Casquero Oiarzabal wrote:
>> Hello,
>>
>>     I'm trying to see the usage of the CastorTransformer with the
>>     example included in Cocoon-2.1, but I can't see any result
>>   ( <zoo xmlns:castor="http://castor.exolab.org/cocoontransfomer" /> ).
>>   I looked log files and in sitemap.log I get the following error
>>
>> WARN    (2003-09-30) 10:30.59:161   [sitemap] (/cocoon/samples/castor/)
>> Thread-18/CastorTransformer: Failed to marshal bean Mouse
>> org.xml.sax.SAXException: System property org.xml.sax.parser not specified
>> at org.xml.sax.helpers.ParserAdapter.<init>(ParserAdapter.java:104)
>>
>>         Has anybody tried to solve this? Is this a problem of the
>>         castor example, or a cocoon bug in castor configuration?
>>
>> Best regards,
>>  Oskar
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
>> For additional commands, e-mail: users-help@cocoon.apache.org


WG> ---------------------------------------------------------------------
WG> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
WG> For additional commands, e-mail: users-help@cocoon.apache.org



-- 
Best regards,
 Oskar                            mailto:jtacaoio@bi.ehu.es



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: problems with castor transformer example

Posted by Werner Guttmann <we...@gmx.net>.
Oskar,

it isn't. For historic reasons, the CastorTransformer internally uses the 
SAXAdaptor class to map between SAX1 and SAX2 events. As such, it is a 
requirement to specify the XML parser you are using.

I do not know what web container you are using, but with e.g. Tomcat it would 
be sufficient to specify the environment varaiable JAVA_OPTS as follows: 

JAVA_OPTS=-Dorg.xml.sax.parser=org.apache.xerces.parsers.SAXParser

Please be aware that in my case, I am using Xerces. If you are using another 
parser, please amend the above configuration accordingly.

If you are not using Tomcat (Catalina), please try to include the above 
property with the JVM that's responsible for starting the conatiner.

I hope this hepls
Werner

On Tuesday 30 September 2003 10:51, Oskar Casquero Oiarzabal wrote:
> Hello,
>
>     I'm trying to see the usage of the CastorTransformer with the
>     example included in Cocoon-2.1, but I can't see any result
>   ( <zoo xmlns:castor="http://castor.exolab.org/cocoontransfomer" /> ).
>   I looked log files and in sitemap.log I get the following error
>
> WARN    (2003-09-30) 10:30.59:161   [sitemap] (/cocoon/samples/castor/)
> Thread-18/CastorTransformer: Failed to marshal bean Mouse
> org.xml.sax.SAXException: System property org.xml.sax.parser not specified
> at org.xml.sax.helpers.ParserAdapter.<init>(ParserAdapter.java:104)
>
>         Has anybody tried to solve this? Is this a problem of the
>         castor example, or a cocoon bug in castor configuration?
>
> Best regards,
>  Oskar
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org