|
@@ -3,6 +3,7 @@ package cn.kdan.pdf.tech.core.service.impl;
|
|
|
import cn.kdan.pdf.tech.core.model.*;
|
|
|
import cn.kdan.pdf.tech.core.service.*;
|
|
|
import cn.kdan.pdf.tech.core.utils.KeyFileParseUtils;
|
|
|
+import exception.BackendRuntimeException;
|
|
|
import lombok.RequiredArgsConstructor;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
import org.springframework.stereotype.Service;
|
|
@@ -39,7 +40,10 @@ public class VppKeyFileServiceImpl implements VppKeyFileService {
|
|
|
fileContent = KeyFileParseUtils.parseKeyFile(inputStream, updateOrInit);
|
|
|
} catch (Exception e) {
|
|
|
log.error("解析key文件失败, "+ e.getMessage(), e);
|
|
|
- throw new RuntimeException("The key file signature is invalid.");
|
|
|
+ if (e instanceof BackendRuntimeException) {
|
|
|
+ throw (BackendRuntimeException) e;
|
|
|
+ }
|
|
|
+ throw new RuntimeException("Verily Failed, please try again");
|
|
|
}
|
|
|
if (!updateOrInit) {
|
|
|
VppCompany vppCompany = fileContent.getVppCompany();
|