Win a copy of TDD for a Shopping Website LiveProject this week in the Testing forum!
  • 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
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

Loopup JMS resource in Sun One Application Server

 
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I am having problem to lookup JMS factory and resource from a stand-alone Java application.
Executing the following code will throw NameNotFoundException,

jndiContext = new InitialContext();
connectionFactory = (ConnectionFactory) jndiContext.lookup(
"jms/myQueue");

I know I have to set some System property like JMS provider URL ... etc,
and I like to set those properties and content in the Java Class instead of an other property file,

Would someone tell me how to do that?
I am very frustrated on Sun J2EE 1.4 tutorial's instruction that they have very limited information on this, not sure if they want to teach you or just get you confused....
 
It's just like a fortune cookie, but instead of a cookie, it's pie. And we'll call it ... tiny ad:
free, earth-friendly heat - a kickstarter for putting coin in your pocket while saving the earth
https://coderanch.com/t/751654/free-earth-friendly-heat-kickstarter
reply
    Bookmark Topic Watch Topic
  • New Topic