Skip to content

Commit

Permalink
Merge pull request #2 from rgdoliveira/sync_main
Browse files Browse the repository at this point in the history
Sync main branch with Apache main branch
  • Loading branch information
rgdoliveira authored Jan 18, 2024
2 parents 35135bf + 3929131 commit 3c08db2
Show file tree
Hide file tree
Showing 879 changed files with 17,193 additions and 9,302 deletions.
2 changes: 1 addition & 1 deletion .ci/environments/quarkus-3/before.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ mvn_cmd="mvn ${BUILD_MVN_OPTS:-} ${BUILD_MVN_OPTS_QUARKUS_UPDATE:-}"
ci="${CI:-false}"

rewrite_plugin_version=4.43.0
quarkus_version=${QUARKUS_VERSION:-3.0.0.Final}
quarkus_version=${QUARKUS_VERSION:-3.2.9.Final}

quarkus_recipe_file="${script_dir_path}/quarkus3.yml"
patch_file="${script_dir_path}"/patches/0001_before_sh.patch
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,16 +30,16 @@
import org.apache.commons.io.IOUtils;

import io.quarkus.devtools.project.BuildTool;
import io.quarkus.devtools.project.update.QuarkusUpdateRecipe;
import io.quarkus.devtools.project.update.QuarkusUpdateRecipeIO;
import io.quarkus.devtools.project.update.operations.UpdatePropertyOperation;
import io.quarkus.devtools.project.update.rewrite.QuarkusUpdateRecipe;
import io.quarkus.devtools.project.update.rewrite.QuarkusUpdateRecipeIO;
import io.quarkus.devtools.project.update.rewrite.operations.UpdatePropertyOperation;
import picocli.CommandLine;
import picocli.CommandLine.Command;
import picocli.CommandLine.Option;

///usr/bin/env jbang "$0" "$@" ; exit $?
// Version to be changed when needed
//DEPS io.quarkus:quarkus-devtools-common:3.0.0.Final
//DEPS io.quarkus:quarkus-devtools-common:3.2.9.Final
//DEPS info.picocli:picocli:4.5.0

/*
Expand All @@ -63,7 +63,7 @@ class CreateKieQuarkusProjectMigrationRecipeCli implements Callable<Integer> {
@Option(names={ "-v", "--property-version"}, description = "(multi). Add a dynamic property version to the final recipe")
private Map<String, String> versionProperties = new HashMap<>();

static final String QUARKUS_UPDATES_BASE_URL = "https://raw.githubusercontent.com/quarkusio/quarkus-updates/1.0.0/recipes/src/main/resources/quarkus-updates/core/3alpha.yaml";
static final String QUARKUS_UPDATES_BASE_URL = "https://github.com/quarkusio/quarkus-updates/blob/main/recipes/src/main/resources/quarkus-updates/core/3.2.yaml";

static final Path quarkus3DownloadedRecipePath = Paths.get("quarkus3-base-recipe.yml");
static final Path quarkus3GeneratedRecipePath = Paths.get("quarkus3.yml");
Expand Down
1,971 changes: 1,074 additions & 897 deletions .ci/environments/quarkus-3/patches/0001_before_sh.patch

Large diffs are not rendered by default.

509 changes: 244 additions & 265 deletions .ci/environments/quarkus-3/patches/0002_hibernate_changes.patch

Large diffs are not rendered by default.

20 changes: 7 additions & 13 deletions .ci/environments/quarkus-3/patches/0003_mutiny_changes.patch
Original file line number Diff line number Diff line change
@@ -1,37 +1,31 @@
commit 1f48cf1b6cfeda47e05d1a64363ccb60787fe4df
Author: radtriste <[email protected]>
Date: Wed May 3 15:47:07 2023 +0200

patch: mutiny update

diff --git a/persistence-commons/persistence-commons-infinispan/src/main/java/org/kie/kogito/persistence/infinispan/cache/InfinispanStorage.java b/persistence-commons/persistence-commons-infinispan/src/main/java/org/kie/kogito/persistence/infinispan/cache/InfinispanStorage.java
index 598223d1b..e94a35074 100644
index 29292da9a..1beb34b0f 100644
--- a/persistence-commons/persistence-commons-infinispan/src/main/java/org/kie/kogito/persistence/infinispan/cache/InfinispanStorage.java
+++ b/persistence-commons/persistence-commons-infinispan/src/main/java/org/kie/kogito/persistence/infinispan/cache/InfinispanStorage.java
@@ -76,7 +76,7 @@ public class InfinispanStorage<K, V> implements Storage<K, V> {
@@ -78,7 +78,7 @@ public class InfinispanStorage<K, V> implements Storage<K, V> {
UnicastProcessor<V> processor = UnicastProcessor.create();
CacheObjectCreatedListener<K, V> listener = new CacheObjectCreatedListener<>(delegate, v -> processor.onNext(v));
return processor
- .onSubscribe().invoke(s -> delegate.addClientListener(listener))
+ .onSubscription().invoke(s -> delegate.addClientListener(listener))
.onTermination().invoke(() -> delegate.removeClientListener(listener));
}
@@ -86,7 +86,7 @@ public class InfinispanStorage<K, V> implements Storage<K, V> {

@@ -88,7 +88,7 @@ public class InfinispanStorage<K, V> implements Storage<K, V> {
UnicastProcessor<V> processor = UnicastProcessor.create();
CacheObjectUpdatedListener<K, V> listener = new CacheObjectUpdatedListener<>(delegate, v -> processor.onNext(v));
return processor
- .onSubscribe().invoke(s -> delegate.addClientListener(listener))
+ .onSubscription().invoke(s -> delegate.addClientListener(listener))
.onTermination().invoke(() -> delegate.removeClientListener(listener));
}
@@ -96,7 +96,7 @@ public class InfinispanStorage<K, V> implements Storage<K, V> {

@@ -98,7 +98,7 @@ public class InfinispanStorage<K, V> implements Storage<K, V> {
UnicastProcessor<K> processor = UnicastProcessor.create();
CacheObjectRemovedListener<K> listener = new CacheObjectRemovedListener<>(v -> processor.onNext(v));
return processor
- .onSubscribe().invoke(s -> delegate.addClientListener(listener))
+ .onSubscription().invoke(s -> delegate.addClientListener(listener))
.onTermination().invoke(() -> delegate.removeClientListener(listener));
}

64 changes: 29 additions & 35 deletions .ci/environments/quarkus-3/patches/0004_arc_changes.patch
Original file line number Diff line number Diff line change
@@ -1,100 +1,94 @@
commit 3897fefbcbca59cc79a3d5631dbef8787fe5f971
Author: radtriste <[email protected]>
Date: Thu May 4 11:06:26 2023 +0200

patch: solve arc changes

diff --git a/data-index/data-index-storage/data-index-storage-oracle/src/main/java/org/kie/kogito/index/oracle/storage/OracleStorageService.java b/data-index/data-index-storage/data-index-storage-oracle/src/main/java/org/kie/kogito/index/oracle/storage/OracleStorageService.java
index a11b9fe52..d0fa23be0 100644
index 8c1d6dcfa..efadb2929 100644
--- a/data-index/data-index-storage/data-index-storage-oracle/src/main/java/org/kie/kogito/index/oracle/storage/OracleStorageService.java
+++ b/data-index/data-index-storage/data-index-storage-oracle/src/main/java/org/kie/kogito/index/oracle/storage/OracleStorageService.java
@@ -15,7 +15,9 @@
@@ -18,7 +18,9 @@
*/
package org.kie.kogito.index.oracle.storage;

+import jakarta.annotation.Priority;
import jakarta.enterprise.context.ApplicationScoped;
+import jakarta.enterprise.inject.Alternative;
import jakarta.inject.Inject;

import org.kie.kogito.index.model.Job;
@@ -24,14 +26,14 @@ import org.kie.kogito.index.model.UserTaskInstance;
@@ -28,14 +30,14 @@ import org.kie.kogito.index.model.UserTaskInstance;
import org.kie.kogito.persistence.api.Storage;
import org.kie.kogito.persistence.api.StorageService;

-import io.quarkus.arc.AlternativePriority;
import io.quarkus.arc.properties.IfBuildProperty;

import static java.lang.String.format;
import static org.kie.kogito.persistence.api.factory.Constants.PERSISTENCE_TYPE_PROPERTY;
import static org.kie.kogito.persistence.oracle.Constants.ORACLE_STORAGE;

-@AlternativePriority(1)
+@Alternative
+@Priority(1)
@ApplicationScoped
@IfBuildProperty(name = PERSISTENCE_TYPE_PROPERTY, stringValue = ORACLE_STORAGE)
public class OracleStorageService implements StorageService {
diff --git a/data-index/data-index-storage/data-index-storage-postgresql/src/main/java/org/kie/kogito/index/postgresql/storage/PostgreSqlStorageService.java b/data-index/data-index-storage/data-index-storage-postgresql/src/main/java/org/kie/kogito/index/postgresql/storage/PostgreSqlStorageService.java
index 969d73231..cae9875a1 100644
index deab75186..93bb36faf 100644
--- a/data-index/data-index-storage/data-index-storage-postgresql/src/main/java/org/kie/kogito/index/postgresql/storage/PostgreSqlStorageService.java
+++ b/data-index/data-index-storage/data-index-storage-postgresql/src/main/java/org/kie/kogito/index/postgresql/storage/PostgreSqlStorageService.java
@@ -15,7 +15,9 @@
@@ -18,7 +18,9 @@
*/
package org.kie.kogito.index.postgresql.storage;

+import jakarta.annotation.Priority;
import jakarta.enterprise.context.ApplicationScoped;
+import jakarta.enterprise.inject.Alternative;
import jakarta.inject.Inject;

import org.kie.kogito.index.model.Job;
@@ -24,14 +26,14 @@ import org.kie.kogito.index.model.UserTaskInstance;
@@ -28,14 +30,14 @@ import org.kie.kogito.index.model.UserTaskInstance;
import org.kie.kogito.persistence.api.Storage;
import org.kie.kogito.persistence.api.StorageService;

-import io.quarkus.arc.AlternativePriority;
import io.quarkus.arc.properties.IfBuildProperty;

import static java.lang.String.format;
import static org.kie.kogito.persistence.api.factory.Constants.PERSISTENCE_TYPE_PROPERTY;
import static org.kie.kogito.persistence.postgresql.Constants.POSTGRESQL_STORAGE;

-@AlternativePriority(1)
+@Alternative
+@Priority(1)
@ApplicationScoped
@IfBuildProperty(name = PERSISTENCE_TYPE_PROPERTY, stringValue = POSTGRESQL_STORAGE)
public class PostgreSqlStorageService implements StorageService {
diff --git a/trusty/trusty-storage/trusty-storage-postgresql/src/main/java/org/kie/kogito/trusty/storage/postgresql/PostgresStorageService.java b/trusty/trusty-storage/trusty-storage-postgresql/src/main/java/org/kie/kogito/trusty/storage/postgresql/PostgresStorageService.java
index ee4e19533..3aca96e3e 100644
index 6e174a82a..2adb6a2db 100644
--- a/trusty/trusty-storage/trusty-storage-postgresql/src/main/java/org/kie/kogito/trusty/storage/postgresql/PostgresStorageService.java
+++ b/trusty/trusty-storage/trusty-storage-postgresql/src/main/java/org/kie/kogito/trusty/storage/postgresql/PostgresStorageService.java
@@ -16,7 +16,9 @@

@@ -18,7 +18,9 @@
*/
package org.kie.kogito.trusty.storage.postgresql;

+import jakarta.annotation.Priority;
import jakarta.enterprise.context.ApplicationScoped;
+import jakarta.enterprise.inject.Alternative;
import jakarta.inject.Inject;

import org.kie.kogito.explainability.api.CounterfactualExplainabilityRequest;
@@ -27,7 +29,6 @@ import org.kie.kogito.persistence.api.StorageService;
@@ -29,15 +31,15 @@ import org.kie.kogito.persistence.api.StorageService;
import org.kie.kogito.trusty.storage.api.model.decision.DMNModelWithMetadata;
import org.kie.kogito.trusty.storage.api.model.decision.Decision;

-import io.quarkus.arc.AlternativePriority;
import io.quarkus.arc.properties.IfBuildProperty;

import static java.lang.String.format;
@@ -35,7 +36,8 @@ import static org.kie.kogito.persistence.api.factory.Constants.PERSISTENCE_TYPE_
import static org.kie.kogito.persistence.api.factory.Constants.PERSISTENCE_TYPE_PROPERTY;
import static org.kie.kogito.persistence.postgresql.Constants.POSTGRESQL_STORAGE;

@ApplicationScoped
-@AlternativePriority(1)

+@Alternative
+@Priority(1)
@ApplicationScoped
-@AlternativePriority(1)
@IfBuildProperty(name = PERSISTENCE_TYPE_PROPERTY, stringValue = POSTGRESQL_STORAGE)
public class PostgresStorageService implements StorageService {

Loading

0 comments on commit 3c08db2

Please sign in to comment.