elguardian commented on code in PR #2241:
URL:
https://github.com/apache/incubator-kie-kogito-apps/pull/2241#discussion_r2222613771
##########
jobs-service/kogito-addons-jobs-service/kogito-addons-quarkus-jobs/src/main/java/org/kie/kogito/jobs/embedded/EmbeddedJobExecutor.java:
##########
@@ -142,6 +152,45 @@ private Uni<JobExecutionResponse>
processJobDescription(JobDetails jobDetails, P
.build());
}
+ private Uni<JobExecutionResponse> processJobDescription(JobDetails
jobDetails, ProcessJobDescription processJobDescription) {
+ String processId = processJobDescription.processId();
+ Process<? extends Model> process =
processes.get().processById(processId);
+
+ LOGGER.info("Processing processJobDescription for processId: {},
jobDetails: {}, processDescription: {}, and process: {}",
+ processId, jobDetails, processJobDescription, process);
+
+ if (Objects.isNull(process)) {
+ return Uni.createFrom().item(
+ JobExecutionResponse.builder()
+ .code("401")
+ .jobId(jobDetails.getId())
+ .now()
+ .message("job does not belong to this container")
+ .build());
+ }
+
+ Integer limit = jobDetails.getRetries();
+
+ Supplier<Boolean> execute = () ->
executeInUnitOfWork(application.unitOfWorkManager(), () -> {
+ process.send(SignalFactory.of("timerTriggered",
processJobDescription.expirationTime()));
Review Comment:
should not be the timer instance ? instead of the expiration time ?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]