Bläddra i källkod

Fix a deploy bug (#1226)

Signed-off-by: yhmo <yihua.mo@zilliz.com>
groot 4 månader sedan
förälder
incheckning
05c9745210
4 ändrade filer med 29 tillägg och 16 borttagningar
  1. 3 3
      examples/pom.xml
  2. 18 13
      pom.xml
  3. 4 0
      sdk-bulkwriter/pom.xml
  4. 4 0
      sdk-core/pom.xml

+ 3 - 3
examples/pom.xml

@@ -50,7 +50,7 @@
     <repositories>
         <repository>
             <id>oss.sonatype.org-snapshot</id>
-            <url>http://oss.sonatype.org/content/repositories/snapshots</url>
+            <url>https://oss.sonatype.org/content/repositories/snapshots</url>
             <releases>
                 <enabled>false</enabled>
             </releases>
@@ -64,12 +64,12 @@
         <dependency>
             <groupId>io.milvus</groupId>
             <artifactId>milvus-sdk-java</artifactId>
-            <version>2.5.2</version>
+            <version>2.5.2-SNAPSHOT</version>
         </dependency>
         <dependency>
             <groupId>io.milvus</groupId>
             <artifactId>milvus-sdk-java-bulkwriter</artifactId>
-            <version>2.5.2</version>
+            <version>2.5.2-SNAPSHOT</version>
         </dependency>
         <dependency>
             <groupId>org.tensorflow</groupId>

+ 18 - 13
pom.xml

@@ -71,6 +71,7 @@
         <maven.compiler.source>8</maven.compiler.source>
         <maven.compiler.target>8</maven.compiler.target>
         <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+        <skip.maven.deploy>false</skip.maven.deploy>
 
         <!--for Core-->
         <grpc.version>1.59.1</grpc.version>
@@ -93,6 +94,8 @@
         <protobuf.maven.plugin.version>0.6.1</protobuf.maven.plugin.version>
         <maven.enforcer.plugin.version>3.0.0-M2</maven.enforcer.plugin.version>
         <maven.surefire.plugin.version>2.19.1</maven.surefire.plugin.version>
+        <maven.flatten.plugin.version>1.6.0</maven.flatten.plugin.version>
+        <maven.deploy.plugin.version>3.1.3</maven.deploy.plugin.version>
         <junit.platform.version>1.1.0</junit.platform.version>
         <junit.jupiter.engine.version>5.10.1</junit.jupiter.engine.version>
         <gson.version>2.10.1</gson.version>
@@ -271,34 +274,36 @@
             <plugin>
                 <groupId>org.codehaus.mojo</groupId>
                 <artifactId>flatten-maven-plugin</artifactId>
-                <version>1.3.0</version>
-                <inherited>true</inherited>
+                <version>${maven.flatten.plugin.version}</version>
+                <configuration>
+                    <updatePomFile>true</updatePomFile>
+                    <flattenMode>oss</flattenMode>
+                </configuration>
                 <executions>
                     <execution>
                         <id>flatten</id>
-                        <phase>process-resources</phase>
                         <goals>
                             <goal>flatten</goal>
                         </goals>
-                        <configuration>
-                            <updatePomFile>true</updatePomFile>
-                            <flattenMode>resolveCiFriendliesOnly</flattenMode>
-                            <pomElements>
-                                <parent>expand</parent>
-                                <distributionManagement>remove</distributionManagement>
-                                <repositories>remove</repositories>
-                            </pomElements>
-                        </configuration>
+                        <phase>process-resources</phase>
                     </execution>
                     <execution>
                         <id>flatten.clean</id>
-                        <phase>clean</phase>
                         <goals>
                             <goal>clean</goal>
                         </goals>
+                        <phase>clean</phase>
                     </execution>
                 </executions>
             </plugin>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-deploy-plugin</artifactId>
+                <version>${maven.deploy.plugin.version}</version>
+                <configuration>
+                    <skip>${skip.maven.deploy}</skip>
+                </configuration>
+            </plugin>
         </plugins>
     </build>
 </project>

+ 4 - 0
sdk-bulkwriter/pom.xml

@@ -15,6 +15,10 @@
     <name>${project.artifactId}</name>
     <description>BulkWriter tool for Java</description>
 
+    <properties>
+        <skip.maven.deploy>false</skip.maven.deploy>
+    </properties>
+
     <dependencyManagement>
         <dependencies>
             <dependency>

+ 4 - 0
sdk-core/pom.xml

@@ -15,6 +15,10 @@
     <name>${project.artifactId}</name>
     <description>Milvus Java SDK core functions</description>
 
+    <properties>
+        <skip.maven.deploy>false</skip.maven.deploy>
+    </properties>
+
     <dependencyManagement>
         <dependencies>
             <dependency>