« Return to Thread: java.lang.NullPointerException at org.exist.cocoon.XQueryGenerator.setup

Re: java.lang.NullPointerException at org.exist.cocoon.XQueryGenerator.setup

by Tomek Piechowicz :: Rate this Message:

Reply to Author | View in Thread

Tomek Piechowicz pisze:

> I wanted to execute some simple xml query via XQueryGenerator in my
> cocoon pipeline. After I executed code :
>
> <map:pipeline>
>          <map:match pattern="Exist">
>              <map:generate src="people.xq" type="xquery">
>                  <map:parameter name="user" value="tomek"/>
>                  <map:parameter name="password" value="tomek"/>  
>              </map:generate>
>              <map:serialize encoding="UTF-8" type="xml"/>
>          </map:match>
>      </map:pipeline>
>
> server threw exception :
>
> java.lang.NullPointerException at
> org.exist.cocoon.XQueryGenerator.setup(XQueryGenerator.java:187)
>
> I`ve been using latest production release of eXist 1.2.6, can anyone
> help me with understanging meaning of this exception ? Lack of jars ?
> Wrong xquery syntax ? Bug in eXist code ?
>
> Regards,
> Tomasz.
>
So, finally after suggestion from Maciej Rosiek I added some code in
XQueryGenerator.java in the begining  of setup() function :

try
{  
       parameterize(parameters);
 }
 catch(ParameterException pe)
 {
       System.out.println("ERROR");
 }

after this changes I tested some simple xml query and XQueryGenerator
seems to work ok with cocoon 2.2.

Important : I`m NOT(!) eXist developer, this is only my temporary
solution till official release of eXist with support for Cocon 2.2.

Regards,
Tomasz Piechowicz


------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge  
This is your chance to win up to $100,000 in prizes! For a limited time,
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize
details at: http://p.sf.net/sfu/blackberry
_______________________________________________
Exist-open mailing list
Exist-open@...
https://lists.sourceforge.net/lists/listinfo/exist-open

 « Return to Thread: java.lang.NullPointerException at org.exist.cocoon.XQueryGenerator.setup