马府强
2 years ago
12 changed files with 0 additions and 35 deletions
Binary file not shown.
@ -1,19 +0,0 @@ |
|||||
spring.application.name=tlog-logback-feign-consumer |
|
||||
server.port=3111 |
|
||||
#eureka.client.service-url.defaultZone=http://127.0.0.1:1111/eureka/ |
|
||||
|
|
||||
tlog.pattern=[$currIp][$spanId][$traceId] |
|
||||
#spring.cloud.nacos.discovery.server-addr=127.0.0.1:8848 |
|
||||
|
|
||||
http.connectTimeOutMillis=8000 |
|
||||
http.readTimeOutMillis=8000 |
|
||||
|
|
||||
spring.task.execution.pool.core-size=5 |
|
||||
spring.task.execution.pool.max-size=50 |
|
||||
spring.task.execution.pool.queue-capacity=200 |
|
||||
spring.task.execution.thread-name-prefix=woniugege- |
|
||||
|
|
||||
|
|
||||
spring.redis.host=192.168.56.10 |
|
||||
spring.redis.password=123456 |
|
||||
spring.redis.port=6379 |
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -1,16 +0,0 @@ |
|||||
--获取KEY |
|
||||
local key = KEYS[1] |
|
||||
|
|
||||
local limit = tonumber(ARGV[1]) |
|
||||
|
|
||||
local curentLimit = tonumber(redis.call('get', key) or "0") |
|
||||
|
|
||||
if curentLimit + 1 > limit |
|
||||
then return 0 |
|
||||
else |
|
||||
-- 自增长 1 |
|
||||
redis.call('INCRBY', key, 1) |
|
||||
-- 设置过期时间 |
|
||||
redis.call('EXPIRE', key, ARGV[2]) |
|
||||
return curentLimit + 1 |
|
||||
end |
|
Loading…
Reference in new issue