博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
Spring Boot入门
阅读量:4659 次
发布时间:2019-06-09

本文共 2273 字,大约阅读时间需要 7 分钟。

Spring Boot 入门


 MicroServices

  微服务:架构风格(服务微化),一个应用应该是一组小型服务,可以通过HTTP的方式进行互通,每一个功能单元最最终都是一个可以独立替换和独立升级的软件单元;

 HelloWord

1 
2
4
4.0.0
5
6
com.ahabest.springboot
7
HelloWord
8
0.0.1-SNAPSHOT
9
HelloWord
10
HelloWord
11
12
13
1.8
14
15
16
17
18
org.springframework.boot
19
spring-boot-starter-parent
20
2.1.6.RELEASE
21
22
23
24
25
26
27
org.springframework.boot
28
spring-boot-starter-web
29
30
31
32
org.springframework.boot
33
spring-boot-starter-test
34
test
35
36 37
38
39
40
41
42
org.springframework.boot
43
spring-boot-maven-plugin
44
45
46
47
1 package com.ahabest.springboot.controller; 2 import org.springframework.stereotype.Controller; 3 import org.springframework.web.bind.annotation.RequestMapping; 4 import org.springframework.web.bind.annotation.ResponseBody; 5 @Controller 6 public class HelloWord { 7     @ResponseBody 8     @RequestMapping("/hello") 9     public String hello() {10         return "Hello Word!";11     }12 }
1 package com.ahabest.springboot;2 import org.springframework.boot.SpringApplication;3 import org.springframework.boot.autoconfigure.SpringBootApplication;4 @SpringBootApplication5 public class HelloWordApplication {6     public static void main(String[] args) {7         SpringApplication.run(HelloWordApplication.class, args);8     }9 }

 

 

转载于:https://www.cnblogs.com/Aha-Best/p/11205366.html

你可能感兴趣的文章
web渗透测试基本步骤
查看>>
使用Struts2标签遍历集合
查看>>
angular.isUndefined()
查看>>
第一次软件工程作业(改进版)
查看>>
网络流24题-飞行员配对方案问题
查看>>
引入css的四种方式
查看>>
iOS开发UI篇—transframe属性(形变)
查看>>
3月7日 ArrayList集合
查看>>
jsp 环境配置记录
查看>>
Python03
查看>>
LOJ 2537 「PKUWC2018」Minimax
查看>>
使用java中replaceAll方法替换字符串中的反斜杠
查看>>
Some configure
查看>>
流量调整和限流技术 【转载】
查看>>
1 线性空间
查看>>
VS不显示最近打开的项目
查看>>
DP(动态规划)
查看>>
chkconfig
查看>>
2.抽取代码(BaseActivity)
查看>>
夏天过去了, 姥爷推荐几套来自smashingmagzine的超棒秋天主题壁纸
查看>>