Spring 数据访问 之 JNDI
Many Java EE application servers build in data source implementations that you can configure from the server console or in configuration files. If you have a data source configured in an application server and exposed for JNDI lookup, you can use JndiObjectFactoryBean to look it up. 很多JAVA EE应用服务器都有内建的DataSource实现 我们可以通过服务器控制台或者配置文件来进行设置,如果你有一个配置好的应用服务器的datasource并且暴露给了JNDI来进行查找,那么你可以使用JndiObjectFactoryBean来找到它 [code="xml"] [/code] In Spring, a JNDI lookup can be simplified by the jndi-lookup element defined in the jee sjee schema. 在Spring里 通过使用JEE Schema定义的jndi-lookup元素来设置一个JNDI查找是很简单的事情。 [code="xml"] ... [/code]