From eeb86aaf2f73a02600195ce2637dde6caf858a88 Mon Sep 17 00:00:00 2001 From: T100738 <1821349743@qq.com> Date: 星期二, 16 四月 2024 22:30:34 +0800 Subject: [PATCH] commit --- product-server-data-center/src/main/java/com/product/data/center/utils/CustomLock.java | 57 ++ product-server-data-center/src/main/java/com/product/data/center/service/DataExtractService.java | 2 product-server-data-center/src/main/java/com/product/data/center/service/DataSyncService.java | 1138 +++++++++++++++++++++++++++-------------------------- product-server-data-center/src/main/java/com/product/data/center/service/DataArchivingQueue.java | 2 product-server-web/resources/LicenseKey.dat | 2 5 files changed, 632 insertions(+), 569 deletions(-) diff --git a/product-server-data-center/src/main/java/com/product/data/center/service/DataArchivingQueue.java b/product-server-data-center/src/main/java/com/product/data/center/service/DataArchivingQueue.java index a2f6daa..235fa07 100644 --- a/product-server-data-center/src/main/java/com/product/data/center/service/DataArchivingQueue.java +++ b/product-server-data-center/src/main/java/com/product/data/center/service/DataArchivingQueue.java @@ -202,7 +202,7 @@ ExecutorService executorService = queryThreadMap.get(tableName); if (executorService != null) { if (!executorService.isShutdown()) { - executorService.shutdown(); + executorService.shutdownNow(); } queryThreadMap.remove(tableName); } diff --git a/product-server-data-center/src/main/java/com/product/data/center/service/DataExtractService.java b/product-server-data-center/src/main/java/com/product/data/center/service/DataExtractService.java index 25252be..31c710e 100644 --- a/product-server-data-center/src/main/java/com/product/data/center/service/DataExtractService.java +++ b/product-server-data-center/src/main/java/com/product/data/center/service/DataExtractService.java @@ -533,7 +533,7 @@ maybeUpdate.getData().sort((o1, o2) -> DateUtil.compare(o1.getDate(extractUpdateTimeField), o2.getDate(extractUpdateTimeField))); - batchResultEntity = targetNewDao.updateBatch(maybeUpdate, updateFilterEntity, false); + batchResultEntity = targetNewDao.updateBatch(maybeUpdate, updateFilterEntity, true); WriteExtractUtil.append("鏇存柊鎻愬彇杩囨护鍚庢暟鎹細" + extractTargetTable + ",闇�瑕佹洿鏂扮殑鏉℃暟锛�" + maybeUpdate.getRows() + ",鑰楁椂锛�" + tempTestTimer2.intervalMs()); targetNewDao.closeConnection(); diff --git a/product-server-data-center/src/main/java/com/product/data/center/service/DataSyncService.java b/product-server-data-center/src/main/java/com/product/data/center/service/DataSyncService.java index a9fb406..b1c208e 100644 --- a/product-server-data-center/src/main/java/com/product/data/center/service/DataSyncService.java +++ b/product-server-data-center/src/main/java/com/product/data/center/service/DataSyncService.java @@ -43,21 +43,21 @@ */ @Component public class DataSyncService { - @Autowired - private BaseDao baseDao; - @Autowired - private JournalManagerService journalManagerService; + @Autowired + private BaseDao baseDao; + @Autowired + private JournalManagerService journalManagerService; - public static final String cryptPublicKey = "MFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAJlJtWr3FRT-T2HzJk0Jhxbt-Qm2fupACtwpqeLnz9iXfXGWdSvkc4OUpmM4pNGOa1fBTB_RNu5f1-dm74QEEV0CAwEAAQ"; - // public static final String cryptPrivateKey = "MIIBVQIBADANBgkqhkiG9w0BAQEFAASCAT8wggE7AgEAAkEAmUm1avcVFP5PYfMmTQmHFu35CbZ-6kAK3Cmp4ufP2Jd9cZZ1K-Rzg5SmYzik0Y5rV8FMH9E27l_X52bvhAQRXQIDAQABAkBHyE6ekqpatGS0N8s91DJguHwg4kc4p1julMwrp-abREwrfW1RiwN4YIhwmMHBw_971RCtN55XJPVb7shx7Bh5AiEAy_pCJaRgeHUlZfQxOu7eBoswbimm4xks2Q7_4HqoT28CIQDAYelqjDNgeigKwVUrgOmKBSqldDxqXXixVDBebMSF8wIhAILviYiKRNbuM-yHXRa8gM9oh9UfbZ536Z8IDt61PdeHAiBjT2f2F4_CAu0-uBSmU3K7S_V62akCY2QVbldVtyIv3wIhAKB4lbrlUL3OC7DDtRaYNaCQdkYqDVV2eRZgQdzLnQTo"; + public static final String cryptPublicKey = "MFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAJlJtWr3FRT-T2HzJk0Jhxbt-Qm2fupACtwpqeLnz9iXfXGWdSvkc4OUpmM4pNGOa1fBTB_RNu5f1-dm74QEEV0CAwEAAQ"; + // public static final String cryptPrivateKey = "MIIBVQIBADANBgkqhkiG9w0BAQEFAASCAT8wggE7AgEAAkEAmUm1avcVFP5PYfMmTQmHFu35CbZ-6kAK3Cmp4ufP2Jd9cZZ1K-Rzg5SmYzik0Y5rV8FMH9E27l_X52bvhAQRXQIDAQABAkBHyE6ekqpatGS0N8s91DJguHwg4kc4p1julMwrp-abREwrfW1RiwN4YIhwmMHBw_971RCtN55XJPVb7shx7Bh5AiEAy_pCJaRgeHUlZfQxOu7eBoswbimm4xks2Q7_4HqoT28CIQDAYelqjDNgeigKwVUrgOmKBSqldDxqXXixVDBebMSF8wIhAILviYiKRNbuM-yHXRa8gM9oh9UfbZ536Z8IDt61PdeHAiBjT2f2F4_CAu0-uBSmU3K7S_V62akCY2QVbldVtyIv3wIhAKB4lbrlUL3OC7DDtRaYNaCQdkYqDVV2eRZgQdzLnQTo"; // public static final String signPublicKey = "MFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAJkgrw6CzG6odwYfbN8Yp77vjfs3ufjaR8S3xLQiZBmsMFv5T9Mkt4EkDpKZRx9BoAOf_a0zyhq8lbk78kDcKFUCAwEAAQ"; - public static final String signPrivateKey = "MIIBUwIBADANBgkqhkiG9w0BAQEFAASCAT0wggE5AgEAAkEAmSCvDoLMbqh3Bh9s3xinvu-N-ze5-NpHxLfEtCJkGawwW_lP0yS3gSQOkplHH0GgA5_9rTPKGryVuTvyQNwoVQIDAQABAkAWJTnr-VKjdk2wXv8ZzLEF1hNMj6SfrsHOW11hR8_-PkVSZmCzxlBNaREtixV538GdWZhjMbmlbvApa4c9TZaBAiEA1t8X6SyHAVKZRfGeheAWA0iyJRw9RZoW0RIH0qUoKXECIQC2cBX8jUDZdtZzGVQhUnnmmXVH4Tu_kaXjHFO1DwNbJQIgA7EVkhYHw8gNhhweoyI0fp3zIZwYmWeKWNE8fSwFQqECIEQGtVwPe4_a7QnL9v_Z1hRzQjUEOhgrgfSWWmwX5gN1AiAJsxMXJN81YsKlacXJZXofJMhGHheJ3xnF1UkntC96HQ"; + public static final String signPrivateKey = "MIIBUwIBADANBgkqhkiG9w0BAQEFAASCAT0wggE5AgEAAkEAmSCvDoLMbqh3Bh9s3xinvu-N-ze5-NpHxLfEtCJkGawwW_lP0yS3gSQOkplHH0GgA5_9rTPKGryVuTvyQNwoVQIDAQABAkAWJTnr-VKjdk2wXv8ZzLEF1hNMj6SfrsHOW11hR8_-PkVSZmCzxlBNaREtixV538GdWZhjMbmlbvApa4c9TZaBAiEA1t8X6SyHAVKZRfGeheAWA0iyJRw9RZoW0RIH0qUoKXECIQC2cBX8jUDZdtZzGVQhUnnmmXVH4Tu_kaXjHFO1DwNbJQIgA7EVkhYHw8gNhhweoyI0fp3zIZwYmWeKWNE8fSwFQqECIEQGtVwPe4_a7QnL9v_Z1hRzQjUEOhgrgfSWWmwX5gN1AiAJsxMXJN81YsKlacXJZXofJMhGHheJ3xnF1UkntC96HQ"; - private static CustomLock customLock = new CustomLock(); + private static CustomLock customLock = new CustomLock(); - public static void test() throws NoSuchAlgorithmException, InvalidKeySpecException { - JSONArray jsonArray = new JSONArray(); + public static void test() throws NoSuchAlgorithmException, InvalidKeySpecException { + JSONArray jsonArray = new JSONArray(); // JSONObject obj1 = new JSONObject(); // obj1.put(CmnConst.TABLE_NAME, "TT_T_CO_EMP_DESC"); @@ -65,601 +65,607 @@ // obj1.put(CmnConst.UPDATE_TIME, "updated_utc_datetime"); // jsonArray.add(obj1); - JSONObject obj2 = new JSONObject(); - obj2.put(CmnConst.TABLE_NAME, "TT_T_CO_EMPANDEMPLOYKIND"); - obj2.put(CmnConst.UNIQUE_NAME, "EMPANDEMPLOYKIND_ID"); - jsonArray.add(obj2); + JSONObject obj2 = new JSONObject(); + obj2.put(CmnConst.TABLE_NAME, "TT_T_CO_EMPANDEMPLOYKIND"); + obj2.put(CmnConst.UNIQUE_NAME, "EMPANDEMPLOYKIND_ID"); + jsonArray.add(obj2); - String signedData = RSAUtil.privateEncrypt(jsonArray.toString(), RSAUtil.getPrivateKey(signPrivateKey)); - System.out.println(signedData.equals("UADjiSAUii_PYdXTx-Jud6nY6cmsrQlsNfWK3vnIsuxg8rlugO-GUe0PetQxtvGuPrUR8hBcBrJUEsamI8rXyVp7WYdlBRsZmraglklb1orLspNSPgQzgSPHP6jhnW5OlTYMbdu_aU1r328jIfjwCk_hjHhN20ed7JW1OUXyQEQ")); - String encodedData = RSAUtil.publicEncrypt(signedData, RSAUtil.getPublicKey(cryptPublicKey)); - System.out.println(encodedData); + String signedData = RSAUtil.privateEncrypt(jsonArray.toString(), RSAUtil.getPrivateKey(signPrivateKey)); + System.out.println(signedData.equals("UADjiSAUii_PYdXTx-Jud6nY6cmsrQlsNfWK3vnIsuxg8rlugO-GUe0PetQxtvGuPrUR8hBcBrJUEsamI8rXyVp7WYdlBRsZmraglklb1orLspNSPgQzgSPHP6jhnW5OlTYMbdu_aU1r328jIfjwCk_hjHhN20ed7JW1OUXyQEQ")); + String encodedData = RSAUtil.publicEncrypt(signedData, RSAUtil.getPublicKey(cryptPublicKey)); + System.out.println(encodedData); // dataSync(encodedData); - } + } - public void runTimeTask(String uuid) { - FieldSetEntity fse = baseDao.getFieldSetEntity("product_sys_data_sync_mes_sub", uuid, false); - if (FieldSetEntity.isEmpty(fse)) { - return; - } - JSONObject objects = BaseUtil.fieldSetEntityToJson(fse); - markProcess(this.dataSync(objects, true)); - } + public void runTimeTask(String uuid) { + FieldSetEntity fse = baseDao.getFieldSetEntity("product_sys_data_sync_mes_sub", uuid, false); + if (FieldSetEntity.isEmpty(fse)) { + return; + } + JSONObject objects = BaseUtil.fieldSetEntityToJson(fse); + markProcess(this.dataSync(objects, true)); + } - /** - * 閲嶆柊澶勭悊 - * - * @param logUUID - */ - public void reDeal(String logUUID) { - asynRedeal(logUUID); - } + /** + * 閲嶆柊澶勭悊 + * + * @param logUUID + */ + public void reDeal(String logUUID) { + asynRedeal(logUUID); + } - @Async - public void asynRedeal(String logUUID) { - FieldSetEntity logFse = baseDao.getFieldSetEntity(CmnConst.PRODUCT_SYS_DATA_CENTER_LOG, logUUID, false); - if (FieldSetEntity.isEmpty(logFse) || !"3".equals(logFse.getString(CmnConst.TYPE))) { - return; - } - String otherInfo = logFse.getString(CmnConst.OTHER_INFO); - SyncDataLogEntity syncDataLogEntity = JSONObject.toJavaObject(JSON.parseObject(otherInfo), SyncDataLogEntity.class); - Object syncInfo = syncDataLogEntity.getSyncInfo(); - if (syncInfo instanceof String && syncDataLogEntity.getErrorType() == 1) { - //瑙e瘑閿欒绫诲瀷 搴熷純鏃ュ織閫昏緫浠g爜鏈疄鐜� - dataSync((String) syncInfo); - } else if (syncDataLogEntity.getErrorType() == 2 || syncDataLogEntity.getErrorType() == 3) { - //杩愯杩囩▼涓骇鐢熺殑閿欒 - markProcess(dataSync((JSONObject) syncInfo)); - } + @Async + public void asynRedeal(String logUUID) { + FieldSetEntity logFse = baseDao.getFieldSetEntity(CmnConst.PRODUCT_SYS_DATA_CENTER_LOG, logUUID, false); + if (FieldSetEntity.isEmpty(logFse) || !"3".equals(logFse.getString(CmnConst.TYPE))) { + return; + } + String otherInfo = logFse.getString(CmnConst.OTHER_INFO); + SyncDataLogEntity syncDataLogEntity = JSONObject.toJavaObject(JSON.parseObject(otherInfo), SyncDataLogEntity.class); + Object syncInfo = syncDataLogEntity.getSyncInfo(); + if (syncInfo instanceof String && syncDataLogEntity.getErrorType() == 1) { + //瑙e瘑閿欒绫诲瀷 搴熷純鏃ュ織閫昏緫浠g爜鏈疄鐜� + dataSync((String) syncInfo); + } else if (syncDataLogEntity.getErrorType() == 2 || syncDataLogEntity.getErrorType() == 3) { + //杩愯杩囩▼涓骇鐢熺殑閿欒 + markProcess(dataSync((JSONObject) syncInfo)); + } - } + } - /** - * 鏍囪鏃ュ織 - * - * @param lists - */ - private void markProcess(List<JournalEntity> lists) { - if (lists == null || lists.isEmpty()) { - return; - } - long count = lists.stream().filter(item -> item.getResult() != 1).count(); - try { - SyncDataLogEntity syncDataLogEntity = JSONObject.toJavaObject(JSON.parseObject(lists.get(0).getOther_info()), SyncDataLogEntity.class); - JSONObject syncInfo = (JSONObject) syncDataLogEntity.getSyncInfo(); - if (syncInfo != null && !StringUtils.isEmpty(syncInfo.getString(CmnConst.TABLE_NAME))) { - String tableName = syncInfo.getString(CmnConst.TABLE_NAME); - baseDao.executeUpdate("UPDATE product_sys_data_center_log set deal_flag=?,deal_result=?,updated_utc_datetime=?" + - " where type=3 and UPPER(other_info) like concat('%',UPPER(?),'%')" - , new Object[]{1, count == lists.size() ? 1 : 0, new Date(), "\"table_name\":\"" + tableName + "\""}); - } - } catch (Exception e) { - e.printStackTrace(); - SpringMVCContextHolder.getSystemLogger().error(e); - } - } + /** + * 鏍囪鏃ュ織 + * + * @param lists + */ + private void markProcess(List<JournalEntity> lists) { + if (lists == null || lists.isEmpty()) { + return; + } + long count = lists.stream().filter(item -> item.getResult() != 1).count(); + try { + SyncDataLogEntity syncDataLogEntity = JSONObject.toJavaObject(JSON.parseObject(lists.get(0).getOther_info()), SyncDataLogEntity.class); + JSONObject syncInfo = (JSONObject) syncDataLogEntity.getSyncInfo(); + if (syncInfo != null && !StringUtils.isEmpty(syncInfo.getString(CmnConst.TABLE_NAME))) { + String tableName = syncInfo.getString(CmnConst.TABLE_NAME); + baseDao.executeUpdate("UPDATE product_sys_data_center_log set deal_flag=?,deal_result=?,updated_utc_datetime=?" + + " where type=3 and config_uuid in (select uuid from product_sys_data_sync_mes_sub where UPPER(table_name)=UPPER(?)) and (result=0 or deal_result=0)" + , new Object[]{1, count == lists.size() ? 1 : 0, new Date(), tableName}); + } + } catch (Exception e) { + e.printStackTrace(); + SpringMVCContextHolder.getSystemLogger().error(e); + } + } - public List<JournalEntity> dataSync(JSONObject jsonArray) { - return dataSync(jsonArray, false); - } + public List<JournalEntity> dataSync(JSONObject jsonArray) { + return dataSync(jsonArray, false); + } - public List<JournalEntity> dataSync(JSONObject jsonObject, boolean timeTaskTrigger) { - List<JournalEntity> journalEntities = new ArrayList<>(); + public List<JournalEntity> dataSync(JSONObject jsonObject, boolean timeTaskTrigger) { + List<JournalEntity> journalEntities = new ArrayList<>(); - SyncDataLogEntity<JSONObject> syncDataLogEntity = new SyncDataLogEntity(); - syncDataLogEntity.setSyncInfo(jsonObject); - syncDataLogEntity.setTimeTaskTrigger(timeTaskTrigger); - Calendar c1 = Calendar.getInstance(); - boolean lockStatus = false; - String lockKey = null; - Dao sourceDao = null; - try { - String tableName = jsonObject.getString(CmnConst.TABLE_NAME); - String[] uniqueSignFieldName = (StringUtils.isEmpty(jsonObject.getString(CmnConst.UNIQUE_NAME)) ? "" : jsonObject.getString(CmnConst.UNIQUE_NAME)).split(","); - if (ArrayUtil.isEmpty(uniqueSignFieldName)) { - throw new BaseException(ErrorCode.NO_TABLE_OR_UNIQUE_SIGN); - } - // 鑾峰彇鍚屾閰嶇疆淇℃伅 - DataTableEntity syncConfigDte = baseDao.listTable(CmnConst.PRODUCT_SYS_DATA_SYNC_MES); - if (DataTableEntity.isEmpty(syncConfigDte)) { - throw new BaseException(ErrorCode.SYNC_GET_CONFIG_FAIL); - } - FieldSetEntity syncConfigFse = syncConfigDte.getFieldSetEntity(0); - if (FieldSetEntity.isEmpty(syncConfigFse)) { - throw new BaseException(ErrorCode.SYNC_GET_CONFIG_FAIL); - } - lockKey = jsonObject.getString(CmnConst.TABLE_NAME); - if (!customLock.tryLock(lockKey)) { - syncDataLogEntity.setOtherInfo("璇ヨ〃鏁版嵁鍚屾宸叉湁浠诲姟鍦ㄦ墽琛�,璺宠繃鏈鎵ц锛�"); - journalEntities.add(getLogRecord(syncDataLogEntity, null, tableName, - null, null, null, 0L)); - return null; - } - lockStatus = true; - if (jsonObject == null || jsonObject.isEmpty()) { - throw new BaseException(ErrorCode.SYNC_GET_PARAM_FAIL); - } + SyncDataLogEntity<JSONObject> syncDataLogEntity = new SyncDataLogEntity(); + syncDataLogEntity.setSyncInfo(jsonObject); + syncDataLogEntity.setTimeTaskTrigger(timeTaskTrigger); + Calendar c1 = Calendar.getInstance(); + boolean lockStatus = false; + String lockKey = null; + Dao sourceDao = null; + try { + try { + String tableName = jsonObject.getString(CmnConst.TABLE_NAME); + String[] uniqueSignFieldName = (StringUtils.isEmpty(jsonObject.getString(CmnConst.UNIQUE_NAME)) ? "" : jsonObject.getString(CmnConst.UNIQUE_NAME)).split(","); + if (ArrayUtil.isEmpty(uniqueSignFieldName)) { + throw new BaseException(ErrorCode.NO_TABLE_OR_UNIQUE_SIGN); + } + // 鑾峰彇鍚屾閰嶇疆淇℃伅 + DataTableEntity syncConfigDte = baseDao.listTable(CmnConst.PRODUCT_SYS_DATA_SYNC_MES); + if (DataTableEntity.isEmpty(syncConfigDte)) { + throw new BaseException(ErrorCode.SYNC_GET_CONFIG_FAIL); + } + FieldSetEntity syncConfigFse = syncConfigDte.getFieldSetEntity(0); + if (FieldSetEntity.isEmpty(syncConfigFse)) { + throw new BaseException(ErrorCode.SYNC_GET_CONFIG_FAIL); + } + lockKey = jsonObject.getString(CmnConst.TABLE_NAME); + if (!customLock.tryLock(lockKey, 120)) { + syncDataLogEntity.setOtherInfo("璇ヨ〃鏁版嵁鍚屾宸叉湁浠诲姟鍦ㄦ墽琛�,璺宠繃鏈鎵ц锛�"); + journalEntities.add(getLogRecord(syncDataLogEntity, null, tableName, + null, null, null, 0L)); + return null; + } + lockStatus = true; + if (jsonObject == null || jsonObject.isEmpty()) { + throw new BaseException(ErrorCode.SYNC_GET_PARAM_FAIL); + } - // 鑾峰彇鏉ユ簮杩炴帴鍜岀洰鏍囪繛鎺� - if (StringUtils.isEmpty(syncConfigFse.getString(CmnConst.DATA_SOURCE))) { - throw new BaseException(ErrorCode.SYNC_GET_DATA_SOURCE_FAIL); - } - FieldSetEntity sourceDataSourceFse = baseDao.getFieldSetEntity(CmnConst.PRODUCT_SYS_DATA_SYNC_MANAGER, syncConfigFse.getString(CmnConst.DATA_SOURCE), false); - DataBaseEntity sourceDbe = new DataBaseEntity(sourceDataSourceFse); - sourceDao = sourceDbe.getDao(); - if (StringUtils.isEmpty(syncConfigFse.getString(CmnConst.TARGET_DATA_SOURCE))) { - throw new BaseException(ErrorCode.SYNC_GET_TARGET_DATA_SOURCE_FAIL); - } - DataTableEntity targetDataSourceDte = baseDao.listTable(CmnConst.PRODUCT_SYS_DATA_SYNC_MANAGER, BaseUtil.buildQuestionMarkFilter("uuid", syncConfigFse.getString(CmnConst.TARGET_DATA_SOURCE).split(","), true)); - List<Dao> targetDaoList = Lists.newArrayList(); - FieldSetEntity targetDataSourceFse; - for (int i = 0; i < targetDataSourceDte.getRows(); i++) { - targetDataSourceFse = targetDataSourceDte.getFieldSetEntity(i); - targetDaoList.add(new DataBaseEntity(targetDataSourceFse).getDao()); - } + // 鑾峰彇鏉ユ簮杩炴帴鍜岀洰鏍囪繛鎺� + if (StringUtils.isEmpty(syncConfigFse.getString(CmnConst.DATA_SOURCE))) { + throw new BaseException(ErrorCode.SYNC_GET_DATA_SOURCE_FAIL); + } + FieldSetEntity sourceDataSourceFse = baseDao.getFieldSetEntity(CmnConst.PRODUCT_SYS_DATA_SYNC_MANAGER, syncConfigFse.getString(CmnConst.DATA_SOURCE), false); + DataBaseEntity sourceDbe = new DataBaseEntity(sourceDataSourceFse); + sourceDao = sourceDbe.getDao(); + if (StringUtils.isEmpty(syncConfigFse.getString(CmnConst.TARGET_DATA_SOURCE))) { + throw new BaseException(ErrorCode.SYNC_GET_TARGET_DATA_SOURCE_FAIL); + } + DataTableEntity targetDataSourceDte = baseDao.listTable(CmnConst.PRODUCT_SYS_DATA_SYNC_MANAGER, BaseUtil.buildQuestionMarkFilter("uuid", syncConfigFse.getString(CmnConst.TARGET_DATA_SOURCE).split(","), true)); + List<Dao> targetDaoList = Lists.newArrayList(); + FieldSetEntity targetDataSourceFse; + for (int i = 0; i < targetDataSourceDte.getRows(); i++) { + targetDataSourceFse = targetDataSourceDte.getFieldSetEntity(i); + targetDaoList.add(new DataBaseEntity(targetDataSourceFse).getDao()); + } - // 鏁版嵁澶勭悊 - String updateTimeFieldName; - DataTableEntity sourceDataDte; - FieldSetEntity sourceDataFse; - DataTableEntity targetDataDte = null; - List<String> sourceUniqueKeyList;// 鏉ユ簮鏁版嵁鐨勫敮涓�閿泦鍚� - List<String> targetUniqueKeyList;// 鐩爣鏁版嵁鐨勫敮涓�閿泦鍚� - List<String> sourceOnlyKeyList;// 鏉ユ簮鏁版嵁鍗曠嫭瀛樺湪鐨勫敮涓�閿泦鍚� - List<String> targetOnlyKeyList;// 鐩爣鏁版嵁鍗曠嫭瀛樺湪鐨勫敮涓�閿泦鍚� - List<String> publicKeyList;// 涓よ�呴兘瀛樺湪鐨勫敮涓�閿泦鍚� - DataTableEntity addDte; - DataTableEntity updateDte; + // 鏁版嵁澶勭悊 + String updateTimeFieldName; + DataTableEntity sourceDataDte; + FieldSetEntity sourceDataFse; + DataTableEntity targetDataDte = null; + List<String> sourceUniqueKeyList;// 鏉ユ簮鏁版嵁鐨勫敮涓�閿泦鍚� + List<String> targetUniqueKeyList;// 鐩爣鏁版嵁鐨勫敮涓�閿泦鍚� + List<String> sourceOnlyKeyList;// 鏉ユ簮鏁版嵁鍗曠嫭瀛樺湪鐨勫敮涓�閿泦鍚� + List<String> targetOnlyKeyList;// 鐩爣鏁版嵁鍗曠嫭瀛樺湪鐨勫敮涓�閿泦鍚� + List<String> publicKeyList;// 涓よ�呴兘瀛樺湪鐨勫敮涓�閿泦鍚� + DataTableEntity addDte; + DataTableEntity updateDte; // StringBuilder errorInfo = new StringBuilder(1024); - int dataSourceCount = 0; - try { - tableName = tableName.toLowerCase(Locale.ROOT); + int dataSourceCount = 0; + try { + tableName = tableName.toLowerCase(Locale.ROOT); // uniqueSignFieldName = uniqueSignFieldName.toLowerCase(Locale.ROOT); - updateTimeFieldName = jsonObject.getString(CmnConst.UPDATE_TIME); - if (StringUtils.isEmpty(updateTimeFieldName)) { - // 娌℃湁鏇存柊鏍囪瘑锛屾墽琛岃鐩栧姣旀洿鏂� - sourceDataDte = sourceDao.getList(tableName, ""); - sourceUniqueKeyList = sourceDataDte.getData().stream().map(item -> getUniqueValue(item, uniqueSignFieldName)).collect(Collectors.toList()); - //dao瀵瑰簲鐩爣鏁版嵁婧愪俊鎭殑涓嬫爣 - for (Dao targetDao : targetDaoList) { - addDte = new DataTableEntity(); - updateDte = new DataTableEntity(); - TimeInterval timer = DateUtil.timer(); - try { - targetDataDte = targetDao.getList(tableName, ""); - if (!DataTableEntity.isEmpty(targetDataDte)) { - targetUniqueKeyList = targetDataDte.getData().stream().map(item -> getUniqueValue(item, uniqueSignFieldName)).collect(Collectors.toList()); - sourceOnlyKeyList = dealDataUniqueKeyList(sourceUniqueKeyList, targetUniqueKeyList, 1); - targetOnlyKeyList = dealDataUniqueKeyList(sourceUniqueKeyList, targetUniqueKeyList, -1); - publicKeyList = dealDataUniqueKeyList(sourceUniqueKeyList, targetUniqueKeyList, 0); - for (int j = 0; j < sourceDataDte.getRows(); j++) { - sourceDataFse = sourceDataDte.getFieldSetEntity(j); - sourceDataFse.setTableName(tableName); - if (sourceOnlyKeyList.contains(getUniqueValue(sourceDataFse, uniqueSignFieldName))) { - addDte.addFieldSetEntity(sourceDataFse); - } else if (publicKeyList.contains(getUniqueValue(sourceDataFse, uniqueSignFieldName))) { - updateDte.addFieldSetEntity(sourceDataFse); - } - } - String filter = " ( "; - for (int i = 0; i < uniqueSignFieldName.length; i++) { - String uniqueSign = uniqueSignFieldName[i]; - if (i > 0) { - filter += " and "; + updateTimeFieldName = jsonObject.getString(CmnConst.UPDATE_TIME); + if (StringUtils.isEmpty(updateTimeFieldName)) { + // 娌℃湁鏇存柊鏍囪瘑锛屾墽琛岃鐩栧姣旀洿鏂� + sourceDataDte = sourceDao.getList(tableName, ""); + sourceUniqueKeyList = sourceDataDte.getData().stream().map(item -> getUniqueValue(item, uniqueSignFieldName)).collect(Collectors.toList()); + //dao瀵瑰簲鐩爣鏁版嵁婧愪俊鎭殑涓嬫爣 + for (Dao targetDao : targetDaoList) { + addDte = new DataTableEntity(); + updateDte = new DataTableEntity(); + TimeInterval timer = DateUtil.timer(); + try { + targetDataDte = targetDao.getList(tableName, ""); + if (!DataTableEntity.isEmpty(targetDataDte)) { + targetUniqueKeyList = targetDataDte.getData().stream().map(item -> getUniqueValue(item, uniqueSignFieldName)).collect(Collectors.toList()); + sourceOnlyKeyList = dealDataUniqueKeyList(sourceUniqueKeyList, targetUniqueKeyList, 1); + targetOnlyKeyList = dealDataUniqueKeyList(sourceUniqueKeyList, targetUniqueKeyList, -1); + publicKeyList = dealDataUniqueKeyList(sourceUniqueKeyList, targetUniqueKeyList, 0); + for (int j = 0; j < sourceDataDte.getRows(); j++) { + sourceDataFse = sourceDataDte.getFieldSetEntity(j); + sourceDataFse.setTableName(tableName); + if (sourceOnlyKeyList.contains(getUniqueValue(sourceDataFse, uniqueSignFieldName))) { + addDte.addFieldSetEntity(sourceDataFse); + } else if (publicKeyList.contains(getUniqueValue(sourceDataFse, uniqueSignFieldName))) { + updateDte.addFieldSetEntity(sourceDataFse); + } + } + String filter = " ( "; + for (int i = 0; i < uniqueSignFieldName.length; i++) { + String uniqueSign = uniqueSignFieldName[i]; + if (i > 0) { + filter += " and "; - } - filter += " " + uniqueSign + "=? "; - } - filter += " ) "; - String[] lower = new String[uniqueSignFieldName.length]; - for (int i = 0; i < uniqueSignFieldName.length; i++) { - lower[i] = uniqueSignFieldName[i].toLowerCase(); - } - targetDao.updateBatch(updateDte, new UpdateFilterEntity(filter, lower), true); - if (!targetOnlyKeyList.isEmpty()) { - List<Object> delParams = new ArrayList<>(); - StringBuilder delFilter = new StringBuilder(); - for (int i = 0; i < targetOnlyKeyList.size(); i++) { - delParams.addAll(Arrays.asList(getUniqueValue(targetOnlyKeyList.get(i)))); - if (i > 0) { - delFilter.append(" OR "); - } - delFilter.append(" ( "); - for (int j = 0; j < uniqueSignFieldName.length; j++) { - if (j > 0) { - delFilter.append(" and "); - } - delFilter.append(uniqueSignFieldName[j]).append("=? "); - } - delFilter.append(" ) "); - } + } + filter += " " + uniqueSign + "=? "; + } + filter += " ) "; + String[] lower = new String[uniqueSignFieldName.length]; + for (int i = 0; i < uniqueSignFieldName.length; i++) { + lower[i] = uniqueSignFieldName[i].toLowerCase(); + } + targetDao.updateBatch(updateDte, new UpdateFilterEntity(filter, lower), true); + if (!targetOnlyKeyList.isEmpty()) { + List<Object> delParams = new ArrayList<>(); + StringBuilder delFilter = new StringBuilder(); + for (int i = 0; i < targetOnlyKeyList.size(); i++) { + delParams.addAll(Arrays.asList(getUniqueValue(targetOnlyKeyList.get(i)))); + if (i > 0) { + delFilter.append(" OR "); + } + delFilter.append(" ( "); + for (int j = 0; j < uniqueSignFieldName.length; j++) { + if (j > 0) { + delFilter.append(" and "); + } + delFilter.append(uniqueSignFieldName[j]).append("=? "); + } + delFilter.append(" ) "); + } - targetDao.delete(tableName, delFilter.toString(), delParams.toArray()); - } - } else { - addDte = sourceDataDte; - addDte.getMeta().setTableName(new Object[]{tableName}); - } - targetDao.addBatch(addDte); - syncDataLogEntity = new SyncDataLogEntity(syncDataLogEntity); - journalEntities.add(getLogRecord(syncDataLogEntity, targetDataDte.getRows(), tableName, - targetDataSourceDte.getString(dataSourceCount, CmnConst.UUID), timer.intervalMs())); - } catch (Exception e) { - e.printStackTrace(); - SpringMVCContextHolder.getSystemLogger().error(e); - syncDataLogEntity = new SyncDataLogEntity(syncDataLogEntity); - syncDataLogEntity.setOtherInfo("鐩爣鏁版嵁婧愰厤缃畊uid锛�" + targetDataSourceDte.getString(dataSourceCount, "uuid")); - syncDataLogEntity.setErrorType(3); - journalEntities.add(getLogRecord(syncDataLogEntity, targetDataDte != null ? targetDataDte.getRows() : 0, tableName, - targetDataSourceDte.getString(dataSourceCount, CmnConst.UUID), timer.intervalMs(), e)); - } finally { - dataSourceCount++; - } - } - } else { - // 瀛樺湪鏇存柊鏍囪瘑锛屾墽琛屽閲忔洿鏂� - updateTimeFieldName = updateTimeFieldName.toLowerCase(Locale.ROOT); - dataSourceCount = 0; - for (Dao targetDao : targetDaoList) { - TimeInterval timer = DateUtil.timer(); - StringBuilder sql = new StringBuilder(128); - String maxValue = null; - String minValue = null; - int totalCount = 0; - try { - sql.append("select max(").append(updateTimeFieldName).append(") max_value from ").append(tableName); - FieldSetEntity paramFse = targetDao.getOne(sql.toString()); - StringBuilder filter = new StringBuilder(128); - if (paramFse != null) { - if (!StringUtils.isEmpty(paramFse.getString("max_value"))) { - filter.append(updateTimeFieldName).append(">=").append(SqlTransferUtil.str2Date(sourceDao.getDataBaseType().getValue(), paramFse.getDate("max_value"))) - .append(" and ").append(updateTimeFieldName).append("<=").append(SqlTransferUtil.str2Date(sourceDao.getDataBaseType().getValue(), c1.getTime())); - } - } - sql.setLength(0); - sql.append("select count(*) total_count from ").append(tableName); - if (filter.length() > 0) { - sql.append(" where ").append(filter); - } - paramFse = sourceDao.getOne(sql.toString()); - totalCount = StringUtils.isEmpty(paramFse.getString("total_count")) ? 0 : paramFse.getInteger("total_count"); - int batchCount = StringUtils.isEmpty(syncConfigFse.getString(CmnConst.INCREMENT_BATCH_COUNT)) ? 1000 : syncConfigFse.getInteger(CmnConst.INCREMENT_BATCH_COUNT); - int totalPage = (int) Math.ceil((double) totalCount / batchCount); - for (int j = 0; j < totalPage; j++) { - addDte = new DataTableEntity(); - updateDte = new DataTableEntity(); - sourceDataDte = sourceDao.getList(tableName, filter.toString(), new Object[]{}, j + 1, batchCount); - sourceUniqueKeyList = sourceDataDte.getData().stream().map(item -> getUniqueValue(item, uniqueSignFieldName)).collect(Collectors.toList()); - sql.setLength(0); - sql.append("select "); - filter.setLength(0); + targetDao.delete(tableName, delFilter.toString(), delParams.toArray()); + } + } else { + addDte = sourceDataDte; + addDte.getMeta().setTableName(new Object[]{tableName}); + } + targetDao.addBatch(addDte); + syncDataLogEntity = new SyncDataLogEntity(syncDataLogEntity); + journalEntities.add(getLogRecord(syncDataLogEntity, targetDataDte.getRows(), tableName, + targetDataSourceDte.getString(dataSourceCount, CmnConst.UUID), timer.intervalMs())); + } catch (Exception e) { + e.printStackTrace(); + SpringMVCContextHolder.getSystemLogger().error(e); + syncDataLogEntity = new SyncDataLogEntity(syncDataLogEntity); + syncDataLogEntity.setOtherInfo("鐩爣鏁版嵁婧愰厤缃畊uid锛�" + targetDataSourceDte.getString(dataSourceCount, "uuid")); + syncDataLogEntity.setErrorType(3); + journalEntities.add(getLogRecord(syncDataLogEntity, targetDataDte != null ? targetDataDte.getRows() : 0, tableName, + targetDataSourceDte.getString(dataSourceCount, CmnConst.UUID), timer.intervalMs(), e)); + } finally { + dataSourceCount++; + } + } + } else { + // 瀛樺湪鏇存柊鏍囪瘑锛屾墽琛屽閲忔洿鏂� + updateTimeFieldName = updateTimeFieldName.toLowerCase(Locale.ROOT); + dataSourceCount = 0; + for (Dao targetDao : targetDaoList) { + TimeInterval timer = DateUtil.timer(); + StringBuilder sql = new StringBuilder(128); + String maxValue = null; + String minValue = null; + int totalCount = 0; + try { + sql.append("select max(").append(updateTimeFieldName).append(") max_value from ").append(tableName); + FieldSetEntity paramFse = targetDao.getOne(sql.toString()); + StringBuilder filter = new StringBuilder(128); + if (paramFse != null) { + if (!StringUtils.isEmpty(paramFse.getString("max_value"))) { + filter.append(updateTimeFieldName).append(">=").append(SqlTransferUtil.str2Date(sourceDao.getDataBaseType().getValue(), paramFse.getDate("max_value"))) + .append(" and ").append(updateTimeFieldName).append("<=").append(SqlTransferUtil.str2Date(sourceDao.getDataBaseType().getValue(), c1.getTime())); + } + } + sql.setLength(0); + sql.append("select count(*) total_count from ").append(tableName); + if (filter.length() > 0) { + sql.append(" where ").append(filter); + } + paramFse = sourceDao.getOne(sql.toString()); + totalCount = StringUtils.isEmpty(paramFse.getString("total_count")) ? 0 : paramFse.getInteger("total_count"); + int batchCount = StringUtils.isEmpty(syncConfigFse.getString(CmnConst.INCREMENT_BATCH_COUNT)) ? 1000 : syncConfigFse.getInteger(CmnConst.INCREMENT_BATCH_COUNT); + int totalPage = (int) Math.ceil((double) totalCount / batchCount); + for (int j = 0; j < totalPage; j++) { + addDte = new DataTableEntity(); + updateDte = new DataTableEntity(); + sourceDataDte = sourceDao.getList(tableName, filter.toString(), new Object[]{}, j + 1, batchCount); + sourceUniqueKeyList = sourceDataDte.getData().stream().map(item -> getUniqueValue(item, uniqueSignFieldName)).collect(Collectors.toList()); + sql.setLength(0); + sql.append("select "); + filter.setLength(0); - for (int i = 0; i < sourceUniqueKeyList.size(); i++) { - if (i > 0) { - filter.append(" or "); - } - filter.append(" ( "); - for (int k = 0; k < uniqueSignFieldName.length; k++) { - if (i == 0) { - if (k > 0) { - sql.append(","); - } - sql.append(uniqueSignFieldName[k]); + for (int i = 0; i < sourceUniqueKeyList.size(); i++) { + if (i > 0) { + filter.append(" or "); + } + filter.append(" ( "); + for (int k = 0; k < uniqueSignFieldName.length; k++) { + if (i == 0) { + if (k > 0) { + sql.append(","); + } + sql.append(uniqueSignFieldName[k]); - } - if (k > 0) { - filter.append(" AND "); - } - filter.append(uniqueSignFieldName[k]).append("= ? "); - } - filter.append(" ) "); - } + } + if (k > 0) { + filter.append(" AND "); + } + filter.append(uniqueSignFieldName[k]).append("= ? "); + } + filter.append(" ) "); + } - sql.append(" from ").append(tableName).append(" where ").append(filter); + sql.append(" from ").append(tableName).append(" where ").append(filter); - String[][] objects = sourceUniqueKeyList.stream().map(item -> getUniqueValue(item)).toArray(String[][]::new); - String[] parmas = ArrayUtil.addAll(objects); - DataTableEntity paramDte = targetDao.getList(sql.toString(), parmas); - if (!DataTableEntity.isEmpty(paramDte)) { - targetUniqueKeyList = paramDte.getData().stream().map(item -> getUniqueValue(item, uniqueSignFieldName)).collect(Collectors.toList()); - sourceOnlyKeyList = dealDataUniqueKeyList(sourceUniqueKeyList, targetUniqueKeyList, 1); - publicKeyList = dealDataUniqueKeyList(sourceUniqueKeyList, targetUniqueKeyList, 0); - for (int k = 0; k < sourceDataDte.getRows(); k++) { - sourceDataFse = sourceDataDte.getFieldSetEntity(k); - String uniqueValue = getUniqueValue(sourceDataFse, uniqueSignFieldName); - //鑾峰彇鏈�灏忓敮涓�鍊� - if (StringUtils.isEmpty(minValue)) { - minValue = uniqueValue; - } else { - minValue = getAimID(minValue, uniqueValue, 0); - } - //鑾峰彇鏈�澶у敮涓�鍊� - if (StringUtils.isEmpty(maxValue)) { - maxValue = uniqueValue; - } else { - maxValue = getAimID(minValue, uniqueValue, 1); - } - sourceDataFse = sourceDataDte.getFieldSetEntity(k); - sourceDataFse.setTableName(tableName); - if (sourceOnlyKeyList.contains(getUniqueValue(sourceDataFse, uniqueSignFieldName))) { - addDte.addFieldSetEntity(sourceDataFse); - } else if (publicKeyList.contains(getUniqueValue(sourceDataFse, uniqueSignFieldName))) { - updateDte.addFieldSetEntity(sourceDataFse); - } - } - String filterUp = " ( "; - for (int i = 0; i < uniqueSignFieldName.length; i++) { - String uniqueSign = uniqueSignFieldName[i]; - if (i > 0) { - filterUp += " and "; + String[][] objects = sourceUniqueKeyList.stream().map(item -> getUniqueValue(item)).toArray(String[][]::new); + String[] parmas = ArrayUtil.addAll(objects); + DataTableEntity paramDte = targetDao.getList(sql.toString(), parmas); + if (!DataTableEntity.isEmpty(paramDte)) { + targetUniqueKeyList = paramDte.getData().stream().map(item -> getUniqueValue(item, uniqueSignFieldName)).collect(Collectors.toList()); + sourceOnlyKeyList = dealDataUniqueKeyList(sourceUniqueKeyList, targetUniqueKeyList, 1); + publicKeyList = dealDataUniqueKeyList(sourceUniqueKeyList, targetUniqueKeyList, 0); + for (int k = 0; k < sourceDataDte.getRows(); k++) { + sourceDataFse = sourceDataDte.getFieldSetEntity(k); + String uniqueValue = getUniqueValue(sourceDataFse, uniqueSignFieldName); + //鑾峰彇鏈�灏忓敮涓�鍊� + if (StringUtils.isEmpty(minValue)) { + minValue = uniqueValue; + } else { + minValue = getAimID(minValue, uniqueValue, 0); + } + //鑾峰彇鏈�澶у敮涓�鍊� + if (StringUtils.isEmpty(maxValue)) { + maxValue = uniqueValue; + } else { + maxValue = getAimID(minValue, uniqueValue, 1); + } + sourceDataFse = sourceDataDte.getFieldSetEntity(k); + sourceDataFse.setTableName(tableName); + if (sourceOnlyKeyList.contains(getUniqueValue(sourceDataFse, uniqueSignFieldName))) { + addDte.addFieldSetEntity(sourceDataFse); + } else if (publicKeyList.contains(getUniqueValue(sourceDataFse, uniqueSignFieldName))) { + updateDte.addFieldSetEntity(sourceDataFse); + } + } + String filterUp = " ( "; + for (int i = 0; i < uniqueSignFieldName.length; i++) { + String uniqueSign = uniqueSignFieldName[i]; + if (i > 0) { + filterUp += " and "; - } - filterUp += " " + uniqueSign + "=? "; - } - filterUp += " ) "; + } + filterUp += " " + uniqueSign + "=? "; + } + filterUp += " ) "; - String[] lower = new String[uniqueSignFieldName.length]; - for (int i = 0; i < uniqueSignFieldName.length; i++) { - lower[i] = uniqueSignFieldName[i].toLowerCase(); - } - targetDao.updateBatch(updateDte, new UpdateFilterEntity(filterUp, lower), true); - } else { - addDte = sourceDataDte; - addDte.getMeta().setTableName(new Object[]{tableName}); - } - targetDao.addBatch(addDte); - } - syncDataLogEntity = new SyncDataLogEntity(syncDataLogEntity); - journalEntities.add(getLogRecord(syncDataLogEntity, totalCount, tableName, - minValue, maxValue, - targetDataSourceDte.getString(dataSourceCount, CmnConst.UUID), timer.intervalMs())); - } catch (Exception e) { - e.printStackTrace(); - SpringMVCContextHolder.getSystemLogger().error(e); - syncDataLogEntity = new SyncDataLogEntity(syncDataLogEntity); - syncDataLogEntity.setErrorType(3); - syncDataLogEntity.setOtherInfo("鐩爣鏁版嵁婧愰厤缃畊uid锛�" + targetDataSourceDte.getString(dataSourceCount, "uuid")); - journalEntities.add(getLogRecord(syncDataLogEntity, totalCount, tableName, - minValue, maxValue, - targetDataSourceDte.getString(dataSourceCount, CmnConst.UUID), timer.intervalMs(), e)); - } finally { - dataSourceCount++; - } - } - } - } catch (Exception e) { - throw e; - } finally { - if (targetDaoList != null && !targetDaoList.isEmpty()) { - for (int i1 = 0; i1 < targetDaoList.size(); i1++) { - Dao dao = targetDaoList.get(i1); - if (dao != null) { - dao.closeConnection(); - } - } - } + String[] lower = new String[uniqueSignFieldName.length]; + for (int i = 0; i < uniqueSignFieldName.length; i++) { + lower[i] = uniqueSignFieldName[i].toLowerCase(); + } + targetDao.updateBatch(updateDte, new UpdateFilterEntity(filterUp, lower), true); + } else { + addDte = sourceDataDte; + addDte.getMeta().setTableName(new Object[]{tableName}); + } + targetDao.addBatch(addDte); + } + syncDataLogEntity = new SyncDataLogEntity(syncDataLogEntity); + journalEntities.add(getLogRecord(syncDataLogEntity, totalCount, tableName, + minValue, maxValue, + targetDataSourceDte.getString(dataSourceCount, CmnConst.UUID), timer.intervalMs())); + } catch (Exception e) { + e.printStackTrace(); + SpringMVCContextHolder.getSystemLogger().error(e); + syncDataLogEntity = new SyncDataLogEntity(syncDataLogEntity); + syncDataLogEntity.setErrorType(3); + syncDataLogEntity.setOtherInfo("鐩爣鏁版嵁婧愰厤缃畊uid锛�" + targetDataSourceDte.getString(dataSourceCount, "uuid")); + journalEntities.add(getLogRecord(syncDataLogEntity, totalCount, tableName, + minValue, maxValue, + targetDataSourceDte.getString(dataSourceCount, CmnConst.UUID), timer.intervalMs(), e)); + } finally { + dataSourceCount++; + } + } + } + } catch (Exception e) { + throw e; + } finally { + if (targetDaoList != null && !targetDaoList.isEmpty()) { + for (int i1 = 0; i1 < targetDaoList.size(); i1++) { + Dao dao = targetDaoList.get(i1); + if (dao != null) { + dao.closeConnection(); + } + } + } - } + } - return journalEntities; - } catch (Exception e) { - e.printStackTrace(); - syncDataLogEntity = new SyncDataLogEntity(syncDataLogEntity); - syncDataLogEntity.setErrorType(2); - journalEntities.add(getLogRecord(syncDataLogEntity, null, null, null, 0L - , e)); - return journalEntities; - } finally { - if (journalEntities != null) { - for (int i = 0; i < journalEntities.size(); i++) { - journalManagerService.autoCreateJournal(journalEntities.get(i)); - } - } - if (lockStatus && !StringUtils.isEmpty(lockKey)) { - customLock.unLock(lockKey); - } - if(sourceDao!=null){ - sourceDao.closeConnection(); - } + return journalEntities; + } catch (Exception e) { + e.printStackTrace(); + syncDataLogEntity = new SyncDataLogEntity(syncDataLogEntity); + syncDataLogEntity.setErrorType(2); + journalEntities.add(getLogRecord(syncDataLogEntity, null, null, null, 0L + , e)); + return journalEntities; + } finally { + if (journalEntities != null) { + for (int i = 0; i < journalEntities.size(); i++) { + journalManagerService.autoCreateJournal(journalEntities.get(i)); + } + } + if (lockStatus && !StringUtils.isEmpty(lockKey)) { + customLock.unLock(lockKey); + } + if (sourceDao != null) { + sourceDao.closeConnection(); + } - } - } + } + } finally { + if (lockStatus && !StringUtils.isEmpty(lockKey)) { + customLock.unLock(lockKey); + } + } + } - private static String[] getUniqueValue(String value) { - return value.split("\\*-\\*_~!"); - } + private static String[] getUniqueValue(String value) { + return value.split("\\*-\\*_~!"); + } - private String getUniqueValue(FieldSetEntity item, String[] uniqueFieldNames) { - String name = ""; - for (int i = 0; i < uniqueFieldNames.length; i++) { - if (i > 0) { - name += "*-*_~!"; - } - name += item.getString(uniqueFieldNames[i].toLowerCase()); - } - return name; - } + private String getUniqueValue(FieldSetEntity item, String[] uniqueFieldNames) { + String name = ""; + for (int i = 0; i < uniqueFieldNames.length; i++) { + if (i > 0) { + name += "*-*_~!"; + } + name += item.getString(uniqueFieldNames[i].toLowerCase()); + } + return name; + } - /** - * 鏃ュ織鍙槸璁板綍涓�鏉★紝鍙嶆姣忔 - * 瑕嗙洊 閮芥槸鍏ㄩ儴閲嶆柊鎼� - * 澧為噺 閮芥槸鏌ヨ瀛愬簱鍙栦簡涓�涓渶澶х殑鏃堕棿浣滀负鏍囧噯 - * 鐐瑰嚮鏃ュ織涓殑閲嶆柊澶勭悊鍙槸涓轰簡瑙﹀彂杩欎釜鍙e瓙鑰屽凡锛屽拰瀹為檯宸茬粡鎿嶄綔浜嗗ソ澶氭暟鎹墿浣欏ソ澶氭暟鎹苟娌℃湁濂藉ぇ鐨勫叧绯伙紙鏌ヨ鍜屾彃鍏ユ暟鎹緷鐒堕噰鐢ㄥ垎鎵癸紝涓嶇劧鏁版嵁閲忓ぇ浜嗗唴瀛樿宕╋級 - * 鏁版嵁涓嶈繘琛屽洖婊氾紝閬囧埌閿欒鐩存帴鍐欏叆鍒版棩蹇椾腑锛堝洜涓鸿嫢鏄洖婊氾紝閭d箞灏辩浉褰撲簬鎵�鏈夌殑绾块兘娌℃湁鑾峰彇鍒版柊鐨勫唴瀹癸紝涓嶅洖婊氭暟鎹彲浠ヨ娌¢棶棰樼殑绾挎甯稿鐞嗭級 - * - * @param encodedData - */ - @Deprecated - public synchronized void dataSync(String encodedData) { - TimeInterval timer = DateUtil.timer(); - JSONArray jsonArray = null; - List<JournalEntity> journalEntities = new ArrayList<>(); - try { - // 鑾峰彇鍚屾閰嶇疆淇℃伅 - DataTableEntity syncConfigDte = baseDao.listTable(CmnConst.PRODUCT_SYS_DATA_SYNC_MES); - if (DataTableEntity.isEmpty(syncConfigDte)) { - throw new BaseException(ErrorCode.SYNC_GET_CONFIG_FAIL); - } - FieldSetEntity syncConfigFse = syncConfigDte.getFieldSetEntity(0); - if (FieldSetEntity.isEmpty(syncConfigFse)) { - throw new BaseException(ErrorCode.SYNC_GET_CONFIG_FAIL); - } - String cryptPrivateKey = syncConfigFse.getString(CmnConst.DECRYPT_KEY); - String signPublicKey = syncConfigFse.getString(CmnConst.SIGN_KEY); - String signedData = RSAUtil.privateDecrypt(encodedData, RSAUtil.getPrivateKey(cryptPrivateKey)); - String jsonArrayStr = RSAUtil.publicDecrypt(signedData, RSAUtil.getPublicKey(signPublicKey)); + /** + * 鏃ュ織鍙槸璁板綍涓�鏉★紝鍙嶆姣忔 + * 瑕嗙洊 閮芥槸鍏ㄩ儴閲嶆柊鎼� + * 澧為噺 閮芥槸鏌ヨ瀛愬簱鍙栦簡涓�涓渶澶х殑鏃堕棿浣滀负鏍囧噯 + * 鐐瑰嚮鏃ュ織涓殑閲嶆柊澶勭悊鍙槸涓轰簡瑙﹀彂杩欎釜鍙e瓙鑰屽凡锛屽拰瀹為檯宸茬粡鎿嶄綔浜嗗ソ澶氭暟鎹墿浣欏ソ澶氭暟鎹苟娌℃湁濂藉ぇ鐨勫叧绯伙紙鏌ヨ鍜屾彃鍏ユ暟鎹緷鐒堕噰鐢ㄥ垎鎵癸紝涓嶇劧鏁版嵁閲忓ぇ浜嗗唴瀛樿宕╋級 + * 鏁版嵁涓嶈繘琛屽洖婊氾紝閬囧埌閿欒鐩存帴鍐欏叆鍒版棩蹇椾腑锛堝洜涓鸿嫢鏄洖婊氾紝閭d箞灏辩浉褰撲簬鎵�鏈夌殑绾块兘娌℃湁鑾峰彇鍒版柊鐨勫唴瀹癸紝涓嶅洖婊氭暟鎹彲浠ヨ娌¢棶棰樼殑绾挎甯稿鐞嗭級 + * + * @param encodedData + */ + @Deprecated + public synchronized void dataSync(String encodedData) { + TimeInterval timer = DateUtil.timer(); + JSONArray jsonArray = null; + List<JournalEntity> journalEntities = new ArrayList<>(); + try { + // 鑾峰彇鍚屾閰嶇疆淇℃伅 + DataTableEntity syncConfigDte = baseDao.listTable(CmnConst.PRODUCT_SYS_DATA_SYNC_MES); + if (DataTableEntity.isEmpty(syncConfigDte)) { + throw new BaseException(ErrorCode.SYNC_GET_CONFIG_FAIL); + } + FieldSetEntity syncConfigFse = syncConfigDte.getFieldSetEntity(0); + if (FieldSetEntity.isEmpty(syncConfigFse)) { + throw new BaseException(ErrorCode.SYNC_GET_CONFIG_FAIL); + } + String cryptPrivateKey = syncConfigFse.getString(CmnConst.DECRYPT_KEY); + String signPublicKey = syncConfigFse.getString(CmnConst.SIGN_KEY); + String signedData = RSAUtil.privateDecrypt(encodedData, RSAUtil.getPrivateKey(cryptPrivateKey)); + String jsonArrayStr = RSAUtil.publicDecrypt(signedData, RSAUtil.getPublicKey(signPublicKey)); - if (StringUtils.isEmpty(jsonArrayStr)) { - throw new BaseException(ErrorCode.SYNC_GET_PARAM_FAIL); - } - jsonArray = JSON.parseArray(jsonArrayStr); - } catch (Exception e) { - SpringMVCContextHolder.getSystemLogger().error(e); - SyncDataLogEntity<String> syncDataLogEntity = new SyncDataLogEntity(); - syncDataLogEntity.setErrorType(1); - syncDataLogEntity.setSyncInfo(encodedData); - JournalEntity journalEntity = (getLogRecord(syncDataLogEntity, null, null, null, timer.intervalMs() - , e)); - journalManagerService.autoCreateJournal(journalEntity); - } - if (jsonArray != null) { - try { - for (int i = 0; i < jsonArray.size(); i++) { - this.dataSync(jsonArray.getJSONObject(i)); - } - } catch (Exception e) { - //涓嶅閿欒鍋氫换浣曟搷浣滆鍦ㄨ皟鐢ㄧ殑鏂规硶涓繘琛屽鐞� - e.printStackTrace(); - } - } - } + if (StringUtils.isEmpty(jsonArrayStr)) { + throw new BaseException(ErrorCode.SYNC_GET_PARAM_FAIL); + } + jsonArray = JSON.parseArray(jsonArrayStr); + } catch (Exception e) { + SpringMVCContextHolder.getSystemLogger().error(e); + SyncDataLogEntity<String> syncDataLogEntity = new SyncDataLogEntity(); + syncDataLogEntity.setErrorType(1); + syncDataLogEntity.setSyncInfo(encodedData); + JournalEntity journalEntity = (getLogRecord(syncDataLogEntity, null, null, null, timer.intervalMs() + , e)); + journalManagerService.autoCreateJournal(journalEntity); + } + if (jsonArray != null) { + try { + for (int i = 0; i < jsonArray.size(); i++) { + this.dataSync(jsonArray.getJSONObject(i)); + } + } catch (Exception e) { + //涓嶅閿欒鍋氫换浣曟搷浣滆鍦ㄨ皟鐢ㄧ殑鏂规硶涓繘琛屽鐞� + e.printStackTrace(); + } + } + } - private JournalEntity getLogRecord(SyncDataLogEntity syncDataLogEntity, Integer dataCount, String configUid, - String dataSourceUid, long elapsedTime, Throwable throwable) { - return getLogRecord(syncDataLogEntity, dataCount, configUid, null, null, dataSourceUid, elapsedTime, throwable); - } + private JournalEntity getLogRecord(SyncDataLogEntity syncDataLogEntity, Integer dataCount, String configUid, + String dataSourceUid, long elapsedTime, Throwable throwable) { + return getLogRecord(syncDataLogEntity, dataCount, configUid, null, null, dataSourceUid, elapsedTime, throwable); + } - private JournalEntity getLogRecord(SyncDataLogEntity syncDataLogEntity, Integer dataCount, String configUid, - String dataSourceUid, long elapsedTime) { - return getLogRecord(syncDataLogEntity, dataCount, configUid, null, null, dataSourceUid, elapsedTime, null); - } + private JournalEntity getLogRecord(SyncDataLogEntity syncDataLogEntity, Integer dataCount, String configUid, + String dataSourceUid, long elapsedTime) { + return getLogRecord(syncDataLogEntity, dataCount, configUid, null, null, dataSourceUid, elapsedTime, null); + } - private JournalEntity getLogRecord(SyncDataLogEntity syncDataLogEntity, Integer dataCount, String configUid, String minId, - String maxId, String dataSourceUid, long elapsedTime) { - return getLogRecord(syncDataLogEntity, dataCount, configUid, minId, maxId, dataSourceUid, elapsedTime, null); - } + private JournalEntity getLogRecord(SyncDataLogEntity syncDataLogEntity, Integer dataCount, String configUid, String minId, + String maxId, String dataSourceUid, long elapsedTime) { + return getLogRecord(syncDataLogEntity, dataCount, configUid, minId, maxId, dataSourceUid, elapsedTime, null); + } - private JournalEntity getLogRecord(SyncDataLogEntity syncDataLogEntity, Integer dataCount, String configUid, String minId, - String maxId, String dataSourceUid, long elapsedTime, Throwable throwable) { - JournalEntity journalEntity = new JournalEntity(); - journalEntity.setType(3); - journalEntity.setDeal_flag(0); - journalEntity.setResult(syncDataLogEntity.getErrorType() == -1 ? 1 : 0); - String configUUID = ""; - if (syncDataLogEntity.getSyncInfo() != null) { - JSONObject syncInfo = JSONObject.parseObject(syncDataLogEntity.getSyncInfo().toString()); - configUUID = syncInfo.getString(CmnConst.UUID); - } - journalEntity.setConfigUuid(StringUtils.isEmpty(configUUID) ? "1" : configUUID); - journalEntity.setCount(dataCount); - journalEntity.setMin_id(minId); - journalEntity.setMax_id(maxId); - journalEntity.setData_source(dataSourceUid); - journalEntity.setSingle_duration(elapsedTime); - journalEntity.setOther_info(syncDataLogEntity.toString()); - journalEntity.setCreated_utc_datetime(new Date()); - if (journalEntity.getResult() != 1 && throwable != null) { - journalEntity.setError(journalManagerService.getStackTrace(throwable)); - } - journalEntity.setDeal_result(journalEntity.getResult() == 1 ? 1 : 0); - return journalEntity; - } + private JournalEntity getLogRecord(SyncDataLogEntity syncDataLogEntity, Integer dataCount, String configUid, String minId, + String maxId, String dataSourceUid, long elapsedTime, Throwable throwable) { + JournalEntity journalEntity = new JournalEntity(); + journalEntity.setType(3); + journalEntity.setDeal_flag(0); + journalEntity.setResult(syncDataLogEntity.getErrorType() == -1 ? 1 : 0); + String configUUID = ""; + if (syncDataLogEntity.getSyncInfo() != null) { + JSONObject syncInfo = JSONObject.parseObject(syncDataLogEntity.getSyncInfo().toString()); + configUUID = syncInfo.getString(CmnConst.UUID); + } + journalEntity.setConfigUuid(StringUtils.isEmpty(configUUID) ? "1" : configUUID); + journalEntity.setCount(dataCount); + journalEntity.setMin_id(minId); + journalEntity.setMax_id(maxId); + journalEntity.setData_source(dataSourceUid); + journalEntity.setSingle_duration(elapsedTime); + journalEntity.setOther_info(syncDataLogEntity.toString()); + journalEntity.setCreated_utc_datetime(new Date()); + if (journalEntity.getResult() != 1 && throwable != null) { + journalEntity.setError(journalManagerService.getStackTrace(throwable)); + } + journalEntity.setDeal_result(journalEntity.getResult() == 1 ? 1 : 0); + return journalEntity; + } - private String getAimID(String s1, String s2, int sign) { - if (org.apache.commons.lang3.StringUtils.isEmpty(s1) && org.apache.commons.lang3.StringUtils.isEmpty(s2)) { - return null; - } - if (org.apache.commons.lang3.StringUtils.isEmpty(s1) || org.apache.commons.lang3.StringUtils.isEmpty(s2)) { - return org.apache.commons.lang3.StringUtils.isEmpty(s1) ? s2 : s1; - } - String numberRegexp = "\\d{1,11}"; - if (s1.matches(numberRegexp) && s2.matches(numberRegexp)) { - boolean b = Long.parseLong(s1) > Long.parseLong(s2); - if (sign > 0) { - return b ? s1 : s2; - } else { - return b ? s2 : s1; - } - } else { - if (sign > 0) { - return s1.compareTo(s2) > 0 ? s1 : s2; - } else { - return s1.compareTo(s2) > 0 ? s2 : s1; - } - } - } + private String getAimID(String s1, String s2, int sign) { + if (org.apache.commons.lang3.StringUtils.isEmpty(s1) && org.apache.commons.lang3.StringUtils.isEmpty(s2)) { + return null; + } + if (org.apache.commons.lang3.StringUtils.isEmpty(s1) || org.apache.commons.lang3.StringUtils.isEmpty(s2)) { + return org.apache.commons.lang3.StringUtils.isEmpty(s1) ? s2 : s1; + } + String numberRegexp = "\\d{1,11}"; + if (s1.matches(numberRegexp) && s2.matches(numberRegexp)) { + boolean b = Long.parseLong(s1) > Long.parseLong(s2); + if (sign > 0) { + return b ? s1 : s2; + } else { + return b ? s2 : s1; + } + } else { + if (sign > 0) { + return s1.compareTo(s2) > 0 ? s1 : s2; + } else { + return s1.compareTo(s2) > 0 ? s2 : s1; + } + } + } - /** - * 澶勭悊鍞竴閿泦鍚� - * - * @param sourceList 鏉ユ簮 - * @param targetList 鐩爣 - * @param sign 1 鏉ユ簮鍗曠嫭瀛樺湪锛�0 涓よ�呭叡鏈夛紱-1 鐩爣鍗曠嫭瀛樺湪 - * @return - */ - private <T> List<T> dealDataUniqueKeyList(List<T> sourceList, List<T> targetList, int sign) { - List<T> sourceUniqueKeyList = Lists.newArrayList(); - sourceUniqueKeyList.addAll(sourceList); - List<T> targetUniqueKeyList = Lists.newArrayList(); - targetUniqueKeyList.addAll(targetList); - List<T> resultObjList; - if (sign == 1) { - sourceUniqueKeyList.removeAll(targetUniqueKeyList); - resultObjList = sourceUniqueKeyList; - } else if (sign == -1) { - targetUniqueKeyList.removeAll(sourceUniqueKeyList); - resultObjList = targetUniqueKeyList; - } else if (sign == 0) { - sourceUniqueKeyList.retainAll(targetUniqueKeyList); - resultObjList = sourceUniqueKeyList; - } else { - throw new BaseException(ErrorCode.SYNC_NO_DATA_DEAL_WAY); - } - return transferListType(resultObjList); - } + /** + * 澶勭悊鍞竴閿泦鍚� + * + * @param sourceList 鏉ユ簮 + * @param targetList 鐩爣 + * @param sign 1 鏉ユ簮鍗曠嫭瀛樺湪锛�0 涓よ�呭叡鏈夛紱-1 鐩爣鍗曠嫭瀛樺湪 + * @return + */ + private <T> List<T> dealDataUniqueKeyList(List<T> sourceList, List<T> targetList, int sign) { + List<T> sourceUniqueKeyList = Lists.newArrayList(); + sourceUniqueKeyList.addAll(sourceList); + List<T> targetUniqueKeyList = Lists.newArrayList(); + targetUniqueKeyList.addAll(targetList); + List<T> resultObjList; + if (sign == 1) { + sourceUniqueKeyList.removeAll(targetUniqueKeyList); + resultObjList = sourceUniqueKeyList; + } else if (sign == -1) { + targetUniqueKeyList.removeAll(sourceUniqueKeyList); + resultObjList = targetUniqueKeyList; + } else if (sign == 0) { + sourceUniqueKeyList.retainAll(targetUniqueKeyList); + resultObjList = sourceUniqueKeyList; + } else { + throw new BaseException(ErrorCode.SYNC_NO_DATA_DEAL_WAY); + } + return transferListType(resultObjList); + } - /** - * 杞崲list涓璷bj涓簊tring - * - * @param list - * @return - */ - private <T> List<T> transferListType(List<T> list) { - List<T> resultList = Lists.newArrayList(); - list.forEach(k -> { - if (k == null) { - resultList.add(null); - } else { - resultList.add(k); - } - }); - return resultList; - } + /** + * 杞崲list涓璷bj涓簊tring + * + * @param list + * @return + */ + private <T> List<T> transferListType(List<T> list) { + List<T> resultList = Lists.newArrayList(); + list.forEach(k -> { + if (k == null) { + resultList.add(null); + } else { + resultList.add(k); + } + }); + return resultList; + } - /** - * 杩藉姞閿欒淇℃伅 - * - * @param errorInfo - * @param e - */ - private void appendError(StringBuilder errorInfo, Throwable e) { - if (errorInfo.length() > 0) { - errorInfo.append("\n"); - } - errorInfo.append(journalManagerService.getStackTrace(e)); - } + /** + * 杩藉姞閿欒淇℃伅 + * + * @param errorInfo + * @param e + */ + private void appendError(StringBuilder errorInfo, Throwable e) { + if (errorInfo.length() > 0) { + errorInfo.append("\n"); + } + errorInfo.append(journalManagerService.getStackTrace(e)); + } } diff --git a/product-server-data-center/src/main/java/com/product/data/center/utils/CustomLock.java b/product-server-data-center/src/main/java/com/product/data/center/utils/CustomLock.java index 331802b..6336553 100644 --- a/product-server-data-center/src/main/java/com/product/data/center/utils/CustomLock.java +++ b/product-server-data-center/src/main/java/com/product/data/center/utils/CustomLock.java @@ -1,11 +1,15 @@ package com.product.data.center.utils; import cn.hutool.core.collection.ConcurrentHashSet; +import cn.hutool.core.date.DateUtil; import cn.hutool.core.thread.ThreadUtil; import cn.hutool.core.util.ArrayUtil; import com.product.core.spring.context.SpringMVCContextHolder; import org.apache.commons.lang3.StringUtils; +import javax.swing.*; +import java.text.DateFormat; +import java.util.Date; import java.util.Map; import java.util.Set; import java.util.concurrent.ConcurrentHashMap; @@ -19,6 +23,7 @@ private Map<String, Long> obj = new ConcurrentHashMap<>(); + private Map<String, Long> threadObj = new ConcurrentHashMap<>(); private long detectionWaitTime = 1000L; @@ -41,12 +46,64 @@ return this.tryLock(ArrayUtil.join(key, ",")); } + public static void main(String[] args) { + long timemillis = 1709654400039L; + //杞崲涓哄勾鏈堟棩鏃跺垎绉� + String format = DateUtil.format(DateUtil.date(timemillis), "yyyy-MM-dd HH:mm:ss"); + + System.out.println(format); + } + + public boolean tryLock(String key, long timeoutMinute) { + if (!StringUtils.isEmpty(key)) { + key = key.toUpperCase(); + synchronized (key.intern()) { + if (!this.obj.containsKey(key)) { + lock(key); + //鑾峰彇褰撳墠绾跨▼ + long id = Thread.currentThread().getId(); + threadObj.put(key, id); + return true; + } else if (timeoutMinute > 0) { + //鑾峰彇閿佽繘鍏ュ紑濮嬫椂闂� + long startTime = obj.get(key); + //鑾峰彇褰撳墠鏃堕棿 + long currentTime = System.currentTimeMillis(); + + //灏嗗垎閽熻浆鎹负姣 + long timeout = timeoutMinute * 60 * 1000; + //濡傛灉褰撳墠鏃堕棿鍑忓幓寮�濮嬫椂闂村ぇ浜庣瓑浜庤秴鏃舵椂闂� + if (currentTime - startTime >= timeout) { + long threadId = threadObj.get(key); + //鏍规嵁绾跨▼id鑾峰彇绾跨▼ + Thread[] threads = ThreadUtil.getThreads(); + for (Thread thread : threads) { + if (thread.getId() == threadId) { + //涓柇绾跨▼ + ThreadUtil.interrupt(thread, true); + SpringMVCContextHolder.getSystemLogger().error("绾跨▼锛�" + thread.getName() + "瓒呮椂琚腑鏂�"); + return tryLock(key, timeoutMinute); + } + } + return true; + } + + } + } + } + return false; + } + + public boolean tryLock(String key) { if (!StringUtils.isEmpty(key)) { key = key.toUpperCase(); synchronized (key.intern()) { if (!this.obj.containsKey(key)) { lock(key); + //鑾峰彇褰撳墠绾跨▼ + long id = Thread.currentThread().getId(); + threadObj.put(key, id); return true; } } diff --git a/product-server-web/resources/LicenseKey.dat b/product-server-web/resources/LicenseKey.dat index bf6b940..28d1a3f 100644 --- a/product-server-web/resources/LicenseKey.dat +++ b/product-server-web/resources/LicenseKey.dat @@ -1 +1 @@ -704F16B1D215BC04042005365EB2001E3324D7BEEBA9206CA1F670D493A7874D7C65C473EBDEBD0C0EF47C7DAA7F2BF77CAEEAD85E4F681748A2D3CD6A86DF628FF6A90AD4E28B7DA66B8EA0915E4F4DC5DAAC065A7B746CEE1E7533BE0918A4C79FBCDEA24B82014A01B6D8E3A52BBDAC3DAA66FE9FDE3E8D92ACB54DA1746779BBD63F16726C6330140ED5EF0D1974692C5AABA9DBB6BFE742983374187BC2C0BF118861E3A0D68EF1CCBA87CA33988FB2F40FEE7ACFF8952DDCAC47AD42976792F264AC0C6C90D698959D70638E1C38307B559BB540F0F978D3F8B663E7D59E4143B96D5A6C02E5D5086BA3858386E638D338AA4353193CF6FDCC122CF6D68768ACF82104FB2AFF7BC993427E0A2CBD0DD5F1BF735AAC085FB9987E6CA983DB4C45064137A400B6F3DA128276ED819B65241830F4C8B5E849C75F16C93A17B11FE7195A7DF875199562CBE01186A6F4E87FFFF487D09BB4D1887F23C681DB31D998DB659BD4CAB381937A188CEF2DAA2F7065D5A5D42D9697A6E6F00BA3E9 +7BAAE941D97E32ED0D3DB709586097FA3A9BBF61E20398F7ACC5C04F94F9525779220CFCE69C6A5E051BD2CEA5DBBADC79D39E9A5CDC6CF341E3E8BF6169E62583CB5D82DF7AFE36A245D2159797065DC849C4B25650EA9BE02620B4B6C852BACD276A03ACE2795F4EFFBE2FE18D2501A16742D8FC728A488D162F544B9A66D07F223933170C022537C7833AE01614E76FB42ABEA383B9E8E5B2AAEA758FA433C6A79DC5625EC63180C83868891D03318B4D16D6ED6DE8729155B69F475768AE6805EEABA38645F2DE1D0CA57A48D1143932E32F9B3CCFF1F7D3E5A2B036027A91DE7DF36CDB626EE836B389A6DBE536E7C50EB8AD05B32A3A6262F91E18A53081BB06CD2A7C6DFEFD0CFAEF4453ECEBB410C36BB35CDCAE057869517C86ED83D0E2BAFE44219C47B9FA8C668A6F7EC29C9758C530EAAF91EB886F851010F2CBB7B5D64C5C52FEAD11C192EBEF09E629F7273461FE0B88A1B3FD7ADB226F3D9D3B75FA246BCAED37B981FB891C52AFFAA6DFB07ADEF8B9059DC55C20FF3C7829 \ No newline at end of file -- Gitblit v1.9.2