Hello,
1)You might need to check the JNDI name you are referring to. It may be the case that DataSource you are trying to refer is not created successfully and hence the JNDI name is not bound to it.
AFAIK any
Java class running in the server process can access the DataSource just by instantiating the InitialContext.
Context ctx = new InitialContext();
DataSource ds = (DataSource)ctx.lookup("datasourcejndiname");
If your app client is running outside server process then you need to instantiate the InitialContext with the ProviderURL and InitialContextFactory(You need check this with websphere documentation)
2)Regarding Recommanded Approach using Datasource via EJB -
I am not able to understand this because as I mentioned before the DataSource is a server resource and can be accessed by any java class. While doing session beans if you need the the database connection then you would access the datasource from an EJB and use it to get the connection. But this does not mean your stand-alone app need to go through EJB to use the datasource.
3) If you are using a Spring configuration to inject the datasource in application then you can consider deploying your application as a webapplication. And load the spring context using ContextLoaderLister or ContextLoaderServlet. There must be other ways as well to load the spring configuration and get it used by your application client. But I think using webapp would be the most easiest of them all.
Hope this helps you.
regards,
amit