IGNITE-28073 : Examples fail with IllegalStateException when run directly - deploymentUnitJar not built#7710
Open
ashishm07 wants to merge 541 commits intoapache:mainfrom
Open
IGNITE-28073 : Examples fail with IllegalStateException when run directly - deploymentUnitJar not built#7710ashishm07 wants to merge 541 commits intoapache:mainfrom
ashishm07 wants to merge 541 commits intoapache:mainfrom
Conversation
valepakh
reviewed
Mar 10, 2026
|
|
||
| public static void main(String[] args) throws Exception { | ||
|
|
||
| try ( |
Contributor
There was a problem hiding this comment.
These changes seem unrelated to the deployment unit issue
There was a problem hiding this comment.
I agree. I see no difference with main. The files are identical. I even pasted the main one to this branch and there is no difference.
…primary replica side) (apache#7408)
…7434) Signed-off-by: Slava Koptilin <slava.koptilin@gmail.com> Co-authored-by: Slava Koptilin <slava.koptilin@gmail.com>
…ache#7441) Signed-off-by: Slava Koptilin <slava.koptilin@gmail.com> Co-authored-by: Slava Koptilin <slava.koptilin@gmail.com>
Signed-off-by: Slava Koptilin <slava.koptilin@gmail.com> Co-authored-by: Slava Koptilin <slava.koptilin@gmail.com>
Signed-off-by: Slava Koptilin <slava.koptilin@gmail.com>
Signed-off-by: Slava Koptilin <slava.koptilin@gmail.com> Co-authored-by: Slava Koptilin <slava.koptilin@gmail.com>
Fix flakiness in PartitionAwarenessRealClusterTests and others that rely on GetProxies.
…out (apache#7459) Increase timeout, set category, fix logging.
…apache#7420) Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Signed-off-by: Aleksandr Polovtsev <alex.polovtcev@gmail.com> Co-authored-by: Aleksandr Polovtsev <alex.polovtcev@gmail.com>
Signed-off-by: Aleksandr Polovtsev <alex.polovtcev@gmail.com> Co-authored-by: Aleksandr Polovtsev <alex.polovtcev@gmail.com>
Signed-off-by: Aleksandr Polovtsev <alex.polovtcev@gmail.com> Co-authored-by: Aleksandr Polovtsev <alex.polovtcev@gmail.com>
apache#7624) Co-authored-by: Egor Kuts <i@ekuts.ru>
…tor of IgniteImpl when launched without JVM options "--add-opens=..." (apache#7606)
Co-authored-by: dzabotlin <dzabotlin@gridgain.com>
Co-authored-by: Kirill Sizov <sizov.kirill.y@gmail.com>
* TotalEmptySize * TotalDataSize * PagesFillFactor
Signed-off-by: Aleksandr Polovtsev <alex.polovtcev@gmail.com> Co-authored-by: Aleksandr Polovtsev <alex.polovtcev@gmail.com>
Signed-off-by: Aleksandr Polovtsev <alex.polovtcev@gmail.com> Co-authored-by: Aleksandr Polovtsev <alex.polovtcev@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Running any example that requires a deployment unit directly via Gradle fails with:
java.lang.IllegalStateException: Deployment unit JAR not found at: .../examples/java/build/libs/deploymentunit-example-1.0.0.jar
Root Cause:
deploymentUnitJar was only wired into the build lifecycle. Direct class execution via Gradle uses a JavaExec task that only depends on classes, bypassing deploymentUnitJar. As a result, the JAR is never built unless ./gradlew :ignite-examples:build is run explicitly beforehand.
Affected Examples:
code/deployment/CodeDeploymentExample
compute/ComputeAsyncExample
compute/ComputeBroadcastExample
compute/ComputeCancellationExample
compute/ComputeColocatedExample
compute/ComputeExample
compute/ComputeJobPriorityExample
compute/ComputeJobStateExample
compute/ComputeMapReduceExample
compute/ComputeWithCustomResultMarshallerExample
compute/ComputeWithResultExample
serialization/SerializationExample
streaming/DistributedComputeWithReceiverExample
streaming/MultiTableDataStreamerExample
Background / Motivation:
The ai3tests framework imports the ignite-examples JAR and drives each example class as an automated test, invoking them via a shared runExample(...) utility:
java@Test
@DisplayName("Run ComputeRustJobExample")
public void testCompute*Example()
{ runExample(Compute*Example.class); }
This pattern allows individual examples to be validated in a repeatable, CI-friendly way and forms the foundation for cyclic stability testing as well. For this to work reliably, examples must be executable directly via Gradle without requiring a manual build step beforehand — making this fix a prerequisite for stable automated test execution.
Fix:
Added to examples/java/build.gradle:
groovy
tasks.withType(JavaExec).configureEach {
dependsOn deploymentUnitJar
}
This ensures the deployment unit JAR is always built before any example class is executed via Gradle, regardless of whether build was run first.