From f23170b45c58593ca31d7d5c9efa243e8fd505ab Mon Sep 17 00:00:00 2001
From: YuCheng Hu <huyuchengus@gmail.com>
Date: Fri, 6 Jan 2023 16:17:12 -0500
Subject: [PATCH] update the maven repo

---
 .idea/jarRepositories.xml |  27 +++++++---
 api/pom.xml               |  58 ---------------------
 client/pom.xml            |  58 ---------------------
 pom.xml                   | 104 ++++++++++++++++++++++++--------------
 4 files changed, 87 insertions(+), 160 deletions(-)

diff --git a/.idea/jarRepositories.xml b/.idea/jarRepositories.xml
index 7f6fb97..4388718 100644
--- a/.idea/jarRepositories.xml
+++ b/.idea/jarRepositories.xml
@@ -7,9 +7,9 @@
       <option name="url" value="https://repo.ossez.com/repository/maven-snapshots/" />
     </remote-repository>
     <remote-repository>
-      <option name="id" value="ossez-repo-releases" />
-      <option name="name" value="OSSEZ Private Releases" />
-      <option name="url" value="https://repo.ossez.com/repository/maven-releases/" />
+      <option name="id" value="central" />
+      <option name="name" value="Central Repository" />
+      <option name="url" value="https://repo.ossez.com/repository/maven-public/" />
     </remote-repository>
     <remote-repository>
       <option name="id" value="ossez-repo" />
@@ -17,9 +17,9 @@
       <option name="url" value="https://repo.ossez.com/repository/maven-snapshots/" />
     </remote-repository>
     <remote-repository>
-      <option name="id" value="central" />
-      <option name="name" value="Central Repository" />
-      <option name="url" value="https://repo.ossez.com/repository/maven-public/" />
+      <option name="id" value="ossez-repo-releases" />
+      <option name="name" value="OSSEZ Private Releases" />
+      <option name="url" value="https://repo.ossez.com/repository/maven-releases/" />
     </remote-repository>
     <remote-repository>
       <option name="id" value="central" />
@@ -31,5 +31,20 @@
       <option name="name" value="JBoss Community repository" />
       <option name="url" value="https://repository.jboss.org/nexus/content/repositories/public/" />
     </remote-repository>
+    <remote-repository>
+      <option name="id" value="ossrh-snapshots" />
+      <option name="name" value="OSSEZ Private Snapshots" />
+      <option name="url" value="https://oss.sonatype.org/content/repositories/snapshots" />
+    </remote-repository>
+    <remote-repository>
+      <option name="id" value="ossrh-releases" />
+      <option name="name" value="ossrh Releases" />
+      <option name="url" value="https://repo.ossez.com/repository/maven-releases/" />
+    </remote-repository>
+    <remote-repository>
+      <option name="id" value="ossrh" />
+      <option name="name" value="ossrh" />
+      <option name="url" value="https://oss.sonatype.org/content/repositories/snapshots" />
+    </remote-repository>
   </component>
 </project>
\ No newline at end of file
diff --git a/api/pom.xml b/api/pom.xml
index 99f65d3..3b966c7 100644
--- a/api/pom.xml
+++ b/api/pom.xml
@@ -45,69 +45,11 @@
         <tag>HEAD</tag>
     </scm>
 
-
-
     <issueManagement>
         <system>JIRA</system>
         <url>http://bug.ossez.com/projects/USVisaTrack</url>
     </issueManagement>
 
-
-
-    <!-- Note that the 'repositories' and 'pluginRepositories' blocks below are actually copy-pasted from the Jenkins org pom. This is on purpose
-        to keep jenkins core buildable even if one has *not* defined the specific details in the settings.xml file. -->
-    <repositories>
-        <repository>
-            <id>ossez-repo</id>
-            <name>Ossez-Repo-Snapshot</name>
-            <url>https://repo.ossez.com/repository/maven-snapshots/</url>
-            <snapshots>
-                <enabled>true</enabled>
-            </snapshots>
-            <releases>
-                <enabled>false</enabled>
-            </releases>
-        </repository>
-    </repositories>
-
-
-    <pluginRepositories>
-    </pluginRepositories>
-
-    <dependencyManagement>
-        <dependencies>
-            <dependency>
-                <groupId>org.samba.jcifs</groupId>
-                <artifactId>jcifs</artifactId>
-                <version>1.3.17-kohsuke-1</version>
-            </dependency>
-            <dependency>
-                <groupId>org.kohsuke</groupId>
-                <artifactId>access-modifier-annotation</artifactId>
-                <version>${access-modifier-annotation.version}</version>
-            </dependency>
-        </dependencies>
-    </dependencyManagement>
-
-    <distributionManagement>
-        <site>
-            <id>github-pages</id>
-            <url>gitsite:git@github.com/USRealEstate/Usreio-Docs.git:core</url>
-        </site>
-
-        <repository>
-            <id>ossez-repo</id>
-            <url>https://repo.ossez.com/repository/maven-releases/</url>
-        </repository>
-
-        <snapshotRepository>
-            <id>ossez-repo</id>
-            <url>https://repo.ossez.com/repository/maven-snapshots/</url>
-        </snapshotRepository>
-
-    </distributionManagement>
-
-
     <dependencies>
 
         <!-- LOGGING WITH SELF4J AND LOG4J2 -->
diff --git a/client/pom.xml b/client/pom.xml
index 6678683..1903770 100644
--- a/client/pom.xml
+++ b/client/pom.xml
@@ -80,60 +80,6 @@
         <changelog.url>https://upcex.com/changelog</changelog.url>
     </properties>
 
-    <!-- Note that the 'repositories' and 'pluginRepositories' blocks below are actually copy-pasted from the Jenkins org pom. This is on purpose
-        to keep jenkins core buildable even if one has *not* defined the specific details in the settings.xml file. -->
-    <repositories>
-        <repository>
-            <id>ossez-repo</id>
-            <name>Ossez-Repo-Snapshot</name>
-            <url>https://repo.ossez.com/repository/maven-snapshots/</url>
-            <snapshots>
-                <enabled>true</enabled>
-            </snapshots>
-            <releases>
-                <enabled>false</enabled>
-            </releases>
-        </repository>
-    </repositories>
-
-
-    <pluginRepositories>
-    </pluginRepositories>
-
-    <dependencyManagement>
-        <dependencies>
-            <dependency>
-                <groupId>org.samba.jcifs</groupId>
-                <artifactId>jcifs</artifactId>
-                <version>1.3.17-kohsuke-1</version>
-            </dependency>
-            <dependency>
-                <groupId>org.kohsuke</groupId>
-                <artifactId>access-modifier-annotation</artifactId>
-                <version>${access-modifier-annotation.version}</version>
-            </dependency>
-        </dependencies>
-    </dependencyManagement>
-
-    <distributionManagement>
-        <site>
-            <id>github-pages</id>
-            <url>gitsite:git@github.com/USRealEstate/Usreio-Docs.git:core</url>
-        </site>
-
-        <repository>
-            <id>ossez-repo</id>
-            <url>https://repo.ossez.com/repository/maven-releases/</url>
-        </repository>
-
-        <snapshotRepository>
-            <id>ossez-repo</id>
-            <url>https://repo.ossez.com/repository/maven-snapshots/</url>
-        </snapshotRepository>
-
-    </distributionManagement>
-
-
     <dependencies>
 
         <!-- LOGGING WITH SELF4J AND LOG4J2 -->
@@ -270,10 +216,6 @@
         </resources>
         <pluginManagement>
             <plugins>
-                <plugin>
-                    <groupId>org.springframework.boot</groupId>
-                    <artifactId>spring-boot-maven-plugin</artifactId>
-                </plugin>
                 <plugin>
                     <groupId>org.apache.maven.plugins</groupId>
                     <artifactId>maven-deploy-plugin</artifactId>
diff --git a/pom.xml b/pom.xml
index 891d11a..0d7aeca 100644
--- a/pom.xml
+++ b/pom.xml
@@ -79,23 +79,22 @@
 
         <java.level>11</java.level>
 
-        <changelog.url>https://upcex.com/changelog</changelog.url>
     </properties>
 
     <!-- Note that the 'repositories' and 'pluginRepositories' blocks below are actually copy-pasted from the Jenkins org pom. This is on purpose
         to keep jenkins core buildable even if one has *not* defined the specific details in the settings.xml file. -->
     <repositories>
-        <repository>
-            <id>ossez-repo</id>
-            <name>Ossez-Repo-Snapshot</name>
-            <url>https://repo.ossez.com/repository/maven-snapshots/</url>
-            <snapshots>
-                <enabled>true</enabled>
-            </snapshots>
-            <releases>
-                <enabled>false</enabled>
-            </releases>
-        </repository>
+<!--        <repository>-->
+<!--            <id>ossez-repo</id>-->
+<!--            <name>Ossez-Repo-Snapshot</name>-->
+<!--            <url>https://repo.ossez.com/repository/maven-snapshots/</url>-->
+<!--            <snapshots>-->
+<!--                <enabled>true</enabled>-->
+<!--            </snapshots>-->
+<!--            <releases>-->
+<!--                <enabled>false</enabled>-->
+<!--            </releases>-->
+<!--        </repository>-->
     </repositories>
 
 
@@ -118,20 +117,16 @@
     </dependencyManagement>
 
     <distributionManagement>
-        <site>
-            <id>github-pages</id>
-            <url>gitsite:git@github.com/USRealEstate/Usreio-Docs.git:core</url>
-        </site>
 
-        <repository>
-            <id>ossez-repo</id>
-            <url>https://repo.ossez.com/repository/maven-releases/</url>
-        </repository>
+<!--        <repository>-->
+<!--            <id>ossez-repo</id>-->
+<!--            <url>https://repo.ossez.com/repository/maven-releases/</url>-->
+<!--        </repository>-->
 
-        <snapshotRepository>
-            <id>ossez-repo</id>
-            <url>https://repo.ossez.com/repository/maven-snapshots/</url>
-        </snapshotRepository>
+<!--        <snapshotRepository>-->
+<!--            <id>ossrh</id>-->
+<!--            <url>https://oss.sonatype.org/content/repositories/snapshots</url>-->
+<!--        </snapshotRepository>-->
 
     </distributionManagement>
 
@@ -290,6 +285,12 @@
                     <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>true</autoReleaseAfterClose>
+                    </configuration>
                 </plugin>
 
                 <plugin>
@@ -309,11 +310,6 @@
                     </configuration>
                 </plugin>
 
-                <plugin>
-                    <groupId>org.apache.maven.plugins</groupId>
-                    <artifactId>maven-gpg-plugin</artifactId>
-                    <version>1.4</version>
-                </plugin>
                 <plugin>
                     <groupId>org.apache.maven.plugins</groupId>
                     <artifactId>maven-install-plugin</artifactId>
@@ -451,15 +447,17 @@
 
                 <plugin>
                     <groupId>org.apache.maven.plugins</groupId>
-                    <artifactId>maven-site-plugin</artifactId>
-                    <version>3.3</version>
-                    <dependencies>
-                        <dependency>
-                            <groupId>org.kohsuke</groupId>
-                            <artifactId>doxia-module-markdown</artifactId>
-                            <version>1.0</version>
-                        </dependency>
-                    </dependencies>
+                    <artifactId>maven-gpg-plugin</artifactId>
+                    <version>1.5</version>
+                    <executions>
+                        <execution>
+                            <id>sign-artifacts</id>
+                            <phase>verify</phase>
+                            <goals>
+                                <goal>sign</goal>
+                            </goals>
+                        </execution>
+                    </executions>
                 </plugin>
 
 
@@ -475,6 +473,36 @@
                     <release>11</release>
                 </configuration>
             </plugin>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-source-plugin</artifactId>
+                <version>3.2.1</version>
+                <executions>
+                    <execution>
+                        <id>attach-sources</id>
+                        <goals>
+                            <goal>jar-no-fork</goal>
+                        </goals>
+                    </execution>
+                </executions>
+            </plugin>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-javadoc-plugin</artifactId>
+                <version>3.4.1</version>
+                <configuration>
+                    <source>11</source>
+                </configuration>
+                <executions>
+                    <execution>
+                        <id>attach-javadocs</id>
+                        <goals>
+                            <goal>jar</goal>
+                        </goals>
+                    </execution>
+                </executions>
+            </plugin>
+
             <plugin>
                 <groupId>org.apache.maven.plugins</groupId>
                 <artifactId>maven-deploy-plugin</artifactId>