修复问题
This commit is contained in:
parent
598dffcc5d
commit
85d774d0e4
@ -132,8 +132,7 @@ public class SydApi4Database implements SydApi {
|
||||
if (null == this.hsms || this.hsms.length < 1) {
|
||||
throw new SydApiException(-1);
|
||||
}
|
||||
@CheckForNull
|
||||
SydApiException le = null;
|
||||
SydApiException le = new SydApiException(0);
|
||||
|
||||
updateLastUseTime();
|
||||
for (SydApi4j api : this.hsms) {
|
||||
@ -191,8 +190,8 @@ public class SydApi4Database implements SydApi {
|
||||
log.debug("Util.hexString2Bytes方法返回值:{}", Arrays.toString(procData));
|
||||
|
||||
}
|
||||
@CheckForNull
|
||||
SydApiException le = null;
|
||||
|
||||
SydApiException le = new SydApiException(0);
|
||||
updateLastUseTime();
|
||||
for (SydApi4j api : this.hsms) {
|
||||
if (null == api) {
|
||||
@ -236,6 +235,7 @@ public class SydApi4Database implements SydApi {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
throw le;
|
||||
}
|
||||
|
||||
@ -254,8 +254,7 @@ public class SydApi4Database implements SydApi {
|
||||
|
||||
updateLastUseTime();
|
||||
String keyIndex = String.format("%08d", iKeyIndex);
|
||||
@CheckForNull
|
||||
SydApiException le = null;
|
||||
SydApiException le = new SydApiException(0);
|
||||
for (SydApi4j api : this.hsms) {
|
||||
if (null == api) {
|
||||
continue;
|
||||
@ -335,8 +334,8 @@ public class SydApi4Database implements SydApi {
|
||||
for (int i = 0; i < iKeyIndex.length; i++) {
|
||||
keys[i] = "SK" + SYMUtil.genPrivateKeyMark("000000", "00A", String.format("%08d", iKeyIndex[i]));
|
||||
}
|
||||
@CheckForNull
|
||||
SydApiException le = null;
|
||||
|
||||
SydApiException le = new SydApiException(0);
|
||||
for (SydApi4j api : this.hsms) {
|
||||
if (null == api) {
|
||||
continue;
|
||||
@ -394,8 +393,8 @@ public class SydApi4Database implements SydApi {
|
||||
}
|
||||
updateLastUseTime();
|
||||
String keyIndex = String.format("%08d", iKeyIndex);
|
||||
@CheckForNull
|
||||
SydApiException le = null;
|
||||
|
||||
SydApiException le = new SydApiException(0);
|
||||
for (SydApi4j api : this.hsms) {
|
||||
if (null == api) {
|
||||
continue;
|
||||
@ -478,8 +477,7 @@ public class SydApi4Database implements SydApi {
|
||||
for (int i = 0; i < iKeyIndex.length; i++) {
|
||||
keys[i] = "SK" + SYMUtil.genPrivateKeyMark("000000", "00A", String.format("%08d", iKeyIndex[i]));
|
||||
}
|
||||
@CheckForNull
|
||||
SydApiException le = null;
|
||||
SydApiException le = new SydApiException(0);
|
||||
for (SydApi4j api : this.hsms) {
|
||||
if (null == api) {
|
||||
continue;
|
||||
@ -546,8 +544,8 @@ public class SydApi4Database implements SydApi {
|
||||
for (int i = 0; i < iKeyIndex.length; i++) {
|
||||
keys[i] = "SK" + SYMUtil.genPrivateKeyMark("000000", "00A", String.format("%08d", iKeyIndex[i]));
|
||||
}
|
||||
@CheckForNull
|
||||
SydApiException le = null;
|
||||
|
||||
SydApiException le = new SydApiException(0);
|
||||
for (SydApi4j api : this.hsms) {
|
||||
if (null == api) {
|
||||
continue;
|
||||
@ -617,8 +615,7 @@ public class SydApi4Database implements SydApi {
|
||||
if (Consts.PkgNumAll != iPkgNum && Consts.PkgNumHead != iPkgNum) {
|
||||
iv = pcProcData.getBytes();
|
||||
}
|
||||
@CheckForNull
|
||||
SydApiException le = null;
|
||||
SydApiException le = new SydApiException(0);
|
||||
updateLastUseTime();
|
||||
for (SydApi4j api : this.hsms) {
|
||||
if (null == api) {
|
||||
@ -716,8 +713,8 @@ public class SydApi4Database implements SydApi {
|
||||
}
|
||||
String keyIndex = "SK" + SYMUtil.genPrivateKeyMark("000000", "00A", String.format("%08d", iKeyIndex));
|
||||
log.debug("\"SK\" + SYMUtil.genPrivateKeyMark方法返回值:{}", keyIndex);
|
||||
@CheckForNull
|
||||
SydApiException le = null;
|
||||
|
||||
SydApiException le = new SydApiException(0);
|
||||
updateLastUseTime();
|
||||
for (SydApi4j api : this.hsms) {
|
||||
if (null == api) {
|
||||
|
||||
@ -35,8 +35,8 @@ public class LogFactory {
|
||||
// 日志目录
|
||||
public static String pcLogPath = "./sydapi-logs/";
|
||||
|
||||
// 日期格式
|
||||
public static SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd");
|
||||
// // 日期格式
|
||||
// private SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd");
|
||||
|
||||
private LogFactory() {
|
||||
}
|
||||
@ -59,10 +59,10 @@ public class LogFactory {
|
||||
// "/logs/test/" + jobID + "/syncshows-job-" + jobID + ".log.gz",
|
||||
// "true", jobID, null, null, null, tp, null, layout, null,
|
||||
// null, null, null, config);
|
||||
|
||||
SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd");
|
||||
// 日志打印方式——输出为文件
|
||||
Appender appender = FileAppender.createAppender(
|
||||
String.format( pcLogPath +"sydapi_"+getToday() + ".log"),
|
||||
String.format( pcLogPath +"sydapi_"+ format.format(new Date()) + ".log"),
|
||||
"true", "false",
|
||||
logName, null, "true", "true", null, layout, null, null, null, config);
|
||||
|
||||
@ -88,10 +88,6 @@ public class LogFactory {
|
||||
}
|
||||
|
||||
|
||||
public static String getToday(){
|
||||
return format.format( new Date());
|
||||
}
|
||||
|
||||
/**
|
||||
* 创建 Logger
|
||||
* @return Logger
|
||||
|
||||
Loading…
Reference in New Issue
Block a user