diff --git a/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-common/src/test/java/org/kie/kogito/index/AbstractProcessDataIndexIT.java b/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-common/src/test/java/org/kie/kogito/index/AbstractProcessDataIndexIT.java
index ee13a56258..a5c910067a 100644
--- a/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-common/src/test/java/org/kie/kogito/index/AbstractProcessDataIndexIT.java
+++ b/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-common/src/test/java/org/kie/kogito/index/AbstractProcessDataIndexIT.java
@@ -86,6 +86,10 @@ public RequestSpecification dataIndexSpec() {
return spec;
}
+ protected ValidatableResponse addCheck(ValidatableResponse res) {
+ return res.body("data.ProcessDefinitions[0].source", notNullValue());
+ }
+
@Test
public void testProcessInstanceEvents() throws IOException {
String pId = given()
@@ -163,14 +167,14 @@ public void testProcessInstanceEvents() throws IOException {
await()
.atMost(TIMEOUT)
- .untilAsserted(() -> given().spec(dataIndexSpec()).contentType(ContentType.JSON)
- .body("{ \"query\" : \"{ProcessDefinitions{ id, version, name } }\" }")
+ .untilAsserted(() -> addCheck(given().spec(dataIndexSpec()).contentType(ContentType.JSON)
+ .body("{ \"query\" : \"{ProcessDefinitions{ id, version, name, source} }\" }")
.when().post("/graphql")
.then().statusCode(200)
.body("data.ProcessDefinitions.size()", is(1))
.body("data.ProcessDefinitions[0].id", is("approvals"))
.body("data.ProcessDefinitions[0].version", is("1.0"))
- .body("data.ProcessDefinitions[0].name", is("approvals")));
+ .body("data.ProcessDefinitions[0].name", is("approvals"))));
await()
.atMost(TIMEOUT)
diff --git a/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexInfinispanIT.java b/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexInfinispanIT.java
index ba47c3812b..f38169b8b3 100644
--- a/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexInfinispanIT.java
+++ b/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexInfinispanIT.java
@@ -35,7 +35,7 @@
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT, classes = { KogitoApplication.class })
@ContextConfiguration(initializers = { KogitoServiceRandomPortSpringTestResource.class, DataIndexInfinispanSpringTestResource.class })
@DirtiesContext(classMode = DirtiesContext.ClassMode.AFTER_CLASS)
-public class ProcessDataIndexInfinispanIT extends AbstractProcessDataIndexIT {
+public class ProcessDataIndexInfinispanIT extends SpringBootAbstractProcessInstanceIT {
@LocalServerPort
private int httpPort;
diff --git a/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexMongoDBIT.java b/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexMongoDBIT.java
index bb4b480755..7f253cbcdf 100644
--- a/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexMongoDBIT.java
+++ b/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexMongoDBIT.java
@@ -35,7 +35,7 @@
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT, classes = { KogitoApplication.class })
@ContextConfiguration(initializers = { KogitoServiceRandomPortSpringTestResource.class, DataIndexMongoDBSpringTestResource.class })
@DirtiesContext(classMode = DirtiesContext.ClassMode.AFTER_CLASS)
-public class ProcessDataIndexMongoDBIT extends AbstractProcessDataIndexIT {
+public class ProcessDataIndexMongoDBIT extends SpringBootAbstractProcessInstanceIT {
@LocalServerPort
private int httpPort;
diff --git a/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexOracleIT.java b/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexOracleIT.java
index a25f029bcd..9f9278ce26 100644
--- a/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexOracleIT.java
+++ b/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexOracleIT.java
@@ -35,7 +35,7 @@
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT, classes = { KogitoApplication.class })
@ContextConfiguration(initializers = { KogitoServiceRandomPortSpringTestResource.class, DataIndexOracleSpringTestResource.class })
@DirtiesContext(classMode = DirtiesContext.ClassMode.AFTER_CLASS)
-public class ProcessDataIndexOracleIT extends AbstractProcessDataIndexIT {
+public class ProcessDataIndexOracleIT extends SpringBootAbstractProcessInstanceIT {
@LocalServerPort
private int httpPort;
diff --git a/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexPostgreSqlIT.java b/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexPostgreSqlIT.java
index 43746273cd..c62f844a48 100644
--- a/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexPostgreSqlIT.java
+++ b/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/ProcessDataIndexPostgreSqlIT.java
@@ -35,7 +35,7 @@
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT, classes = { KogitoApplication.class })
@ContextConfiguration(initializers = { KogitoServiceRandomPortSpringTestResource.class, DataIndexPostgreSqlSpringTestResource.class })
@DirtiesContext(classMode = DirtiesContext.ClassMode.AFTER_CLASS)
-public class ProcessDataIndexPostgreSqlIT extends AbstractProcessDataIndexIT {
+public class ProcessDataIndexPostgreSqlIT extends SpringBootAbstractProcessInstanceIT {
@LocalServerPort
private int httpPort;
diff --git a/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/SpringBootAbstractProcessInstanceIT.java b/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/SpringBootAbstractProcessInstanceIT.java
new file mode 100644
index 0000000000..a2bd94dbb8
--- /dev/null
+++ b/apps-integration-tests/integration-tests-data-index-service/integration-tests-data-index-service-springboot/src/test/java/org/kie/kogito/index/SpringBootAbstractProcessInstanceIT.java
@@ -0,0 +1,31 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.kie.kogito.index;
+
+import io.restassured.response.ValidatableResponse;
+
+abstract class SpringBootAbstractProcessInstanceIT extends AbstractProcessDataIndexIT {
+
+ @Override
+ protected ValidatableResponse addCheck(ValidatableResponse res) {
+ // disable source check for Springboot since it is not implemented yet
+ return res;
+ }
+
+}
diff --git a/apps-integration-tests/integration-tests-data-index-service/pom.xml b/apps-integration-tests/integration-tests-data-index-service/pom.xml
index 17e3e7facd..128f5b6b2f 100644
--- a/apps-integration-tests/integration-tests-data-index-service/pom.xml
+++ b/apps-integration-tests/integration-tests-data-index-service/pom.xml
@@ -35,24 +35,11 @@
integration-tests-data-index-service-quarkus-devservice
+ integration-tests-data-index-service-common
+ integration-tests-data-index-service-quarkus
+ integration-tests-data-index-service-springboot
-
-
- default
-
-
- !productized
-
-
-
- integration-tests-data-index-service-common
- integration-tests-data-index-service-quarkus
- integration-tests-data-index-service-springboot
-
-
-
-
diff --git a/apps-integration-tests/pom.xml b/apps-integration-tests/pom.xml
index 25d6775c5c..724fe26259 100644
--- a/apps-integration-tests/pom.xml
+++ b/apps-integration-tests/pom.xml
@@ -36,22 +36,9 @@
integration-tests-data-index-service
+ integration-tests-jobs-service
+ integration-tests-trusty-audit
+ integration-tests-trusty-service
-
-
- default
-
-
- !productized
-
-
-
- integration-tests-jobs-service
- integration-tests-trusty-audit
- integration-tests-trusty-service
-
-
-
-
diff --git a/data-index/data-index-common/src/main/java/org/kie/kogito/index/service/ProcessDefinitionHelper.java b/data-index/data-index-common/src/main/java/org/kie/kogito/index/service/ProcessDefinitionHelper.java
index c751cc9a76..6ce25264c2 100644
--- a/data-index/data-index-common/src/main/java/org/kie/kogito/index/service/ProcessDefinitionHelper.java
+++ b/data-index/data-index-common/src/main/java/org/kie/kogito/index/service/ProcessDefinitionHelper.java
@@ -64,6 +64,7 @@ public static ProcessDefinition merge(ProcessDefinition instance, ProcessDefinit
instance.setAnnotations(doMerge(data.getAnnotations(), instance.getAnnotations()));
instance.setMetadata(doMerge(toStringMap(data.getMetadata()), instance.getMetadata()));
instance.setNodes(doMerge(nodeDefinitions(data), instance.getNodes()));
+ instance.setSource(doMerge(data.getSource(), instance.getSource()));
return instance;
}
diff --git a/data-index/data-index-service/pom.xml b/data-index/data-index-service/pom.xml
index 4ea6fd1d77..48be5911aa 100644
--- a/data-index/data-index-service/pom.xml
+++ b/data-index/data-index-service/pom.xml
@@ -35,22 +35,12 @@
data-index-service-common
data-index-service-inmemory
data-index-service-postgresql
+ data-index-service-infinispan
+ data-index-service-mongodb
+ data-index-service-oracle
-
- default
-
-
- !productized
-
-
-
- data-index-service-infinispan
- data-index-service-mongodb
- data-index-service-oracle
-
-
native
diff --git a/data-index/data-index-storage/data-index-storage-common/src/main/java/org/kie/kogito/index/storage/merger/ProcessInstanceNodeDataEventMerger.java b/data-index/data-index-storage/data-index-storage-common/src/main/java/org/kie/kogito/index/storage/merger/ProcessInstanceNodeDataEventMerger.java
index d2bfac1cbb..f3442d24b9 100644
--- a/data-index/data-index-storage/data-index-storage-common/src/main/java/org/kie/kogito/index/storage/merger/ProcessInstanceNodeDataEventMerger.java
+++ b/data-index/data-index-storage/data-index-storage-common/src/main/java/org/kie/kogito/index/storage/merger/ProcessInstanceNodeDataEventMerger.java
@@ -18,6 +18,7 @@
*/
package org.kie.kogito.index.storage.merger;
+import java.time.ZonedDateTime;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
@@ -62,18 +63,18 @@ public ProcessInstance merge(ProcessInstance pi, ProcessInstanceDataEvent> dat
nodeInstance.setNodeId(body.getNodeDefinitionId());
nodeInstance.setName(body.getNodeName());
nodeInstance.setType(body.getNodeType());
+ ZonedDateTime eventDate = toZonedDateTime(body.getEventDate());
switch (body.getEventType()) {
case EVENT_TYPE_ENTER:
- nodeInstance.setEnter(toZonedDateTime(body.getEventDate()));
+ nodeInstance.setEnter(eventDate);
break;
case EVENT_TYPE_EXIT:
- nodeInstance.setExit(toZonedDateTime(body.getEventDate()));
-
+ nodeInstance.setExit(eventDate);
+ default:
if (nodeInstance.getEnter() == null) {
// Adding a default enter time for exit events triggered by EventNodeInstances
- nodeInstance.setEnter(nodeInstance.getExit());
+ nodeInstance.setEnter(eventDate);
}
- break;
}
nodeInstances.add(nodeInstance);
diff --git a/data-index/data-index-storage/data-index-storage-jpa/src/main/java/org/kie/kogito/index/jpa/storage/ProcessInstanceEntityStorage.java b/data-index/data-index-storage/data-index-storage-jpa/src/main/java/org/kie/kogito/index/jpa/storage/ProcessInstanceEntityStorage.java
index 34c59225b6..f86570fbd4 100644
--- a/data-index/data-index-storage/data-index-storage-jpa/src/main/java/org/kie/kogito/index/jpa/storage/ProcessInstanceEntityStorage.java
+++ b/data-index/data-index-storage/data-index-storage-jpa/src/main/java/org/kie/kogito/index/jpa/storage/ProcessInstanceEntityStorage.java
@@ -18,6 +18,7 @@
*/
package org.kie.kogito.index.jpa.storage;
+import java.time.ZonedDateTime;
import java.util.ArrayList;
import java.util.Set;
@@ -155,18 +156,19 @@ private NodeInstanceEntity updateNode(NodeInstanceEntity nodeInstance, ProcessIn
nodeInstance.setNodeId(body.getNodeDefinitionId());
nodeInstance.setName(body.getNodeName());
nodeInstance.setType(body.getNodeType());
+ ZonedDateTime eventDate = toZonedDateTime(body.getEventDate());
switch (body.getEventType()) {
+
case EVENT_TYPE_ENTER:
- nodeInstance.setEnter(toZonedDateTime(body.getEventDate()));
+ nodeInstance.setEnter(eventDate);
break;
case EVENT_TYPE_EXIT:
- nodeInstance.setExit(toZonedDateTime(body.getEventDate()));
-
+ nodeInstance.setExit(eventDate);
+ default:
if (nodeInstance.getEnter() == null) {
// Adding a default enter time for exit events triggered by EventNodeInstances
- nodeInstance.setEnter(nodeInstance.getExit());
+ nodeInstance.setEnter(eventDate);
}
- break;
}
return nodeInstance;
}
diff --git a/data-index/data-index-storage/pom.xml b/data-index/data-index-storage/pom.xml
index 2a7e94c9f6..d7f550b721 100644
--- a/data-index/data-index-storage/pom.xml
+++ b/data-index/data-index-storage/pom.xml
@@ -37,23 +37,10 @@
data-index-storage-protobuf
data-index-storage-postgresql
data-index-storage-jpa
+ data-index-storage-common
+ data-index-storage-infinispan
+ data-index-storage-mongodb
+ data-index-storage-postgresql-reporting
+ data-index-storage-oracle
-
-
-
- default
-
-
- !productized
-
-
-
- data-index-storage-common
- data-index-storage-infinispan
- data-index-storage-mongodb
- data-index-storage-postgresql-reporting
- data-index-storage-oracle
-
-
-
\ No newline at end of file
diff --git a/data-index/kogito-addons-quarkus-data-index-persistence/kogito-addons-quarkus-data-index-persistence-common/runtime/src/main/java/org/kie/kogito/index/addon/api/KogitoAddonRuntimeClientImpl.java b/data-index/kogito-addons-quarkus-data-index-persistence/kogito-addons-quarkus-data-index-persistence-common/runtime/src/main/java/org/kie/kogito/index/addon/api/KogitoAddonRuntimeClientImpl.java
index b186975634..39cd248378 100644
--- a/data-index/kogito-addons-quarkus-data-index-persistence/kogito-addons-quarkus-data-index-persistence-common/runtime/src/main/java/org/kie/kogito/index/addon/api/KogitoAddonRuntimeClientImpl.java
+++ b/data-index/kogito-addons-quarkus-data-index-persistence/kogito-addons-quarkus-data-index-persistence-common/runtime/src/main/java/org/kie/kogito/index/addon/api/KogitoAddonRuntimeClientImpl.java
@@ -29,7 +29,6 @@
import org.eclipse.microprofile.context.ManagedExecutor;
import org.kie.kogito.Application;
-import org.kie.kogito.addon.source.files.SourceFilesProvider;
import org.kie.kogito.index.api.KogitoRuntimeClient;
import org.kie.kogito.index.api.KogitoRuntimeCommonClient;
import org.kie.kogito.index.model.Node;
@@ -42,6 +41,7 @@
import org.kie.kogito.process.Processes;
import org.kie.kogito.process.impl.AbstractProcess;
import org.kie.kogito.services.uow.UnitOfWorkExecutor;
+import org.kie.kogito.source.files.SourceFilesProvider;
import org.kie.kogito.svg.ProcessSvgService;
import jakarta.enterprise.context.ApplicationScoped;
diff --git a/data-index/kogito-addons-quarkus-data-index-persistence/kogito-addons-quarkus-data-index-persistence-common/runtime/src/test/java/org/kie/kogito/index/addon/api/KogitoAddonRuntimeClientImplTest.java b/data-index/kogito-addons-quarkus-data-index-persistence/kogito-addons-quarkus-data-index-persistence-common/runtime/src/test/java/org/kie/kogito/index/addon/api/KogitoAddonRuntimeClientImplTest.java
index 17f9a07efd..6392cd4941 100644
--- a/data-index/kogito-addons-quarkus-data-index-persistence/kogito-addons-quarkus-data-index-persistence-common/runtime/src/test/java/org/kie/kogito/index/addon/api/KogitoAddonRuntimeClientImplTest.java
+++ b/data-index/kogito-addons-quarkus-data-index-persistence/kogito-addons-quarkus-data-index-persistence-common/runtime/src/test/java/org/kie/kogito/index/addon/api/KogitoAddonRuntimeClientImplTest.java
@@ -25,7 +25,6 @@
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.ExtendWith;
import org.kie.kogito.Application;
-import org.kie.kogito.addon.source.files.SourceFilesProvider;
import org.kie.kogito.index.api.KogitoRuntimeCommonClient;
import org.kie.kogito.index.model.Job;
import org.kie.kogito.index.model.ProcessInstance;
@@ -37,6 +36,7 @@
import org.kie.kogito.process.impl.AbstractProcess;
import org.kie.kogito.services.uow.CollectingUnitOfWorkFactory;
import org.kie.kogito.services.uow.DefaultUnitOfWorkManager;
+import org.kie.kogito.source.files.SourceFilesProvider;
import org.kie.kogito.svg.ProcessSvgService;
import org.mockito.ArgumentCaptor;
import org.mockito.Mock;
diff --git a/data-index/kogito-addons-quarkus-data-index-persistence/kogito-addons-quarkus-data-index-persistence-postgresql/pom.xml b/data-index/kogito-addons-quarkus-data-index-persistence/kogito-addons-quarkus-data-index-persistence-postgresql/pom.xml
index 249d21c4af..534c37123a 100644
--- a/data-index/kogito-addons-quarkus-data-index-persistence/kogito-addons-quarkus-data-index-persistence-postgresql/pom.xml
+++ b/data-index/kogito-addons-quarkus-data-index-persistence/kogito-addons-quarkus-data-index-persistence-postgresql/pom.xml
@@ -40,20 +40,7 @@
deployment
runtime
integration-tests-sw
+ integration-tests-process
-
-
- default
-
-
- !productized
-
-
-
- integration-tests-process
-
-
-
-
diff --git a/data-index/kogito-addons-quarkus-data-index-persistence/pom.xml b/data-index/kogito-addons-quarkus-data-index-persistence/pom.xml
index 2a5f24a89c..a50d704971 100644
--- a/data-index/kogito-addons-quarkus-data-index-persistence/pom.xml
+++ b/data-index/kogito-addons-quarkus-data-index-persistence/pom.xml
@@ -34,21 +34,8 @@
kogito-addons-quarkus-data-index-persistence-common
kogito-addons-quarkus-data-index-persistence-postgresql
+ kogito-addons-quarkus-data-index-persistence-infinispan
+ kogito-addons-quarkus-data-index-persistence-mongodb
-
-
- default
-
-
- !productized
-
-
-
- kogito-addons-quarkus-data-index-persistence-infinispan
- kogito-addons-quarkus-data-index-persistence-mongodb
-
-
-
-
diff --git a/data-index/kogito-addons-quarkus-data-index/kogito-addons-quarkus-data-index-inmemory/pom.xml b/data-index/kogito-addons-quarkus-data-index/kogito-addons-quarkus-data-index-inmemory/pom.xml
index 0091609377..0f6a0b62bb 100644
--- a/data-index/kogito-addons-quarkus-data-index/kogito-addons-quarkus-data-index-inmemory/pom.xml
+++ b/data-index/kogito-addons-quarkus-data-index/kogito-addons-quarkus-data-index-inmemory/pom.xml
@@ -40,20 +40,7 @@
deployment
runtime
integration-tests-sw
+ integration-tests-process
-
-
- default
-
-
- !productized
-
-
-
- integration-tests-process
-
-
-
-
diff --git a/data-index/kogito-addons-quarkus-data-index/kogito-addons-quarkus-data-index-postgresql/pom.xml b/data-index/kogito-addons-quarkus-data-index/kogito-addons-quarkus-data-index-postgresql/pom.xml
index 0340ed30cd..df80ccf45c 100644
--- a/data-index/kogito-addons-quarkus-data-index/kogito-addons-quarkus-data-index-postgresql/pom.xml
+++ b/data-index/kogito-addons-quarkus-data-index/kogito-addons-quarkus-data-index-postgresql/pom.xml
@@ -40,20 +40,7 @@
deployment
runtime
integration-tests-sw
+ integration-tests-process
-
-
- default
-
-
- !productized
-
-
-
- integration-tests-process
-
-
-
-
diff --git a/data-index/kogito-addons-quarkus-data-index/pom.xml b/data-index/kogito-addons-quarkus-data-index/pom.xml
index 853e1c215d..ba51ba6cdb 100644
--- a/data-index/kogito-addons-quarkus-data-index/pom.xml
+++ b/data-index/kogito-addons-quarkus-data-index/pom.xml
@@ -35,21 +35,8 @@
kogito-addons-quarkus-data-index-common
kogito-addons-quarkus-data-index-inmemory
kogito-addons-quarkus-data-index-postgresql
+ kogito-addons-quarkus-data-index-infinispan
+ kogito-addons-quarkus-data-index-mongodb
-
-
- default
-
-
- !productized
-
-
-
- kogito-addons-quarkus-data-index-infinispan
- kogito-addons-quarkus-data-index-mongodb
-
-
-
-
diff --git a/jobs-service/jobs-service-common/src/main/java/org/kie/kogito/jobs/service/json/ProcessInstanceJobDescriptionDeserializer.java b/jobs-service/jobs-service-common/src/main/java/org/kie/kogito/jobs/service/json/ProcessInstanceJobDescriptionDeserializer.java
index 8b60fd6444..6ccfb99f47 100644
--- a/jobs-service/jobs-service-common/src/main/java/org/kie/kogito/jobs/service/json/ProcessInstanceJobDescriptionDeserializer.java
+++ b/jobs-service/jobs-service-common/src/main/java/org/kie/kogito/jobs/service/json/ProcessInstanceJobDescriptionDeserializer.java
@@ -45,14 +45,14 @@ public ProcessInstanceJobDescription deserialize(JsonParser jp, DeserializationC
ProcessInstanceJobDescriptionBuilder builder = ProcessInstanceJobDescription.builder();
JsonNode node = jp.getCodec().readTree(jp);
- ofNullable(node.get("id")).ifPresent(e -> builder.id(e.asText()));
- ofNullable(node.get("timerId")).ifPresent(e -> builder.timerId(e.asText()));
+ ofNullable(node.get("id")).ifPresent(e -> builder.id(e.textValue()));
+ ofNullable(node.get("timerId")).ifPresent(e -> builder.timerId(e.textValue()));
ofNullable(node.get("priority")).ifPresent(e -> builder.priority(e.asInt()));
- ofNullable(node.get("processInstanceId")).ifPresent(e -> builder.processInstanceId(e.asText()));
- ofNullable(node.get("rootProcessInstanceId")).ifPresent(e -> builder.rootProcessInstanceId(e.asText()));
- ofNullable(node.get("processId")).ifPresent(e -> builder.processId(e.asText()));
- ofNullable(node.get("rootProcessId")).ifPresent(e -> builder.rootProcessId(e.asText()));
- ofNullable(node.get("nodeInstanceId")).ifPresent(e -> builder.nodeInstanceId(e.asText()));
+ ofNullable(node.get("processInstanceId")).ifPresent(e -> builder.processInstanceId(e.textValue()));
+ ofNullable(node.get("rootProcessInstanceId")).ifPresent(e -> builder.rootProcessInstanceId(e.textValue()));
+ ofNullable(node.get("processId")).ifPresent(e -> builder.processId(e.textValue()));
+ ofNullable(node.get("rootProcessId")).ifPresent(e -> builder.rootProcessId(e.textValue()));
+ ofNullable(node.get("nodeInstanceId")).ifPresent(e -> builder.nodeInstanceId(e.textValue()));
String type = node.get("expirationTime").get("@type").asText();
try {
diff --git a/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/pom.xml b/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/pom.xml
index 139794f95f..ed160a6db6 100644
--- a/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/pom.xml
+++ b/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/pom.xml
@@ -52,6 +52,10 @@
io.quarkus
quarkus-resteasy-reactive-jackson
+
+ io.quarkus
+ quarkus-container-image-jib
+
diff --git a/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/main/java/org/kie/kogito/jobs/embedded/JobInVMEventPublisher.java b/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/main/java/org/kie/kogito/jobs/embedded/JobInVMEventPublisher.java
index 814db7e91d..aa8f331a8e 100644
--- a/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/main/java/org/kie/kogito/jobs/embedded/JobInVMEventPublisher.java
+++ b/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/main/java/org/kie/kogito/jobs/embedded/JobInVMEventPublisher.java
@@ -26,7 +26,9 @@
import org.eclipse.microprofile.config.inject.ConfigProperty;
import org.kie.kogito.event.EventPublisher;
import org.kie.kogito.event.job.JobInstanceDataEvent;
+import org.kie.kogito.jobs.ProcessInstanceJobDescription;
import org.kie.kogito.jobs.service.adapter.ScheduledJobAdapter;
+import org.kie.kogito.jobs.service.api.Recipient;
import org.kie.kogito.jobs.service.model.JobDetails;
import org.kie.kogito.jobs.service.model.JobExecutionResponse;
import org.kie.kogito.jobs.service.model.ScheduledJob;
@@ -138,6 +140,15 @@ public void observe(@ObservesAsync EmbeddedJobServiceEvent serviceEvent) {
LOGGER.debug("Emmit in-vm publishJobStatusChange {}", jobDetails);
try {
ScheduledJob scheduledJob = ScheduledJobAdapter.of(jobDetails);
+ Recipient recipient = jobDetails.getRecipient().getRecipient();
+ ProcessInstanceJobDescription jobDescription = recipient.getPayload().getJobDescription();
+
+ scheduledJob.setProcessInstanceId(jobDescription.processInstanceId());
+ scheduledJob.setProcessId(jobDescription.processId());
+ scheduledJob.setRootProcessInstanceId(jobDescription.rootProcessInstanceId());
+ scheduledJob.setRootProcessId(jobDescription.rootProcessId());
+ scheduledJob.setNodeInstanceId(jobDescription.nodeInstanceId());
+
byte[] jsonContent = objectMapper.writeValueAsBytes(scheduledJob);
JobInstanceDataEvent event = new JobInstanceDataEvent(JOB_EVENT_TYPE,
url + RestApiConstants.JOBS_PATH,
diff --git a/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/test/java/org/kie/kogito/jobs/embedded/EmbeddedJobsServiceTest.java b/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/test/java/org/kie/kogito/jobs/embedded/EmbeddedJobsServiceTest.java
new file mode 100644
index 0000000000..c854f86f7f
--- /dev/null
+++ b/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/test/java/org/kie/kogito/jobs/embedded/EmbeddedJobsServiceTest.java
@@ -0,0 +1,108 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.kie.kogito.jobs.embedded;
+
+import java.util.List;
+import java.util.concurrent.CountDownLatch;
+import java.util.function.Consumer;
+
+import org.junit.jupiter.api.Assertions;
+import org.junit.jupiter.api.Test;
+import org.kie.kogito.event.DataEvent;
+import org.kie.kogito.event.job.JobInstanceDataEvent;
+import org.kie.kogito.jobs.DurationExpirationTime;
+import org.kie.kogito.jobs.JobsService;
+import org.kie.kogito.jobs.ProcessInstanceJobDescription;
+
+import io.quarkus.test.junit.QuarkusTest;
+
+import jakarta.inject.Inject;
+
+import static org.assertj.core.api.Assertions.assertThat;
+
+@QuarkusTest
+public class EmbeddedJobsServiceTest {
+
+ private static final String PROCESS_ID = "processId";
+ private static final String PROCESS_INSTANCE_ID = "1";
+ private static final String NODE_INSTANCE_ID = "node_1";
+ private static final String ROOT_PROCESS_ID = "rootProcess";
+ private static final String ROOT_PROCESS_INSTANCE_ID = "0";
+
+ @Inject
+ JobsService jobService;
+
+ @Inject
+ TestEventPublisher publisher;
+
+ @Test
+ public void testJobService() throws Exception {
+
+ // testing only when we have the full lifecycle
+ CountDownLatch latch = new CountDownLatch(8);
+ publisher.setLatch(latch);
+
+ ProcessInstanceJobDescription description = ProcessInstanceJobDescription.builder()
+ .generateId()
+ .timerId("-1")
+ .expirationTime(DurationExpirationTime.now())
+ .processInstanceId(PROCESS_INSTANCE_ID)
+ .rootProcessInstanceId(null)
+ .processId(PROCESS_ID)
+ .rootProcessId(null)
+ .nodeInstanceId(NODE_INSTANCE_ID)
+ .build();
+ jobService.scheduleProcessInstanceJob(description);
+
+ ProcessInstanceJobDescription descriptionWRootProcess = ProcessInstanceJobDescription.builder()
+ .generateId()
+ .timerId("-1")
+ .expirationTime(DurationExpirationTime.now())
+ .processInstanceId(PROCESS_INSTANCE_ID)
+ .rootProcessInstanceId(ROOT_PROCESS_INSTANCE_ID)
+ .processId(PROCESS_ID)
+ .rootProcessId(ROOT_PROCESS_ID)
+ .nodeInstanceId(NODE_INSTANCE_ID)
+ .build();
+ jobService.scheduleProcessInstanceJob(descriptionWRootProcess);
+
+ latch.await();
+
+ List> events = publisher.getEvents();
+
+ Assertions.assertEquals(8, events.size());
+
+ Consumer> noRootProcess = e -> assertThat(e)
+ .hasFieldOrPropertyWithValue("kogitoRootProcessInstanceId", null)
+ .hasFieldOrPropertyWithValue("kogitoRootProcessId", null);
+
+ Consumer> withRootProcess = e -> assertThat(e)
+ .hasFieldOrPropertyWithValue("kogitoRootProcessInstanceId", ROOT_PROCESS_INSTANCE_ID)
+ .hasFieldOrPropertyWithValue("kogitoRootProcessId", ROOT_PROCESS_ID);
+
+ events.forEach(event -> {
+ assertThat(event)
+ .isInstanceOf(JobInstanceDataEvent.class)
+ .hasFieldOrPropertyWithValue("kogitoProcessId", PROCESS_ID)
+ .hasFieldOrPropertyWithValue("kogitoProcessInstanceId", PROCESS_INSTANCE_ID)
+ .satisfiesAnyOf(noRootProcess, withRootProcess);
+ });
+ }
+
+}
diff --git a/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/test/java/org/kie/kogito/jobs/embedded/EmbeddedJobsServiceTests.java b/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/test/java/org/kie/kogito/jobs/embedded/EmbeddedJobsServiceTests.java
deleted file mode 100644
index b602a9dff7..0000000000
--- a/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/test/java/org/kie/kogito/jobs/embedded/EmbeddedJobsServiceTests.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.kogito.jobs.embedded;
-
-import java.util.List;
-
-import org.junit.jupiter.api.Assertions;
-import org.junit.jupiter.api.Test;
-import org.kie.kogito.event.DataEvent;
-import org.kie.kogito.jobs.DurationExpirationTime;
-import org.kie.kogito.jobs.JobsService;
-import org.kie.kogito.jobs.ProcessInstanceJobDescription;
-
-import io.quarkus.test.junit.QuarkusTest;
-
-import jakarta.inject.Inject;
-
-@QuarkusTest
-public class EmbeddedJobsServiceTests {
-
- @Inject
- JobsService jobService;
-
- @Inject
- TestEventPublisher publisher;
-
- @Test
- public void testJobService() throws Exception {
- // testing only we have the full lifecycle
- publisher.expectedEvents(2);
-
- ProcessInstanceJobDescription description = ProcessInstanceJobDescription.builder()
- .generateId()
- .timerId("-1")
- .expirationTime(DurationExpirationTime.now())
- .processInstanceId("1")
- .rootProcessInstanceId(null)
- .processId("processId")
- .rootProcessId(null)
- .nodeInstanceId("node_1")
- .build();
- jobService.scheduleProcessInstanceJob(description);
-
- List> events = publisher.getEvents();
- Assertions.assertEquals(2, events.size());
-
- }
-
-}
diff --git a/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/test/java/org/kie/kogito/jobs/embedded/TestEventPublisher.java b/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/test/java/org/kie/kogito/jobs/embedded/TestEventPublisher.java
index f5b43f7afd..f077205d54 100644
--- a/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/test/java/org/kie/kogito/jobs/embedded/TestEventPublisher.java
+++ b/jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/test/java/org/kie/kogito/jobs/embedded/TestEventPublisher.java
@@ -54,8 +54,8 @@ public void publish(Collection> events) {
events.forEach(e -> latch.countDown());
}
- public void expectedEvents(int numOfEvents) {
- latch = new CountDownLatch(numOfEvents);
+ public void setLatch(CountDownLatch latch) {
+ this.latch = latch;
}
}
diff --git a/jobs-service/pom.xml b/jobs-service/pom.xml
index d06d4a7fef..a505ae3031 100644
--- a/jobs-service/pom.xml
+++ b/jobs-service/pom.xml
@@ -44,23 +44,10 @@
kogito-addons-jobs-service
jobs-service-messaging-kafka
jobs-service-messaging-http
+ jobs-service-infinispan
+ jobs-service-mongodb
-
-
- default
-
-
- !productized
-
-
-
- jobs-service-infinispan
- jobs-service-mongodb
-
-
-
-
diff --git a/kogito-apps-build-parent/pom.xml b/kogito-apps-build-parent/pom.xml
index da5e174a55..8760600b75 100644
--- a/kogito-apps-build-parent/pom.xml
+++ b/kogito-apps-build-parent/pom.xml
@@ -69,7 +69,7 @@
6.2.13.Final
2.3.1
- 1.8
+ 1.10.0
2.0.0
1.5.5.Final
1.5.0
diff --git a/persistence-commons/pom.xml b/persistence-commons/pom.xml
index cef62cf009..9c7fb64511 100644
--- a/persistence-commons/pom.xml
+++ b/persistence-commons/pom.xml
@@ -39,23 +39,11 @@
persistence-commons-protobuf
persistence-commons-jpa
persistence-commons-postgresql
+ persistence-commons-infinispan
+ persistence-commons-mongodb
+ persistence-commons-redis
+ persistence-commons-reporting-parent
kogito-ddl
-
-
- default
-
-
- !productized
-
-
-
- persistence-commons-infinispan
- persistence-commons-mongodb
- persistence-commons-redis
- persistence-commons-reporting-parent
-
-
-
\ No newline at end of file
diff --git a/pom.xml b/pom.xml
index d4defab9d2..79026f8a88 100644
--- a/pom.xml
+++ b/pom.xml
@@ -36,6 +36,26 @@
Kogito Apps
Kogito Apps
+
+ 2024-01-16T00:00:00Z
+ 3.4.1
+
+
+
+
+
+
+ org.apache.maven.plugins
+ maven-artifact-plugin
+ ${version.maven.artifact.plugin}
+
+ ${project.build.outputTimestamp}
+
+
+
+
+
+
@@ -54,50 +74,27 @@
+
+ kogito-apps-bom
+ kogito-apps-build-parent
+ persistence-commons
+ jobs-service
+ data-index
+ data-audit
+ ui-packages
+ security-commons
+ management-console
+ trusty-ui
+ task-console
+ explainability
+ trusty
+ jitexecutor
+ apps-integration-tests
+ runtime-tools-quarkus-extension-parent
+ kogito-quarkus-serverless-workflow-devui-parent
+
+
-
- default
-
- true
-
-
- kogito-apps-bom
- kogito-apps-build-parent
- persistence-commons
- jobs-service
- data-index
- data-audit
- ui-packages
- security-commons
- management-console
- trusty-ui
- task-console
- explainability
- trusty
- jitexecutor
- apps-integration-tests
- runtime-tools-quarkus-extension-parent
- kogito-quarkus-serverless-workflow-devui-parent
-
-
-
- productized
-
-
- productized
-
-
-
- kogito-apps-bom
- kogito-apps-build-parent
- persistence-commons
- data-index
- ui-packages
- kogito-quarkus-serverless-workflow-devui-parent
- jobs-service
- apps-integration-tests
-
-
optaplanner-downstream
diff --git a/ui-packages/packages/consoles-common/package.json b/ui-packages/packages/consoles-common/package.json
old mode 100755
new mode 100644
index 0065c91b24..56ef5aeb3c
--- a/ui-packages/packages/consoles-common/package.json
+++ b/ui-packages/packages/consoles-common/package.json
@@ -33,7 +33,7 @@
"@patternfly/react-core": "^4.276.8",
"@patternfly/react-icons": "^4.93.6",
"@patternfly/react-styles": "^4.92.6",
- "axios": "0.21.2",
+ "axios": "1.6.0",
"gql-query-builder": "3.1.3",
"graphql-tag": "2.0.0",
"history": "^4.10.1",
diff --git a/ui-packages/packages/jobs-management/package.json b/ui-packages/packages/jobs-management/package.json
index 2050fcf7d1..417e24a6a5 100644
--- a/ui-packages/packages/jobs-management/package.json
+++ b/ui-packages/packages/jobs-management/package.json
@@ -36,7 +36,7 @@
"@patternfly/react-core": "^4.276.8",
"@patternfly/react-icons": "^4.93.6",
"@patternfly/react-table": "^4.113.0",
- "axios": "0.21.2",
+ "axios": "1.6.0",
"lodash": "^4.17.21",
"react": "^17.0.2",
"react-dom": "^17.0.2",
diff --git a/ui-packages/packages/management-console-webapp/package.json b/ui-packages/packages/management-console-webapp/package.json
index db2eb446fa..7d0e032261 100644
--- a/ui-packages/packages/management-console-webapp/package.json
+++ b/ui-packages/packages/management-console-webapp/package.json
@@ -46,7 +46,7 @@
"apollo-link-context": "^1.0.20",
"apollo-link-error": "1.1.13",
"apollo-link-http": "1.5.17",
- "axios": "0.21.2",
+ "axios": "1.6.0",
"history": "^4.10.1",
"react": "^17.0.2",
"react-apollo": "^3.1.5",
diff --git a/ui-packages/packages/process-list/package.json b/ui-packages/packages/process-list/package.json
index 9fc06e367c..8fe7dc74d7 100644
--- a/ui-packages/packages/process-list/package.json
+++ b/ui-packages/packages/process-list/package.json
@@ -36,7 +36,7 @@
"@patternfly/react-core": "^4.276.8",
"@patternfly/react-icons": "^4.93.6",
"@patternfly/react-table": "^4.113.0",
- "axios": "0.21.2",
+ "axios": "1.6.0",
"lodash": "^4.17.21",
"react": "^17.0.2",
"react-dom": "^17.0.2",
diff --git a/ui-packages/packages/runtime-gateway-api/package.json b/ui-packages/packages/runtime-gateway-api/package.json
old mode 100755
new mode 100644
index 37cc5a573c..5256d82311
--- a/ui-packages/packages/runtime-gateway-api/package.json
+++ b/ui-packages/packages/runtime-gateway-api/package.json
@@ -32,7 +32,7 @@
"@kogito-apps/consoles-common": "workspace:*",
"@kogito-apps/management-console-shared": "workspace:*",
"apollo-client": "2.6.10",
- "axios": "0.21.2",
+ "axios": "1.6.0",
"graphql": "14.3.1",
"react-apollo": "3.1.3",
"react-apollo-hooks": "0.5.0"
diff --git a/ui-packages/packages/runtime-tools-dev-ui-webapp/package.json b/ui-packages/packages/runtime-tools-dev-ui-webapp/package.json
index f89f6fd031..3151e8ed15 100644
--- a/ui-packages/packages/runtime-tools-dev-ui-webapp/package.json
+++ b/ui-packages/packages/runtime-tools-dev-ui-webapp/package.json
@@ -75,7 +75,7 @@
"apollo-client": "2.6.10",
"apollo-link-error": "1.1.13",
"apollo-link-http": "1.5.17",
- "axios": "0.21.2",
+ "axios": "1.6.0",
"history": "^4.10.1",
"lodash": "^4.17.21",
"monaco-editor": "^0.33.0",
diff --git a/ui-packages/packages/trusty/package.json b/ui-packages/packages/trusty/package.json
index b20e932ab8..ee0278d4dc 100644
--- a/ui-packages/packages/trusty/package.json
+++ b/ui-packages/packages/trusty/package.json
@@ -22,7 +22,7 @@
"@testing-library/react": "^10.4.9",
"@testing-library/react-hooks": "^3.7.0",
"@types/react-custom-scrollbars": "^4.0.10",
- "axios": "0.21.2",
+ "axios": "1.6.0",
"date-fns": "^2.30.0",
"flatpickr": "^4.6.13",
"lodash": "^4.17.21",