powerJob报错以及解决办法集锦

1. 本地测试成功新建任务并运行成功,但是部署到服务器时新建任务只要 “参数”有中文就无法报错

        前台报错信息:

powerJob报错以及解决办法集锦_第1张图片

ERROR:JpaSystemException: could not execute statement; nested exception is org.hibernate.exception.GenericJDBCException: could not execute statement

控制台报错信息:

SQLException: Incorrect string value: '\xB2\xE2\xCA\xD4' for column 'job_params' at row 1

 解决办法: 在数据源配置中的url添加    &clobCharacterEncoding=utf-8    即可解决

spring.datasource.core.jdbc-url=jdbc:mysql://localhost:3306/powerjob-daily?useUnicode=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&clobCharacterEncoding=utf-8

2. 启动server直接启动worker报错:

PowerJobException: app(powerjob-agent-test) is not registered! Please register the app in oms-console first.

解决办法:先去页面注册应用,再根据这个注册的应用去配置worker,之后再启动worker

3. 使用邮箱作为报警功能,然而发送邮箱时报错

  WARN 9952 --- [    AlarmPool-0] t.p.s.c.a.i.MailAlarmService             : [MailAlarmService] send mail failed, reason is Mail server connection failed; nested exception is javax.mail.MessagingException: Could not convert socket to TLS;
  nested exception is:
	javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target. Failed messages: javax.mail.MessagingException: Could not convert socket to TLS;
  nested exception is:
	javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target

---------------暂未解决

你可能感兴趣的:(定时任务,powerjob,定时任务调度,错误解决)