java秒杀系统方案优化1-1 项目框架搭建
前言
本项目是一个java学习课程,记录一下学习过程,参考如下:
课程地址:https://coding.imooc.com/class/168.html
项目地址: https://github.com/qiurunze123/miaosha
Spring Boot环境搭建
首先用idea创建一个springboot项目,可以参考文档,了解官方的使用介绍
Quick start: https://spring.io/projects/spring-boot
Reference: https://docs.spring.io/spring-boot/docs/1.5.8.RELEASE/reference/htmlsingle/
或者使用idea直接创建:

填好GroupId,ArtifactId, 一路next 即可创建一个new project.

项目创建好后,修改pom文件依赖
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
然后创建一个demo

启动类
@SpringBootApplication public class MainApplication { public static void main(String[] args) { SpringApplication.run(MainApplication.class, args); } }
启动项目成功

最后我们打开浏览器访问一下本地路径 http://localhost:8080/demo/ 即可看到页面上的输出内容hello world.

后记
很久就注册博客园账号了,但一直没有来写博客(每次都是三天打鱼两天晒网哈哈~),在这里记录一下自己学习经历,希望可以坚持下去~fighting!
本文来自博客园,作者:明知道,转载请注明原文链接:https://www.cnblogs.com/luckey33/p/16058892.html

浙公网安备 33010602011771号