• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Paul Clapham
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Liutauras Vilda
Saloon Keepers:
  • Tim Holloway
  • Carey Brown
  • Roland Mueller
  • Piet Souris
Bartenders:

Passing runtime parameters to EJB

 
Ranch Hand
Posts: 171
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,
I need to pass some parameters to my stateless session EJB (mail server info) at creation. Have looked in the associated deployment descriptors (ejb-jar.xml, etc) and see that there is no extensibility there. Anyone have any ideas about how to do this?
 
Ranch Hand
Posts: 113
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
We use properties files
 
Ranch Hand
Posts: 977
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
you can use from the ejb-jar.xml dd:

then from your implementation:

regards.
[ June 14, 2002: Message edited by: Marcos Maia ]
 
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
One Problem with setting these in the descriptor as env entries is, that it might be necessary to redeploy the app in the appserver(for changes).
(Unless of course the Appserver allows you to edit the descriptor while the App is running.
I worked on iPlanet and it requires a redeploy.
I think weblogic allows you to edit descriptors through admin console.Correct me If I'm wrong!
)
Properties file seems to be more easier to manage.
 
Marcos Maia
Ranch Hand
Posts: 977
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by seshu kumar:
One Problem with setting these in the descriptor as env entries is, that it might be necessary to redeploy the app in the appserver(for changes).
(Unless of course the Appserver allows you to edit the descriptor while the App is running.
I worked on iPlanet and it requires a redeploy.
I think weblogic allows you to edit descriptors through admin console.Correct me If I'm wrong!
)
Properties file seems to be more easier to manage.



Hi,
Yes, you�re wrigth about WebLogic 6x, you can edit the dd through the admin console.
 
Ranch Hand
Posts: 312
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is it possible to pass runtime properties for a servlet.
Regards,
Raman.
 
Saloon Keeper
Posts: 28758
211
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Malli Subramanian Raman:
[QB]Is it possible to pass runtime properties for a servlet.


If it wasn't, Struts wouldn't work.
Both properties files and the web.xml file are available, in addition to the runtime environmental sources such as JNDI.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic