Я следую инструкциям на https://spring.io/guides/gs/accessing-data-mysql/, чтобы начать использовать проект MySQL для Gradle, однако, когда я пытаюсь добавить в аннотацию @Entity все это
Вот мой build.gradle, который повторяет то же самое на сайте:
buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath("org.springframework.boot:spring-boot-gradle-plugin:2.0.5.RELEASE")
}
}
apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'idea'
apply plugin: 'org.springframework.boot'
apply plugin: 'io.spring.dependency-management'
bootJar {
baseName = 'gs-accessing-data-mysql'
version = '0.1.0'
}
repositories {
mavenCentral()
}
sourceCompatibility = 1.8
targetCompatibility = 1.8
dependencies {
compile("org.springframework.boot:spring-boot-starter-web")
// JPA Data (We are going to use Repositories, Entities, Hibernate, etc...)
compile 'org.springframework.boot:spring-boot-starter-data-jpa'
compile group: 'javax.persistence', name: 'persistence-api', version: '1.0'
// Use MySQL Connector-J
compile 'mysql:mysql-connector-java'
testCompile('org.springframework.boot:spring-boot-starter-test')
}