Commit 69b9d63b authored by data爬虫-冯 军凯's avatar data爬虫-冯 军凯

transactionLog 数据清洗 main类修改12345678

parent 224949ac
......@@ -32,7 +32,7 @@ public class CleanningTransactionLogMain {
ArrayList<TransactionLog> transactionLogs = new ArrayList<>();
String sql = "INSERT INTO `call_record` (`request_url`, `transaction_id`, `uuid`, `url_type`, `code`, `created_at`, `updated_at`) VALUES (?,?,?,?,?,?,?)";
func.forEachRemaining(item -> {
System.out.println("单条数据清洗");
// System.out.println("单条数据清洗");
try {
String[] split = item.split("\t");
TransactionLog transactionLog = new TransactionLog();
......@@ -46,8 +46,8 @@ public class CleanningTransactionLogMain {
transactionLog.setUpdated_at(timestamp);
if (transactionLogs.size() != 0 && transactionLogs.size() % 200 == 0) {
JdbcExecuters.prepareBatchUpdateExecuteTransactionid(sql, transactionLogs);
System.out.println("执行sql集合: "+transactionLogs.size());
JdbcExecuters.prepareBatchUpdateExecuteTransactionid(sql, transactionLogs);
transactionLogs.clear();
}
} catch (Exception e) {
......
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