Skip to content
Permalink
Browse files

0004097: remove sym_data_event.router_id

  • Loading branch information...
erilong committed Oct 2, 2019
1 parent 1848bbd commit 085b7b17df1ed1daade398210f6ebccb113815e9
@@ -73,7 +73,7 @@
Types.VARCHAR, Types.VARCHAR, Types.TIMESTAMP };

private final static String INSERT_DATA_EVENT_SQL = "insert into sym_data_event " +
"(data_id, batch_id, router_id, create_time) values (?, ?, ?, current_timestamp)";
"(data_id, batch_id, create_time) values (?, ?, current_timestamp)";

protected ISymmetricEngine engine;

@@ -262,7 +262,7 @@ protected void queueEvents(ChannelRouterContext context, ISqlTransaction transac
batchByNode.put(nodeId, batch);
}
batch.incrementTableCount(tableName);
insertDataEvent(transaction, tableInfo, batch.getBatchId(), dataId);
insertDataEvent(transaction, batch.getBatchId(), dataId);
context.getDataIds().add(dataId);
}
insertBatchMs += (System.currentTimeMillis() - ts);
@@ -307,9 +307,9 @@ protected long insertData(ISqlTransaction transaction, TableInfo tableInfo, Stri
return dataId;
}

protected void insertDataEvent(ISqlTransaction transaction, TableInfo tableInfo, long batchId, long dataId) {
transaction.prepareAndExecute(INSERT_DATA_EVENT_SQL, new Object[] { dataId, batchId, tableInfo.getRouterInfo().getRouter().getRouterId() },
new int[] { Types.NUMERIC, Types.NUMERIC, Types.VARCHAR });
protected void insertDataEvent(ISqlTransaction transaction, long batchId, long dataId) {
transaction.prepareAndExecute(INSERT_DATA_EVENT_SQL, new Object[] { dataId, batchId },
new int[] { Types.NUMERIC, Types.NUMERIC });
}

public void setSymmetricEngine(ISymmetricEngine engine) {

0 comments on commit 085b7b1

Please sign in to comment.
You can’t perform that action at this time.