Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,10 @@
import com.blazebit.persistence.view.EntityViews;
import com.blazebit.persistence.view.spi.EntityViewConfiguration;
import com.blazebit.persistence.view.spi.EntityViewMapping;
import io.quarkus.builder.Version;
import io.quarkus.deployment.annotations.BuildProducer;
import io.quarkus.deployment.annotations.BuildStep;
import io.quarkus.deployment.builditem.AdditionalApplicationArchiveMarkerBuildItem;
import io.quarkus.deployment.builditem.AdditionalIndexedClassesBuildItem;
import io.quarkus.deployment.builditem.CapabilityBuildItem;
import io.quarkus.deployment.builditem.CombinedIndexBuildItem;
import io.quarkus.deployment.builditem.FeatureBuildItem;
import io.quarkus.deployment.builditem.nativeimage.ReflectiveClassBuildItem;
Expand Down Expand Up @@ -67,7 +65,6 @@
*/
class BlazePersistenceProcessor {

static final String CAPABILITY = "com.blazebit.persistence.integration.quarkus";
static final String FEATURE = "blaze-persistence";

private static final Logger LOG = Logger.getLogger(BlazePersistenceProcessor.class);
Expand All @@ -76,17 +73,6 @@ class BlazePersistenceProcessor {
private static final DotName BLAZE_PERSISTENCE_INSTANCE_REPEATABLE_CONTAINER = DotName
.createSimple(BlazePersistenceInstance.List.class.getName());

@BuildStep
CapabilityBuildItem capability() {
String version = Version.getVersion();
int dotIndex = version.indexOf('.');
// As of version Quarkus 2, the capabilities are read from the extension descriptor
if (dotIndex == -1 || Integer.parseInt(version.substring(0, dotIndex)) >= 2) {
return null;
}
return new CapabilityBuildItem(CAPABILITY);
}
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think it's worth keeping that for new versions given Quarkus 2 is there for quite a while now and there's very little chance people would use new versions of the extension with it.


@BuildStep
FeatureBuildItem feature() {
return new FeatureBuildItem(FEATURE);
Expand Down
21 changes: 20 additions & 1 deletion integration/quarkus/runtime/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,25 @@
</resource>
</resources>
<plugins>
<plugin>
<groupId>io.quarkus</groupId>
<artifactId>quarkus-bootstrap-maven-plugin</artifactId>
Copy link
Copy Markdown
Contributor Author

@gsmet gsmet Jan 1, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@aloubyansky can you check I did things properly? I checked the metadata and they look fine now.

Metadata are:

---
name: "Blaze-Persistence"
metadata:
  short-name: "BP"
  keywords:
  - "jpa"
  - "hibernate"
  - "blaze-persistence"
  - "entity-view"
  - "dto"
  - "mapper"
  - "sql"
  guide: "https://quarkus.io/guides/blaze-persistence"
  categories:
  - "data"
  status: "stable"
  built-with-quarkus-core: "2.6.1.Final"
  capabilities:
    provides:
    - "com.blazebit.persistence.integration.quarkus"
  extension-dependencies:
  - "io.quarkus:quarkus-core"
  - "io.quarkus:quarkus-hibernate-orm"
  - "io.quarkus:quarkus-agroal"
  - "io.quarkus:quarkus-arc"
  - "io.quarkus:quarkus-datasource"
  - "io.quarkus:quarkus-narayana-jta"
  - "io.quarkus:quarkus-mutiny"
  - "io.quarkus:quarkus-smallrye-context-propagation"
  - "io.quarkus:quarkus-caffeine"
artifact: "com.blazebit:blaze-persistence-integration-quarkus::jar:1.6.5-SNAPSHOT"
description: "Advanced SQL support for JPA and Entity-Views as efficient DTOs"

<version>${version.quarkus}</version>
<executions>
<execution>
<phase>compile</phase>
<goals>
<goal>extension-descriptor</goal>
</goals>
<configuration>
<deployment>${project.groupId}:${project.artifactId}-deployment:${project.version}</deployment>
<capabilities>
<provides>com.blazebit.persistence.integration.quarkus</provides>
</capabilities>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.bsc.maven</groupId>
<artifactId>maven-processor-plugin</artifactId>
Expand All @@ -100,4 +119,4 @@
</plugin>
</plugins>
</build>
</project>
</project>

This file was deleted.

2 changes: 1 addition & 1 deletion parent/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@
<version.jakarta-jpa-api>3.0.0</version.jakarta-jpa-api>

<version.weld>3.1.5.Final</version.weld>
<version.quarkus>1.11.0.Final</version.quarkus>
<version.quarkus>2.6.1.Final</version.quarkus>
<version.jandex>2.0.4.Final</version.jandex>
<version.classgraph>4.8.89</version.classgraph>

Expand Down