Skip to content
This repository was archived by the owner on Aug 7, 2025. It is now read-only.

Conversation

@namannandan
Copy link
Collaborator

@namannandan namannandan commented Jun 23, 2023

Description

Sanity in CI currently fails with the following error:

A problem occurred evaluating project ':server'.
> Could not resolve all files for configuration ':server:runtimeClasspath'.
   > Could not find org.pytorch:torchserve-plugins-sdk:0.0.4.
     Searched in the following locations:
       - https://repo.maven.apache.org/maven2/org/pytorch/torchserve-plugins-sdk/0.0.4/torchserve-plugins-sdk-0.0.4.pom
       - https://jcenter.bintray.com/org/pytorch/torchserve-plugins-sdk/0.0.4/torchserve-plugins-sdk-0.0.4.pom
     Required by:
         project :server

The torchserve-plugins-sdk artifacts are currently unavailable via JCenter or Maven Central repositories.

The fix (Reference: https://central.sonatype.org/publish/publish-maven):

  • Update the distributionManagement definition in torchserve-plugins-sdk pom.xml to point to Sonatype OSSRH repo.
  • Update the torchserve-plugins-sdk version used as dependencies since the current version being built is 0.0.5
  • Add nexus-staging-maven-plugin to pom.xml
  • Configure maven settings on the host used to deploy to nexus OSSRH
<settings>
  <servers>
    <server>
      <id>ossrh</id>
      <username>your-ossrh-user-id</username>
      <password>your-ossrh-pwd</password>
    </server>
  </servers>
  <profiles>
    <profile>
      <id>ossrh_deploy</id>
      <activation>
        <activeByDefault>true</activeByDefault>
      </activation>
      <properties>
        <skip.gpg>false</skip.gpg>
        <gpg.keyname>your-gpg-keyname</gpg.keyname>
        <gpg.passphrase>your-gpg-passphrase</gpg.passphrase>
      </properties>
    </profile>
  </profiles>
</settings>
  • Publish artifacts to maven central repository:
    • cd serving-sdk
    • mvn clean deploy
  • Release artifacts from OSSRH account

In addition to publishing the torchserve-plugins-sdk artifacts to maven central, this PR also includes:

  • Revert prior workaround to build and install torchserve-plugins-sdk locally: Find torchserve-plugins-sdk artifacts locally #2429
  • Disable building and installing torchserve-plugins-sdk locally in GPU and CPU CI workflows
  • Remove dependence on JCenter to fetch dependency build artifacts

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)

Tests

@namannandan namannandan force-pushed the naman-fix-serving-sdk-artifacts branch from 4578861 to c91b19f Compare June 26, 2023 22:26
@namannandan namannandan changed the title Fix missing torchserve-plugins-sdk artifacts and version Publish torchserve-plugins-sdk artifacts and Maven Central repository Jun 26, 2023
@codecov
Copy link

codecov bot commented Jun 26, 2023

Codecov Report

Merging #2422 (3ce4514) into master (ec3b992) will decrease coverage by 0.09%.
The diff coverage is n/a.

❗ Current head 3ce4514 differs from pull request most recent head 35844b6. Consider uploading reports for the commit 35844b6 to get more accurate results

@@            Coverage Diff             @@
##           master    #2422      +/-   ##
==========================================
- Coverage   71.89%   71.81%   -0.09%     
==========================================
  Files          78       78              
  Lines        3654     3654              
  Branches       58       58              
==========================================
- Hits         2627     2624       -3     
- Misses       1023     1026       +3     
  Partials        4        4              

see 1 file with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@namannandan namannandan changed the title Publish torchserve-plugins-sdk artifacts and Maven Central repository Publish torchserve-plugins-sdk artifacts to Maven Central repository Jun 28, 2023
@namannandan namannandan marked this pull request as ready for review June 28, 2023 22:16
@namannandan namannandan merged commit 2551a99 into pytorch:master Jun 28, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants