修改异常
parent
b25d7589c2
commit
00c5ed651e
|
@ -1,5 +1,7 @@
|
||||||
package xyz.zhouxy.plusone.sms;
|
package xyz.zhouxy.plusone.sms;
|
||||||
|
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
import com.tencentcloudapi.common.Credential;
|
import com.tencentcloudapi.common.Credential;
|
||||||
import com.tencentcloudapi.common.exception.TencentCloudSDKException;
|
import com.tencentcloudapi.common.exception.TencentCloudSDKException;
|
||||||
import com.tencentcloudapi.common.profile.ClientProfile;
|
import com.tencentcloudapi.common.profile.ClientProfile;
|
||||||
|
@ -8,11 +10,8 @@ import com.tencentcloudapi.sms.v20210111.SmsClient;
|
||||||
import com.tencentcloudapi.sms.v20210111.models.SendSmsRequest;
|
import com.tencentcloudapi.sms.v20210111.models.SendSmsRequest;
|
||||||
import com.tencentcloudapi.sms.v20210111.models.SendSmsResponse;
|
import com.tencentcloudapi.sms.v20210111.models.SendSmsResponse;
|
||||||
|
|
||||||
import org.springframework.stereotype.Service;
|
|
||||||
|
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import xyz.zhouxy.plusone.constant.ErrorCodeConsts;
|
import xyz.zhouxy.plusone.exception.SysException;
|
||||||
import xyz.zhouxy.plusone.exception.BizException;
|
|
||||||
import xyz.zhouxy.plusone.sms.SmsProperties.SmsCredentialProperties;
|
import xyz.zhouxy.plusone.sms.SmsProperties.SmsCredentialProperties;
|
||||||
import xyz.zhouxy.plusone.sms.SmsProperties.SmsHttpProperties;
|
import xyz.zhouxy.plusone.sms.SmsProperties.SmsHttpProperties;
|
||||||
import xyz.zhouxy.plusone.sms.SmsProperties.SmsProxyProperties;
|
import xyz.zhouxy.plusone.sms.SmsProperties.SmsProxyProperties;
|
||||||
|
@ -69,7 +68,7 @@ public class TencentSmsServiceImpl implements SmsService {
|
||||||
|
|
||||||
} catch (TencentCloudSDKException e) {
|
} catch (TencentCloudSDKException e) {
|
||||||
log.error(e.getMessage(), e);
|
log.error(e.getMessage(), e);
|
||||||
throw new BizException(ErrorCodeConsts.DEFAULT_ERROR_CODE, e);
|
throw SysException.of(e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue