Revision 46871
Added by Sandro La Bruzzo about 7 years ago
DedupFixRelationReducer.java | ||
---|---|---|
54 | 54 |
final Iterator<ImmutableBytesWritable> it = values.iterator(); |
55 | 55 |
final DNGF first = DNGFDecoder.decode(it.next().copyBytes()).getDNGF(); |
56 | 56 |
|
57 |
if (!first.getRel().getRelType().equals("merges")) { |
|
57 |
if (!first.getRel().getRelType().getClassid().equals("merges")) {
|
|
58 | 58 |
context.getCounter(COUNTER_GROUP, "Relation skipped").increment(1); |
59 |
|
|
60 |
it.forEachRemaining(b -> { |
|
61 |
try { |
|
62 |
DNGF otherRels = DNGFDecoder.decode(b.copyBytes()).getDNGF(); |
|
63 |
if (otherRels.getRel().getRelType().equals("merges")) { |
|
64 |
context.getCounter(COUNTER_GROUP, "Merges Rels not in first position").increment(1); |
|
65 |
} |
|
66 |
} catch (Exception e) { |
|
67 |
throw new RuntimeException(e); |
|
68 |
} |
|
69 |
}); |
|
70 |
|
|
71 |
|
|
72 |
|
|
73 |
|
|
74 | 59 |
return; |
75 | 60 |
} |
76 | 61 |
context.getCounter(COUNTER_GROUP, "Item to fix").increment(1); |
Also available in: Unified diff