Hi All,
I've noticed that when I use the 'xhtml-to-pdf' processor from a pipeline that's run through the scheduler it fails at the point where it tries to resolve an external resource (like my css).
It generates a NullPointerException at
Whenever I run the pipeline through an http request (using the pfc) all works fine. The problem probably has to do with the lack of a ExternalContext/Request object when running a pipeline through the scheduler. Could anyone let me know if there's a workaround to this?
Thanks in advance! Jasper
-- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws |
Administrator
|
Jasper,
We need to fix this at some point. As a not-so-nice workaround, you could have your scheduler perform an HTTP request, and implement the PDF generation from that service.
-Erik
On Mon, May 2, 2011 at 6:14 AM, Jasper Linthorst <[hidden email]> wrote: Hi All, -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws |
Hi Erik,
Thanks for the feedback. Will go with the suggested workaround. Jasper
On Tue, May 3, 2011 at 6:16 AM, Erik Bruchez <[hidden email]> wrote: Jasper, -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws |
Ok, eventually I fixed things in a different matter, because it turned out that the xforms submission processor (which I tried to use to make the http request) also uses the ExternalContext (so I ended up with a similar error). What I've done now is I've created a custom 'xhtml-to-pdf' processor based on Orbeon's code and made a minor change so that it doesn't retrieve the ExternalContext through the PipelineContext, but instead create an instance of SimpleExternalContext and use that for the rewriting... All seems to work just fine.
@Erik, could you let me know if this could be a probable solution?
On Tue, May 3, 2011 at 9:18 AM, Jasper Linthorst <[hidden email]> wrote: Hi Erik, -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws |
Administrator
|
Jasper,
That is a possible one. I think it would still be better if an external context was available and handled properly. Without spending a bit more time looking into it I am not completely sure though!
-Erik
On Tue, May 3, 2011 at 4:09 AM, Jasper Linthorst <[hidden email]> wrote: Ok, eventually I fixed things in a different matter, because it turned out that the xforms submission processor (which I tried to use to make the http request) also uses the ExternalContext (so I ended up with a similar error). What I've done now is I've created a custom 'xhtml-to-pdf' processor based on Orbeon's code and made a minor change so that it doesn't retrieve the ExternalContext through the PipelineContext, but instead create an instance of SimpleExternalContext and use that for the rewriting... All seems to work just fine. -- You receive this message as a subscriber of the [hidden email] mailing list. To unsubscribe: mailto:[hidden email] For general help: mailto:[hidden email]?subject=help OW2 mailing lists service home page: http://www.ow2.org/wws |
Free forum by Nabble | Edit this page |