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

Publish torchserve-plugins-sdk artifacts to Maven Central repository #2422

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions .github/workflows/ci_cpu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,14 +43,6 @@ jobs:
retry_on: error
command: |
python torchserve_sanity.py
- name: mvn install - unix
if: matrix.os != 'windows-latest'
run: |
cd serving-sdk/ && ./mvnw clean install -q && cd ../
- name: mvn install - windows
if: matrix.os == 'windows-latest'
run: |
cd serving-sdk/ && .\mvnw.cmd clean install -q && cd ../
# Any coverage.xml will be picked up by this step
# Just make sure each coverage.xml is in a different folder
- name: Upload codecov
Expand Down
3 changes: 0 additions & 3 deletions .github/workflows/ci_gpu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,6 @@ jobs:
max_attempts: 3
command: |
python torchserve_sanity.py
- name: mvn install
run: |
cd serving-sdk/ && ./mvnw clean install -q && cd ../

# Any coverage.xml will be picked up by this step
# Just make sure each coverage.xml is in a different folder
Expand Down
2 changes: 0 additions & 2 deletions frontend/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ allprojects {

repositories {
mavenCentral()
jcenter()
mavenLocal()
}

apply plugin: 'idea'
Expand Down
34 changes: 30 additions & 4 deletions serving-sdk/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,12 @@
</developer>
</developers>

<scm>
<connection>scm:git:git://github.com/pytorch/serve.git</connection>
<developerConnection>scm:git:ssh://github.com:pytorch/serve.git</developerConnection>
<url>https://github.com/pytorch/serve</url>
</scm>

<url>http://maven.apache.org</url>
<properties>
<repo_url>file://${project.build.directory}/repo</repo_url>
Expand Down Expand Up @@ -61,6 +67,12 @@
<version>1.6</version>
<configuration>
<skip>${skip.gpg}</skip>
<keyname>${gpg.keyname}</keyname>
<passphrase>${gpg.passphrase}</passphrase>
<gpgArguments>
<arg>--pinentry-mode</arg>
<arg>loopback</arg>
</gpgArguments>
</configuration>
<executions>
<execution>
Expand Down Expand Up @@ -112,7 +124,7 @@
<execution>
<id>attach-sources</id>
<goals>
<goal>jar</goal>
<goal>jar-no-fork</goal>
</goals>
</execution>
</executions>
Expand Down Expand Up @@ -142,14 +154,28 @@
<target>8</target>
</configuration>
</plugin>
<plugin>
<groupId>org.sonatype.plugins</groupId>
<artifactId>nexus-staging-maven-plugin</artifactId>
<version>1.6.13</version>
<extensions>true</extensions>
<configuration>
<serverId>ossrh</serverId>
<nexusUrl>https://oss.sonatype.org/</nexusUrl>
<autoReleaseAfterClose>false</autoReleaseAfterClose>
</configuration>
</plugin>
</plugins>
</build>

<distributionManagement>
<snapshotRepository>
<id>ossrh</id>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
</snapshotRepository>
<repository>
<id>bintray-pytorch-maven</id>
<name>pytorch-maven</name>
<url>https://api.bintray.com/maven/pytorch/maven/org.pytorch:torchserve_plugins_sdk/</url>
<id>ossrh</id>
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
</repository>
</distributionManagement>
</project>
15 changes: 0 additions & 15 deletions ts_scripts/install_dependencies.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,6 @@ def install_wget(self):
def install_numactl(self):
pass

def install_torchserve_plugins_sdk(self):
pass


class Linux(Common):
def __init__(self):
Expand Down Expand Up @@ -113,9 +110,6 @@ def install_numactl(self):
if os.system("numactl --show") != 0 or args.force:
os.system(f"{self.sudo_cmd}apt-get install -y numactl")

def install_torchserve_plugins_sdk(self):
os.system(f"cd {REPO_ROOT}/serving-sdk/ && ./mvnw clean install -q && cd ../")


class Windows(Common):
def __init__(self):
Expand All @@ -134,11 +128,6 @@ def install_wget(self):
def install_numactl(self):
pass

def install_torchserve_plugins_sdk(self):
os.system(
f"cd {REPO_ROOT}/serving-sdk/ && .\mvnw.cmd clean install -q && cd ../"
)


class Darwin(Common):
def __init__(self):
Expand Down Expand Up @@ -167,9 +156,6 @@ def install_numactl(self):
if os.system("numactl --show") != 0 or args.force:
os.system("brew install numactl")

def install_torchserve_plugins_sdk(self):
os.system(f"cd {REPO_ROOT}/serving-sdk/ && ./mvnw clean install -q && cd ../")


def install_dependencies(cuda_version=None, nightly=False):
os_map = {"Linux": Linux, "Windows": Windows, "Darwin": Darwin}
Expand All @@ -180,7 +166,6 @@ def install_dependencies(cuda_version=None, nightly=False):
system.install_nodejs()
system.install_node_packages()
system.install_numactl()
system.install_torchserve_plugins_sdk()

# Sequence of installation to be maintained
system.install_java()
Expand Down