update bug
This commit is contained in:
+15
-16
@@ -134,30 +134,29 @@ class BigdataDealBatch extends BaseBatch{
|
|||||||
|
|
||||||
for(def i=0;i<rets.size();i++){
|
for(def i=0;i<rets.size();i++){
|
||||||
final def trade = rets[i]
|
final def trade = rets[i]
|
||||||
if(dealIds.contains(trade._id.toString())){
|
|
||||||
println "重复:"+trade._id.toString() + " "+ trade.district_name
|
|
||||||
continue
|
|
||||||
}
|
|
||||||
fixedThreadPool.execute(new Runnable() {
|
fixedThreadPool.execute(new Runnable() {
|
||||||
void run() {
|
void run() {
|
||||||
try {
|
try {
|
||||||
totalCount.addAndGet(1)
|
totalCount.addAndGet(1)
|
||||||
if(source == "youda"){
|
|
||||||
|
|
||||||
def ret = converYouDaData(trade, cityCodeDatas, distCodeMap, ccbPriceMap)
|
if(dealIds.contains(trade._id.toString())){
|
||||||
if(ret){
|
println "重复:"+trade._id.toString() + " "+ trade.district_name
|
||||||
result << ret
|
|
||||||
println totalCount.get() +" 友达:"+trade.city+" "+trade.region+" "+trade.fjName+" "+new Date().toLocaleString()
|
|
||||||
}
|
|
||||||
}else{
|
}else{
|
||||||
def ret = converData(trade, cityCodeDatas, distCodeMap)
|
if(source == "youda"){
|
||||||
if(ret){
|
def ret = converYouDaData(trade, cityCodeDatas, distCodeMap, ccbPriceMap)
|
||||||
result << ret
|
if(ret){
|
||||||
println totalCount.get() +" 第三方:"+trade.city+" "+trade.region+" "+trade.district_name+" "+new Date().toLocaleString()
|
result << ret
|
||||||
|
println totalCount.get() +" 友达:"+trade.city+" "+trade.region+" "+trade.fjName+" "+new Date().toLocaleString()
|
||||||
|
}
|
||||||
|
}else{
|
||||||
|
def ret = converData(trade, cityCodeDatas, distCodeMap)
|
||||||
|
if(ret){
|
||||||
|
result << ret
|
||||||
|
println totalCount.get() +" 第三方:"+trade.city+" "+trade.region+" "+trade.district_name+" "+new Date().toLocaleString()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace()
|
e.printStackTrace()
|
||||||
} finally {
|
} finally {
|
||||||
|
|||||||
Reference in New Issue
Block a user