Where to put persistent (writeable) files in web apps?

I want to persist a small amount of data from a web-app, saving when the app is stopped and reloading when started.
This will be done from a ContextListener, and I plan simply to serialise a small table when the context is destroyed.
The question is, where should I put the file? Obviously I could simply specify an absolute directory, probably via an environmental entry (so as to specify it in the server, since it would be dependant on server configuration). I'd far rather have something more automatic.
I suppose I could put it somewhere under WEB-INF, but that doesn't seem right, the web-app directory should be read-only.
Servlet engines typically have a writable working directory where they keep compiled JSPs and persisted sessions, but is there a standard way of getting to it?

Well, now I'm not so sure anymore. But I have some
checkboxes I want to share among different
applications. So why can you share classes and jar
files and can not share JSP's?Sounds like more trouble than it's worth. Disk space is cheap. I'd deploy them with each app.
The only thing that would make me hesitate is the DRY principle. In that case, I might have "common" JSPs in my version control. I'd have the Ant script from each Web app check out the same "common" JSPs and build them into WARs. That would keep those JSPs common and not violate DRY. JMO - MOD

Similar Messages

  • Which folder i have to put my .jsp file for web report?

    for web report(not the paper report) i put my .jsp files in the
    \reports\j2ee\reports_ids\web
    folder
    this is for the DS(Developer Suite)
    i'm trying to move this file to different machine where AS(Application Server)
    is installed.
    but couldn't find above path. where do i have to put .jsp file for
    web report?
    or do i have to modify in the registry? if so, where?
    Thanks

    Hello,
    Take a look to the thread :
    where to add new jsp reports directory location in path
    "...You have to keep jsp files under document root that is OH/j2ee/OC4J_BI_Forms/applications/reports/web directory. You can create sufbolders under this directory and keep jsp files. ..."
    Regards

  • Where I can find .WAR file for web UI?

    I would like to use jakarta project
    web container for webUI.How I can accomplish
    this?

    Hello, I mean tomcat of jakarta.apache.org project- it's web container but .war file is web application archive as specified in servlet 2.2 spec.
    Why? I need support for latest spec. servlet 2.2/jsp 1.2 that provided by tomcat 4.0 beta(as standalone it's working fine for me;)). I'll be more concrete
    I need sophisticated JSP rendering engine for:
    Using JSPs of developer guide:
    <
    Deploying Java Beans and JSPs
    All compiled Java Beans must be stored in the directory $ORACLE_HOME/ifs/custom_classes on the server where Oracle iFS is installed.
    The Oracle iFS product comes with a starting-point directory structure. One of the folders in that structure is reserved for holding JSPs: $ORACLE_HOME/ifs/jsp-bin. To have your JSP compile and execute properly in Oracle iFS, you must store the JSP in this folder. JSPs stored elsewhere will not be executed by the Oracle iFS JSP compiler.
    >
    I would like to use web UI as frontend and my JSPs/servlets as extension of this application. It's easy create custom web app if I have ready .WAR file-it's portable
    between web containers and well structured... For example this schema doesn't have such constraints as location of JSPs and beans support classes location is well known-
    WEB-INF/classes for .WAR structured file, in WEB-INF/lib can be placed different ifs libs and all is clean and portable;).
    I mean webUI must not be integrated part of ifs- it must be developer tool( extensible and reusable).By the way who give constraints on JSPs/classes location: HTTP server of ifs
    or webUI?
    It's very nice that IFS has such thing as webUI but that if I can use it as dead(stable) code:(. I need write myself webUI presenting IFS document structure but why?
    Web UI is future(IE 5.5/w3 and other standards based;) so why put on it such restrictions.
    Best regards.
    P.S I can infiltrate web app from ifs- but it's not right(I can do something wrong).If I can help you somehow tell me.
    null

  • Where to put the properties file

    I am a new user of NetBeans6.0, I am making a simple application for user registration. I have coded everything but when I run project I get error caused by the dao.properties file load problem.
    I have put the dao.properties file inside the classes directory(where all java class files are build after running the project) of my web application directory( I didn't create this directory though, it is automatically created by IDE), I think there is a problem with its path.
    where should I put the dao.properties file so that when I run the project the Tomcat automatically find it and also, what the settings I should do?
    actually, I have referred to BalusC'd  DAO tutorial: the data layer but that comes in use when we are working off the IDEs, In my case since I am using Netbeans so it may be different from that one.
    if someone already done that then please let me know

    ok, but will it work if I upload the project in a remote host?
    lets talk besides IDE, as in your DAO tutorial you have instructed to put the properties file somewhere in root of the classpaths. ok, it will work on a local computer cause there is classpath setting but since remote host doesn't know about that property file and we cant set classpath at remote host(I am not sure though if we can) then how will it work at remote host.
    how the server at remote host comes to know about that property file?
    In my case since I have made the project using IDE and everything regarding classpaths have been set automatically(IDE done itself), but at remote host these sort of settings are not done then how the project will run?
    if I have described my problem incorrectly then please consider it as it is supposed to be.

  • Where to put LUT(.cube) files on SD card to be loaded with F55?

    I have downloaded several LUTs(.cube) and wish to put them onto my SD card so I can load them using my F55.. I want to use them as monitor LUTs. Can anybody tell me where in the SD cards file structure I have to put them? I've searched all over the web and haven't found any information about this.

    artcastel wrote:
    I have downloaded several LUTs(.cube) and wish to put them onto my SD card so I can load them using my F55.. I want to use them as monitor LUTs. Can anybody tell me where in the SD cards file structure I have to put them? I've searched all over the web and haven't found any information about this.It doesn't work like that, that's why there's no info. You can't load 3D LUTs into the camera. There are pre-contructed 3D LUTs already in the camera's 3.0 firmware referred to by Sony as "Looks", but as of FW 3.0, you can't load your own. If in the future they do allow this, it looks as though 3D LUTs from Resolve would first have to be loaded into Raw Viewer and converted into something more camera friendly, and then Raw Viewer wrotes it to an SD card in the correct file/folder structure. You CAN do 1D LUTs today though, using Raw Viewer.

  • Where to put AntiXssLibrary.dll file after installation of BPC Server

    Hi Experts,
         In the installation of BPC, that is after the installation of BPC Servers there comes another step "Installing the Anti-Cross Site Scripting Library"....The document tells us to download "AntiXssLibraryV1.5Installer.msi" and run the setup. Once it gets done the final step says "Copy AntiXssLibrary.dll to %BPC_PROGRAM%\Websrvr\Web\bin on both the BPC Application server and the BPC Web server." I can't understand where i should paste the file on Application Server and I could paste it in "C:\BPC\WebSvr\Web\Bin" what is the other location I should put the file.
    I am installing BPC on single server...Please help me out...
    Thanks
    Sudhakar Kuricheti

    Hello,
    Please use the follow link
    http://www.microsoft.com/downloads/details.aspx?FamilyId=EFB9C819-53FF-4F82-BFAF-E11625130C25&displaylang=en
    to download an installation kit for Microsoft Anti-Cross Site Scripting Library.
    In this way you will not have any more the problem where to put a dll and what you have to do with it.
    This program should be used into application server it is not necessary to put it into db server.
    If you have problem regarding unzip of dimensions then you have to check if you have into client side into C:\Program Files\BPC the dll xceedzip.dll and you have to check if this was correct register. (using regsvr32).
    I hope this help to understand what is that dll and what you have to do to complete the installation of SAP BPC server.
    Regards
    Sorin Radulescu

  • Where to put XSDs in the local Web(HTTP)Server so that they are visible ?

    Currently I am statically import XSD Schema files from my hard disc into projects.
    However I would prefer to put these XSD files onto the local Web(HTTP)server so that I can refer to them
    dynamically with a http://... address.
    How (where/which directory) do I have to put the XSD schema files on the local Oracle WebServer so that I can refer to them as http://127.0.0.1/... resp. http://localhost/....
    Peter

    I have placed my xsd file hierarchy under $ORACLE_HOME/bpel/system/xmllib, and address them with something like http://HOST:PORT/orabpel/xmllib/XYZ.xsd, as you suggest. This works fine if the schemas are in the xmllib directory itself. However, if I put the schemas in a subdirectory, the server does not produce the schema, just a blank page.
    How can you make schemas in the xmllib subdirectories visible using a URL as above?

  • Where to put shared JSP files in Tomcat?

    I'm building two different web applications. Both applications are deployed within Tomcat. Now these applications share some JSP files. I can not figure out where to put JSP files that are shared (with the include directive) among several applications. Can anyone help me?
    Thanx debeumers

    Well, now I'm not so sure anymore. But I have some
    checkboxes I want to share among different
    applications. So why can you share classes and jar
    files and can not share JSP's?Sounds like more trouble than it's worth. Disk space is cheap. I'd deploy them with each app.
    The only thing that would make me hesitate is the DRY principle. In that case, I might have "common" JSPs in my version control. I'd have the Ant script from each Web app check out the same "common" JSPs and build them into WARs. That would keep those JSPs common and not violate DRY. JMO - MOD

  • By default where does report write output files on web server

    I am running forms and reports over web. I am running a form which on the click of a button runs a report. Using the
    Orarrp utility (I already have) I want to print this report.
    In my form trigger I am using the run_report_object and I set report parameters DESTYPE to File, and I set
    DESNAME giving it a file name. When report finishes, I use Show_Document('http://server:domain/filename.ext','_blank'),
    it returns the 404 error, The requested URL /receipt.rrpa was not found on this server.
    Can anyone tell me, by default where the server writes the file output? I have checked under
    $ORACLE_HOME/reports60/server/cache but did not find my output file.
    Is there a way to specifically direct the output file to a directory, and have the reports server recognize the path?
    Perhaps using some sort of 'Virtual Path' in the server configuration, but where?
    Any help is appreciated?
    Regards
    Mark

    Hi,
    destype file writes the file to wherever you send it to.
    destype=file desname = c:\temp\myRep.html
    creates the file myRep.html in the temp directory on the server. Destype 'cache' only writes to the Cache directory you mention. normally, if not giving any directory information, it's the working directory that the file gets created in. Do a seacrh for your file and I am sure that you'll find it.
    regards Frank

  • By default where do reports write output files on web server

    I am running forms and reports over web. I am running a form which on the click of a button runs a report. Using the
    Orarrp utility (I already have) I want to print this report.
    In my form trigger I am using the run_report_object and I set report parameters DESTYPE to File, and I set
    DESNAME giving it a file name. When report finishes, I use Show_Document('http://server:domain/filename.ext','_blank'), it returns the 404 error, The requested URL
    /receipt.rrpa was not found on this server.
    Can anyone tell me, by default where the server writes the file output? I have checked under
    $ORACLE_HOME/reports60/server/cache but did not find my output file.
    Is there a way to specifically direct the output file to a directory, and have the reports server recognize the path?
    Perhaps using some sort of 'Virtual Path' in the server configuration, but where?
    Any help is appreciated?
    Regards
    Mark

    Hi Mark,
    In Oracle Reports 6i, reports is only written to cache when DESTYPE=cache. For DESTYPE=File, the report is wriiten in DESNAME mentioned.
    Your URL : http://server:domain/filename.ext, filename.ext is respective to the WebServer root directory. Assume your Webserver roor directory is "d:\apache\home".
    Set the DESNAME respective to your Webserver root directory (DESNAME=d:\apache\home\filename.ext).
    With Regards
    Reports Team

  • Where to put simple html-file in WebLogic directory structure?

    After installing JDeveloper 11g and WebLogic 10.3 which came in the same exe-file (jdevstudio11110install.exe), I want to try WebLogic as a ordinary web server for a simple html-file. Where should the file be placed in WebLogics directory structure, and are there any settings that need to be done to get this to work?

    Thank you, Maxence -
    I made it work this way:
    - Entered the following in weblogic.xml for a simple dummy-servlet...
    (WebLogicServletTest-ProjectWebLogicServletTest-context-root)
    ... deployed to the WebLogic server:
    <?xml version = '1.0' encoding = 'windows-1252'?>
    <weblogic-web-app>
    <virtual-directory-mapping>
    <local-path>C:\WorkScratch\</local-path>
    <url-pattern>*.html</url-pattern>
    </virtual-directory-mapping>
    </weblogic-web-app>
    WebLogic served up the hoppla.html-file in the C:\WorkScratch directory with the following browser URL:
    http://192.168.15.108:8900/WebLogicServletTest-ProjectWebLogicServletTest-context-root/hoppla.html

  • Where to put the .txt file in order to read it

    think ur prog can read the data.. but it said
    java:9: unreported exception java.io.FileNotFoundException; must be caught or declared to be thrown
    FileInputStream sStream = new FileInputStream("data.txt");
    so where to paste the .txt file if i want to read it
    same folder with my .java file?

    u must put the .txt file in order to read it as an
    argument to java command at runtime this code may help
    u out
    import java.io.*;
    class Demofin     
    {public static void main(String[] args) throws
    IOException
         int i;
         FileInputStream fin;
              try
                   fin=new FileInputStream(args[0]);
              catch (FileNotFoundException e)
              {System.out.println(" file not found");
              return;
              catch (ArrayIndexOutOfBoundsException e)
                   System.out.println("usage demofin filename.txt");
                   return;
              do
              {i=fin.read();
              if(i!=-1)System.out.print((char) i);
              while (i!=-1);
                   fin.close();
    }Use tags..

  • Where to put ~ITSMOBILEDEVICEINCLUDE html-file?

    Hi,
    we are building an ITS Service based on ABAP-Dynrpos (similar to LM01).
    We are using the Motorola (Symbol) MC3100 Handheld Scanner and want it to perform an "Auto-Enter" after scanning a barcode.
    I found this:
    http://service.sap.com/sap/support/notes/1311169
    Mobile Devices and Browser - Wiki - SCN Wiki
    My understanding is, that we need to define a ~ITSMOBILEDEVICEINCLUDE in the service (in SICF).
    But where to put this device specific HTML-file on the server? Or am I misunderstanding something here...?
    Thank You for your input!
    Jan

    Never mind, I found out myself. You can create this file directly in SE80.
    Navigate to Your ITS service in SE80 and then right click on the "HTML Templates" node of your ITS-Service, then choose "create" from the context menu...
    Samples of device include files can be found in SE80 for ITS-Service ITSMOBILE01:
    Regards
    Jan

  • Anyconnect 4 as 802.1x supplicant replacement for Windows - where to put config xml file?

    I want to try out Anyconnect NAM as a 802.1x supplicant replacement in Windows 8.1
    And I have made myself a fine little config xml file that I want to test.
    But where do I put that config file?
    Should I rename it to something special, or should Anyconnect NAM have some extra startup parameters?
    Thank you.

    The file must be called "configuration.xml" and if you already installed NAM, then put the file in \Users\All Users\Cisco\Cisco AnyConnect Secure Mobility Client\Network Access Manager\newConfigfiles\ and restart the anyconnect service
    If instead you are creating an install package for deploying, you can put the configuration in a directory named Profiles/NAM/  together with the msi package, the installation will import the config itself.when you run the msi file.

  • Where to put the class file

    i am using tomcat 4.1.27 server and i created a UserData.java file as a bean; i have placed the class file in the WEB-INF/classes folder. still i get the following error:
    ==============================================================
    org.apache.jasper.JasperException: Unable to compile class for JSP
    An error occurred at line: 21 in the jsp file: /ics334/Javanese/name7.jsp
    Generated servlet error:
    [javac] Compiling 1 source file
    C:\Program Files\Apache Group\Tomcat 4.1\work\Standalone\localhost\_\ics334\Javanese\name7_jsp.java:60: cannot resolve symbol
    symbol : class UserData
    location: class org.apache.jsp.name7_jsp
    UserData user = null;
    ^
    An error occurred at line: 21 in the jsp file: /ics334/Javanese/name7.jsp
    Generated servlet error:
    C:\Program Files\Apache Group\Tomcat 4.1\work\Standalone\localhost\_\ics334\Javanese\name7_jsp.java:62: cannot resolve symbol
    symbol : class UserData
    location: class org.apache.jsp.name7_jsp
    user = (UserData) pageContext.getAttribute("user", PageContext.SESSION_SCOPE);
    ^
    An error occurred at line: 21 in the jsp file: /ics334/Javanese/name7.jsp
    Generated servlet error:
    C:\Program Files\Apache Group\Tomcat 4.1\work\Standalone\localhost\_\ics334\Javanese\name7_jsp.java:65: cannot resolve symbol
    symbol : class UserData
    location: class org.apache.jsp.name7_jsp
    user = (UserData) java.beans.Beans.instantiate(this.getClass().getClassLoader(), "UserData");
    ^
    3 errors
    Apache Tomcat/4.1.27
    ===============================================================
    the structure of the jsp file is as
    <%@ page contentType="text/html" %>
    <%@ page import="java.sql.*,java.util.*" %>
    <%@ page import ="javax.servlet.*"%>
    <%@ page import ="javax.servlet.http.*"%>
    <html dir="rtl">
    <head>
    <meta http-equiv="Content-Language" content="en-us">
    <meta name="GENERATOR" content="Microsoft FrontPage 6.0">
    <meta name="ProgId" content="FrontPage.Editor.Document">
    <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
    <title>New Page 1</title>
    </head>
    <body>
    <p dir="ltr">
    <jsp:useBean id="user" class="UserData" scope="session"/>
    <jsp:setProperty name="user" property="*"/>
    <font size="5">Your Name is :<%= user.getUsername() %> <BR></font>
    </p>
    </body>
    </html>
    can anyone help plz?

    I am also facing the same problem. Try placing ur
    class files in tomcat's /common/classes folder.
    Sometimes it works. How ever it did not work in my
    case. Hope it works in your!!This ain't a right way of doing it... when creating a web-app, the files should be contained in it.
    The problem is can be resolved by packaging the class in say beans. Then place that class in WEB_INF/classes/beans.
    Cheers!
    ***Annie***

Maybe you are looking for

  • Error While defining screen layout in asset account

    Hi Guru's,      I tried to define screen layout rules in asset accounting but it showing error "screen layout control"410"does not exist.can any body tell me whats wrong? Thanks

  • Can't edit/adjust photos in Lightroom 4 (v4.4)

    Hello, In development mode, any adjustments I make on the sliders on the right have no effect to the picture. Sometimes the picture greys out and I have to try and click on a different picture below for it to show up again. The grey screen comes up i

  • Ad new words to Pages to the spellchecker - in a easy way?

    It is not easy to add new words to the spellchecker - via Learn it would be fine if a menu came up - and as default - a ADD to box - by hitting the Enter key that would speed up - when I have to go to add 50 - 100 technical words etc. 2) better solut

  • ORA-07445 error in 10.2.0.4 database on Windows Server 2003

    Hello, We run an Oracle 10.2.0.4 database on a Windows 2003 Server. Yesterday we started encountering an odd, repeating error: ORA-07445: exception encountered: core dump [ACCESS_VIOLATION] [__VInfreq__kqlCompileSynonym+3038] [PC:0x2F93172] [ADDR:0x3

  • [flexcoders] Error #2025 - UIMovieclip and Focus Manager

    Hello Everybody, I'm getting a runtime Error #2025 when I try to use an UIMovieclip into a Flex Application. The issue happens when the key tab is pressed and It seems has being caused by the Focus Manager. I found some threads over the internet but