mvn install[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile (default-compile) on project lab-web: Compilation failure: Compilation failure:
[ERROR] /Users/sura/IdeaProjects/lab-web/src/main/java/ch/ildsoftware/lab/security/SecurityUserDetailsService.java:[45,84] error: cannot find symbol
[ERROR] variable user of type User
[ERROR] /Users/sura/IdeaProjects/lab-web/src/main/java/ch/ildsoftware/lab/controller/UserController.java:[38,50] error: cannot find symbol
[ERROR] variable user of type User
[ERROR] /Users/sura/IdeaProjects/lab-web/src/main/java/ch/ildsoftware/lab/controller/UserController.java:[44,35] error: cannot find symbol
[ERROR] variable user of type UserNewDTO
[ERROR] /Users/sura/IdeaProjects/lab-web/src/main/java/ch/ildsoftware/lab/controller/UserController.java:[44,55] error: cannot find symbol
[ERROR] variable user of type UserNewDTO
[ERROR] /Users/sura/IdeaProjects/lab-web/src/main/java/ch/ildsoftware/lab/controller/UserController.java:[44,72] error: cannot find symbolHere is that line 44:
userService.createUser(user.getUsername(), user.getEmail(), user.getPlainTextPassword());Whereas in User it’s simply
@Getter @Setter private String username;
@Getter @Setter private String passwordDigest;
@Getter @Setter private String email;The lombok Plugin in Intellij Idea is enabled, as well as the little tick in Annotation Processors in both locations (Mac).
1.) Intellij Idea -> Preferences -> Compiler -> Annotation Processors
2.) File -> Other Settings -> Default Settings -> Compiler -> Annotation Processors
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>1.16.4</version>
<scope>provided</scope>
</dependency>
...
<build>
<finalName>${project.artifactId}-${project.version}</finalName>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<configuration>
<source>${java-version}</source>
<target>${java-version}</target>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>install</id>
<phase>install</phase>
<goals>
<goal>sources</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.tomcat.maven</groupId>
<artifactId>tomcat7-maven-plugin</artifactId>
<version>2.2</version>
<configuration>
<path>/</path>
<httpsPort>8443</httpsPort>
<keystoreFile>${basedir}/other/keystore.jks</keystoreFile>
<keystorePass>secret</keystorePass>
</configuration>
</plugin>
</plugins>
</build>
Maven 3Java 1.8Lombok 1.16.4Tomcat 7.0.62
How can I get it to compile without errors?Thanks a lot.