Copilot commented on code in PR #6600:
URL: https://github.com/apache/ignite-3/pull/6600#discussion_r2352556632


##########
modules/client/src/test/java/org/apache/ignite/client/fakes/FakeCompute.java:
##########
@@ -136,7 +136,7 @@ public 
CompletableFuture<JobExecution<ComputeJobDataHolder>> executeAsyncWithFai
             Class<ComputeJob<Object, Object>> jobClass = 
ComputeUtils.jobClass(jobClassLoader, jobClassName);
             ComputeJob<Object, Object> job = 
ComputeUtils.instantiateJob(jobClass);
             CompletableFuture<Object> jobFut = job.executeAsync(
-                    new JobExecutionContextImpl(ignite, new AtomicBoolean(), 
jobClassLoader, null),
+                    new JobExecutionContextImpl(ignite, new AtomicBoolean(), 
jobClassLoader, null, List.of()),

Review Comment:
   The constructor call includes `List.of()` as the last parameter, but looking 
at the `JobExecutionContextImpl` constructor signature in the diff, it only 
takes 4 parameters (ignite, isInterrupted, classLoader, partition). This 
appears to be passing an extra parameter that doesn't match the constructor.
   ```suggestion
                       new JobExecutionContextImpl(ignite, new AtomicBoolean(), 
jobClassLoader, null),
   ```



##########
modules/compute/src/main/java/org/apache/ignite/internal/compute/JobExecutionContextImpl.java:
##########
@@ -36,6 +42,8 @@ public class JobExecutionContextImpl implements 
JobExecutionContext {
 
     private final @Nullable Partition partition;
 
+    private Collection<DeploymentUnitInfo> deploymentUnits;

Review Comment:
   The `deploymentUnits` field is accessed without synchronization in a lazy 
initialization pattern. The `initDeploymentUnits()` method could be called 
concurrently, potentially creating multiple collections and causing race 
conditions.



-- 
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]

Reply via email to