question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

java.lang.ClassNotFoundException: org.springframework.dao.DataAccessException

See original GitHub issue

When ‘org.springframework.boot:spring-boot-starter-web’ dependency is only added and

run the following code:

@EnableAutoConfiguration
@ComponentScan
public class Application {

    public static void main(String[] args) {
        SpringApplication.run(Application.class);
    }

}

Got the following exception:

java.lang.ClassNotFoundException: org.springframework.dao.DataAccessException

I think there’s no reason to get the above exception.

Issue Analytics

  • State:closed
  • Created 9 years ago
  • Comments:12 (8 by maintainers)

github_iconTop GitHub Comments

2reactions
snicollcommented, Nov 6, 2014

Well, maybe you should have 😃

Here’s the exception you have in the logs

Caused by: java.lang.IllegalStateException: Could not evaluate condition owing to internal class not found. This can happen if you are @ComponentScanning a springframework package (e.g. if you put a @ComponentScan in the default package by mistake)
1reaction
snicollcommented, Aug 31, 2015

As I told you on stackoverflow already, you probably have one class in the default package that has component scan (defaut package = no package statement in the class). If that’s not the case, please create a separate issue with a sample project that reproduces the problem.

Read more comments on GitHub >

github_iconTop Results From Across the Web

NoClassDefFoundError: DataAccessException using spring
Class : org.springframework.dao.DataAccessException is defined in Spring-DAO. Check if have below dependency.
Read more >
org.springframework.dao.DataAccessException (Example)
There is one possible error with Thymeleaf: ClassNotFoundException: org.springframework.dao.DataAccessException The cause is: The use of...
Read more >
CannotGetJdbcConnectionExce...
org.springframework.jdbc. Class CannotGetJdbcConnectionException ... Fatal exception thrown when we can't connect to an RDBMS using JDBC. Author: Rod Johnson; See ...
Read more >
java.lang.NoClassDefFoundError: org/springframework/dao ...
开发搭建ssm框架时,遇到java.lang.NoClassDefFoundError: org/springframework/dao/DataAccessException异常,如何处理? 在这里插入图片描述. 查看 ...
Read more >
Serialized Form (spring-tx 4.1.2.RELEASE API) - Javadoc.io
DataAccessException extends org.springframework.core. ... Package org.springframework.dao.annotation ... DelegatingConnectionFactory extends java.lang.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found