新增示例auth、user、gateway、client
diff --git a/samples/user/pom.xml b/samples/user/pom.xml
new file mode 100644
index 0000000..bcd22ec
--- /dev/null
+++ b/samples/user/pom.xml
@@ -0,0 +1,101 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>com.supwisdom.leaveschool</groupId>
+ <artifactId>samples-parent</artifactId>
+ <version>0.0.1-SNAPSHOT</version>
+ </parent>
+
+ <groupId>com.supwisdom.leaveschool</groupId>
+ <artifactId>sample-user</artifactId>
+ <packaging>jar</packaging>
+
+ <dependencies>
+
+ <dependency>
+ <groupId>org.springframework.boot</groupId>
+ <artifactId>spring-boot-starter</artifactId>
+ </dependency>
+
+ <!-- 微服务 健康监控 -->
+ <!-- <dependency>
+ <groupId>org.springframework.boot</groupId>
+ <artifactId>spring-boot-starter-actuator</artifactId>
+ </dependency> -->
+
+ <dependency>
+ <groupId>org.springframework.boot</groupId>
+ <artifactId>spring-boot-starter-web</artifactId>
+ </dependency>
+
+
+ <dependency>
+ <groupId>com.supwisdom.infras</groupId>
+ <artifactId>infras-mvc</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>com.supwisdom.infras</groupId>
+ <artifactId>infras-object-mapper</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>com.supwisdom.infras</groupId>
+ <artifactId>infras-i18n</artifactId>
+ </dependency>
+
+ <!--
+ <dependency>
+ <groupId>com.supwisdom.infras</groupId>
+ <artifactId>infras-lang</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>com.supwisdom.infras</groupId>
+ <artifactId>infras-pinyin</artifactId>
+ </dependency>
+ -->
+
+ <!-- Test things -->
+ <dependency>
+ <groupId>org.testng</groupId>
+ <artifactId>testng</artifactId>
+ <scope>test</scope>
+ </dependency>
+
+ <dependency>
+ <groupId>org.springframework.boot</groupId>
+ <artifactId>spring-boot-starter-test</artifactId>
+ <scope>test</scope>
+ </dependency>
+
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-compiler-plugin</artifactId>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-failsafe-plugin</artifactId>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-javadoc-plugin</artifactId>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-release-plugin</artifactId>
+ </plugin>
+ <plugin>
+ <groupId>org.jacoco</groupId>
+ <artifactId>jacoco-maven-plugin</artifactId>
+ </plugin>
+ </plugins>
+ </build>
+
+</project>
diff --git a/samples/user/src/main/java/com/supwisdom/leaveschool/user/UserApplication.java b/samples/user/src/main/java/com/supwisdom/leaveschool/user/UserApplication.java
new file mode 100644
index 0000000..e6ee620
--- /dev/null
+++ b/samples/user/src/main/java/com/supwisdom/leaveschool/user/UserApplication.java
@@ -0,0 +1,13 @@
+package com.supwisdom.leaveschool.user;
+
+import org.springframework.boot.SpringApplication;
+import org.springframework.boot.autoconfigure.SpringBootApplication;
+
+@SpringBootApplication
+public class UserApplication {
+
+ public static void main(String[] args) {
+ SpringApplication.run(UserApplication.class, args);
+ }
+
+}
diff --git a/samples/user/src/main/java/com/supwisdom/leaveschool/user/controller/api/admin/ApiAdminUserController.java b/samples/user/src/main/java/com/supwisdom/leaveschool/user/controller/api/admin/ApiAdminUserController.java
new file mode 100644
index 0000000..f8adf36
--- /dev/null
+++ b/samples/user/src/main/java/com/supwisdom/leaveschool/user/controller/api/admin/ApiAdminUserController.java
@@ -0,0 +1,31 @@
+package com.supwisdom.leaveschool.user.controller.api.admin;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import org.springframework.util.MimeTypeUtils;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.PathVariable;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+@RestController
+@RequestMapping("/api/admin/users")
+public class ApiAdminUserController {
+
+
+ /**
+ * curl -i -s -X GET -H 'Accept:application/json' 'http://localhost:10010/api/admin/users/greeting/abc'
+ *
+ * @param name
+ * @return
+ */
+ @GetMapping(path = "/greeting/{name}", produces = MimeTypeUtils.APPLICATION_JSON_VALUE)
+ public Map<String, Object> greeting(@PathVariable("name") String name) {
+ System.out.println(name);
+ Map<String, Object> result = new HashMap<>();
+ result.put("message", "Good " + name);
+ return result;
+ }
+
+}
diff --git a/samples/user/src/main/resources/application.yml b/samples/user/src/main/resources/application.yml
new file mode 100755
index 0000000..f8a64c2
--- /dev/null
+++ b/samples/user/src/main/resources/application.yml
@@ -0,0 +1,14 @@
+server:
+ port: 10010
+
+## logging
+logging:
+ level:
+ root: INFO
+ org.springframework.web: INFO
+ com.supwisdom.infras.security: DEBUG
+ com.supwisdom.leaveschool: DEBUG
+
+spring:
+ application:
+ name: sample-user