记得上下班打卡 | git大法好,push需谨慎

Commit e3e1a389 authored by 张国柄's avatar 张国柄

fix:mq.sql.consumer;

parent 52f00ce0
......@@ -62,13 +62,13 @@ public class BaseDao implements IBaseDao {
break;
}
if (!o.isEmpty()) {
int[] ints = jdbcTemplate.batchUpdate(sql.get(i), o);
jdbcTemplate.batchUpdate(sql.get(i), o);
for (int c : ints) {
if (c <= 0) {
throw new LiquidnetServiceException("NON.SQL", sql.get(i));
}
}
// for (int c : ints) {
// if (c <= 0) {
// throw new LiquidnetServiceException("NON.SQL", sql.get(i));
// }
// }
}
i++;
}
......@@ -79,11 +79,11 @@ public class BaseDao implements IBaseDao {
TransactionTemplate tt = new TransactionTemplate(transactionManager);
return tt.execute(callback);
} catch (Exception ex) {
if (ex instanceof LiquidnetServiceException) {
log.error("###Error.Code:{} - {}", ((LiquidnetServiceException) ex).getCode(), ex.getMessage());
} else {
log.error("###Error.Sqls:{}\nParameters:{}", JsonUtils.toJson(sql), JsonUtils.toJson(values), ex);
}
// if (ex instanceof LiquidnetServiceException) {
// log.error("###Error.Code:{} - {}", ((LiquidnetServiceException) ex).getCode(), ex.getMessage());
// } else {
log.error("###Error.Sqls:{}\nParameters:{},Ex:{}", JsonUtils.toJson(sql), JsonUtils.toJson(values), ex.getMessage());
// }
return false;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment