Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @Bean
- @Primary
- public DataSource businessDataSource() throws IllegalArgumentException, NamingException {
- JndiObjectFactoryBean dataSource = new JndiObjectFactoryBean();
- dataSource.setResourceRef(true);
- dataSource.setJndiName("MYDS");
- dataSource.afterPropertiesSet();
- return (DataSource) dataSource.getObject();
- }
Add Comment
Please, Sign In to add comment