Conversation
Replace external jfrog binary orchestration with a Go SDK runtime layer that preserves the plugin contract while removing the container and binary coupling from execution paths. Introduce isolated JFROG_CLI_HOME_DIR runtime setup, direct Artifactory and build-info command execution, SDK-backed upload/download/promote/scan/discard flows, and hybrid Maven and Gradle integration through JFrog command packages. Keep host Maven and Gradle execution behavior for binary-only usage, normalize missing-tool failures into explicit user-facing errors, and remove jfrog CLI installation from plugin images and plugin metadata. Add focused runtime tests for auth and spec behavior and host-tool error normalization, while updating module dependencies to the JFrog Go client stack required by the migration.
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.
Summary
This change removes the plugin’s runtime dependency on the external
jfbinary and replaces the execution path with JFrog Go SDK and command-library integrations.The result is a plugin binary that:
Maven and Gradle remain host-tool dependent by design:
mvnfromPATHgradlewwhen present, otherwisegradlefromPATHArchitectural Changes
Runtime execution
JFROG_CLI_HOME_DIRAuth handling
ServerDetailsfor Maven and Gradle registrationApiKeyfield instead of routing API keys throughAccessTokenjfrog-cli-corestill requiresServerDetailsMaven and Gradle
jfBehavioral Compatibility
This refactor preserves the plugin’s supported behavior surface, including:
PLUGIN_SPECandPLUGIN_SPEC_PATHThe plugin no longer depends on JFrog CLI at runtime, but it does still depend on host build tools for Maven and Gradle operations.
Follow-up Hardening Included
This PR also addresses the post-migration runtime issues that surfaced during review:
context.Contextthrough the SDK-backed generic and build-info pathscontext.Background()Dependency Notes
The JFrog module set remains pinned to source-compatible pseudo-versions for
jfrog-cli-artifactory,jfrog-cli-core,jfrog-client-go, andbuild-info-go.This is an upstream constraint, not a local preference:
jfrog-cli-artifactoryrelease is missing APIs used by this migration pathA TODO comment is included at the wrapper compatibility seam to revisit this once upstream publishes a fully tagged compatible stack.
Validation
Validated with:
go test ./...Coverage added around:
Risk / Caveats