Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial attempt to fix local publication #187

Closed

Conversation

owaiskazi19
Copy link
Member

@owaiskazi19 owaiskazi19 commented Nov 22, 2023

Description

Fix ./gradlew publishToMavenLocal

Still failing with the below:

* What went wrong:
Execution failed for task ':publishNebulaPublicationToMavenLocal'.
> Failed to publish publication 'nebula' to repository 'mavenLocal'
   > Invalid publication 'nebula': supplied groupId (org.opensearch) does not match value from POM file (org.opensearch.plugin). Cannot edit groupId directly in the POM file.

Issues Resolved

Fixes #186

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@github-actions github-actions bot added the backport 2.x backport PRs to 2.x branch label Nov 22, 2023
// add license information to generated poms
all {
pom {
name = 'opensearch-flow-framework'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You may need to add groupId = "org.opensearch.plugin" here, should fix your problem

Copy link
Member Author

@owaiskazi19 owaiskazi19 Nov 23, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's here already though. Do you think I should add on L93 as well?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Though it's build successfully but not published at the right location with the above change.

> Task :publishPluginZipPublicationToMavenLocal
Multiple publications with coordinates 'org.opensearch.plugin:opensearch-flow-framework:3.0.0.0-SNAPSHOT' are published to repository 'mavenLocal'. The publications 'nebula' in root project 'opensearch-flow-framework' and 'pluginZip' in root project 'opensearch-flow-framework' will overwrite each other!

BUILD SUCCESSFUL in 688ms
ls ~/.m2/repository/org/opensearch/opensearch-
opensearch-benchmarks/                                   opensearch-job-scheduler-spi-1.2.0.0-javadoc.jar.sha256  opensearch-ml-client/
opensearch-cli/                                          opensearch-job-scheduler-spi-1.2.0.0-javadoc.jar.sha512  opensearch-ml-common/
opensearch-common/                                       opensearch-job-scheduler-spi-1.2.0.0-sources.jar         opensearch-ml-spi/
opensearch-compress/                                     opensearch-job-scheduler-spi-1.2.0.0-sources.jar.md5     opensearch-nio/
opensearch-core/                                         opensearch-job-scheduler-spi-1.2.0.0-sources.jar.sha1    opensearch-performance-analyzer/
opensearch-dissect/                                      opensearch-job-scheduler-spi-1.2.0.0-sources.jar.sha256  opensearch-plugin-classloader/
opensearch-geo/                                          opensearch-job-scheduler-spi-1.2.0.0-sources.jar.sha512  opensearch-plugin-cli/
opensearch-grok/                                         opensearch-job-scheduler-spi-1.2.0.0.jar                 opensearch-secure-sm/
opensearch-job-scheduler/                                opensearch-job-scheduler-spi-1.2.0.0.jar.md5             opensearch-ssl-config/
opensearch-job-scheduler-sample-extension/               opensearch-job-scheduler-spi-1.2.0.0.jar.sha1            opensearch-telemetry/
opensearch-job-scheduler-spi/                            opensearch-job-scheduler-spi-1.2.0.0.jar.sha256          opensearch-upgrade-cli/
opensearch-job-scheduler-spi-1.2.0.0-javadoc.jar         opensearch-job-scheduler-spi-1.2.0.0.jar.sha512          opensearch-x-content/
opensearch-job-scheduler-spi-1.2.0.0-javadoc.jar.md5     opensearch-launchers/                                    
opensearch-job-scheduler-spi-1.2.0.0-javadoc.jar.sha1    opensearch-ml/  

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Though it's build successfully but not published at the right location with the above change.

Oh wait, this is for jar publications right?

Copy link
Member Author

@owaiskazi19 owaiskazi19 Nov 24, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is for ./gradlew publishToMavenLocal

./gradlew publishToMavenLocal

> Configure project :
fatal: ambiguous argument '|| true': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
=======================================
OpenSearch Build Hamster says Hello!
  Gradle Version        : 8.4
  OS Info               : Linux 5.11.0-1020-aws (amd64)
  Runtime JDK Version   : 14 (Private Build JDK)
  Runtime java.home     : /usr/lib/jvm/java-14-openjdk-amd64
  Gradle JDK Version    : 17 (Oracle JDK)
  Gradle java.home      : /usr/lib/jvm/java-17/jdk-17.0.1
  Random Testing Seed   : A23D4553EE612FE1
  In FIPS 140 mode      : false
=======================================

> Task :publishPluginZipPublicationToMavenLocal
Multiple publications with coordinates 'org.opensearch.plugin:opensearch-flow-framework:3.0.0.0-SNAPSHOT' are published to repository 'mavenLocal'. The publications 'nebula' in root project 'opensearch-flow-framework' and 'pluginZip' in root project 'opensearch-flow-framework' will overwrite each other!

BUILD SUCCESSFUL in 781ms
15 actionable tasks: 5 executed, 10 up-to-date

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is for ./gradlew publishToMavenLocal

Thanks @owaiskazi19 , back on that, could you please just clarify one question for me: this plugin should only publish the plugin ZIP or also client JARs?

Copy link
Member Author

@owaiskazi19 owaiskazi19 Nov 29, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missed this @reta. Yes, it should publish the plugin ZIP.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@owaiskazi19 np at all, sorry I cannot push the change here, but here we are , #226

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport 2.x backport PRs to 2.x branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] Unable to publish Flow Framework plugin to maven local
2 participants