jianjun 4 years ago
parent
commit
0ed2222015
  1. 12
      epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/dataToIndex/impl/IndexOriginExtractServiceImpl.java
  2. 4
      epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/ExUserDao.xml

12
epmet-module/data-statistical/data-statistical-server/src/main/java/com/epmet/service/evaluationindex/extract/dataToIndex/impl/IndexOriginExtractServiceImpl.java

@ -80,6 +80,8 @@ public class IndexOriginExtractServiceImpl implements IndexOriginExtractService
private void submitJob(ExtractIndexFormDTO param) { private void submitJob(ExtractIndexFormDTO param) {
CountDownLatch countDownLatch = new CountDownLatch(2);
long start = System.currentTimeMillis();
final String customerId = param.getCustomerId(); final String customerId = param.getCustomerId();
final String monthId = param.getMonthId(); final String monthId = param.getMonthId();
threadPool.submit(() -> { threadPool.submit(() -> {
@ -87,6 +89,8 @@ public class IndexOriginExtractServiceImpl implements IndexOriginExtractService
calCpcIndexService.calCpcPartyAbility(customerId, monthId); calCpcIndexService.calCpcPartyAbility(customerId, monthId);
} catch (Exception e) { } catch (Exception e) {
log.error("抽取【党员相关数据】发生异常,参数:" + JSON.toJSONString(param), e); log.error("抽取【党员相关数据】发生异常,参数:" + JSON.toJSONString(param), e);
}finally {
countDownLatch.countDown();
} }
}); });
threadPool.submit(() -> { threadPool.submit(() -> {
@ -123,6 +127,14 @@ public class IndexOriginExtractServiceImpl implements IndexOriginExtractService
}catch (Exception e){ }catch (Exception e){
log.error("抽取【全区治理能力-全区党建能力-服务能力】发生异常,参数:" + JSON.toJSONString(param), e); log.error("抽取【全区治理能力-全区党建能力-服务能力】发生异常,参数:" + JSON.toJSONString(param), e);
} }
countDownLatch.countDown();
}); });
try {
countDownLatch.await();
} catch (InterruptedException e) {
log.error("indexOriginExtractAll countDownLatch exception", e);
}
log.warn("indexOriginExtractAll执行完毕======总耗时:{}ms,customerId:{}",System.currentTimeMillis()-start, param.getCustomerId());
} }
} }

4
epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/ExUserDao.xml

@ -33,9 +33,9 @@
</trim> </trim>
WHERE 1=1 WHERE 1=1
<foreach collection="list" item="item" open="AND( " separator=" OR " index="index" close=")"> <foreach collection="list" item="item" open="AND ( " separator=" OR " index="index" close=")">
(qx_user_id = #{item.qxUserId} ) (qx_user_id = #{item.qxUserId} )
</foreach> </foreach>
</update> </update>
</mapper> </mapper>

Loading…
Cancel
Save