Draft
Conversation
01f4638 to
a484d3b
Compare
There was a problem hiding this comment.
Pull Request Overview
This PR adds a standalone Gremlin bootstrap class to extract nested JARs, resolve dependencies, and launch the application, and extends the Gradle plugin with tasks to index and package those nested JARs into a single executable archive.
- Introduce
GremlinBootstrapfor runtime unpacking, dependency resolution, and custom classloader launch. - Add
IndexNestedJarsandGremlinJartasks to the Gradle plugin, plus adefaultGremlinRuntimeconfiguration. - Wire new tasks into
GremlinPluginand adjust resource/output wiring for nested JAR packaging.
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| runtime/src/main/java/xyz/jpenilla/gremlin/runtime/GremlinBootstrap.java | Implements bootstrap logic to extract nested JARs, read dependencies, and spawn the main thread. |
| gradle-plugin/src/main/kotlin/xyz/jpenilla/gremlin/gradle/IndexNestedJars.kt | Adds a task to generate index.txt listing nested JAR names. |
| gradle-plugin/src/main/kotlin/xyz/jpenilla/gremlin/gradle/GremlinPlugin.kt | Registers defaultGremlinRuntime, indexNestedJars, and gremlinJar tasks; wires configurations. |
| gradle-plugin/src/main/kotlin/xyz/jpenilla/gremlin/gradle/GremlinJar.kt | Defines GremlinJar task to assemble an executable JAR with nested JARs and custom manifest. |
runtime/src/main/java/xyz/jpenilla/gremlin/runtime/GremlinBootstrap.java
Outdated
Show resolved
Hide resolved
runtime/src/main/java/xyz/jpenilla/gremlin/runtime/GremlinBootstrap.java
Outdated
Show resolved
Hide resolved
gradle-plugin/src/main/kotlin/xyz/jpenilla/gremlin/gradle/GremlinPlugin.kt
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Pull Request Overview
Adds a standalone Gremlin launcher and the accompanying Gradle plugin support for bundling nested JARs.
- Introduces
GremlinBootstrapto extract nested JARs, resolve dependencies, and launch the main application from a single JAR. - Adds Gradle tasks and utilities (
PrepareNestedJars,BootstrapJar, and helper extensions) to package Gremlin runtime and nested JARs. - Updates plugin extension properties for controlling inclusion of the Gremlin runtime on compile/runtime classpaths.
Reviewed Changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| runtime/src/main/java/xyz/jpenilla/gremlin/runtime/GremlinBootstrap.java | New bootstrap class to unpack nested JARs, resolve dependencies, and invoke the target main class. |
| gradle-plugin/src/main/kotlin/xyz/jpenilla/gremlin/gradle/utils.kt | Added Path and zip-file helper extensions for URI and filesystem operations. |
| gradle-plugin/src/main/kotlin/xyz/jpenilla/gremlin/gradle/PrepareNestedJars.kt | New Gradle task that copies specified JARs into an output dir and generates an index. |
| gradle-plugin/src/main/kotlin/xyz/jpenilla/gremlin/gradle/GremlinPlugin.kt | Registers gremlinRuntime & nestedJars configurations and tasks (prepareNestedJars, bootstrapJar), and wires classpath extensions. |
| gradle-plugin/src/main/kotlin/xyz/jpenilla/gremlin/gradle/GremlinExtension.kt | Replaced old runtime-dependency flag with separate compile/runtime flags and added a nestJars helper. |
| gradle-plugin/src/main/kotlin/xyz/jpenilla/gremlin/gradle/BootstrapJar.kt | Defines a custom Jar task that unpacks runtime JARs, writes manifest entries, and nests additional JARs. |
Comments suppressed due to low confidence (1)
runtime/src/main/java/xyz/jpenilla/gremlin/runtime/GremlinBootstrap.java:51
- [nitpick] There are no unit tests covering
GremlinBootstrap. Adding tests for nested-jar extraction, manifest parsing, and main invocation would help prevent regressions.
public static void main(final String[] args) {
runtime/src/main/java/xyz/jpenilla/gremlin/runtime/GremlinBootstrap.java
Outdated
Show resolved
Hide resolved
runtime/src/main/java/xyz/jpenilla/gremlin/runtime/GremlinBootstrap.java
Show resolved
Hide resolved
gradle-plugin/src/main/kotlin/xyz/jpenilla/gremlin/gradle/GremlinExtension.kt
Show resolved
Hide resolved
gradle-plugin/src/main/kotlin/xyz/jpenilla/gremlin/gradle/BootstrapJar.kt
Show resolved
Hide resolved
a4c2f9e to
c301df6
Compare
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.
Simplifies using Gremlin for a standalone application.