how can i locate the properties files within a ejb container?

Discussions

EJB programming & troubleshooting: how can i locate the properties files within a ejb container?

  1. how can i locate the properties files within a ejb container? (1 messages)

    when i develop servlet+javabean structure application,in order to imploement decoupling,i would like to write the config information in the properties files(key-value pair),in servlet,i use "getResourceAsStream(String relativePath)" method to retrieve the configuration information from the properties files(i even write the SQL clause in the files),it alwsys works well.
    now,i want to implement such function within the ejb container,that is to read a properties file from session bean,but i don't know how can i locate the file within the ejb container by using relative path,i wonder if there is the same method within ejb container as "getResourceAsStream(.......)" method within servlet container?

    thanks for any helps!
    the code snippet is appreciated!
  2. property files can be load by ejb container/ servlet container by using java ResourceBundle class. also u can load the properties file by the servlet container by writing a class(xyzloadingmanager) to load the properties file and the loading can be in the init method of the controller servlet. hope this help or else mail me at anillingutla at yahoo dot com so that we can discuss more about this.