Re: Problem with SISCweb update
"Alessandro Colomba" <[email protected]> Mon, 10 Sep 2007 17:41:44 -0400
| Newsgroups | gmane.comp.java.sisc.user |
|---|---|
| Message-ID | <[email protected]> |
Hello Nikita,
Sorry you are having problems. I am unable to try your exact test case
right now, but I believe the problem you are seeing comes from the way
the (load) function works in SISC. Specifically, (load) takes the path
to be a URL relative to the path of the file being executed -- in this
case the JNDI-addressed servlet parameter. (The "Source Loading"
section in the SISC manual contains some examples.)
Since the path of the file you are loading is inside the web
application, you can use something like:
(class-path-extension-append! '("WEB-INF/code/"))
(require-extension (lib loader))
This also has the advantage of addressing the files in a manner
relative to the application, whatever its name and location.
You can find more details in the SISCweb manual:
http://siscweb.sourceforge.net/swm/ch02.html#adapter-servlet
Let us know how that works for you, or if you have any questions.
Regards,
___
Alessandro
On 9/10/07, Nikita <[email protected]> wrote:
> Hello,
>
>
> After updating SISCweb from 0.4 to 0.5 my web-application doesn't want
> to start.
>
> It appears that it can't run code from on-init-sexp servlet parameter
> and breaks on the first line which is:
> (load "/home/nikita/myapp/WEB-INF/code/loader.scm").
>
> The error I get is:
> javax.servlet.ServletException: ((java-exception . #<java
> java.io.FileNotFoundException java.io.FileNotFoundException>) (message .
> "error opening 'jndi:/home/nikita/myapp/WEB-INF/code/loader.scm'.")
> (location . load))
> siscweb.web.SISCAdapterServlet.init(SISCAdapterServlet.java:119)
> javax.servlet.GenericServlet.init(GenericServlet.java:212)
> ...
>
> I have no idea why it adds "jndi:" in front of path. If this code is
> executed in REPL then everything is fine.
>
> Could anyone suggest something?
>
>
>
>
> Best regard,
> Nikita
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2005.
> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
> _______________________________________________
> Sisc-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/sisc-users
>
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/