Repository: Alluxio/alluxio (language: java)

Issue:
Rest API documentation link in File System API documentation page doesn't work
**Alluxio Version:**
https://docs.alluxio.io/os/user/edge/en/api/FS-API.html

**Describe the bug**
The link to "Rest API documentation" doesn't work on the above page.
The link on master works. The link is generated as [REST API documentation](https://docs.alluxio.io/os/restdoc/{{site.ALLUXIO_MAJOR_VERSION}}/proxy/index.html)

Is there a more reliable way to make sure this works?

I double checked 2.7.4 documentation, which redirects to https://docs.alluxio.io/os/restdoc/stable/master/index.html

The word "master" in the link also makes me wonder whether this is the right version to link to.

**To Reproduce**
Go to https://docs.alluxio.io/os/user/edge/en/api/FS-API.html, search for "REST API documentation", click on the link,
which brings you to https://docs.alluxio.io/os/restdoc/edge/proxy/index.html, which is almost empty.

**Expected behavior**
Compare to https://docs.alluxio.io/os/restdoc/stable/master/index.html which has detailed descriptions of apis.

**Urgency**
I don't know.

**Are you planning to fix it**
No, I don't know how to fix this.



Discussion / hints:
https://docs.alluxio.io/os/user/edge/en/api/FS-API.html#rest-api links to https://docs.alluxio.io/os/restdoc/edge/proxy/index.html which is the correct behavior

https://docs.alluxio.io/os/user/stable/en/api/FS-API.html#rest-api links to https://docs.alluxio.io/os/restdoc/2.7/proxy/index.html which is the incorrect behavior when we switched to assigning the full 3 digit version string instead of 2. this is applicable to all 2.7.x and 2.6.x doc versions

https://docs.alluxio.io/os/restdoc/2.5/proxy/index.html links to https://docs.alluxio.io/os/restdoc/2.5/proxy/index.html which is also correct and is true for all older pages

the empty page for the proxy API is a different problem. https://docs.alluxio.io/os/restdoc/2.4/proxy/index.html is the first version with an empty page whereas https://docs.alluxio.io/os/restdoc/2.3/proxy/index.html and older look fine. the pages were all recently generated, so it is likely due to an issue with the generation logic that is present in branch-2.4 and newer (ex. different restdoc generation maven plugin)

Fix patch:
diff --git a/core/server/proxy/pom.xml b/core/server/proxy/pom.xml
index 580c6b35897e..81a337104b3d 100644
--- a/core/server/proxy/pom.xml
+++ b/core/server/proxy/pom.xml
@@ -128,7 +128,11 @@
 1. The Streams endpoint provides a RESTful gateway to the Alluxio file system for data operations.
                 </description>
               </info>
-              <locations>alluxio.proxy.AlluxioProxyRestServiceHandler;alluxio.proxy.PathsRestServiceHandler;alluxio.proxy.StreamsRestServiceHandler</locations>
+              <locations>
+                <location>alluxio.proxy.AlluxioProxyRestServiceHandler</location>
+                <location>alluxio.proxy.PathsRestServiceHandler</location>
+                <location>alluxio.proxy.StreamsRestServiceHandler</location>
+              </locations>
               <templatePath>${project.parent.parent.parent.basedir}/templates/strapdown.html.hbs</templatePath>
               <outputPath>${project.parent.parent.parent.basedir}/generated/proxy/index.html</outputPath>
               <swaggerDirectory>${project.parent.parent.parent.basedir}/generated/proxy/swagger-ui</swaggerDirectory>
diff --git a/job/server/pom.xml b/job/server/pom.xml
index 7f42cf354143..655512206272 100644
--- a/job/server/pom.xml
+++ b/job/server/pom.xml
@@ -164,7 +164,11 @@
                 The Alluxio Job Worker is a component of the Job Service that executes various I/O intensive tasks scheduled by the Alluxio system.
               </description>
             </info>
-            <locations>alluxio.master.AlluxioJobMasterRestServiceHandler;alluxio.worker.AlluxioJobWorkerRestServiceHandler;alluxio.master.job.JobMasterClientRestServiceHandler</locations>
+            <locations>
+              <location>alluxio.master.AlluxioJobMasterRestServiceHandler</location>
+              <location>alluxio.worker.AlluxioJobWorkerRestServiceHandler</location>
+              <location>alluxio.master.job.JobMasterClientRestServiceHandler</location>
+            </locations>
             <templatePath>${project.parent.parent.basedir}/templates/strapdown.html.hbs</templatePath>
             <outputPath>${project.parent.parent.basedir}/generated/job/index.html</outputPath>
             <swaggerDirectory>${project.parent.parent.basedir}/generated/job/swagger-ui</swaggerDirectory>


Test patch: