给所有定时任务添加入日志表的操作
This commit is contained in:
parent
90cca38ff9
commit
f0c20320d4
@ -4,7 +4,6 @@ import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
|
||||
|
||||
import org.quartz.Job;
|
||||
import org.quartz.JobExecutionContext;
|
||||
import org.quartz.JobExecutionException;
|
||||
@ -15,6 +14,7 @@ import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.amarsoft.are.log.Log;
|
||||
import com.base.util.QuartzUtil;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
import com.tenwa.reckon.util.DateUtil;
|
||||
|
||||
@ -61,7 +61,9 @@ public class AdjustStartDateYear implements Job {
|
||||
|
||||
logger.info("起租日年调息完成");
|
||||
tx.commit();
|
||||
QuartzUtil.insertLog("com.tenwa.reckon.adjustInterest.AdjustStartDateYear", "success", "成功");
|
||||
} catch (Exception e) {
|
||||
QuartzUtil.insertLog("com.tenwa.reckon.adjustInterest.AdjustStartDateYear", "success", "失败");
|
||||
try {
|
||||
if(tx!=null){
|
||||
tx.rollback();
|
||||
|
||||
@ -9,6 +9,7 @@ import org.quartz.JobExecutionException;
|
||||
import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.base.util.QuartzUtil;
|
||||
|
||||
public class HelloJob implements Job {
|
||||
|
||||
@ -21,8 +22,9 @@ public class HelloJob implements Job {
|
||||
BizObject bo = bom.newObject();
|
||||
bom.saveObject(bo);
|
||||
//SendMessageUtil.sendMessageByHttpClient("13764771906", "²âÊÔ¶ÌÐÅ£¡");
|
||||
QuartzUtil.insertLog("com.amarsoft.app.util.HelloJob", "success", "成功");
|
||||
} catch (Exception e) {
|
||||
// TODO Auto-generated catch block
|
||||
QuartzUtil.insertLog("com.amarsoft.app.util.HelloJob", "success", "失败");
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
@ -15,6 +15,7 @@ import com.amarsoft.are.jbo.BizObject;
|
||||
import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.base.util.QuartzUtil;
|
||||
|
||||
public class BaseMessageJob implements Job {
|
||||
|
||||
@ -25,7 +26,9 @@ public class BaseMessageJob implements Job {
|
||||
tx= JBOFactory.createJBOTransaction();
|
||||
this.executeMessage(tx);
|
||||
tx.commit();
|
||||
QuartzUtil.insertLog("com.tenwa.comm.message.controller.BaseMessageJob", "success", "成功");
|
||||
} catch (Exception e) {
|
||||
QuartzUtil.insertLog("com.tenwa.comm.message.controller.BaseMessageJob", "success", "失败");
|
||||
try {
|
||||
if(tx!=null){
|
||||
tx.rollback();
|
||||
|
||||
@ -21,6 +21,7 @@ import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.amarsoft.are.util.StringFunction;
|
||||
import com.base.util.QuartzUtil;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
/**
|
||||
* 对业务审批结束后超过指定时间未合同制作的业务合同进行
|
||||
@ -38,7 +39,10 @@ public class BusinessCancelJob implements Job {
|
||||
tx= JBOFactory.createJBOTransaction();
|
||||
this.executeMessage(tx);
|
||||
tx.commit();
|
||||
QuartzUtil.insertLog("com.tenwa.comm.message.controller.BusinessCancelJob", "success", "成功");
|
||||
} catch (Exception e) {
|
||||
QuartzUtil.insertLog("com.tenwa.comm.message.controller.BusinessCancelJob", "error", "失败");
|
||||
|
||||
try {
|
||||
if(tx!=null){
|
||||
tx.rollback();
|
||||
|
||||
@ -15,6 +15,7 @@ import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.base.util.QuartzUtil;
|
||||
import com.tenwa.comm.util.date.DateAssistant;
|
||||
import com.tenwa.flow.comm.handler.flowmanage.OverdueProjectCache;
|
||||
|
||||
@ -55,7 +56,9 @@ public class AutoFiveGradeClassification implements Job {
|
||||
}
|
||||
}
|
||||
tx.commit();
|
||||
QuartzUtil.insertLog("com.tenwa.lease.app.quartzmession.AutoFiveGradeClassification", "success", "成功");
|
||||
} catch (Exception e) {
|
||||
QuartzUtil.insertLog("com.tenwa.lease.app.quartzmession.AutoFiveGradeClassification", "success", "失败");
|
||||
try {
|
||||
if(tx!=null){
|
||||
tx.rollback();
|
||||
|
||||
@ -19,6 +19,7 @@ import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.base.util.QuartzUtil;
|
||||
import com.ibm.sslight.tools.mainExit;
|
||||
import com.tenwa.comm.util.date.DateAssistant;
|
||||
import com.tenwa.comm.util.jboutil.DataOperatorUtil;
|
||||
@ -29,8 +30,9 @@ public class CreateSendMessageListAction implements Job{
|
||||
public void execute(JobExecutionContext arg0) throws JobExecutionException{
|
||||
try {
|
||||
this.getDebitTipsList();
|
||||
QuartzUtil.insertLog("com.tenwa.lease.app.quartzmession.CreateSendMessageListAction", "success", "成功");
|
||||
} catch (Exception e) {
|
||||
// TODO Auto-generated catch block
|
||||
QuartzUtil.insertLog("com.tenwa.lease.app.quartzmession.CreateSendMessageListAction", "error", "失败");
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
|
||||
@ -3,16 +3,22 @@ package com.tenwa.lease.app.quartzmession;
|
||||
import org.quartz.Job;
|
||||
import org.quartz.JobExecutionContext;
|
||||
import org.quartz.JobExecutionException;
|
||||
|
||||
import com.base.util.QuartzUtil;
|
||||
import com.tenwa.voucher.CreateVoucherProcess.CreateVoucherMonthSettlement;
|
||||
|
||||
public class CreateVoucherMonthSettlementMission implements Job {
|
||||
|
||||
@Override
|
||||
public void execute(JobExecutionContext arg0) throws JobExecutionException {
|
||||
CreateVoucherMonthSettlement vouchermanage=new CreateVoucherMonthSettlement();
|
||||
vouchermanage.CreateVoucher("PZ2018071200000017");//月结手续费
|
||||
vouchermanage.CreateVoucher("PZ2018071200000016");//月结利息
|
||||
vouchermanage.CreateVoucher("PZ2018072100000055");//日结税金
|
||||
try{
|
||||
CreateVoucherMonthSettlement vouchermanage=new CreateVoucherMonthSettlement();
|
||||
vouchermanage.CreateVoucher("PZ2018071200000017");//月结手续费
|
||||
vouchermanage.CreateVoucher("PZ2018071200000016");//月结利息
|
||||
vouchermanage.CreateVoucher("PZ2018072100000055");//日结税金
|
||||
QuartzUtil.insertLog("com.tenwa.lease.app.quartzmession.CreateVoucherMonthSettlementMission", "success", "成功");
|
||||
} catch (Exception e) {
|
||||
QuartzUtil.insertLog("com.tenwa.lease.app.quartzmession.CreateVoucherMonthSettlementMission", "error", "失败");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -4,6 +4,7 @@ import org.quartz.Job;
|
||||
import org.quartz.JobExecutionContext;
|
||||
import org.quartz.JobExecutionException;
|
||||
|
||||
import com.base.util.QuartzUtil;
|
||||
import com.tenwa.voucher.CreateVoucherProcess.CreateVoucherInsuranceSettlement;
|
||||
import com.tenwa.voucher.CreateVoucherProcess.CreateVoucherMonthSettlement;
|
||||
import com.tenwa.voucher.CreateVoucherProcess.CreateVoucherRentIncome;
|
||||
@ -12,13 +13,19 @@ public class CreateVoucherRentIncomeMission implements Job {
|
||||
|
||||
@Override
|
||||
public void execute(JobExecutionContext arg0) throws JobExecutionException {
|
||||
CreateVoucherRentIncome cvri=new CreateVoucherRentIncome();
|
||||
cvri.CreateVoucher("PZ2018072100000024");//收到租金
|
||||
cvri.CreateVoucher("PZ2018072100000025");//收到逾期利息
|
||||
|
||||
CreateVoucherInsuranceSettlement cvis=new CreateVoucherInsuranceSettlement();
|
||||
cvis.CreateVoucher("PZ2018072100000029");//收到理赔保险费
|
||||
cvis.CreateVoucher("PZ2018072100000054");//收到理赔保险费
|
||||
try{
|
||||
CreateVoucherRentIncome cvri=new CreateVoucherRentIncome();
|
||||
cvri.CreateVoucher("PZ2018072100000024");//收到租金
|
||||
cvri.CreateVoucher("PZ2018072100000025");//收到逾期利息
|
||||
|
||||
CreateVoucherInsuranceSettlement cvis=new CreateVoucherInsuranceSettlement();
|
||||
cvis.CreateVoucher("PZ2018072100000029");//收到理赔保险费
|
||||
cvis.CreateVoucher("PZ2018072100000054");//收到理赔保险费
|
||||
|
||||
QuartzUtil.insertLog("com.tenwa.comm.message.controller.BusinessCancelJob", "success", "成功");
|
||||
} catch (Exception e) {
|
||||
QuartzUtil.insertLog("com.tenwa.comm.message.controller.BusinessCancelJob", "error", "失败");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -22,6 +22,7 @@ import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.base.util.QuartzUtil;
|
||||
import com.tenwa.lease.util.VehicleAppraisementUtil;
|
||||
|
||||
public class QueryCommercialVehicleModeListAction implements Job{
|
||||
@ -181,7 +182,10 @@ public class QueryCommercialVehicleModeListAction implements Job{
|
||||
.setParameter("MODELVERSIONTIME",StringUtil.nullToString(versionListObject.get("model_version_time"),""))
|
||||
.setParameter("INITIALVERSION",StringUtil.nullToString(versionListObject.get("from_version"),"")).executeUpdate();
|
||||
}
|
||||
QuartzUtil.insertLog("com.tenwa.lease.app.quartzmession.QueryCommercialVehicleModeListAction", "success", "成功");
|
||||
} catch (Exception e) {
|
||||
QuartzUtil.insertLog("com.tenwa.lease.app.quartzmession.QueryCommercialVehicleModeListAction", "error", "失败");
|
||||
|
||||
try {
|
||||
if(null != tx){
|
||||
tx.rollback();
|
||||
|
||||
@ -23,6 +23,7 @@ import com.amarsoft.are.jbo.BizObjectManager;
|
||||
import com.amarsoft.are.jbo.JBOException;
|
||||
import com.amarsoft.are.jbo.JBOFactory;
|
||||
import com.amarsoft.are.jbo.JBOTransaction;
|
||||
import com.base.util.QuartzUtil;
|
||||
import com.tenwa.lease.util.VehicleAppraisementUtil;
|
||||
|
||||
public class QueryPassengerVehicleModeListAction implements Job{
|
||||
@ -214,7 +215,9 @@ public class QueryPassengerVehicleModeListAction implements Job{
|
||||
.setParameter("INITIALVERSION",StringUtil.nullToString(map.get("InitialVersion"),"")).executeUpdate();
|
||||
}
|
||||
System.out.println("乘用车车型库更新完毕!");
|
||||
} catch (Exception e) {
|
||||
QuartzUtil.insertLog("com.tenwa.lease.app.quartzmession.QueryPassengerVehicleModeListAction", "success", "成功");
|
||||
} catch (Exception e) {
|
||||
QuartzUtil.insertLog("com.tenwa.lease.app.quartzmession.QueryPassengerVehicleModeListAction", "error", "失败");
|
||||
try {
|
||||
if(null != tx){
|
||||
tx.rollback();
|
||||
|
||||
@ -24,6 +24,7 @@ import com.amarsoft.awe.util.ASResultSet;
|
||||
import com.amarsoft.awe.util.SqlObject;
|
||||
import com.amarsoft.awe.util.Transaction;
|
||||
import com.amarsoft.dict.als.cache.CacheLoaderFactory;
|
||||
import com.base.util.QuartzUtil;
|
||||
import com.tenwa.leasing.service.voucher.CreateVoucherService;
|
||||
import com.tenwa.leasing.serviceImpl.voucher.CreateVoucherServiceImpl;
|
||||
import com.tenwa.reckon.constant.Scale;
|
||||
@ -101,7 +102,9 @@ public class SplitInts implements Job{
|
||||
}
|
||||
rs.close();
|
||||
Sqlca.commit();
|
||||
}catch (Exception e) {
|
||||
QuartzUtil.insertLog("com.tenwa.lease.app.quartzmession.SplitInts", "success", "成功");
|
||||
} catch (Exception e) {
|
||||
QuartzUtil.insertLog("com.tenwa.lease.app.quartzmession.SplitInts", "success", "失败");
|
||||
logger.error(e.getMessage());
|
||||
e.printStackTrace();
|
||||
}finally{
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user