on-internet
← Community

Error creating bean with name 'sqlSessionFactory' ... Invocation of init method failed; nested exception is java.lang.NullPointerException

Stack Overflow ·

I'm trying to integrate spring-mybatis in my application. I'm using spring 4.1.4 and mybatis 3.2.8 java 7 and the server is WebSphere Application Server Liberty. I'm using a spring java configuration class. This error is showing only when I'm deploying the war file, if I'm using Eclipse to deploy the project everything is ok. Deploying in Tomcat 8 is working too. @Configuration @MapperScan("x.y.z.mappers") @PropertySource("classpath:/x/y/z/data_source.properties") @EnableTransactionManagement public class DataAccessConfiguration { @Autowired private Environment env; @Bean public DataSource dat

Comments

Sign in or sign up to comment and upvote.

No comments yet.