Skip to content

Commit

Permalink
添加quickstart例子
Browse files Browse the repository at this point in the history
  • Loading branch information
rhwayfun committed Sep 10, 2017
1 parent f3320b3 commit 4093f1c
Show file tree
Hide file tree
Showing 44 changed files with 459 additions and 2,324 deletions.
661 changes: 368 additions & 293 deletions pom.xml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion spring-boot-aspect/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>springboot-aspect</artifactId>
<artifactId>spring-boot-aspect</artifactId>


</project>
2 changes: 1 addition & 1 deletion spring-boot-cache-caffeine/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>springboot-cache-caffeine</artifactId>
<artifactId>spring-boot-cache-caffeine</artifactId>


</project>
2 changes: 1 addition & 1 deletion spring-boot-disconf/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>springboot-disconf</artifactId>
<artifactId>spring-boot-disconf</artifactId>


</project>
2 changes: 1 addition & 1 deletion spring-boot-dubbo/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>springboot-dubbo</artifactId>
<artifactId>spring-boot-dubbo</artifactId>


</project>
2 changes: 1 addition & 1 deletion spring-boot-kafka/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>springboot-kafka</artifactId>
<artifactId>spring-boot-kafka</artifactId>


</project>
2 changes: 1 addition & 1 deletion spring-boot-mockito/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>springboot-mockito</artifactId>
<artifactId>spring-boot-mockito</artifactId>


</project>
15 changes: 15 additions & 0 deletions spring-boot-mongodb/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<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">
<parent>
<artifactId>spring-boot-learning-examples</artifactId>
<groupId>com.rhwayfun</groupId>
<version>0.0.1-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>spring-boot-mongodb</artifactId>


</project>
2 changes: 1 addition & 1 deletion spring-boot-mybatis/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>springboot-mybatis</artifactId>
<artifactId>spring-boot-mybatis</artifactId>


</project>
44 changes: 33 additions & 11 deletions spring-boot-quickstart/pom.xml
Original file line number Diff line number Diff line change
@@ -1,15 +1,37 @@
<?xml version="1.0" encoding="UTF-8"?>
<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">
<parent>
<artifactId>spring-boot-learning-examples</artifactId>
<groupId>com.rhwayfun</groupId>
<version>0.0.1-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<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>

<artifactId>springboot-quickstart</artifactId>
<parent>
<artifactId>spring-boot-learning-examples</artifactId>
<groupId>com.rhwayfun</groupId>
<version>0.0.1-SNAPSHOT</version>
</parent>

<artifactId>spring-boot-quickstart</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>

</project>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>

<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
<optional>true</optional> <!-- 这个需要为 true 热部署才有效 -->
</dependency>
</dependencies>

<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
</plugins>
</build>
</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
package com.rhwayfun.springboot.quickstart;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

@SpringBootApplication
public class Application {

public static void main(String[] args) {
SpringApplication.run(Application.class, args);
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
package com.rhwayfun.springboot.quickstart.web;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.Calendar;
import java.util.Date;

/**
* Created by chubin on 2017/9/10.
*/
@RestController
public class DemoController {

@GetMapping("/now")
public Date now(){
return Calendar.getInstance().getTime();
}
}
2 changes: 1 addition & 1 deletion spring-boot-redis/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>springboot-redis</artifactId>
<artifactId>spring-boot-redis</artifactId>


</project>
2 changes: 1 addition & 1 deletion spring-boot-retry/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>springboot-retry</artifactId>
<artifactId>spring-boot-retry</artifactId>


</project>
2 changes: 1 addition & 1 deletion spring-boot-rocketmq/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>springboot-rocketmq</artifactId>
<artifactId>spring-boot-rocketmq</artifactId>


</project>
2 changes: 1 addition & 1 deletion spring-boot-security/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>springboot-security</artifactId>
<artifactId>spring-boot-security</artifactId>


</project>
2 changes: 1 addition & 1 deletion spring-boot-task/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>springboot-task</artifactId>
<artifactId>spring-boot-task</artifactId>


</project>
7 changes: 0 additions & 7 deletions src/main/resources/banners.txt

This file was deleted.

21 changes: 0 additions & 21 deletions src/main/resources/config/application.properties

This file was deleted.

33 changes: 0 additions & 33 deletions src/main/resources/disconf.properties

This file was deleted.

70 changes: 0 additions & 70 deletions src/main/resources/log4j2.xml

This file was deleted.

Loading

0 comments on commit 4093f1c

Please sign in to comment.