Properties file missing

Hi,
I am trying to use MYSQL with J2EESDK 1.4. I have create a simple CMP bean. When i try to deploy i get the following error.
JDO7001: Cannot find resource com/sun/jdo/spi/persistence/generator/database/MYSQL.properties. I wonder if this is related to
mysql.properties=dbType\=mysqlin my database.properties file. I am not sure what has to be given but the default pointbase has
pointbase.properties=dbType\=pointbaseThanx for all your help.

Hi,
I was having the exact same problem , and I am using mysql as well.
the error was:
JDO7001: Cannot find resource com/sun/jdo/spi/persistence/generator/database/MYSQL.properties.
I think I have solved my problem. It turned out that I had not saved my CMP mappings (from entity bean to database) .
open your EAR (or Jar) in the deploy tool.
click on a jar that contains entity beans and switch to the "general" tab for that bean
in the main window, open the "META-INF" link... you should see a file called
"sun-cmp-mappings.xml"
This file must exist for every jar contaning entity beans - it contains the cmp to database mappings.
If its not there for a given jar (one that contains entity beans, that is), then look at the general tab for each entity bean and select "sun-specific settings"
In the window that opens, switch the view pull-down to CMP-DATABASE. This is where you map your cmp feilds to database fields.
note that you must first map the database schema for your databases (see chapter 22 of the j2ee tutorial) before you can map the feilds, then add the database schema to your JAR that contains the entity beans.
Be sure to SAVE after you map!

Similar Messages

  • How to use properties file

    Hi,
    I want to use properties file in my application. I have kept properties file inside a directory called properties which is inside myProject(which is the parent directory of my project) i.e "myProject/properties".
    My java file where i want to call this properties file is inside the myProject/WEB-INF/src/java.
    How can i call the properties file from myProject/WEB-INF/src/java/PropertyReader.java
    I wrote java program in myProject/WEB-INF/src/java/PropertyReader.java like:::::
    ResourceBundle resBun = ResourceBundle.getBundle("Test", Locale.getDefault()); // Test.properties is inside myProject/properties
    resBun..getString("name");
    After running the program i am getting the following errors:::::
    Exception in thread "main" java.util.MissingResourceException: Can't find bundle for base name Test, locale en_US
    at java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java:836)
    at java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:805)
    at java.util.ResourceBundle.getBundle(ResourceBundle.java:576)
    at PropertiesReader.main(PropertiesReader.java:4)
    What is the issue? How to use properties file?
    Waiting for reply.
    Thanks

    Still getting same exception. As you explained i tried like the below:::
    1. I am using ant as build tool.
    2. My properties file is for database configuration
    My properties file is::
    database.properties (inside myProject/properties)
    JDBCDriver=org.gjt.mm.mysql.Driver
    JDBCConnectionURL=jdbc:mysql://pmdbmysql:3306/bandwidthshaper?user=admin&password=admin
    My java package structure is
    WEB-INF/src/java
    WEB-INF/src/classes
    For build WEB-INF is the base directory and build.xml is inside the src directory
    In my build.xml i wrote the following lines for compilation::
              <target name="compile" >
                   <javac srcdir="src" destdir="src/classes" debug="true" debuglevel="lines,vars,source">
                        <classpath refid="class.path"/>
                   </javac>
    <copy todir = "src/classes" >
    <fileset dir = "../properties" />
    </copy>
                   <jar jarfile="lib/${project.jar.file}" basedir="src/classes"/>
              </target>
    I am copying properties file to the classes directory.
    Now in java file which is inside /WEB-INF/src/java, I wrote::
    try {
    Properties programProps = new Properties();
    InputStream is = getClass().getResourceAsStream("/database.properties");
    if(is == null)
    throw new IllegalStateException("Properties file missing ");
    programProps.load(is);
    System.out.println("driver name::::::: "+programProps.getProperty("JDBCDriver"));
    is.close();
    } catch(Exception e) {
    e.printStackTrace();
    After compilation in my classes directory i am getting database.properties file and my java file with package.
    At the time of running i am getting "java.lang.IllegalStateException: Properties file missing"
    Now tell me where is the fault. Why again i am getting exception.
    Thanks

  • ConfigTool Login problem..SecStore.Properties file is missing..!

    hi all,
    I am unable to open Configtool since the SecStore.Properties file is missing which is supposed to be available in /sapmnt/<SID>/global/security/data/SecStore.properties..
    Below is the error being thrown while starting configtool.sh...
    Error while loading the securestore..
    Msg: File"/sapmnt/<SID>/global/security/data/SecStore.properties" does not exist although it should
    The OS is Solaris 10..How can i resolve this issue..Can i just copy it from some of colleague or just create it with the necessary parameter ( if yes,what is the procedure to create such file )
    Your valuable answers will be appreciated and rewared.
    Please help..
    Thanks!
    Addy

    Hi,
    I am a new user having super admin role.Ours is EP 7.0  Standalone JAVA with LDAP.
    Actually, the file SecStore.properties is not been created or not been used for my user.
    when i try to start configtool with my own UID/PW  i get this error.
    My question here is..Am i supposed to use Administrator (since, its standslone JAVA ) or the <sid>adm as per everyone's suggestion.
    I guess i can use both Administrator and <sid>adm for configtool since both needs master password to login. but, why not my UID/PW which has Super admin role..??!!
    Appreciate your time discussing on this.
    Addy

  • Application missing Resource MyApplication .properties file

    For some reason I have one Web Dynpro application that does not generate a .properties file. All of my other projects do. Is there any reason why?
    I need this file so I can write resource bundles for other languages.
    Thanks.

    The .properties file is generated from the .xlf file.
    in the webdynpro perspective:
    select "Navigator view".
    Open src ... find your view/window xlf-file.
    right-click on the xlf-file and select I18N Tools -> Create Property file
    The file is also generated automaticly from some wizards and editors. That's why you see it in some projects and not in some others.
    /Mikael

  • Unable to load properties file from filesystem

    Hi,
    I have a client swing-applicatiion packaged in a jar-file. The application uses some resource files, including a xxxx.properties file to set defaults for the application. All resource files are included in the jar file and everything works as expected. I load the xxxx.properties file as follows:
    is_ = getClass().getResourceAsStream("/resources/xxxx.properties");
    Because it is not possibl to change any property values inside the jar-file without recreating this jar-file, i want to exclude the xxxx.properties file from the jar-file and put it in the folder containing the jar-file.
    So i have:
    drive:/folder/app.jar
    drive:/folder/xxxx.properties
    Now i read the xxxx.properties file from disk in stead of the 'resouce'-folder within my application (jar):
    is_ = getClass().getResourceAsStream("drive:/folder/xxxx.propoerties");
    but it doesn't work, the file isn't found.
    What am i missing here?
    Any suggestions?

    The best way to approach this is to include the properties file in the Jar as you originally did. If the user changes any property, save the entire set of properties to a sub-directory of user.home (perhaps based on the package name of the main class). Check for the copy in user.home before using the 'default' properties built into the Jar.
    Other places/ways to store the changed information.
    - java.util.prefs.Preferences
    - Assuming the app. has a GUI and can be deployed over a network, the JNLP API PersistenceService. Here is a demo. of the PersistenceService (http://pscode.org/jws/api.html#ps).
    Edit 1:
    I did not at first notice that this post was in Java Applet Development.
    <li> Applets can also (theoretically) use cookies to store information. This is prone to failure when users disable cookies.
    <li> To store information on the local file system (e.g. in user.home) or to use Preferences (AFAIU) would require trusted code.
    <li> If the user has the Next Generation Java Plug-In (Java 1.6.0_10+) it is possible to leverage the JNLP API services in an embedded & sand-boxed applet.
    Edited by: Andrew Thompson on Feb 1, 2011 9:32 AM

  • In a new Application, the ApplicationResources_en.properties file is not having the constraint messages created

    Hi Everyone:
              We are using JDev 11.1.2 and JHeadstart 11.1.2.  We have been having a multitude of problems when running applications through the migrator (and we have now been told by an Oracle consultant that the migrator is problematic), so we are trying to re-write things from scratch to bring them over from 11.1.1.4 to 11.1.2.
              I have been working on a simple application from scratch and discovered that the messages for constraints on the entities that I am using are not showing up in the ApplicationResources_en.properties.file.  We noticed a similar thing with converting an application using the migrator and that post is found here - java.lang.NullPointerException ADF_FACES-60097 message ***WITH SOLUTION*** -. 
              However, I didn't get a single reply to that thread. 
              I initially thought it was a migration issue, but this application is from scratch.  Whenever I tried to input an invalid value into a page column, the following exception would be received.
    "java.lang.NullPointerException  ADF_FACES-60097:For more information, please see the server's error log for an entry beginning with: ADF_FACES-60096:Server Exception during PPR, #"
               This Null Pointer turned out to be the missing message from the ApplicationResources_en.properties file.  In the new application I just wrote, I had to manually edit to add the following lines to the ApplicationResources_en.properties file and the application no longer gives me the error if I input an invalid value.
    VALIDATE_FEE_CATEGORY_3=Feecategory with this FeeCategory does not exist
    VALIDATE_ACADEMIC_TERM36=Academicterm with this EffectiveTermStart does not exist
    VALIDATE_ACADEMIC_TERM36_CASDEL=Cannot delete Academicterm while dependent Specialexchange exists
    VALIDATE_ACADEMIC_TERM37=Academicterm with this EffectiveTermEnd does not exist
    VALIDATE_ACADEMIC_TERM37_CASDEL=Cannot delete Academicterm while dependent Specialexchange exists
    VALIDATE_CURRENCY23=Currency with this Currency does not exist
    VALIDATE_CURRENCY23_CASDEL=Cannot delete Currency while dependent Specialexchange exists
    VALIDATE_FEE_CATEGORY_3=Feecategory with this FeeCategory does not exist
    VALIDATE_FEE_CATEGORY_3_CASDEL=Cannot delete Feecategory while dependent Specialexchange exists
    These constraints are found in the Entities .xml files  as shown below.  We are using a re-usable business components .jar file to import them in.
      <Key
        Name="UniqueFeeCategory"
        PrimaryKey="true">
        <DesignTime>
          <Attr Name="_DBObjectName" Value="UNIQUE_FEE_CATEGORY"/>
        </DesignTime>
        <AttrArray Name="Attributes">
          <Item
            Value="its.sis.uwbm.AREdit.entityobjects.Specialexchange.FeeCategory"/>
          <Item Value="its.sis.uwbm.AREdit.entityobjects.Specialexchange.Currency"/>
          <Item
            Value="its.sis.uwbm.AREdit.entityobjects.Specialexchange.EffectiveTermEnd"/>
        </AttrArray>
      </Key>
      <Key
        Name="ValidateAcademicTerm36">
        <DesignTime>
          <Attr Name="_referencedKey" Value="UNIQUE_ACADTERM_CODE"/>
          <Attr Name="_isForeign" Value="true"/>
          <Attr Name="_DBObjectName" Value="VALIDATE_ACADEMIC_TERM36"/>
        </DesignTime>
        <AttrArray Name="Attributes">
          <Item
            Value="its.sis.uwbm.AREdit.entityobjects.Specialexchange.EffectiveTermStart"/>
        </AttrArray>
      </Key>
      <Key
        Name="ValidateAcademicTerm37">
        <DesignTime>
          <Attr Name="_referencedKey" Value="UNIQUE_ACADTERM_CODE"/>
          <Attr Name="_isForeign" Value="true"/>
          <Attr Name="_DBObjectName" Value="VALIDATE_ACADEMIC_TERM37"/>
        </DesignTime>
        <AttrArray Name="Attributes">
          <Item
            Value="its.sis.uwbm.AREdit.entityobjects.Specialexchange.EffectiveTermEnd"/>
        </AttrArray>
      </Key>
      <Key
        Name="ValidateCurrency23">
        <DesignTime>
          <Attr Name="_referencedKey" Value="UNIQUE_CURRENCY_CODE"/>
          <Attr Name="_isForeign" Value="true"/>
          <Attr Name="_DBObjectName" Value="VALIDATE_CURRENCY23"/>
        </DesignTime>
        <AttrArray Name="Attributes">
          <Item Value="its.sis.uwbm.AREdit.entityobjects.Specialexchange.Currency"/>
        </AttrArray>
      </Key>
      <Key
        Name="ValidateFeeCategory3">
        <DesignTime>
          <Attr Name="_referencedKey" Value="UNIQUE_FEECAT_CODE"/>
          <Attr Name="_isForeign" Value="true"/>
          <Attr Name="_DBObjectName" Value="VALIDATE_FEE_CATEGORY_3"/>
        </DesignTime>
        <AttrArray Name="Attributes">
          <Item
            Value="its.sis.uwbm.AREdit.entityobjects.Specialexchange.FeeCategory"/>
        </AttrArray>
        Is this a known bug (I have searched and havent found it) and is there anything that I can do about it without having to manually add the messages?
    Mary
    UofW

    Hi Everyone:
               I have done some further testing.  We are using a re-usable Business Components .jar file to access our entities.  We import the .jar file into the project and create the ViewObjects and ViewLinks from that .jar file.
                It APPEARS that a test case using the HRSchema and using the Entities & Associates generates the constraint error messages, but when I use the .jar file of re-usable business components imported into the project, those constraint error messages are not created in the ApplicationResources_en.properties file.  I have created two testcases as well as the re-usable .jar file that I can send to you to show what I mean. 
                This behaviour seems to have shown up in 11.1.2 as there was no problem before this.
                 Please let me know where you'd like me to upload the testcases.
                 Thank you.
    Mary
    UofW

  • An Error Message when loading a Resource.properties File

    Hi, all:
    I tried to load a Resources.properties file in a JSP page:
    <%@ page import="java.util.*" %>
    <%
    ResourceBundle rb = null;
    try {
    rb = ResourceBundle.getBundle("Resources");
    } catch (MissingResourceException e) {
    rb = null;
    throw new RuntimeException("The resource is missing!");
    %>
    Test
    When I run it, I got the following error message:
    Error 500--Internal Server Error
    From RFC 2068 Hypertext Transfer Protocol -- HTTP/1.1:
    10.5.1 500 Internal Server Error
    The server encountered an unexpected condition which prevented it from fulfilling the request.
    Any ideas what's going on here?
    Thanks
    Jeff

    Hi,
    I had a similar error just a few days ago. I could solve it by replicating the datasources again and activating the transfer structures via rs_transtru_activate_all. After that the load went fine.
    regards
    Siggi

  • WEB-INF and properties files

    okay, this may be really naive and maybe i'm missing some key piece of
    documentation, but i'm missing something regarding the file structure with
    iplanet enterprise 4.1 on solaris.
    in my /usr/local/netscape/suitespot there's a docs directory that is the
    default docs directory.
    I've created a /WEB-INF directory under docs and a /classes directory under
    that. I've placed a jay.properties file in the /WEB-INF/classes directory,
    but when I try to access that through a servlet instantiated bean, I get an
    error from the ResourceBundle call, telling me that it can't load that
    properties file.
    I have two questions:
    1. did i build the WEB-INF directory in the correct place (ie - is this the
    standard way of working under the iplanet server) - this doesn't seem to be
    supported by the admin server in the sense that i can browse this directory,
    when i'd expect that iplanet would build in some basic security around the
    WEB-INF directory
    2. what do i name and where do i put the properties file? should it be
    jay_en.properties? i've tried a number of different scenarios with no luck.
    thanks...
    jay

    Why would you create a WEB-INF directory on the web tier?
    WEB-INF is a directory with a special meaning to the web container. All
    of your properties files and such will need to be placed on the
    application server tier, in the WEB-INF directory that was automatically
    created there. And you can do that just be properly placing them in the
    WAR file.
    David
    Jay Wright wrote:
    > okay, this may be really naive and maybe i'm missing some key piece
    > of documentation, but i'm missing something regarding the file
    > structure with iplanet enterprise 4.1 on solaris.
    >
    > in my /usr/local/netscape/suitespot there's a docs directory that is
    > the default docs directory.
    >
    > I've created a /WEB-INF directory under docs and a /classes
    > directory under that. I've placed a jay.properties file in the
    > /WEB-INF/classes directory, but when I try to access that through a
    > servlet instantiated bean, I get an error from the ResourceBundle
    > call, telling me that it can't load that properties file.
    >
    > I have two questions: 1. did i build the WEB-INF directory in the
    > correct place (ie - is this the standard way of working under the
    > iplanet server) - this doesn't seem to be supported by the admin
    > server in the sense that i can browse this directory, when i'd
    > expect that iplanet would build in some basic security around the WEB-INF
    > directory
    >
    > 2. what do i name and where do i put the properties file? should it
    > be jay_en.properties? i've tried a number of different scenarios
    > with no luck.
    >
    > thanks... jay
    >
    >
    >

  • PLEASE HELP. How do you access properties files in WEB-INF  and classes directory

    We have a war file that needs to access properties files that are in the WEB-INF directory
    of the war file. We also need to load one of the properties files from the classpath.
    However, when we deploy the application ( an ear which inlcludes an ejbjar and a
    war and the libraries both the ejbjar (with a manifest setting the classpath ) and
    war need ) the properties don't get extracted.
    In some of our servlets we are trying to access those files with the path "WEB-INF/foo.properties"
    and we get a FileNotFoundException. Then we check and see that NO properties files
    have been extracted into their appropriate places ( not even those we throw into
    the WEB-INF/classes directory ).
    PLEASE HELP,
    Christian Hargraves

    The file doesn't have to be extracted from the war. For example, you can place
    test.properties into your app WEB-INF and write a simple JSP to see how it
    works:
    <%
    InputStream in = application.getResourceAsStream("/WEB-INF/test.properties");
    %>
    It will return you a zip inputstream if you deployed your application as a .war.
    Christian Hargraves <[email protected]> wrote:
    I try this, but I get a NullPointerException. The file never actually gets extracted
    from the war. Under tomcat and resin this works great ( that's why I am having all
    of the trouble i am having ), but there are absolutely no properties files in the
    extracted directories for WebLogic deploys. only:
    WEB-INF/some_tmp_dir/WEB-INF/lib
    and then some dynamically generated jor file with all of the classes that would normally
    go in WEB-INF/classes ( all except the properties, of course, which are no where
    to be found. ).
    There has to be some kind of setting I am missing. Please don't make me seperate
    these properties files from the war/ear and then put the path to these properties
    files in the CLASSPATH, changing one step to three steps to deploy!!
    I have found a documented bug where you can't even put the properties files in a
    jar file and that bug will never be fixed for WebLogic 6.1.
    "Dimitri I. Rakitine" <[email protected]> wrote:
    To access files in WEB-INF you can use ServletContext.getResourceXXX("/WEB-INF/filename")
    Christian Hargraves <[email protected]> wrote:
    We have a war file that needs to access properties files that are in theWEB-INF directory
    of the war file. We also need to load one of the properties files fromthe classpath.
    However, when we deploy the application ( an ear which inlcludes an ejbjarand a
    war and the libraries both the ejbjar (with a manifest setting the classpath) and
    war need ) the properties don't get extracted.
    In some of our servlets we are trying to access those files with the path"WEB-INF/foo.properties"
    and we get a FileNotFoundException. Then we check and see that NO propertiesfiles
    have been extracted into their appropriate places ( not even those wethrow into
    the WEB-INF/classes directory ).
    PLEASE HELP,
    Christian Hargraves--
    Dimitri
    Dimitri

  • Log4j does not find properties file (but its in the classes directory)

    I am using eclipse, I have created a log4j object:
         private static Logger logger = Logger.getLogger(Http.class.getName());When I try to run the test case, I get:
    log4j:WARN No appenders could be found for logger (com.cable.comcast.nsec.common.Http).
    log4j:WARN Please initialize the log4j system properly.I usually run into this problem when the log4j.properties file is not in the 'classes' directory, but this time it is.
    atlantis@atlantis-laptop:~/workspace/ArborAPI$ cat .classpath | grep output
            <classpathentry kind="output" path="classes"/>
    atlantis@atlantis-laptop:~/workspace/ArborAPI$ ls -la classes/
    total 16
    drwxr-xr-x 3 atlantis atlantis 4096 2008-02-06 16:44 .
    drwxr-xr-x 7 atlantis atlantis 4096 2008-02-06 17:08 ..
    drwxr-xr-x 3 atlantis atlantis 4096 2008-02-06 16:35 com
    -rw-r--r-- 1 atlantis atlantis 2603 2008-02-06 16:44 log4j.propertiesAm I missing something?

    Sorry I was really busy the last few days. Thank you for your answers!
    I probably should have left out all the specifics of what the software was that I was packaging, because I think what I was really asking did not come across clearly. What I really wanted to know is:
    Why do I have to provide the "-I /usr/include/headers_dir" compiler option for some libraries but not for others, although the header files for each lie in a level 1 subdir of /usr/include?
    I thought that maybe there was some kind of index of installed libraries that I didn't know about, which I could have updated from within PKGBUILD (so I guess that's why I included it originally). Seems to me now, though, that this is not the case.
    I did put in some google time (but not lots b/c 1. hard to google and 2. busy) to find an answer, but to no avail and it's not really top priority right now (and quite honestly never will be, since there is the -I option), so I guess it'll have to wait, unless someone knows...
    ---EDIT---
    So, right after I posted this (stupid me) I had a little think and I finally understand, whats happening.
    1. Headers are not found without specifying the directory they are in.
    2. I need the -I option because easykf headers are not well formed.
    Thanks a lot!
    Last edited by maximax (2013-09-27 00:26:03)

  • File missing in petstore1.4

    Hi all,
    i unzipped the sample bundle of j2ee1.4 but i got an error while doing asant in the samples/bluprints/petstore1.4/src folder as the instructions say. The error is about java.io.FileNotFoundException: samples/common-ant.xml (No such file or directory). And also sample/common.properties file is missing.
    Can anyone explain me why are these files missing?
    Thank you all.

    Hi luker,
    I think the easies way is to copy the entire samples directory to the following folder, c:\Sun\AppServer\samples or any location that you installed the Sun application server. The missing files is at that location. The problem happens because we install the application server and the sample bundles separately and unfortunately we don't have any file mention this problem.
    Tell me if it works luker
    Regards,

  • How use properties file

    Hi i read about properties file in java .. i didn't get much more..
    how can we use this in program.. what is the benefit..
    anyone know any examples in site.please let me know about that

    int count=getGoogleSearchCount();
    public int getGoogleSearchCount(){
    search keyword="http://www.google.co.ke/search?hl=en&q=java+properties+class&btnG=Google+Search";
    // missing code
    return count;
    System.out.println(count);i ran the above code snipplet and guess the output?
    291,000 results.
    DONT BE LAZY.

  • SQLException: Message file missing

    I am using oracle thin driver (oracle 816 drivers) to connect my serlvet to the database. The current environment I am using is JDK/JRE 1.1.7B and the database is Oracle 7.3. (according to the FAQ section, this is allowed. 816 drivers are compatible).
    However, when I run my Servlet in the servlet container, I get the following:
    java.sql.SQLException: Message file "oracle.jdbc.dbaccess.Messages" is missing.
    I have the oracle jar file in the right location and is referenced in my classpath. I looked into the jar file and there is:
    oracle/jdbc/dbaccess/Message.class
    oracle/jdbc/dbaccess/Messages.properties
    but no:
    oracle/jdbc/dbaccess/Messages.class
    which the exception message leads me to think is missing. What file is actually missing? and how can I fix or work around this problem?
    null

    I too used to get this error when the classes111.zip was unzipped, but this should not cause any problem if classess111.zip is used in the classpath.
    It is trying to load the messages.properties
    as a resource.
    Do not use a deployment tool to pull all the required classes, they miss these kinda properties file and you end up in trouble.
    Check your IDE if any which may do this in the background.
    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by eliotrees:
    I am using oracle thin driver (oracle 816 drivers) to connect my serlvet to the database. The current environment I am using is JDK/JRE 1.1.7B and the database is Oracle 7.3. (according to the FAQ section, this is allowed. 816 drivers are compatible).
    However, when I run my Servlet in the servlet container, I get the following:
    java.sql.SQLException: Message file "oracle.jdbc.dbaccess.Messages" is missing.
    I have the oracle jar file in the right location and is referenced in my classpath. I looked into the jar file and there is:
    oracle/jdbc/dbaccess/Message.class
    oracle/jdbc/dbaccess/Messages.properties
    but no:
    oracle/jdbc/dbaccess/Messages.class
    which the exception message leads me to think is missing. What file is actually missing? and how can I fix or work around this problem?
    <HR></BLOCKQUOTE>
    null

  • Problems with struts MessageResources.properties files

    hi,
    I am a newbie in using struts. I have the following resources.
    Resources:
    java:j2sdk1.4.X
    struts:1.2.4
    webserver:tomcat 5
    jsp:2.0
    servlets:2.4
    IDE:Ecilipse 3.0 IDE
    Problem: I have copied the struts_blank.war file into tomcat webapps dir. Inside Ecilipse I create a new project and import the struts_blank.war file into the project. I type the URL (http://localhost:8080/proj_struts/Welcome.do)and it works file. However if i create any formbeans or any other java classes, the MessageResources.properties file gets deleted from my classes folder in my dir. What am i doing wrong. Is there any plugin for struts for Ecilipse.
    Questions:
    to be specific, where should/which folder should these .properties files be located. Should they be in classes or src folder under WEBINF?. I have seen the entry in strutsconfig.xml file. All it has is the following element relating to .properties.
    Fixes tried:
    I tried copying the MessageResources.properties file into the sources folder
    but i am not sure how to configure the Eclipse so that it reads the .properties file file from src folder insted of classes. I am definately sure thisis a dumb sol..but i donno wht else to do....
    <!-- ======================================== Message Resources Definitions -->
    <message-resources parameter="MessageResources" />
    It doesnt even say where is it looking(which folder).....
    Could some one throw some light on this issue and guide me thru this ordeal
    Regards
    AK

    Problem: I have copied the struts_blank.war file into
    tomcat webapps dir. Inside Ecilipse I create a new
    project and import the struts_blank.war file into the
    project. I type the URL
    (http://localhost:8080/proj_struts/Welcome.do)and it
    works file. However if i create any formbeans or any
    other java classes, the MessageResources.properties
    file gets deleted from my classes folder in my dir.No idea why this should happen.
    What am i doing wrong. Is there any plugin for struts
    for Ecilipse. http://easystruts.sourceforge.net/
    Questions:
    to be specific, where should/which folder should
    these .properties files be located. Should they be in
    classes or src folder under WEBINF?. I have seen the
    entry in strutsconfig.xml file. All it has is the
    following element relating to .properties.WEB-INF/classes, if nothing is specified :)
    Fixes tried:
    I tried copying the MessageResources.properties file
    into the sources folder
    but i am not sure how to configure the Eclipse so
    that it reads the .properties file file from src
    folder insted of classes. I am definately sure thisis
    a dumb sol..but i donno wht else to do....This solution may not be so dumb after all. The only thing you missed out was that Eclipse doesn't copy any files other than classes. Maybe a custom Ant script would have done such a trick :)
    <!-- ======================================== Message
    Resources Definitions -->
    <message-resources parameter="MessageResources"
    ces" />
    It doesnt even say where is it looking(which
    folder).....As I said earlier, it's looking in WEB-INF/classes

  • Visibilty of properties file.

    Hello ;-)
    I'm integrating part of my application written in pure Java with CEP's Bean. Are there any
    limitations for including properties file from project? I tried all combination of access connected
    with "project visibility" but it doesn't work.
    try {
    properties = new Properties();
    properties.load(new FileInputStream("NwbSVMQoSClassifier.properties"));
    properties.load(new FileInputStream("src/NwbSVMQoSClassifier.properties"));
    properties.load(new FileInputStream("procjet/src/NwbSVMQoSClassifier.properties"));
    ...etc.
    }Can I get explanation why? I'm forced to use real path
    "e:\project_path\src\NwbSVMQoSClassifier.properties"
    on application "published on server"...
    ps.
    - Got one bug in Exception, space is missing:
    "<2009-10-13 03:06:34 CEST> <Error> <CQLProcessor> <BEA-000000> <Unknown event type [TestQueryspecified in channel [testChannel]>"Two characters are missing there.. and sometimes server is not connecting right with eclipse later
    - Cleaning console in eclipse brakes output for next operation.. I'm forced to restart server.
    Bye.
    R.
    Edited by: zatzy on 2009-10-18 21:57

    zatzy wrote:
    >
    Anyway In moment where constructor of unknown type from external library is called You can see bug of console. Which seems to
    be conneced with GUI rather then communication. All invisible/missing informations are displayed for short time after restart of server.I'm sorry but I'm not sure I follow the steps you're taking to reach this problem. Can you give more details on how to reproduce this? Thanks!- Use helloWorld example
    - add to "project" jar library.. like JDBC driver or something
    - create JDBC object with call of constructor in final bean.
    When JDBC is not added to "Runtime" tab in plug-in editor of manifest, You can publish app ( why ? something is wrong with analyze of libraries ) and get Exception on output that JDBC class is "Not found". Next, please comment with JDBC constructor calll and press "Publish". Console is hanging ( hit on clear button gives the same result )I think what's happening here is that you're allowed to deploy the app because the problem doesn't occur until the Java VM tries to load the JDBC class, which isn't available because it's not packaged in your bundle JAR. There could potentially be some way to warn users if they have specified a library on the Runtime tab that isn't included in the bundle JAR on the Build tab, but it may be difficult to do this as this is all Eclipse's UI. We'll have to look into this.
    We'll also have to look into the console issue. I'm not sure what's going on there. There are however special requirements I think for loading JDBC drivers early in the server startup, so there may be some issue here that is specific to JDBC. I'm not very familiar with what they are though. Perhaps others who monitor this forum can chime in and say if using a JDBC library embedded in your bundle is a good idea or not. If we don't hear anything back, maybe you could post a separate JDBC-focused question with more information about your use case.

Maybe you are looking for