Browse Source

🔥 init

master
Boom 3 weeks ago
parent
commit
b31082f5b5
  1. 1
      .gitignore
  2. 2
      src/main/java/top/naccl/dwz/controller/IndexController.java
  3. 10
      src/main/resources/application-dev.properties
  4. 20
      src/main/resources/application-prod.properties

1
.gitignore vendored

@ -33,4 +33,3 @@ build/
.vscode/
log
application-prod.properties

2
src/main/java/top/naccl/dwz/controller/IndexController.java

@ -36,7 +36,7 @@ public class IndexController {
return "index";
}
@AccessLimit(seconds = 10, maxCount = 1, msg = "10秒内只能生成一次短链接")
// @AccessLimit(seconds = 10, maxCount = 1, msg = "10秒内只能生成一次短链接")
@PostMapping("/generate")
@ResponseBody
public R generateShortURL(@RequestBody GenerateCmd cmd) {

10
src/main/resources/application-dev.properties

@ -1,15 +1,15 @@
server.port=8060
server.host=http://localhost:8060/
server.host=http://localhost1:8060/
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
spring.datasource.url=jdbc:mysql://localhost:3306/dwz?useUnicode=true&characterEncoding=utf8&useSSL=false&serverTimezone=GMT%2B8
spring.datasource.url=jdbc:mysql://192.168.10.200:3306/dwz?useUnicode=true&characterEncoding=utf8&useSSL=false&serverTimezone=GMT%2B8
spring.datasource.username=root
spring.datasource.password=root
spring.redis.host=192.168.17.132
spring.redis.password=123456
spring.redis.host=192.168.10.200
spring.redis.password=
spring.redis.port=6379
spring.redis.database=1
spring.redis.database=15
spring.redis.timeout=10000ms
mybatis.mapper-locations=classpath:mapper/*.xml

20
src/main/resources/application-prod.properties

@ -0,0 +1,20 @@
server.port=8060
server.host=http://123bs.top/
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
spring.datasource.url=jdbc:mysql://127.0.0.1:3306/dwz?useUnicode=true&characterEncoding=utf8&useSSL=false&serverTimezone=GMT%2B8
spring.datasource.username=root
spring.datasource.password=4730da9b
spring.redis.host=127.0.0.1
spring.redis.password=guozinengliang
spring.redis.port=6379
spring.redis.database=15
spring.redis.timeout=10000ms
mybatis.mapper-locations=classpath:mapper/*.xml
mybatis.configuration.map-underscore-to-camel-case=true
logging.level.root=info
logging.level.top.naccl.dwz=debug
logging.file.name=./log/dwz
Loading…
Cancel
Save