Skip to content

Commit

Permalink
fix:long或者Long初始赋值时,必须使用大写的L,不能是小写的l,小写容易跟数字1混淆,造成误解。
Browse files Browse the repository at this point in the history
  • Loading branch information
TomYule committed Jun 22, 2022
1 parent dce3ada commit 8eb8aef
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,8 @@ public void init() {
try {
String[] values = entry.getValue().replace(" ", ",").split(",");
long maxSize = Long.parseLong(values[0].trim());
long maxIdle = values.length > 1 ? Long.parseLong(values[1].trim()) : 0l;
long maxLive = values.length > 2 ? Long.parseLong(values[2].trim()) : 0l;
long maxIdle = values.length > 1 ? Long.parseLong(values[1].trim()) : 0L;
long maxLive = values.length > 2 ? Long.parseLong(values[2].trim()) : 0L;
CacheStrategy cacheStrategy = new CacheStrategy(split[1].trim(), maxSize, maxIdle, maxLive);
cacheStrategyMap.put(cacheStrategy.getName(), cacheStrategy);
log.debugf("load CacheStrategy %s", cacheStrategy);
Expand Down

0 comments on commit 8eb8aef

Please sign in to comment.