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

Accessing DataSource

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi
I want to access JNDI DataSource created in WebSphere through a java program/client. This java file does not exist in the same classloader and sits outside the class loader(classloader - where webshpere running). How do I access the DataSource in WebSphere? Help is really appreciated.
Thanks
Leela.
[ February 12, 2004: Message edited by: leela kali ]
 
author
Posts: 11962
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
First of all, if you're going to use WebSphere, I'd strongly suggest taking a look at IBM Redbooks | WebSphere -- there's a lot of useful handbooks teaching to use the WebSphere tools.
As to your question about accessing the DataSource from a standalone client, the difference from the regular situation (servlet accessing a DataSource within the same server instance) is in how you obtain an InitialContext for the JNDI tree.
Here's how you need to do it in a standalone client:
 
leela kali
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Lasse,
Thanks for your immediate response. What security credentials I need to pass to the hash table. I am accessing Data Source through pure stand alone java client not a servlet.
Help is really appreciated and thanks for sparing your time.
 
I claim this furniture in the name of The Ottoman Empire! You can keep this 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