Resin - probably configuration problem

Discussion in 'Java' started by Prasalek.Michal@gmail.com, Mar 10, 2008.

  1. Guest

    Hello all.

    I'm in need to save files (primitive cache) in my servlet. But when
    i'm trying to create such file, it is being created outside webapp
    working folder (in Resin startup folder), when i need it to create
    files in webapp folder. I've tried to set app-dir to appropriate path,
    but it changes nothing ... I want to work on relative path, because
    application can work on server side, and as standalone.
    Is there any configuration issue, that i missed? Or should i be
    looking for webapp folder, and change folder context in some way?

    For any help thanks in advance.
     
    , Mar 10, 2008
    #1
    1. Advertising

  2. Arne Vajhøj Guest

    wrote:
    > I'm in need to save files (primitive cache) in my servlet. But when
    > i'm trying to create such file, it is being created outside webapp
    > working folder (in Resin startup folder), when i need it to create
    > files in webapp folder. I've tried to set app-dir to appropriate path,
    > but it changes nothing ... I want to work on relative path, because
    > application can work on server side, and as standalone.
    > Is there any configuration issue, that i missed? Or should i be
    > looking for webapp folder, and change folder context in some way?


    getServletContext().getRealPath("/dir/file")

    Arne
     
    Arne Vajhøj, Mar 11, 2008
    #2
    1. Advertising

  3. Guest

    On Mar 11, 2:57 am, Arne Vajhøj <> wrote:
    > getServletContext().getRealPath("/dir/file")


    Thanks, it works well now :).
     
    , Mar 13, 2008
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. dhek bhun kho

    Resin/JNDI: object lifecycle

    dhek bhun kho, Jul 2, 2003, in forum: Java
    Replies:
    0
    Views:
    1,605
    dhek bhun kho
    Jul 2, 2003
  2. Keith G
    Replies:
    0
    Views:
    1,660
    Keith G
    Sep 8, 2003
  3. luca passani

    Tomcat, Resin and cookies

    luca passani, Sep 13, 2003, in forum: Java
    Replies:
    0
    Views:
    604
    luca passani
    Sep 13, 2003
  4. luca passani

    detecting tomcat and resin

    luca passani, Sep 15, 2003, in forum: Java
    Replies:
    0
    Views:
    360
    luca passani
    Sep 15, 2003
  5. asaguden
    Replies:
    0
    Views:
    548
    asaguden
    Jan 24, 2005
Loading...

Share This Page