cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Hemangi Dua <hemangi....@ictect.com>
Subject Re: Calling servlet block from itself?
Date Thu, 31 Mar 2011 16:02:38 GMT
I have following code in sitemap, and what is "ServletService"

<
<
</
Thanks
Hemangi

 

In a Day, When u dont come across any PROBLEMS, u can be sure that u r traveling 

in a WRONG path....... Swami Vivekananda




----- Original Message ----
From: Thomas Markus <t.markus@proventis.net>
To: users@cocoon.apache.org
Cc: Huib Verweij <huiver@mpi.nl>
Sent: Thu, March 31, 2011 9:07:28 AM
Subject: Re: Calling servlet block from itself?

Hi,

try an absolute name:

<map:transform type="servletService">
    <map:parameter name="service"  
value="servlet:nl.mpi.lexus.db.service+:/workspace/getSortOrders.xml"/>
</map:transform>


regards
Thomas

Am 31.03.2011 13:04, schrieb Huib Verweij:
> Hi,
>
> I would like to call a servlet from within a servlet, e.g.:
>
> <map:transform type="servletService">
>      <map:parameter name="service"  
>value="servlet:db:/workspace/getSortOrders.xml"/>
> </map:transform>
>
> from within the db-servlet itself. I realize this is somewhat like a recursive 
>call and it could lead to unpleasant behavior. I also realize I have setup my 
>blocks incorrectly and probably need to create more blocks, pushing the code I 
>want to call to the basic 'bottom' block. But it would help for now if this is 
>possible :-).
>
> The above statement fails, so I tried to add:
>
> <servlet:connections>
>          <entry key="db" value-ref="nl.mpi.lexus.db.service"/>
>          <entry key="display" value-ref="nl.mpi.lexus.display.service"/>
> </servlet:connections>
>
> to the servlet context for db:
>
> <servlet:context mount-path="/db" context-path="blockcontext:/db/"/>
>
> but then things fail to startup properly.
>
> So, it's not that I can't imagine why this is tricky, but on the other hand I 
>can see this might be useful. An alternative I see would be to use 
>a<map:resource/>  but unfortunately the code I'm trying to call is in a 
>different sitemap.xmap. Any suggestions are appreciated.
>
> Hartelijke groet,
>
> Huib.
>
>
>
>
> --
> Drs. Huib Verweij
> Senior software developer - The Language Archive
> Max Planck Institute for Psycholinguistics
> P.O. Box 310
> 6500 AH Nijmegen
> The Netherlands
> t +31-24-3521911
> e huib.verwey@mpi.nl
> w http://www.mpi.nl/
>
>
>


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

map:transformername="sendmail"src="org.apache.cocoon.mail.transformation.SendMailTransformer">smtphost>localhost</smtphost>map:transformer> 


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


Mime
View raw message