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

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

fix:mq.sql.consumer;

parent 52f00ce0
...@@ -62,13 +62,13 @@ public class BaseDao implements IBaseDao { ...@@ -62,13 +62,13 @@ public class BaseDao implements IBaseDao {
break; break;
} }
if (!o.isEmpty()) { if (!o.isEmpty()) {
int[] ints = jdbcTemplate.batchUpdate(sql.get(i), o); jdbcTemplate.batchUpdate(sql.get(i), o);
for (int c : ints) { // for (int c : ints) {
if (c <= 0) { // if (c <= 0) {
throw new LiquidnetServiceException("NON.SQL", sql.get(i)); // throw new LiquidnetServiceException("NON.SQL", sql.get(i));
} // }
} // }
} }
i++; i++;
} }
...@@ -79,11 +79,11 @@ public class BaseDao implements IBaseDao { ...@@ -79,11 +79,11 @@ public class BaseDao implements IBaseDao {
TransactionTemplate tt = new TransactionTemplate(transactionManager); TransactionTemplate tt = new TransactionTemplate(transactionManager);
return tt.execute(callback); return tt.execute(callback);
} catch (Exception ex) { } catch (Exception ex) {
if (ex instanceof LiquidnetServiceException) { // if (ex instanceof LiquidnetServiceException) {
log.error("###Error.Code:{} - {}", ((LiquidnetServiceException) ex).getCode(), ex.getMessage()); // log.error("###Error.Code:{} - {}", ((LiquidnetServiceException) ex).getCode(), ex.getMessage());
} else { // } else {
log.error("###Error.Sqls:{}\nParameters:{}", JsonUtils.toJson(sql), JsonUtils.toJson(values), ex); log.error("###Error.Sqls:{}\nParameters:{},Ex:{}", JsonUtils.toJson(sql), JsonUtils.toJson(values), ex.getMessage());
} // }
return false; 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