Skip to content

Commit 72011ca

Browse files
committed
Remove dependency on javax.inject from querydsl.
To use querydsl, the spring application will need to add a dependency <dependency> <groupId>com.querydsl</groupId> <artifactId>querydsl-apt</artifactId> <version>${querydsl}</version> <classifier>jakarta</classifier> <scope>provided</scope> </dependency> And explicitly specify CouchbasseAnnotationProcessor <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <executions> <execution> <id>annotation-processing</id> <phase>generate-sources</phase> <goals> <goal>compile</goal> </goals> <configuration> <proc>only</proc> <annotationProcessors> <annotationProcessor>org.springframework.data.couchbase.repository.support.CouchbaseAnnotationProcessor</annotationProcessor> </annotationProcessors> <generatedTestSourcesDirectory>target/generated-test-sources</generatedTestSourcesDirectory> <compilerArgs> <arg>-Aquerydsl.logInfo=true</arg> </compilerArgs> </configuration> </execution> </executions> </plugin> Closes #1989.
1 parent 756a8c5 commit 72011ca

File tree

3 files changed

+2
-18
lines changed

3 files changed

+2
-18
lines changed

pom.xml

+1-16
Original file line numberDiff line numberDiff line change
@@ -47,19 +47,7 @@
4747
<artifactId>querydsl-apt</artifactId>
4848
<version>${querydsl}</version>
4949
<classifier>jakarta</classifier>
50-
<exclusions>
51-
<exclusion>
52-
<groupId>javax.inject</groupId>
53-
<artifactId>javax.inject</artifactId>
54-
</exclusion>
55-
</exclusions>
56-
</dependency>
57-
58-
<dependency>
59-
<groupId>javax.inject</groupId>
60-
<artifactId>javax.inject</artifactId>
61-
<version>1</version>
62-
<scope>test</scope>
50+
<scope>provided</scope>
6351
</dependency>
6452

6553
<dependency>
@@ -261,9 +249,6 @@
261249
<plugin>
262250
<groupId>org.apache.maven.plugins</groupId>
263251
<artifactId>maven-compiler-plugin</artifactId>
264-
<configuration>
265-
<proc>none</proc>
266-
</configuration>
267252
<executions>
268253
<execution>
269254
<id>test-annotation-processing</id>

src/main/java/org/springframework/data/couchbase/repository/support/CouchbaseAnnotationProcessor.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ public boolean process(Set<? extends TypeElement> annotations, RoundEnvironment
7979
return ALLOW_OTHER_PROCESSORS_TO_CLAIM_ANNOTATIONS;
8080
}
8181

82-
Configuration conf = createConfiguration(roundEnv);
82+
Configuration conf = createConfiguration(roundEnv);
8383
try {
8484
conf.getTypeMappings();
8585
} catch (NoClassDefFoundError cnfe ){

src/main/resources/META-INF/services/javax.annotation.processing.Processor

-1
This file was deleted.

0 commit comments

Comments
 (0)