+
diff --git a/integration/entity-view-spring-6.0/pom.xml b/integration/entity-view-spring-6.0/pom.xml
index 25d811d75c..73d26c74a2 100644
--- a/integration/entity-view-spring-6.0/pom.xml
+++ b/integration/entity-view-spring-6.0/pom.xml
@@ -36,7 +36,7 @@
${project.groupId}
- blaze-persistence-entity-view-api-jakarta
+ blaze-persistence-entity-view-api
${project.groupId}
@@ -55,13 +55,21 @@
jakarta.persistence
jakarta.persistence-api
- ${version.jakarta-jpa-api}
+ provided
+
+
+ jakarta.inject
+ jakarta.inject-api
+ provided
+
+
+ jakarta.enterprise
+ jakarta.enterprise.cdi-api
provided
jakarta.transaction
jakarta.transaction-api
- ${version.jakarta-jta}
provided
@@ -69,13 +77,12 @@
${project.groupId}
- blaze-persistence-entity-view-impl-jakarta
+ blaze-persistence-core-impl
test
- jakarta.inject
- jakarta.inject-api
- 2.0.1
+ ${project.groupId}
+ blaze-persistence-entity-view-impl
test
@@ -90,39 +97,4 @@
-
-
-
- org.moditect
- moditect-maven-plugin
-
-
- add-module-infos
- package
-
- add-module-info
-
-
-
-
- module ${module.name} {
- requires java.sql;
- requires java.persistence;
- requires spring.core;
- requires spring.beans;
- requires spring.context;
- requires com.blazebit.persistence.view;
- exports com.blazebit.persistence.integration.view.spring;
- exports com.blazebit.persistence.integration.view.spring.impl to spring.beans;
- opens com.blazebit.persistence.integration.view.spring.impl to spring.core, spring.context;
- provides com.blazebit.persistence.view.spi.TransactionAccessFactory with com.blazebit.persistence.integration.view.spring.impl.SpringTransactionAccessFactory;
- }
-
-
-
-
-
-
-
-
diff --git a/integration/entity-view-spring-6.0/src/main/java/module-info.java b/integration/entity-view-spring-6.0/src/main/java/module-info.java
new file mode 100644
index 0000000000..1253cfc089
--- /dev/null
+++ b/integration/entity-view-spring-6.0/src/main/java/module-info.java
@@ -0,0 +1,20 @@
+/*
+ * SPDX-License-Identifier: Apache-2.0
+ * Copyright Blazebit
+ */
+module com.blazebit.persistence.integration.view.spring {
+ requires java.sql;
+ requires jakarta.persistence;
+ requires spring.core;
+ requires spring.beans;
+ requires spring.context;
+ requires com.blazebit.persistence.view;
+ requires spring.tx;
+ requires jakarta.transaction;
+ exports com.blazebit.persistence.integration.view.spring;
+ exports com.blazebit.persistence.integration.view.spring.impl to spring.beans;
+ opens com.blazebit.persistence.integration.view.spring.impl to spring.core, spring.context;
+ // This also opens up the XSD file
+ opens com.blazebit.persistence.integration.view.spring;
+ provides com.blazebit.persistence.view.spi.TransactionAccessFactory with com.blazebit.persistence.integration.view.spring.impl.SpringTransactionAccessFactory;
+}
\ No newline at end of file
diff --git a/integration/entity-view-spring/pom.xml b/integration/entity-view-spring/pom.xml
deleted file mode 100644
index c3c4e97602..0000000000
--- a/integration/entity-view-spring/pom.xml
+++ /dev/null
@@ -1,261 +0,0 @@
-
-
-
-
- blaze-persistence-integration
- com.blazebit
- 1.6.14-SNAPSHOT
-
- 4.0.0
-
- Blazebit Persistence Integration Entity-View Spring
- blaze-persistence-integration-entity-view-spring
- jar
-
-
- com.blazebit.persistence.integration.view.spring
-
-
-
-
-
- org.springframework
- spring-framework-bom
- ${version.spring}
- import
- pom
-
-
-
-
-
-
- ${project.groupId}
- blaze-persistence-entity-view-api
-
-
- ${project.groupId}
- blaze-common-utils
-
-
- org.springframework
- spring-context
- provided
-
-
- jakarta.persistence
- jakarta.persistence-api
- provided
-
-
- jakarta.transaction
- jakarta.transaction-api
- ${version.jta}
- provided
-
-
-
-
-
- ${project.groupId}
- blaze-persistence-entity-view-impl
- test
-
-
- javax.inject
- javax.inject
- 1
- test
-
-
- org.springframework
- spring-test
- test
-
-
- junit
- junit
- test
-
-
-
-
-
-
- org.moditect
- moditect-maven-plugin
-
-
- add-module-infos
- package
-
- add-module-info
-
-
-
-
- module ${module.name} {
- requires java.sql;
- requires java.persistence;
- requires spring.core;
- requires spring.beans;
- requires spring.context;
- requires com.blazebit.persistence.view;
- exports com.blazebit.persistence.integration.view.spring;
- exports com.blazebit.persistence.integration.view.spring.impl to spring.beans;
- opens com.blazebit.persistence.integration.view.spring.impl to spring.core, spring.context;
- provides com.blazebit.persistence.view.spi.TransactionAccessFactory with com.blazebit.persistence.integration.view.spring.impl.SpringTransactionAccessFactory;
- }
-
-
-
-
-
-
-
-
-
-
-
-
- spring-data-1.11.x
-
- ${version.spring-data-1.x-spring}
-
-
-
-
- org.springframework.data
- spring-data-jpa
- ${version.spring-data-1.x}
- provided
-
-
-
-
- spring-data-2.0.x
-
- ${version.spring-data-2.0-spring}
-
-
-
- org.springframework.data
- spring-data-jpa
- ${version.spring-data-2.0}
- provided
-
-
-
-
- spring-data-2.1.x
-
- ${version.spring-data-2.1-spring}
- 1.8
-
-
-
- org.springframework.data
- spring-data-jpa
- ${version.spring-data-2.1}
- provided
-
-
-
-
- spring-data-2.2.x
-
- ${version.spring-data-2.2-spring}
- 1.8
-
-
-
- org.springframework.data
- spring-data-jpa
- ${version.spring-data-2.2}
- provided
-
-
-
-
- spring-data-2.3.x
-
- ${version.spring-data-2.3-spring}
- 1.8
-
-
-
- org.springframework.data
- spring-data-jpa
- ${version.spring-data-2.3}
- provided
-
-
-
-
- spring-data-2.4.x
-
- ${version.spring-data-2.4-spring}
- 1.8
-
-
-
- org.springframework.data
- spring-data-jpa
- ${version.spring-data-2.4}
- provided
-
-
-
-
- spring-data-2.5.x
-
- ${version.spring-data-2.5-spring}
- 1.8
-
-
-
- org.springframework.data
- spring-data-jpa
- ${version.spring-data-2.5}
- provided
-
-
-
-
- spring-data-2.6.x
-
- ${version.spring-data-2.6-spring}
- 1.8
-
-
-
- org.springframework.data
- spring-data-jpa
- ${version.spring-data-2.6}
- provided
-
-
-
-
- spring-data-2.7.x
-
- true
-
-
- ${version.spring-data-2.7-spring}
- 1.8
-
-
-
- org.springframework.data
- spring-data-jpa
- ${version.spring-data-2.7}
- provided
-
-
-
-
-
\ No newline at end of file
diff --git a/integration/entity-view-spring/src/main/java/com/blazebit/persistence/integration/view/spring/EnableEntityViews.java b/integration/entity-view-spring/src/main/java/com/blazebit/persistence/integration/view/spring/EnableEntityViews.java
deleted file mode 100644
index 97f34c19b3..0000000000
--- a/integration/entity-view-spring/src/main/java/com/blazebit/persistence/integration/view/spring/EnableEntityViews.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- * Copyright Blazebit
- */
-package com.blazebit.persistence.integration.view.spring;
-
-import com.blazebit.persistence.integration.view.spring.impl.EntityViewRegistrar;
-import org.springframework.context.annotation.ComponentScan;
-import org.springframework.context.annotation.Import;
-import org.springframework.core.annotation.AliasFor;
-
-import java.lang.annotation.Documented;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-/**
- * Annotation to enable entity view scanning. By enabling scanning, a bean for {@link com.blazebit.persistence.view.spi.EntityViewConfiguration} is made available.
- *
- * @author Moritz Becker
- * @since 1.2.0
- */
-@Retention(RetentionPolicy.RUNTIME)
-@Target(ElementType.TYPE)
-@Documented
-@Import(EntityViewRegistrar.class)
-public @interface EnableEntityViews {
- /**
- * Alias for {@link #basePackages}.
- * Allows for more concise annotation declarations if no other attributes
- * are needed — for example, {@code @ComponentScan("org.my.pkg")}
- * instead of {@code @ComponentScan(basePackages = "org.my.pkg")}.
- */
- @AliasFor("basePackages")
- String[] value() default {};
-
- /**
- * Base packages to scan for annotated components.
- *
{@link #value} is an alias for (and mutually exclusive with) this
- * attribute.
- *
Use {@link #basePackageClasses} for a type-safe alternative to
- * String-based package names.
- */
- @AliasFor("value")
- String[] basePackages() default {};
-
- /**
- * Type-safe alternative to {@link #basePackages} for specifying the packages
- * to scan for annotated components. The package of each class specified will be scanned.
- *
Consider creating a special no-op marker class or interface in each package
- * that serves no purpose other than being referenced by this attribute.
- */
- Class>[] basePackageClasses() default {};
-
- /**
- * Specifies which types are eligible for component scanning. Further narrows the set of candidate components from
- * everything in {@link #basePackages()} to everything in the base packages that matches the given filter or filters.
- */
- ComponentScan.Filter[] includeFilters() default {};
-
- /**
- * Specifies which types are not eligible for component scanning.
- */
- ComponentScan.Filter[] excludeFilters() default {};
-}
diff --git a/integration/entity-view-spring/src/main/java/com/blazebit/persistence/integration/view/spring/impl/AbstractEntityViewConfigurationSource.java b/integration/entity-view-spring/src/main/java/com/blazebit/persistence/integration/view/spring/impl/AbstractEntityViewConfigurationSource.java
deleted file mode 100644
index b42a58b5eb..0000000000
--- a/integration/entity-view-spring/src/main/java/com/blazebit/persistence/integration/view/spring/impl/AbstractEntityViewConfigurationSource.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- * Copyright Blazebit
- */
-
-package com.blazebit.persistence.integration.view.spring.impl;
-
-import org.springframework.beans.factory.config.BeanDefinition;
-import org.springframework.core.env.Environment;
-import org.springframework.core.io.ResourceLoader;
-import org.springframework.core.type.filter.TypeFilter;
-
-import java.util.Collection;
-import java.util.HashSet;
-import java.util.Set;
-
-/**
- * @author Moritz Becker
- * @since 1.2.0
- */
-public abstract class AbstractEntityViewConfigurationSource {
-
- private final Environment environment;
-
- public AbstractEntityViewConfigurationSource(Environment environment) {
- this.environment = environment;
- }
-
- public abstract Iterable getBasePackages();
-
- protected abstract Iterable getExcludeFilters();
-
- protected abstract Iterable getIncludeFilters();
-
- public Collection getCandidates(ResourceLoader resourceLoader) {
- EntityViewComponentProvider scanner = new EntityViewComponentProvider(getIncludeFilters());
-// scanner.setConsiderNestedRepositoryInterfaces(shouldConsiderNestedRepositories());
- scanner.setResourceLoader(resourceLoader);
- scanner.setEnvironment(environment);
-
- for (TypeFilter filter : getExcludeFilters()) {
- scanner.addExcludeFilter(filter);
- }
-
- Set result = new HashSet();
-
- for (String basePackage : getBasePackages()) {
- Set candidate = scanner.findCandidateComponents(basePackage);
- result.addAll(candidate);
- }
-
- return result;
- }
-}
diff --git a/integration/entity-view-spring/src/main/java/com/blazebit/persistence/integration/view/spring/impl/AnnotationEntityViewConfigurationSource.java b/integration/entity-view-spring/src/main/java/com/blazebit/persistence/integration/view/spring/impl/AnnotationEntityViewConfigurationSource.java
deleted file mode 100644
index d8fe67478a..0000000000
--- a/integration/entity-view-spring/src/main/java/com/blazebit/persistence/integration/view/spring/impl/AnnotationEntityViewConfigurationSource.java
+++ /dev/null
@@ -1,168 +0,0 @@
-/*
- * SPDX-License-Identifier: Apache-2.0
- * Copyright Blazebit
- */
-
-package com.blazebit.persistence.integration.view.spring.impl;
-
-import org.springframework.beans.BeanUtils;
-import org.springframework.context.annotation.FilterType;
-import org.springframework.core.annotation.AnnotationAttributes;
-import org.springframework.core.env.Environment;
-import org.springframework.core.io.ResourceLoader;
-import org.springframework.core.type.AnnotationMetadata;
-import org.springframework.core.type.filter.AnnotationTypeFilter;
-import org.springframework.core.type.filter.AspectJTypeFilter;
-import org.springframework.core.type.filter.AssignableTypeFilter;
-import org.springframework.core.type.filter.RegexPatternTypeFilter;
-import org.springframework.core.type.filter.TypeFilter;
-import org.springframework.util.Assert;
-import org.springframework.util.ClassUtils;
-
-import java.lang.annotation.Annotation;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-import java.util.regex.Pattern;
-
-/**
- * @author Moritz Becker
- * @since 1.2.0
- */
-public class AnnotationEntityViewConfigurationSource extends AbstractEntityViewConfigurationSource {
-
- private static final String BASE_PACKAGES = "basePackages";
- private static final String BASE_PACKAGE_CLASSES = "basePackageClasses";
-
- private final AnnotationMetadata configMetadata;
- private final AnnotationAttributes attributes;
- private final ResourceLoader resourceLoader;
-
- public AnnotationEntityViewConfigurationSource(AnnotationMetadata metadata, Class extends Annotation> annotation,
- ResourceLoader resourceLoader, Environment environment) {
- super(environment);
- Assert.notNull(metadata);
- Assert.notNull(annotation);
- Assert.notNull(resourceLoader);
-
- this.attributes = new AnnotationAttributes(metadata.getAnnotationAttributes(annotation.getName()));
- this.configMetadata = metadata;
- this.resourceLoader = resourceLoader;
- }
-
- /*
- * (non-Javadoc)
- * @see org.springframework.data.repository.config.RepositoryConfigurationSource#getBasePackages()
- */
- @Override
- public Iterable getBasePackages() {
-
- String[] value = attributes.getStringArray("value");
- String[] basePackages = attributes.getStringArray(BASE_PACKAGES);
- Class>[] basePackageClasses = attributes.getClassArray(BASE_PACKAGE_CLASSES);
-
- // Default configuration - return package of annotated class
- if (value.length == 0 && basePackages.length == 0 && basePackageClasses.length == 0) {
- String className = configMetadata.getClassName();
- return Collections.singleton(ClassUtils.getPackageName(className));
- }
-
- Set packages = new HashSet();
- packages.addAll(Arrays.asList(value));
- packages.addAll(Arrays.asList(basePackages));
-
- for (Class> typeName : basePackageClasses) {
- packages.add(ClassUtils.getPackageName(typeName));
- }
-
- return packages;
- }
-
- protected Iterable getIncludeFilters() {
- return parseFilters("includeFilters");
- }
-
- protected Iterable getExcludeFilters() {
- return parseFilters("excludeFilters");
- }
-
- private Set parseFilters(String attributeName) {
- Set