This is an automated email from the ASF dual-hosted git repository.

hefengen pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shenyu.git


The following commit(s) were added to refs/heads/master by this push:
     new 4824cd1233 [Improve] [ISSUE #5628] Migrate Admin swagger from 
springfox to springdoc (#5630)
4824cd1233 is described below

commit 4824cd1233aae7d151ef32baaf454e4dcf4e331f
Author: VampireAchao <ac...@apache.org>
AuthorDate: Sat Aug 24 23:28:17 2024 +0800

    [Improve] [ISSUE #5628] Migrate Admin swagger from springfox to springdoc 
(#5630)
    
    * [Improve] Migrate Admin swagger from springfox to springdoc
    
    * [Fix] try fix ci
    
    * [Fix] fix test case
    
    * [Fix] fix test case
    
    * [Fix] fix test case
---
 pom.xml                                            |   2 +-
 .../manager/impl/PullSwaggerDocServiceImpl.java    |   4 +-
 .../service/manager/impl/SwaggerDocParser.java     |   5 +-
 .../service/manager/impl/DocManagerImplTest.java   |   2 +-
 .../service/manager/impl/SwaggerDocParserTest.java | 239 +++++++--------------
 .../validation/ApacheDubboClientValidatorTest.java |   2 +-
 shenyu-examples/pom.xml                            |  14 +-
 .../examples/http/config/SwaggerConfiguration.java | 157 --------------
 .../Dockerfile                                     |   2 +-
 .../k8s/script/healthcheck.sh                      |   0
 .../k8s/script/services.list                       |   0
 .../k8s/shenyu-deployment.yml                      |  14 +-
 .../k8s/shenyu-examples-http-deployment.yml        |  24 +--
 .../k8s/shenyu-examples-http-service.yml           |  14 +-
 .../k8s/shenyu-service.yml                         |  10 +-
 .../pom.xml                                        |  20 +-
 .../http/ShenyuTestSwaggerApplication.java         |   0
 .../examples/http/config/HttpServerConfig.java     |   0
 .../examples/http/config/SwaggerConfiguration.java | 112 ++++++++++
 .../http/controller/HttpTestController.java        |  49 ++---
 .../examples/http/controller/OauthController.java  |   0
 .../examples/http/controller/OrderController.java  |  12 +-
 .../http/controller/RequestController.java         |  12 +-
 .../controller/ShenyuClientPathController.java     |   4 +-
 .../controller/SpringMvcMappingPathController.java |  12 +-
 .../examples/http/controller/UploadController.java |  13 +-
 .../apache/shenyu/examples/http/dto/OAuth2DTO.java |   4 +-
 .../apache/shenyu/examples/http/dto/OrderDTO.java  |   9 +-
 .../shenyu/examples/http/dto/RequestDTO.java       |  11 +-
 .../apache/shenyu/examples/http/dto/UserDTO.java   |  14 +-
 .../shenyu/examples/http/result/ResultBean.java    |   0
 .../shenyu/examples/http/result/TreeResult.java    |  11 +-
 .../examples/http/router/ShenyuTestHttpRouter.java |   0
 .../src/main/resources/application.yml             |   8 +-
 shenyu-examples/shenyu-examples-http/pom.xml       |   2 +-
 35 files changed, 327 insertions(+), 455 deletions(-)

diff --git a/pom.xml b/pom.xml
index 6bc2b419d9..5f1183c317 100644
--- a/pom.xml
+++ b/pom.xml
@@ -85,7 +85,7 @@
         <skipTests>false</skipTests>
         <!-- maven plugin version start -->
         <exec-maven-plugin.version>1.6.0</exec-maven-plugin.version>
-        <jacoco-maven-plugin.version>0.8.7</jacoco-maven-plugin.version>
+        <jacoco-maven-plugin.version>0.8.12</jacoco-maven-plugin.version>
         
<nexus-staging-maven-plugin.version>1.6.3</nexus-staging-maven-plugin.version>
         <maven-gpg-plugin.version>1.6</maven-gpg-plugin.version>
         <maven-source-plugin.version>3.0.1</maven-source-plugin.version>
diff --git 
a/shenyu-admin/src/main/java/org/apache/shenyu/admin/service/manager/impl/PullSwaggerDocServiceImpl.java
 
b/shenyu-admin/src/main/java/org/apache/shenyu/admin/service/manager/impl/PullSwaggerDocServiceImpl.java
index 9e7a7e5758..dec7c930e6 100644
--- 
a/shenyu-admin/src/main/java/org/apache/shenyu/admin/service/manager/impl/PullSwaggerDocServiceImpl.java
+++ 
b/shenyu-admin/src/main/java/org/apache/shenyu/admin/service/manager/impl/PullSwaggerDocServiceImpl.java
@@ -56,7 +56,7 @@ public class PullSwaggerDocServiceImpl implements 
PullSwaggerDocService {
 
     private static final HttpUtils HTTP_UTILS = new HttpUtils();
 
-    private static final String SWAGGER_V2_PATH = "/v2/api-docs";
+    private static final String SWAGGER_V3_PATH = "/v3/api-docs";
 
     private static final long PULL_MIN_INTERVAL_TIME = 30 * 1000;
 
@@ -181,7 +181,7 @@ public class PullSwaggerDocServiceImpl implements 
PullSwaggerDocService {
         uriComponentsBuilder.host(instance.getIp());
         uriComponentsBuilder.port(instance.getPort());
         
uriComponentsBuilder.path(Optional.ofNullable(instance.getContextPath()).orElse(""));
-        uriComponentsBuilder.path(SWAGGER_V2_PATH);
+        uriComponentsBuilder.path(SWAGGER_V3_PATH);
         return uriComponentsBuilder.build().toUriString();
     }
 
diff --git 
a/shenyu-admin/src/main/java/org/apache/shenyu/admin/service/manager/impl/SwaggerDocParser.java
 
b/shenyu-admin/src/main/java/org/apache/shenyu/admin/service/manager/impl/SwaggerDocParser.java
index f7afed202e..fc8bbf97d0 100755
--- 
a/shenyu-admin/src/main/java/org/apache/shenyu/admin/service/manager/impl/SwaggerDocParser.java
+++ 
b/shenyu-admin/src/main/java/org/apache/shenyu/admin/service/manager/impl/SwaggerDocParser.java
@@ -247,9 +247,8 @@ public class SwaggerDocParser implements DocParser {
     }
 
     protected List<DocParameter> buildDocParameters(final String ref, final 
JsonObject docRoot, final boolean doSubRef) {
-        JsonObject responseObject = 
docRoot.getAsJsonObject("definitions").getAsJsonObject(ref);
-        String className = responseObject.get("title").getAsString();
-        JsonObject extProperties = docRoot.getAsJsonObject(className);
+        JsonObject responseObject = 
docRoot.getAsJsonObject("components").getAsJsonObject("schemas").getAsJsonObject(ref);
+        JsonObject extProperties = 
responseObject.getAsJsonObject("properties");
         JsonArray requiredProperties = 
responseObject.getAsJsonArray("required");
         List<String> requiredFieldList = 
this.jsonArrayToStringList(requiredProperties);
         JsonObject properties = responseObject.getAsJsonObject("properties");
diff --git 
a/shenyu-admin/src/test/java/org/apache/shenyu/admin/service/manager/impl/DocManagerImplTest.java
 
b/shenyu-admin/src/test/java/org/apache/shenyu/admin/service/manager/impl/DocManagerImplTest.java
index 733191716a..60dfdd7dfc 100644
--- 
a/shenyu-admin/src/test/java/org/apache/shenyu/admin/service/manager/impl/DocManagerImplTest.java
+++ 
b/shenyu-admin/src/test/java/org/apache/shenyu/admin/service/manager/impl/DocManagerImplTest.java
@@ -48,7 +48,7 @@ public class DocManagerImplTest {
         instance.setContextPath("/testClusterName");
         AtomicBoolean atomicBoolean = new AtomicBoolean(false);
         docManager.addDocInfo(instance, SwaggerDocParserTest.DOC_INFO_JSON, 
"", docInfo -> {
-            Assertions.assertEquals(docInfo.getTitle(), 
"shenyu-examples-http-swagger2 API");
+            Assertions.assertEquals(docInfo.getTitle(), 
"shenyu-examples-http-swagger3 API");
             Assertions.assertEquals(docInfo.getClusterName(), 
"testClusterName");
             atomicBoolean.set(true);
         });
diff --git 
a/shenyu-admin/src/test/java/org/apache/shenyu/admin/service/manager/impl/SwaggerDocParserTest.java
 
b/shenyu-admin/src/test/java/org/apache/shenyu/admin/service/manager/impl/SwaggerDocParserTest.java
index 323c96757f..7a88703962 100644
--- 
a/shenyu-admin/src/test/java/org/apache/shenyu/admin/service/manager/impl/SwaggerDocParserTest.java
+++ 
b/shenyu-admin/src/test/java/org/apache/shenyu/admin/service/manager/impl/SwaggerDocParserTest.java
@@ -32,165 +32,86 @@ import org.mockito.quality.Strictness;
 public class SwaggerDocParserTest {
 
     public static final String DOC_INFO_JSON = "{\n"
-        + "    \"swagger\":\"2.0\",\n"
-        + "    \"info\":{\n"
-        + "        \"description\":\"shenyu-examples-http-swagger2 API\",\n"
-        + "        \"version\":\"2.3.0\",\n"
-        + "        \"title\":\"shenyu-examples-http-swagger2 API\",\n"
-        + "        \"contact\":{\n"
-        + "            \"name\":\"ShenYu\",\n"
-        + "            \"url\":\"https://github.com/apache/shenyu\",\n";
-        + "            \"email\":\"d...@shenyu.apache.org\"\n"
-        + "        }\n"
-        + "    },\n"
-        + "    \"host\":\"127.0.0.1:8190\",\n"
-        + "    \"basePath\":\"/\",\n"
-        + "    \"tags\":[\n"
-        + "        {\n"
-        + "            \"name\":\"Order API\",\n"
-        + "            \"description\":\"Order Controller\"\n"
-        + "        },\n"
-        + "        {\n"
-        + "            \"name\":\"http-test-controller\",\n"
-        + "            \"description\":\"Http Test Controller\"\n"
-        + "        }\n"
-        + "    ],\n"
-        + "    \"paths\":{\n"
-        + "        \"/order/path/{id}/{name}\":{\n"
-        + "            \"get\":{\n"
-        + "                \"tags\":[\n"
-        + "                    \"Order API\"\n"
-        + "                ],\n"
-        + "                \"summary\":\"getPathVariable\",\n"
-        + "                \"description\":\"get path variable.\",\n"
-        + "                \"operationId\":\"getPathVariableUsingGET_1\",\n"
-        + "                \"produces\":[\n"
-        + "                    \"*/*\"\n"
-        + "                ],\n"
-        + "                \"parameters\":[\n"
-        + "                    {\n"
-        + "                        \"name\":\"X-Access-Token\",\n"
-        + "                        \"in\":\"header\",\n"
-        + "                        \"description\":\"user auth\",\n"
-        + "                        \"required\":false,\n"
-        + "                        \"type\":\"string\"\n"
-        + "                    },\n"
-        + "                    {\n"
-        + "                        \"name\":\"id\",\n"
-        + "                        \"in\":\"path\",\n"
-        + "                        \"description\":\"id\",\n"
-        + "                        \"required\":true,\n"
-        + "                        \"type\":\"string\"\n"
-        + "                    },\n"
-        + "                    {\n"
-        + "                        \"name\":\"name\",\n"
-        + "                        \"in\":\"path\",\n"
-        + "                        \"description\":\"name\",\n"
-        + "                        \"required\":true,\n"
-        + "                        \"type\":\"string\"\n"
-        + "                    }\n"
-        + "                ],\n"
-        + "                \"responses\":{\n"
-        + "                    \"200\":{\n"
-        + "                        \"description\":\"OK\",\n"
-        + "                        \"schema\":{\n"
-        + "                            \"$ref\":\"#/definitions/OrderDTO\"\n"
-        + "                        }\n"
-        + "                    },\n"
-        + "                \"deprecated\":false\n"
-        + "             }\n"
-        + "           }\n"
-        + "        },\n"
-        + "        \"/test/payment\":{\n"
-        + "            \"post\":{\n"
-        + "                \"tags\":[\n"
-        + "                    \"http-test-controller\"\n"
-        + "                ],\n"
-        + "                \"summary\":\"payment\",\n"
-        + "                \"description\":\"The user pays the order.\",\n"
-        + "                \"operationId\":\"postUsingPOST\",\n"
-        + "                \"consumes\":[\n"
-        + "                    \"application/json\"\n"
-        + "                ],\n"
-        + "                \"produces\":[\n"
-        + "                    \"*/*\"\n"
-        + "                ],\n"
-        + "                \"parameters\":[\n"
-        + "                    {\n"
-        + "                        \"name\":\"X-Access-Token\",\n"
-        + "                        \"in\":\"header\",\n"
-        + "                        \"description\":\"user auth\",\n"
-        + "                        \"required\":false,\n"
-        + "                        \"type\":\"string\"\n"
-        + "                    },\n"
-        + "                    {\n"
-        + "                        \"in\":\"body\",\n"
-        + "                        \"name\":\"userDTO\",\n"
-        + "                        \"description\":\"userDTO\",\n"
-        + "                        \"required\":true,\n"
-        + "                        \"schema\":{\n"
-        + "                            \"$ref\":\"#/definitions/UserDTO\"\n"
-        + "                        }\n"
-        + "                    }\n"
-        + "                ],\n"
-        + "                \"responses\":{\n"
-        + "                    \"200\":{\n"
-        + "                        \"description\":\"OK\",\n"
-        + "                        \"schema\":{\n"
-        + "                            \"$ref\":\"#/definitions/UserDTO\"\n"
-        + "                        }\n"
-        + "                    }\n"
-        + "                },\n"
-        + "                \"deprecated\":false\n"
-        + "            }\n"
-        + "        }\n"
-        + "    },\n"
-        + "    \"definitions\":{\n"
-        + "        \"Mono«string»\":{\n"
-        + "            \"type\":\"object\",\n"
-        + "            \"title\":\"Mono«string»\"\n"
-        + "        },\n"
-        + "        \"OrderDTO\":{\n"
-        + "            \"type\":\"object\",\n"
-        + "            \"required\":[\n"
-        + "                \"id\",\n"
-        + "                \"name\"\n"
-        + "            ],\n"
-        + "            \"properties\":{\n"
-        + "                \"id\":{\n"
-        + "                    \"type\":\"string\",\n"
-        + "                    \"example\":100000,\n"
-        + "                    \"description\":\"id\"\n"
-        + "                },\n"
-        + "                \"name\":{\n"
-        + "                    \"type\":\"string\",\n"
-        + "                    \"example\":\"jack\",\n"
-        + "                    \"description\":\"name\"\n"
-        + "                }\n"
-        + "            },\n"
-        + "            \"title\":\"OrderDTO\"\n"
-        + "        },\n"
-        + "        \"UserDTO\":{\n"
-        + "            \"type\":\"object\",\n"
-        + "            \"required\":[\n"
-        + "                \"userId\"\n"
-        + "            ],\n"
-        + "            \"properties\":{\n"
-        + "                \"userId\":{\n"
-        + "                    \"type\":\"string\",\n"
-        + "                    \"example\":100000,\n"
-        + "                    \"description\":\"user id\"\n"
-        + "                },\n"
-        + "                \"userName\":{\n"
-        + "                    \"type\":\"string\",\n"
-        + "                    \"example\":\"shenyu\",\n"
-        + "                    \"description\":\"user name\"\n"
-        + "                }\n"
-        + "            },\n"
-        + "            \"title\":\"UserDTO\"\n"
-        + "        }\n"
-        + "    }\n"
-        + "}";
+            + "  \"openapi\": \"3.0.1\",\n"
+            + "  \"info\": {\n"
+            + "    \"title\": \"shenyu-examples-http-swagger3 API\",\n"
+            + "    \"description\": \"shenyu-examples-http-swagger3 API\",\n"
+            + "    \"version\": \"3.0.1\",\n"
+            + "    \"contact\": {\n"
+            + "      \"name\": \"ShenYu\",\n"
+            + "      \"url\": \"https://github.com/apache/shenyu\",\n";
+            + "      \"email\": \"d...@shenyu.apache.org\"\n"
+            + "    }\n"
+            + "  },\n"
+            + "  \"servers\": [\n"
+            + "    {\n"
+            + "      \"url\": \"http://127.0.0.1:8190\",\n";
+            + "      \"description\": \"Local server\"\n"
+            + "    }\n"
+            + "  ],\n"
+            + "  \"tags\": [\n"
+            + "    {\n"
+            + "      \"name\": \"Order API\",\n"
+            + "      \"description\": \"Order Controller\"\n"
+            + "    }\n"
+            + "  ],\n"
+            + "  \"paths\": {\n"
+            + "    \"/order/path/{id}/{name}\": {\n"
+            + "      \"get\": {\n"
+            + "        \"tags\": [\"Order API\"],\n"
+            + "        \"summary\": \"Get path variable\",\n"
+            + "        \"parameters\": [\n"
+            + "          {\n"
+            + "            \"name\": \"id\",\n"
+            + "            \"in\": \"path\",\n"
+            + "            \"required\": true,\n"
+            + "            \"schema\": {\n"
+            + "              \"type\": \"string\"\n"
+            + "            }\n"
+            + "          },\n"
+            + "          {\n"
+            + "            \"name\": \"name\",\n"
+            + "            \"in\": \"path\",\n"
+            + "            \"required\": true,\n"
+            + "            \"schema\": {\n"
+            + "              \"type\": \"string\"\n"
+            + "            }\n"
+            + "          }\n"
+            + "        ],\n"
+            + "        \"responses\": {\n"
+            + "          \"200\": {\n"
+            + "            \"description\": \"Successful response\",\n"
+            + "            \"content\": {\n"
+            + "              \"application/json\": {\n"
+            + "                \"schema\": {\n"
+            + "                  \"$ref\": \"#/components/schemas/OrderDTO\"\n"
+            + "                }\n"
+            + "              }\n"
+            + "            }\n"
+            + "          }\n"
+            + "        }\n"
+            + "      }\n"
+            + "    }\n"
+            + "  },\n"
+            + "  \"components\": {\n"
+            + "    \"schemas\": {\n"
+            + "      \"OrderDTO\": {\n"
+            + "        \"type\": \"object\",\n"
+            + "        \"required\": [\"id\", \"name\"],\n"
+            + "        \"properties\": {\n"
+            + "          \"id\": {\n"
+            + "            \"type\": \"string\",\n"
+            + "            \"example\": \"100000\"\n"
+            + "          },\n"
+            + "          \"name\": {\n"
+            + "            \"type\": \"string\",\n"
+            + "            \"example\": \"jack\"\n"
+            + "          }\n"
+            + "        }\n"
+            + "      }\n"
+            + "    }\n"
+            + "  }\n"
+            + "}\n";
 
     @InjectMocks
     private SwaggerDocParser swaggerDocParser;
diff --git 
a/shenyu-client/shenyu-client-dubbo/shenyu-client-apache-dubbo/src/test/java/org/apache/shenyu/client/apache/dubbo/validation/ApacheDubboClientValidatorTest.java
 
b/shenyu-client/shenyu-client-dubbo/shenyu-client-apache-dubbo/src/test/java/org/apache/shenyu/client/apache/dubbo/validation/ApacheDubboClientValidatorTest.java
index 73573674ca..626d21ab53 100644
--- 
a/shenyu-client/shenyu-client-dubbo/shenyu-client-apache-dubbo/src/test/java/org/apache/shenyu/client/apache/dubbo/validation/ApacheDubboClientValidatorTest.java
+++ 
b/shenyu-client/shenyu-client-dubbo/shenyu-client-apache-dubbo/src/test/java/org/apache/shenyu/client/apache/dubbo/validation/ApacheDubboClientValidatorTest.java
@@ -91,7 +91,7 @@ public final class ApacheDubboClientValidatorTest {
                 .validate(
                         "methodTwo",
                         new Class<?>[]{MockValidationParameter.class},
-                        new Object[]{new 
MockValidationParameter("NotBeNull")}));
+                        new Object[]{new MockValidationParameter()}));
     }
 
     @Test
diff --git a/shenyu-examples/pom.xml b/shenyu-examples/pom.xml
index 848aab23c6..2190794928 100644
--- a/shenyu-examples/pom.xml
+++ b/shenyu-examples/pom.xml
@@ -38,13 +38,13 @@
         <versions-maven-plugin.version>2.5</versions-maven-plugin.version>
         <docker-maven-plugin.version>0.40.1</docker-maven-plugin.version>
         
<maven-checkstyle-plugin.version>3.1.0</maven-checkstyle-plugin.version>
-        <swagger.version>2.9.2</swagger.version>
+        <swagger.version>2.6.0</swagger.version>
     </properties>
 
     <modules>
         <module>shenyu-examples-common</module>
         <module>shenyu-examples-http</module>
-        <module>shenyu-examples-http-swagger2</module>
+        <module>shenyu-examples-http-swagger3</module>
         <module>shenyu-examples-https</module>
         <module>shenyu-examples-dubbo</module>
         <module>shenyu-examples-springcloud</module>
@@ -63,14 +63,8 @@
     <dependencyManagement>
         <dependencies>
             <dependency>
-                <groupId>io.springfox</groupId>
-                <artifactId>springfox-swagger2</artifactId>
-                <version>${swagger.version}</version>
-            </dependency>
-
-            <dependency>
-                <groupId>io.springfox</groupId>
-                <artifactId>springfox-swagger-ui</artifactId>
+                <groupId>org.springdoc</groupId>
+                <artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
                 <version>${swagger.version}</version>
             </dependency>
         </dependencies>
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/config/SwaggerConfiguration.java
 
b/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/config/SwaggerConfiguration.java
deleted file mode 100644
index 1f62fc3400..0000000000
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/config/SwaggerConfiguration.java
+++ /dev/null
@@ -1,157 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.shenyu.examples.http.config;
-
-import io.swagger.annotations.ApiOperation;
-import java.lang.reflect.Field;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.stream.Collectors;
-import org.apache.shenyu.common.constant.Constants;
-import org.apache.shenyu.common.utils.VersionUtils;
-import org.springframework.beans.BeansException;
-import org.springframework.beans.factory.config.BeanPostProcessor;
-import org.springframework.context.annotation.Bean;
-import org.springframework.context.annotation.Configuration;
-import org.springframework.util.ReflectionUtils;
-import 
org.springframework.web.servlet.mvc.method.RequestMappingInfoHandlerMapping;
-import springfox.documentation.builders.ApiInfoBuilder;
-import springfox.documentation.builders.ParameterBuilder;
-import springfox.documentation.builders.PathSelectors;
-import springfox.documentation.builders.RequestHandlerSelectors;
-import springfox.documentation.schema.ModelRef;
-import springfox.documentation.service.ApiInfo;
-import springfox.documentation.service.Contact;
-import springfox.documentation.service.Parameter;
-import springfox.documentation.spi.DocumentationType;
-import springfox.documentation.spring.web.plugins.Docket;
-import springfox.documentation.spring.web.plugins.WebMvcRequestHandlerProvider;
-import springfox.documentation.swagger2.annotations.EnableSwagger2;
-
-/**
- * Configuration class for Swagger API document.
- */
-@Configuration
-@EnableSwagger2
-public class SwaggerConfiguration {
-
-    private static final String DEFAULT_SWAGGER_API_VERSION = "2.3.0";
-
-    private static final String TITLE = "shenyu-examples-http-swagger2 API";
-
-    private static final String DESCRIPTION = "shenyu-examples-http-swagger2 
API";
-
-    private static final String CONTACT_NAME = "ShenYu";
-
-    private static final String CONTACT_URL = 
"https://github.com/apache/shenyu";;
-
-    private static final String CONTACT_EMAIL = "d...@shenyu.apache.org";
-
-    private static final String TOKEN_DESCRIPTION = "user auth";
-
-    private static final String TOKEN_MODEL_REF_TYPE = "string";
-
-    private static final String TOKEN_PARAMETER_TYPE = "header";
-
-    private static boolean enable = true;
-
-    public SwaggerConfiguration() {
-    }
-
-    /**
-     * Configure The Docket with Swagger.
-     *
-     * @return Docket {@linkplain Docket}
-     */
-    @Bean
-    public Docket createRestApi() {
-        ParameterBuilder commonParam = new ParameterBuilder();
-
-        // X-Access-Token
-        List<Parameter> pars = new ArrayList<>();
-        commonParam.name(Constants.X_ACCESS_TOKEN)
-            .description(TOKEN_DESCRIPTION)
-            .modelRef(new ModelRef(TOKEN_MODEL_REF_TYPE))
-            .parameterType(TOKEN_PARAMETER_TYPE)
-            .required(false);
-        pars.add(commonParam.build());
-
-        return new Docket(DocumentationType.SWAGGER_2)
-            .apiInfo(this.apiInfo())
-            .enable(enable)
-            .globalOperationParameters(pars)
-            .select()
-            
.apis(RequestHandlerSelectors.basePackage("org.apache.shenyu.examples.http.controller"))
-            
.apis(RequestHandlerSelectors.withMethodAnnotation(ApiOperation.class))
-            .paths(PathSelectors.any())
-            .build();
-    }
-
-    /**
-     * use bean to be compatible with springboot 2.6.8.
-     *
-     * @return BeanPostProcessor
-     */
-    @Bean
-    public BeanPostProcessor springfoxBeanHandler() {
-        return new BeanPostProcessor() {
-            @Override
-            public Object postProcessAfterInitialization(final Object bean,
-                final String beanName) throws BeansException {
-                if (bean instanceof WebMvcRequestHandlerProvider) {
-                    
customizeSpringfoxHandlerMappings(getHandlerMappings(bean));
-                }
-                return bean;
-            }
-
-            private <T extends RequestMappingInfoHandlerMapping> void 
customizeSpringfoxHandlerMappings(
-                final List<T> mappings) {
-                List<T> copy = mappings.stream()
-                    .filter(mapping -> mapping.getPatternParser() == null)
-                    .collect(Collectors.toList());
-                mappings.clear();
-                mappings.addAll(copy);
-            }
-
-            @SuppressWarnings("unchecked")
-            private List<RequestMappingInfoHandlerMapping> 
getHandlerMappings(final Object bean) {
-                try {
-                    Field field = ReflectionUtils.findField(bean.getClass(), 
"handlerMappings");
-                    field.setAccessible(true);
-                    return (List<RequestMappingInfoHandlerMapping>) 
field.get(bean);
-                } catch (IllegalArgumentException | IllegalAccessException e) {
-                    throw new IllegalStateException(e);
-                }
-            }
-        };
-    }
-
-    /**
-     * Fetch version information from pom.xml and set title, version, 
description,
-     * contact for Swagger API document.
-     *
-     * @return Api info
-     */
-    private ApiInfo apiInfo() {
-        return new ApiInfoBuilder()
-            .title(TITLE).description(DESCRIPTION)
-            .version(VersionUtils.getVersion(getClass(), 
DEFAULT_SWAGGER_API_VERSION))
-            .contact(new Contact(CONTACT_NAME, CONTACT_URL, CONTACT_EMAIL))
-            .build();
-    }
-}
diff --git a/shenyu-examples/shenyu-examples-http-swagger2/Dockerfile 
b/shenyu-examples/shenyu-examples-http-swagger3/Dockerfile
similarity index 95%
rename from shenyu-examples/shenyu-examples-http-swagger2/Dockerfile
rename to shenyu-examples/shenyu-examples-http-swagger3/Dockerfile
index db8406672e..6c1108c95a 100644
--- a/shenyu-examples/shenyu-examples-http-swagger2/Dockerfile
+++ b/shenyu-examples/shenyu-examples-http-swagger3/Dockerfile
@@ -16,7 +16,7 @@
 
 FROM eclipse-temurin:17-centos7
 
-ENV APP_NAME shenyu-examples-http-swagger2
+ENV APP_NAME shenyu-examples-http-swagger3
 ENV LOCAL_PATH /opt/${APP_NAME}
 
 RUN mkdir -p ${LOCAL_PATH}
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/k8s/script/healthcheck.sh 
b/shenyu-examples/shenyu-examples-http-swagger3/k8s/script/healthcheck.sh
similarity index 100%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/k8s/script/healthcheck.sh
rename to 
shenyu-examples/shenyu-examples-http-swagger3/k8s/script/healthcheck.sh
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/k8s/script/services.list 
b/shenyu-examples/shenyu-examples-http-swagger3/k8s/script/services.list
similarity index 100%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/k8s/script/services.list
rename to shenyu-examples/shenyu-examples-http-swagger3/k8s/script/services.list
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/k8s/shenyu-deployment.yml 
b/shenyu-examples/shenyu-examples-http-swagger3/k8s/shenyu-deployment.yml
similarity index 89%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/k8s/shenyu-deployment.yml
rename to 
shenyu-examples/shenyu-examples-http-swagger3/k8s/shenyu-deployment.yml
index 415ca0be6e..4fdef34672 100644
--- a/shenyu-examples/shenyu-examples-http-swagger2/k8s/shenyu-deployment.yml
+++ b/shenyu-examples/shenyu-examples-http-swagger3/k8s/shenyu-deployment.yml
@@ -20,18 +20,18 @@ metadata:
   name: shenyu-admin
   labels:
     app: shenyu-admin
-    all: shenyu-examples-http-swagger2
+    all: shenyu-examples-http-swagger3
 spec:
   replicas: 1
   selector:
     matchLabels:
       app: shenyu-admin
-      all: shenyu-examples-http-swagger2
+      all: shenyu-examples-http-swagger3
   template:
     metadata:
       labels:
         app: shenyu-admin
-        all: shenyu-examples-http-swagger2
+        all: shenyu-examples-http-swagger3
     spec:
       containers:
         - name: shenyu-admin
@@ -55,18 +55,18 @@ metadata:
   name: shenyu-bootstrap
   labels:
     app: shenyu-bootstrap
-    all: shenyu-examples-http-swagger2
+    all: shenyu-examples-http-swagger3
 spec:
   replicas: 1
   selector:
     matchLabels:
       app: shenyu-bootstrap
-      all: shenyu-examples-http-swagger2
+      all: shenyu-examples-http-swagger3
   template:
     metadata:
       labels:
         app: shenyu-bootstrap
-        all: shenyu-examples-http-swagger2
+        all: shenyu-examples-http-swagger3
     spec:
       containers:
         - name: shenyu-bootstrap
@@ -79,4 +79,4 @@ spec:
             - containerPort: 9195
           imagePullPolicy: IfNotPresent
       restartPolicy: Always
-status: {}
\ No newline at end of file
+status: {}
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/k8s/shenyu-examples-http-deployment.yml
 
b/shenyu-examples/shenyu-examples-http-swagger3/k8s/shenyu-examples-http-deployment.yml
similarity index 80%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/k8s/shenyu-examples-http-deployment.yml
rename to 
shenyu-examples/shenyu-examples-http-swagger3/k8s/shenyu-examples-http-deployment.yml
index 597fdead30..602217e465 100644
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/k8s/shenyu-examples-http-deployment.yml
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/k8s/shenyu-examples-http-deployment.yml
@@ -17,26 +17,26 @@
 apiVersion: apps/v1
 kind: Deployment
 metadata:
-  name: shenyu-examples-http-swagger2-deployment
+  name: shenyu-examples-http-swagger3-deployment
   labels:
-    app: shenyu-examples-http-swagger2
-    all: shenyu-examples-http-swagger2
+    app: shenyu-examples-http-swagger3
+    all: shenyu-examples-http-swagger3
 spec:
   replicas: 1
   selector:
     matchLabels:
-      app: shenyu-examples-http-swagger2
-      all: shenyu-examples-http-swagger2
+      app: shenyu-examples-http-swagger3
+      all: shenyu-examples-http-swagger3
   strategy: {}
   template:
     metadata:
       labels:
-        app: shenyu-examples-http-swagger2
-        all: shenyu-examples-http-swagger2
+        app: shenyu-examples-http-swagger3
+        all: shenyu-examples-http-swagger3
     spec:
       containers:
-        - image: shenyu-examples-http-swagger2
-          name: shenyu-examples-http-swagger2
+        - image: shenyu-examples-http-swagger3
+          name: shenyu-examples-http-swagger3
           livenessProbe:
             exec:
               command:
@@ -59,20 +59,20 @@ kind: Deployment
 metadata:
   labels:
     app: shenyu-zk
-    all: shenyu-examples-http-swagger2
+    all: shenyu-examples-http-swagger3
   name: shenyu-zk
 spec:
   replicas: 1
   selector:
     matchLabels:
       app: shenyu-zk
-      all: shenyu-examples-http-swagger2
+      all: shenyu-examples-http-swagger3
   strategy: {}
   template:
     metadata:
       labels:
         app: shenyu-zk
-        all: shenyu-examples-http-swagger2
+        all: shenyu-examples-http-swagger3
     spec:
       containers:
         - image: zookeeper:3.5
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/k8s/shenyu-examples-http-service.yml
 
b/shenyu-examples/shenyu-examples-http-swagger3/k8s/shenyu-examples-http-service.yml
similarity index 83%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/k8s/shenyu-examples-http-service.yml
rename to 
shenyu-examples/shenyu-examples-http-swagger3/k8s/shenyu-examples-http-service.yml
index d2166b1ab6..c1d08e1be1 100644
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/k8s/shenyu-examples-http-service.yml
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/k8s/shenyu-examples-http-service.yml
@@ -17,14 +17,14 @@
 apiVersion: v1
 kind: Service
 metadata:
-  name: shenyu-examples-http-swagger2-service
+  name: shenyu-examples-http-swagger3-service
   labels:
-    app: shenyu-examples-http-swagger2
-    all: shenyu-examples-http-swagger2
+    app: shenyu-examples-http-swagger3
+    all: shenyu-examples-http-swagger3
 spec:
   selector:
-    app: shenyu-examples-http-swagger2
-    all: shenyu-examples-http-swagger2
+    app: shenyu-examples-http-swagger3
+    all: shenyu-examples-http-swagger3
   type: NodePort
   ports:
   - name: "8190"
@@ -41,12 +41,12 @@ metadata:
   name: shenyu-zk
   labels:
     app: shenyu-zk
-    all: shenyu-examples-http-swagger2
+    all: shenyu-examples-http-swagger3
 spec:
   type: NodePort
   selector:
     app: shenyu-zk
-    all: shenyu-examples-http-swagger2
+    all: shenyu-examples-http-swagger3
   ports:
     - name: "client"
       port: 2181
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/k8s/shenyu-service.yml 
b/shenyu-examples/shenyu-examples-http-swagger3/k8s/shenyu-service.yml
similarity index 87%
rename from shenyu-examples/shenyu-examples-http-swagger2/k8s/shenyu-service.yml
rename to shenyu-examples/shenyu-examples-http-swagger3/k8s/shenyu-service.yml
index 63e38f8f35..5da856eb43 100644
--- a/shenyu-examples/shenyu-examples-http-swagger2/k8s/shenyu-service.yml
+++ b/shenyu-examples/shenyu-examples-http-swagger3/k8s/shenyu-service.yml
@@ -20,12 +20,12 @@ metadata:
   name: shenyu-admin
   labels:
     app: shenyu-admin
-    all: shenyu-examples-http-swagger2
+    all: shenyu-examples-http-swagger3
 spec:
   type: NodePort
   selector:
     app: shenyu-admin
-    all: shenyu-examples-http-swagger2
+    all: shenyu-examples-http-swagger3
   ports:
   - name: "9095"
     port: 9095
@@ -39,14 +39,14 @@ metadata:
   name: shenyu-bootstrap
   labels:
     app: shenyu-bootstrap
-    all: shenyu-examples-http-swagger2
+    all: shenyu-examples-http-swagger3
 spec:
   type: NodePort
   selector:
     app: shenyu-bootstrap
-    all: shenyu-examples-http-swagger2
+    all: shenyu-examples-http-swagger3
   ports:
   - name: "9195"
     port: 9195
     targetPort: 9195
-    nodePort: 31195
\ No newline at end of file
+    nodePort: 31195
diff --git a/shenyu-examples/shenyu-examples-http-swagger2/pom.xml 
b/shenyu-examples/shenyu-examples-http-swagger3/pom.xml
similarity index 92%
rename from shenyu-examples/shenyu-examples-http-swagger2/pom.xml
rename to shenyu-examples/shenyu-examples-http-swagger3/pom.xml
index 8fb3dacca7..4d4313e81e 100644
--- a/shenyu-examples/shenyu-examples-http-swagger2/pom.xml
+++ b/shenyu-examples/shenyu-examples-http-swagger3/pom.xml
@@ -25,10 +25,10 @@
         <version>2.7.0-SNAPSHOT</version>
     </parent>
     <modelVersion>4.0.0</modelVersion>
-    <artifactId>shenyu-examples-http-swagger2</artifactId>
+    <artifactId>shenyu-examples-http-swagger3</artifactId>
 
     <properties>
-        <commons-lang3.version>3.3.2</commons-lang3.version>
+        <commons-lang3.version>3.12.0</commons-lang3.version>
         <guava.version>21.0</guava.version>
         <commons-collections4.version>4.4</commons-collections4.version>
     </properties>
@@ -110,17 +110,13 @@
         </dependency>
 
         <dependency>
-            <groupId>io.springfox</groupId>
-            <artifactId>springfox-swagger2</artifactId>
-        </dependency>
-        <dependency>
-            <groupId>io.springfox</groupId>
-            <artifactId>springfox-swagger-ui</artifactId>
+            <groupId>org.springdoc</groupId>
+            <artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
         </dependency>
     </dependencies>
 
     <build>
-        <finalName>shenyu-examples-http-swagger2</finalName>
+        <finalName>shenyu-examples-http-swagger3</finalName>
         <plugins>
             <plugin>
                 <groupId>org.springframework.boot</groupId>
@@ -137,8 +133,8 @@
         <profile>
             <id>example</id>
             <properties>
-                
<docker.buildArg.APP_NAME>shenyu-examples-http-swagger2</docker.buildArg.APP_NAME>
-                
<docker.image.tag.repo>shenyu-examples-http-swagger2</docker.image.tag.repo>
+                
<docker.buildArg.APP_NAME>shenyu-examples-http-swagger3</docker.buildArg.APP_NAME>
+                
<docker.image.tag.repo>shenyu-examples-http-swagger3</docker.image.tag.repo>
                 <docker.image.tag.tagName>latest</docker.image.tag.tagName>
             </properties>
             <activation>
@@ -153,7 +149,7 @@
                         <configuration>
                             <images>
                                 <image>
-                                    <name>shenyu-examples-http-swagger2</name>
+                                    <name>shenyu-examples-http-swagger3</name>
                                     <build>
                                         
<contextDir>${project.basedir}</contextDir>
                                     </build>
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/ShenyuTestSwaggerApplication.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/ShenyuTestSwaggerApplication.java
similarity index 100%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/ShenyuTestSwaggerApplication.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/ShenyuTestSwaggerApplication.java
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/config/HttpServerConfig.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/config/HttpServerConfig.java
similarity index 100%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/config/HttpServerConfig.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/config/HttpServerConfig.java
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/config/SwaggerConfiguration.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/config/SwaggerConfiguration.java
new file mode 100644
index 0000000000..ea29804308
--- /dev/null
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/config/SwaggerConfiguration.java
@@ -0,0 +1,112 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.shenyu.examples.http.config;
+
+import io.swagger.v3.oas.models.Components;
+import io.swagger.v3.oas.models.OpenAPI;
+import io.swagger.v3.oas.models.info.Info;
+import io.swagger.v3.oas.models.media.StringSchema;
+import io.swagger.v3.oas.models.parameters.Parameter;
+import io.swagger.v3.oas.models.security.SecurityRequirement;
+import io.swagger.v3.oas.models.security.SecurityScheme;
+import io.swagger.v3.oas.models.tags.Tag;
+import org.apache.shenyu.common.constant.Constants;
+import org.apache.shenyu.common.utils.VersionUtils;
+import org.springdoc.core.models.GroupedOpenApi;
+import org.springframework.context.annotation.Bean;
+import org.springframework.context.annotation.Configuration;
+
+import java.util.List;
+
+/**
+ * Configuration class for Swagger API document using Springdoc.
+ */
+@Configuration
+public class SwaggerConfiguration {
+
+    private static final String DEFAULT_SWAGGER_API_VERSION = "3.0.1";
+
+    private static final String TITLE = "shenyu-examples-http-swagger3 API";
+
+    private static final String DESCRIPTION = "shenyu-examples-http-swagger3 
API";
+
+    private static final String CONTACT_NAME = "ShenYu";
+
+    private static final String CONTACT_URL = 
"https://github.com/apache/shenyu";;
+
+    private static final String CONTACT_EMAIL = "d...@shenyu.apache.org";
+
+    private static final String TOKEN_DESCRIPTION = "user auth";
+
+    private static final String TOKEN_PARAMETER_TYPE = "header";
+
+    public SwaggerConfiguration() {
+    }
+
+    /**
+     * Configure The OpenAPI with Springdoc.
+     *
+     * @return GroupedOpenApi {@linkplain GroupedOpenApi}
+     */
+    @Bean
+    public GroupedOpenApi createRestApi() {
+        Parameter commonParam = new Parameter()
+                .in(TOKEN_PARAMETER_TYPE)
+                .name(Constants.X_ACCESS_TOKEN)
+                .description(TOKEN_DESCRIPTION)
+                .required(false)
+                .schema(new StringSchema());
+
+        return GroupedOpenApi.builder()
+                .group("default")
+                .addOperationCustomizer((operation, handlerMethod) -> {
+                    operation.addParametersItem(commonParam);
+                    return operation;
+                })
+                .packagesToScan("org.apache.shenyu.examples.http.controller")
+                .build();
+    }
+
+    /**
+     * Configure the OpenAPI with API information.
+     *
+     * @return OpenAPI {@linkplain OpenAPI}
+     */
+    @Bean
+    public OpenAPI customOpenAPI() {
+        return new OpenAPI()
+                .info(new Info()
+                        .title(TITLE)
+                        .version(VersionUtils.getVersion(getClass(), 
DEFAULT_SWAGGER_API_VERSION))
+                        .description(DESCRIPTION)
+                        .contact(new io.swagger.v3.oas.models.info.Contact()
+                                .name(CONTACT_NAME)
+                                .url(CONTACT_URL)
+                                .email(CONTACT_EMAIL)))
+                .components(new Components()
+                        .addSecuritySchemes(Constants.X_ACCESS_TOKEN, new 
SecurityScheme()
+                                .type(SecurityScheme.Type.APIKEY)
+                                .in(SecurityScheme.In.HEADER)
+                                .name(Constants.X_ACCESS_TOKEN)))
+                .addSecurityItem(new 
SecurityRequirement().addList(Constants.X_ACCESS_TOKEN))
+                .tags(List.of(
+                        new Tag().name("RequestController"),
+                        new Tag().name("Order API")
+                ));
+    }
+}
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/HttpTestController.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/HttpTestController.java
similarity index 90%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/HttpTestController.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/HttpTestController.java
index 71ab18c24f..d09eb5b975 100644
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/HttpTestController.java
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/HttpTestController.java
@@ -18,11 +18,11 @@
 package org.apache.shenyu.examples.http.controller;
 
 import com.google.common.collect.ImmutableMap;
-import io.swagger.annotations.Api;
-import io.swagger.annotations.ApiImplicitParam;
-import io.swagger.annotations.ApiImplicitParams;
-import io.swagger.annotations.ApiOperation;
-import java.util.Arrays;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.Parameter;
+import io.swagger.v3.oas.annotations.Parameters;
+import io.swagger.v3.oas.annotations.media.Schema;
+import io.swagger.v3.oas.annotations.tags.Tag;
 import org.apache.shenyu.client.springmvc.annotation.ShenyuSpringMvcClient;
 import org.apache.shenyu.common.utils.GsonUtils;
 import org.apache.shenyu.examples.http.dto.UserDTO;
@@ -35,18 +35,18 @@ import org.springframework.http.HttpStatus;
 import org.springframework.http.MediaType;
 import org.springframework.http.ResponseEntity;
 import org.springframework.http.codec.multipart.FilePart;
-import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.CookieValue;
 import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.PathVariable;
+import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.PutMapping;
-import org.springframework.web.bind.annotation.RestController;
-import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RequestBody;
-import org.springframework.web.bind.annotation.RequestParam;
-import org.springframework.web.bind.annotation.PathVariable;
 import org.springframework.web.bind.annotation.RequestHeader;
-import org.springframework.web.bind.annotation.CookieValue;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RequestParam;
 import org.springframework.web.bind.annotation.RequestPart;
 import org.springframework.web.bind.annotation.ResponseStatus;
+import org.springframework.web.bind.annotation.RestController;
 import org.springframework.web.server.ServerWebExchange;
 import reactor.core.publisher.Mono;
 
@@ -57,6 +57,7 @@ import java.net.URLEncoder;
 import java.nio.charset.StandardCharsets;
 import java.nio.file.Files;
 import java.nio.file.Path;
+import java.util.Arrays;
 import java.util.Date;
 import java.util.HashMap;
 import java.util.Map;
@@ -67,7 +68,7 @@ import java.util.Map;
 @RestController
 @RequestMapping("/test")
 @ShenyuSpringMvcClient("/test/**")
-@Api(tags = "HttpBaseTestAPI")
+@Tag(name = "HttpBaseTestAPI")
 public class HttpTestController {
 
     private static final Logger LOGGER = 
LoggerFactory.getLogger(HttpTestController.class);
@@ -78,7 +79,7 @@ public class HttpTestController {
      * @param userDTO the user dto
      * @return the user dto
      */
-    @ApiOperation(value = "payment", notes = "The user pays the order.", 
position = -100)
+    @Operation(summary = "payment", description = "The user pays the order.")
     @PostMapping("/payment")
     public UserDTO post(@RequestBody final UserDTO userDTO) {
         return userDTO;
@@ -90,8 +91,8 @@ public class HttpTestController {
      * @param userId the user id
      * @return the string
      */
-    @ApiOperation(value = "findByUserId", notes = "Query the user information 
with the user ID.")
-    @ApiImplicitParam(value = "user id", name = "userId", required = true, 
dataType = "string", example = "100000")
+    @Operation(summary = "findByUserId", description = "Query the user 
information with the user ID.")
+    @Parameter(description = "user id", name = "userId", required = true, 
schema = @Schema(type = "string", example = "100000"))
     @GetMapping("/findByUserId")
     public UserDTO findByUserId(@RequestParam("userId") final String userId) {
         return buildUser(userId, "hello world");
@@ -104,10 +105,10 @@ public class HttpTestController {
      * @param name   name
      * @return the string
      */
-    @ApiOperation(value = "findByUserIdName", notes = "Query user information 
with user ID and name.")
-    @ApiImplicitParams(value = {
-        @ApiImplicitParam(value = "user id", name = "userId", required = true, 
dataTypeClass = String.class, example = "100000"),
-        @ApiImplicitParam(value = "user name", name = "name", dataTypeClass = 
String.class, example = "shenyu")
+    @Operation(summary = "findByUserIdName", description = "Query user 
information with user ID and name.")
+    @Parameters(value = {
+            @Parameter(name = "userId", description = "user id", required = 
true, schema = @Schema(type = "string", example = "100000")),
+            @Parameter(name = "name", description = "user name", schema = 
@Schema(type = "string", example = "shenyu"))
     })
     @GetMapping("/findByUserIdName")
     public UserDTO findByUserId(@RequestParam("userId") final String userId, 
@RequestParam("name") final String name) {
@@ -122,7 +123,7 @@ public class HttpTestController {
      * @param pageSize the page size
      * @return the user dto
      */
-    @ApiOperation(value = "findByPage", notes = "Find user dto by page.")
+    @Operation(summary = "findByPage", description = "Find user dto by page.")
     @GetMapping("/findByPage")
     public UserDTO findByPage(final String keyword, final Integer page, final 
Integer pageSize) {
         return buildUser(keyword, "hello world keyword is " + keyword + " page 
is " + page + " pageSize is " + pageSize);
@@ -135,7 +136,7 @@ public class HttpTestController {
      * @param name the name
      * @return the path variable
      */
-    @ApiOperation(value = "getPathVariable", notes = "Gets path variable.")
+    @Operation(summary = "getPathVariable", description = "Gets path 
variable.")
     @GetMapping("/path/{id}")
     public UserDTO getPathVariable(@PathVariable("id") final String id, 
@RequestParam("name") final String name) {
         return buildUser(id, name);
@@ -147,7 +148,7 @@ public class HttpTestController {
      * @param id the id
      * @return the string
      */
-    @ApiOperation(value = "testRestFul", notes = "Test rest ful string")
+    @Operation(summary = "testRestFul", description = "Test rest ful string")
     @GetMapping("/path/{id}/name")
     public UserDTO testRestFul(@PathVariable("id") final String id) {
         return buildUser(id, "hello world");
@@ -285,7 +286,7 @@ public class HttpTestController {
      * @param requestParameter parameter
      * @return result
      */
-    @ApiOperation(value = "modifyRequestWithHeaderAndCookie", notes = "modify 
request with header and cookie.")
+    @Operation(summary = "modifyRequestWithHeaderAndCookie", description = 
"modify request with header and cookie.")
     @PostMapping(path = "/modifyRequest")
     public Map<String, Object> modifyRequest(@RequestBody final UserDTO 
userDTO,
         @CookieValue(value = "cookie", defaultValue = "") final String cookie,
@@ -305,7 +306,7 @@ public class HttpTestController {
      * @param param param
      * @return TreeResult
      */
-    @ApiOperation(value = "retureTreeData", notes = "Return Tree structure 
data.")
+    @Operation(summary = "retureTreeData", description = "Return Tree 
structure data.")
     @PostMapping("/tree/v1")
     public TreeResult tree(final UserDTO param) {
         int id = 0;
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/OauthController.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/OauthController.java
similarity index 100%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/OauthController.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/OauthController.java
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/OrderController.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/OrderController.java
similarity index 91%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/OrderController.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/OrderController.java
index a96380ce37..58430d8854 100644
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/OrderController.java
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/OrderController.java
@@ -17,8 +17,8 @@
 
 package org.apache.shenyu.examples.http.controller;
 
-import io.swagger.annotations.Api;
-import io.swagger.annotations.ApiOperation;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
 import org.apache.shenyu.client.springmvc.annotation.ShenyuSpringMvcClient;
 import org.apache.shenyu.examples.http.dto.OAuth2DTO;
 import org.apache.shenyu.examples.http.dto.OrderDTO;
@@ -38,7 +38,7 @@ import java.util.Objects;
 /**
  * TestController.
  */
-@Api(tags = "Order API", position = 2)
+@Tag(name = "Order API")
 @RestController
 @RequestMapping("/order")
 @ShenyuSpringMvcClient("/order")
@@ -50,7 +50,7 @@ public class OrderController {
      * @param orderDTO the order dto
      * @return the order dto
      */
-    @ApiOperation(value = "save", notes = "save the order.")
+    @Operation(summary = "save", description = "save the order.")
     @PostMapping("/save")
     @ShenyuSpringMvcClient("/save")
     public OrderDTO save(@RequestBody final OrderDTO orderDTO) {
@@ -64,7 +64,7 @@ public class OrderController {
      * @param id the id
      * @return the order dto
      */
-    @ApiOperation(value = "findById", notes = "find order info by id.")
+    @Operation(summary = "findById", description = "find order info by id.")
     @GetMapping("/findById")
     @ShenyuSpringMvcClient("/findById")
     public OrderDTO findById(@RequestParam("id") final String id) {
@@ -78,7 +78,7 @@ public class OrderController {
      * @param name the name
      * @return the path variable
      */
-    @ApiOperation(value = "getPathVariable", notes = "get path variable.")
+    @Operation(summary = "getPathVariable", description = "get path variable.")
     @GetMapping("/path/{id}/{name}")
     @ShenyuSpringMvcClient("/path/**")
     public OrderDTO getPathVariable(@PathVariable("id") final String id, 
@PathVariable("name") final String name) {
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/RequestController.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/RequestController.java
similarity index 89%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/RequestController.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/RequestController.java
index 22b8539a98..8ce7a9b4cf 100644
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/RequestController.java
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/RequestController.java
@@ -17,8 +17,8 @@
 
 package org.apache.shenyu.examples.http.controller;
 
-import io.swagger.annotations.Api;
-import io.swagger.annotations.ApiOperation;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
 import org.apache.shenyu.client.springmvc.annotation.ShenyuSpringMvcClient;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -35,7 +35,7 @@ import reactor.core.publisher.Mono;
 /**
  * RequestController.
  */
-@Api(tags = "RequestController", position = 1)
+@Tag(name = "RequestController")
 @RestController
 @RequestMapping("/request")
 @ShenyuSpringMvcClient("/request/**")
@@ -50,7 +50,7 @@ public class RequestController {
      * @param serverHttpRequest request
      * @return response
      */
-    @ApiOperation(value = "testRequestHeader", notes = "test request header.")
+    @Operation(summary = "testRequestHeader", description = "test request 
header.")
     @GetMapping(path = "/header")
     public Mono<String> testRequestHeader(@RequestHeader("header_key1") final 
String headerKey1,
         final ServerHttpRequest serverHttpRequest) {
@@ -65,7 +65,7 @@ public class RequestController {
      * @param serverHttpRequest request
      * @return response
      */
-    @ApiOperation(value = "testRequestParameter", notes = "test request 
parameter.")
+    @Operation(summary = "testRequestParameter", description = "test request 
parameter.")
     @PostMapping(path = "/parameter")
     public Mono<String> testRequestParameter(@RequestParam("parameter_key1") 
final String parameterKey1,
         final ServerHttpRequest serverHttpRequest) {
@@ -80,7 +80,7 @@ public class RequestController {
      * @param serverHttpRequest request
      * @return response
      */
-    @ApiOperation(value = "testRequestCookie", notes = "test request 
parameter.")
+    @Operation(summary = "testRequestCookie", description = "test request 
parameter.")
     @GetMapping(path = "/cookie")
     public Mono<String> testRequestCookie(@CookieValue("userId") final String 
userId,
         final ServerHttpRequest serverHttpRequest) {
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/ShenyuClientPathController.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/ShenyuClientPathController.java
similarity index 95%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/ShenyuClientPathController.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/ShenyuClientPathController.java
index 7fdb26112b..b6d92b5370 100644
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/ShenyuClientPathController.java
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/ShenyuClientPathController.java
@@ -17,7 +17,7 @@
 
 package org.apache.shenyu.examples.http.controller;
 
-import io.swagger.annotations.ApiOperation;
+import io.swagger.v3.oas.annotations.Operation;
 import org.apache.shenyu.client.springmvc.annotation.ShenyuSpringMvcClient;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
@@ -53,7 +53,7 @@ public class ShenyuClientPathController {
      * @param name say hello user name
      * @return result
      */
-    @ApiOperation(value = "hello", notes = "Shenyu-Gateway System said hello 
to you.")
+    @Operation(summary = "hello", description = "Shenyu-Gateway System said 
hello to you.")
     @RequestMapping("shenyu/client/hi")
     @ShenyuSpringMvcClient("shenyu/client/hi")
     public String hello(final String name) {
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/SpringMvcMappingPathController.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/SpringMvcMappingPathController.java
similarity index 85%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/SpringMvcMappingPathController.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/SpringMvcMappingPathController.java
index 15130d842e..9ddcbd7927 100644
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/SpringMvcMappingPathController.java
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/SpringMvcMappingPathController.java
@@ -17,8 +17,8 @@
 
 package org.apache.shenyu.examples.http.controller;
 
-import io.swagger.annotations.Api;
-import io.swagger.annotations.ApiOperation;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
 import org.apache.shenyu.client.springmvc.annotation.ShenyuSpringMvcClient;
 import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.RequestMapping;
@@ -29,7 +29,7 @@ import org.springframework.web.bind.annotation.RestController;
  */
 @RestController
 @ShenyuSpringMvcClient(desc = "spring annotation register")
-@Api(value = "springMvcMappingPathController")
+@Tag(name = "springMvcMappingPathController")
 public class SpringMvcMappingPathController {
 
     private static final String HELLO_SUFFIX = "I'm Shenyu-Gateway System. 
Welcome!";
@@ -40,7 +40,7 @@ public class SpringMvcMappingPathController {
      * @return result
      */
     @RequestMapping("hello")
-    @ApiOperation(value = "hello", notes = "say hello.")
+    @Operation(summary = "hello", description = "say hello.")
     public String hello() {
         return "hello! " + HELLO_SUFFIX;
     }
@@ -52,7 +52,7 @@ public class SpringMvcMappingPathController {
      * @return result
      */
     @RequestMapping("hi")
-    @ApiOperation(value = "hi", notes = "say hello to name.")
+    @Operation(summary = "hi", description = "say hello to name.")
     public String hello(final String name) {
         return "hi! " + name + "! " + HELLO_SUFFIX;
     }
@@ -64,7 +64,7 @@ public class SpringMvcMappingPathController {
      * @return result
      */
     @PostMapping("post/hi")
-    @ApiOperation(value = "postHi", notes = "post hi.")
+    @Operation(summary = "postHi", description = "post hi.")
     public String post(final String name) {
         return "[post method result]:hi! " + name + "! " + HELLO_SUFFIX;
     }
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/UploadController.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/UploadController.java
similarity index 89%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/UploadController.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/UploadController.java
index 93d1e9a2b5..ac1d9e58e1 100644
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/controller/UploadController.java
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/controller/UploadController.java
@@ -17,9 +17,8 @@
 
 package org.apache.shenyu.examples.http.controller;
 
-import io.swagger.annotations.Api;
-import io.swagger.annotations.ApiOperation;
-import java.util.stream.Collectors;
+import io.swagger.v3.oas.annotations.Operation;
+import io.swagger.v3.oas.annotations.tags.Tag;
 import org.apache.shenyu.client.springmvc.annotation.ShenyuSpringMvcClient;
 import org.springframework.http.MediaType;
 import org.springframework.http.codec.multipart.FilePart;
@@ -30,13 +29,15 @@ import 
org.springframework.web.bind.annotation.RestController;
 import reactor.core.publisher.Flux;
 import reactor.core.publisher.Mono;
 
+import java.util.stream.Collectors;
+
 /**
  * UploadController.
  */
 @RestController
 @RequestMapping("/upload")
 @ShenyuSpringMvcClient("/upload/**")
-@Api(tags = "upload api")
+@Tag(name = "upload api")
 public class UploadController {
 
     /**
@@ -46,7 +47,7 @@ public class UploadController {
      * @return response
      */
     @PostMapping(value = "/webFluxSingle", consumes = 
{MediaType.MULTIPART_FORM_DATA_VALUE, MediaType.TEXT_PLAIN_VALUE})
-    @ApiOperation(value = "webFluxSingle", notes = "upload webFluxSingle.")
+    @Operation(summary = "webFluxSingle", description = "upload 
webFluxSingle.")
     public Mono<String> webFluxSingle(@RequestPart("file") final FilePart 
file) {
         return Mono.just(file.filename());
     }
@@ -58,7 +59,7 @@ public class UploadController {
      * @return response
      */
     @PostMapping(value = "/webFluxFiles", consumes = 
{MediaType.MULTIPART_FORM_DATA_VALUE, MediaType.TEXT_PLAIN_VALUE})
-    @ApiOperation(value = "webFluxFiles", notes = "upload webFluxFiles.")
+    @Operation(summary = "webFluxFiles", description = "upload webFluxFiles.")
     public Mono<String> webFluxFiles(@RequestPart(value = "files", required = 
false) final Flux<FilePart> files) {
         return files.map(FilePart::filename).collect(Collectors.joining(","));
     }
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/dto/OAuth2DTO.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/dto/OAuth2DTO.java
similarity index 92%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/dto/OAuth2DTO.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/dto/OAuth2DTO.java
index d0b8ca8525..b4c379d9ee 100644
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/dto/OAuth2DTO.java
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/dto/OAuth2DTO.java
@@ -17,11 +17,11 @@
 
 package org.apache.shenyu.examples.http.dto;
 
-import io.swagger.annotations.ApiModelProperty;
+import io.swagger.v3.oas.annotations.media.Schema;
 
 public class OAuth2DTO {
 
-    @ApiModelProperty(value = "token", example = "afte6789try")
+    @Schema(name = "token", example = "afte6789try")
     private String token;
 
     /**
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/dto/OrderDTO.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/dto/OrderDTO.java
similarity index 88%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/dto/OrderDTO.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/dto/OrderDTO.java
index 6f10246599..03792aa2ca 100644
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/dto/OrderDTO.java
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/dto/OrderDTO.java
@@ -17,7 +17,8 @@
 
 package org.apache.shenyu.examples.http.dto;
 
-import io.swagger.annotations.ApiModelProperty;
+import io.swagger.v3.oas.annotations.media.Schema;
+
 import java.io.Serializable;
 import java.util.Date;
 import java.util.StringJoiner;
@@ -27,13 +28,13 @@ import java.util.StringJoiner;
  */
 public class OrderDTO implements Serializable {
 
-    @ApiModelProperty(value = "id", required = true, example = "100000")
+    @Schema(name = "id", requiredMode = Schema.RequiredMode.REQUIRED, example 
= "100000")
     private String id;
 
-    @ApiModelProperty(value = "name", required = true, example = "jack")
+    @Schema(name = "name", requiredMode = Schema.RequiredMode.REQUIRED, 
example = "jack")
     private String name;
 
-    @ApiModelProperty(value = "createTime", example = "2023-08-01 10:10:01")
+    @Schema(name = "createTime", example = "2023-08-01 10:10:01")
     private Date createTime;
 
     /**
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/dto/RequestDTO.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/dto/RequestDTO.java
similarity index 88%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/dto/RequestDTO.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/dto/RequestDTO.java
index ab506d8e67..df98f78892 100644
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/dto/RequestDTO.java
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/dto/RequestDTO.java
@@ -17,7 +17,8 @@
 
 package org.apache.shenyu.examples.http.dto;
 
-import io.swagger.annotations.ApiModelProperty;
+import io.swagger.v3.oas.annotations.media.Schema;
+
 import java.util.StringJoiner;
 
 /**
@@ -25,16 +26,16 @@ import java.util.StringJoiner;
  */
 public class RequestDTO {
 
-    @ApiModelProperty(value = "module", required = true, example = 
"usercenter")
+    @Schema(name = "module", requiredMode = Schema.RequiredMode.REQUIRED, 
example = "usercenter")
     private String module;
 
-    @ApiModelProperty(value = "method", required = true, example = 
"findByUserId", position = 1)
+    @Schema(name = "method", requiredMode = Schema.RequiredMode.REQUIRED, 
example = "findByUserId")
     private String method;
 
-    @ApiModelProperty(value = "content", example = "hello,shenyu")
+    @Schema(name = "content", example = "hello,shenyu")
     private String content;
 
-    @ApiModelProperty(value = "extInfo", example = "extended information", 
position = 2)
+    @Schema(name = "extInfo", example = "extended information")
     private String extInfo;
 
     public RequestDTO() {
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/dto/UserDTO.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/dto/UserDTO.java
similarity index 87%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/dto/UserDTO.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/dto/UserDTO.java
index 0a3980280e..7ea45e0c3c 100644
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/dto/UserDTO.java
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/dto/UserDTO.java
@@ -17,7 +17,9 @@
 
 package org.apache.shenyu.examples.http.dto;
 
-import io.swagger.annotations.ApiModelProperty;
+import io.swagger.v3.oas.annotations.media.ArraySchema;
+import io.swagger.v3.oas.annotations.media.Schema;
+
 import java.util.List;
 import java.util.Map;
 
@@ -26,19 +28,19 @@ import java.util.Map;
  */
 public class UserDTO {
 
-    @ApiModelProperty(value = "user id", required = true, example = "100000")
+    @Schema(name = "user id", requiredMode = Schema.RequiredMode.REQUIRED, 
example = "100000")
     private String userId;
 
-    @ApiModelProperty(value = "user name", example = "shenyu")
+    @Schema(name = "user name", example = "shenyu")
     private String userName;
 
-    @ApiModelProperty(value = "main order", example = "")
+    @Schema(name = "main order", example = "")
     private OrderDTO mainOrder;
 
-    @ApiModelProperty(value = "order list", required = true, dataType = 
"List", example = "")
+    @ArraySchema(schema = @Schema(description = "order list", requiredMode = 
Schema.RequiredMode.REQUIRED, example = ""))
     private List<OrderDTO> orderDetailList;
 
-    @ApiModelProperty(value = "order map", example = "")
+    @Schema(name = "order map", example = "")
     private Map<String, OrderDTO> orderDetailMap;
 
     /**
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/result/ResultBean.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/result/ResultBean.java
similarity index 100%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/result/ResultBean.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/result/ResultBean.java
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/result/TreeResult.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/result/TreeResult.java
similarity index 86%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/result/TreeResult.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/result/TreeResult.java
index c5f7f831ea..cc2af68e15 100755
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/result/TreeResult.java
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/result/TreeResult.java
@@ -17,20 +17,21 @@
 
 package org.apache.shenyu.examples.http.result;
 
-import io.swagger.annotations.ApiModelProperty;
+import io.swagger.v3.oas.annotations.media.Schema;
+
 import java.util.List;
 
 public class TreeResult {
-    @ApiModelProperty(value = "id", required = true, example = "123")
+    @Schema(name = "id", requiredMode = Schema.RequiredMode.REQUIRED, example 
= "123")
     private Integer id;
 
-    @ApiModelProperty(value = "name", required = true, example = "shenyu")
+    @Schema(name = "name", requiredMode = Schema.RequiredMode.REQUIRED, 
example = "shenyu")
     private String name;
 
-    @ApiModelProperty(value = "parent id")
+    @Schema(name = "parent id")
     private Integer parentId;
 
-    @ApiModelProperty(value = "children node list", example = "list")
+    @Schema(name = "children node list", example = "list")
     private List<TreeResult> children;
 
     /**
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/router/ShenyuTestHttpRouter.java
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/router/ShenyuTestHttpRouter.java
similarity index 100%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/java/org/apache/shenyu/examples/http/router/ShenyuTestHttpRouter.java
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/java/org/apache/shenyu/examples/http/router/ShenyuTestHttpRouter.java
diff --git 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/resources/application.yml
 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/resources/application.yml
similarity index 91%
rename from 
shenyu-examples/shenyu-examples-http-swagger2/src/main/resources/application.yml
rename to 
shenyu-examples/shenyu-examples-http-swagger3/src/main/resources/application.yml
index a3662a040a..f220894363 100644
--- 
a/shenyu-examples/shenyu-examples-http-swagger2/src/main/resources/application.yml
+++ 
b/shenyu-examples/shenyu-examples-http-swagger3/src/main/resources/application.yml
@@ -19,7 +19,7 @@ server:
   tomcat:
     max-http-form-post-size: 100MB
   servlet:
-    context-path: /http-swagger2 # should be the same as 
shenyu.client.http.contextPath
+    context-path: /http-swagger3 # should be the same as 
shenyu.client.http.contextPath
 
 shenyu:
   register:
@@ -31,15 +31,15 @@ shenyu:
   client:
       http:
         props:
-          contextPath: /http-swagger2
-          appName: http-swagger2
+          contextPath: /http-swagger3
+          appName: http-swagger3
 #          port: 8190
 #  discovery:
 #    enable: true
 #    protocol: http:// #https://
 #    type: zookeeper
 #    serverList: 127.0.0.1:2181
-#    registerPath: /shenyu/discovery/demo_swagger2_common
+#    registerPath: /shenyu/discovery/demo_swagger3_common
 #    props:
 #      baseSleepTimeMilliseconds: 1000
 #      maxRetries: 4
diff --git a/shenyu-examples/shenyu-examples-http/pom.xml 
b/shenyu-examples/shenyu-examples-http/pom.xml
index 8b97f444c3..bfb9ea521c 100644
--- a/shenyu-examples/shenyu-examples-http/pom.xml
+++ b/shenyu-examples/shenyu-examples-http/pom.xml
@@ -28,7 +28,7 @@
     <artifactId>shenyu-examples-http</artifactId>
 
     <properties>
-        <commons-lang3.version>3.3.2</commons-lang3.version>
+        <commons-lang3.version>3.12.0</commons-lang3.version>
         <guava.version>21.0</guava.version>
         <commons-collections4.version>4.4</commons-collections4.version>
     </properties>

Reply via email to