Advertisement
Guest User

Untitled

a guest
Jul 20th, 2017
46
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.02 KB | None | 0 0
  1. @Data
  2. @Entity
  3. @Table(name = "address")
  4. public class Address {
  5.  
  6. @Id
  7. @GeneratedValue(strategy = GenerationType.AUTO)
  8. private long id;
  9.  
  10. @Column(name = "city")
  11. private String city;
  12. // ...........................
  13. }
  14.  
  15. <dependency>
  16. <groupId>org.springframework.boot</groupId>
  17. <artifactId>spring-boot-starter-data-jpa</artifactId>
  18. </dependency>
  19.  
  20. 2017-07-20 22:47:22 [main] WARN o.s.b.c.e.AnnotationConfigEmbeddedWebApplicationContext - Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'org.springframework.boot.autoconfigure.orm.jpa.HibernateJpaAutoConfiguration': Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [org/springframework/boot/autoconfigure/jdbc/DataSourceConfiguration$Tomcat.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.apache.tomcat.jdbc.pool.DataSource]: Factory method 'dataSource' threw exception; nested exception is org.springframework.boot.autoconfigure.jdbc.DataSourceProperties$DataSourceBeanCreationException: Cannot determine embedded database driver class for database type NONE. If you want an embedded database please put a supported one on the classpath. If you have database settings to be loaded from a particular profile you may need to active it (no profiles are currently active).
  21. 2017-07-20 22:47:22 [main] INFO o.a.catalina.core.StandardService - Stopping service Tomcat
  22.  
  23. <dependency>
  24. <groupId>org.springframework.boot</groupId>
  25. <artifactId>spring-boot-starter-data-jpa</artifactId>
  26. </dependency>
  27.  
  28. <dependency>
  29. <groupId>org.hibernate.javax.persistence</groupId>
  30. <artifactId>hibernate-jpa-2.0-api</artifactId>
  31. <version>1.0.1.Final</version>
  32. </dependency>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement