comparison flys-aft/src/main/java/de/intevation/aft/River.java @ 4110:06891562e633

Extracted and documented the error messages of the process. flys-aft/trunk@4054 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Sascha L. Teichmann <sascha.teichmann@intevation.de>
date Thu, 16 Feb 2012 11:26:56 +0000
parents cdcf98245e36
children 79bb64f66c74
comparison
equal deleted inserted replaced
4109:8ba11e13ae8a 4110:06891562e633
53 while (messstellenRs.next()) { 53 while (messstellenRs.next()) {
54 String name = messstellenRs.getString("NAME"); 54 String name = messstellenRs.getString("NAME");
55 String num = messstellenRs.getString("MESSSTELLE_NR"); 55 String num = messstellenRs.getString("MESSSTELLE_NR");
56 Long number = SyncContext.numberToLong(num); 56 Long number = SyncContext.numberToLong(num);
57 if (number == null) { 57 if (number == null) {
58 log.warn("Invalid MESSSTELLE_NR for MESSSTELLE '"+name+"'"); 58 log.warn("AFT: Invalid MESSSTELLE_NR for MESSSTELLE '"+name+"'");
59 continue; 59 continue;
60 } 60 }
61 DIPSGauge dipsGauge = dipsGauges.get(number); 61 DIPSGauge dipsGauge = dipsGauges.get(number);
62 if (dipsGauge == null) { 62 if (dipsGauge == null) {
63 log.warn( 63 log.warn(
64 "MESSSTELLE '" + name + "' not found in DIPS. " + 64 "DIPS: MESSSTELLE '" + name + "' not found in DIPS. " +
65 "Gauge number used for lookup: " + number); 65 "Gauge number used for lookup: " + number);
66 continue; 66 continue;
67 } 67 }
68 String gaugeRiver = dipsGauge.getRiverName(); 68 String gaugeRiver = dipsGauge.getRiverName();
69 if (!gaugeRiver.equalsIgnoreCase(riverName)) { 69 if (!gaugeRiver.equalsIgnoreCase(riverName)) {
70 log.warn( 70 log.warn(
71 "MESSSTELLE '" + name + 71 "DIPS: MESSSTELLE '" + name +
72 "' is assigned to river '" + gaugeRiver + 72 "' is assigned to river '" + gaugeRiver +
73 "'. Needs to be on '" + riverName + "'."); 73 "'. Needs to be on '" + riverName + "'.");
74 continue; 74 continue;
75 } 75 }
76 dipsGauge.setAftName(name); 76 dipsGauge.setAftName(name);
252 252
253 log.info("Gauge '" + gauge.getAftName() + 253 log.info("Gauge '" + gauge.getAftName() +
254 "' not in FLYS but in AFT/DIPS. -> Create"); 254 "' not in FLYS but in AFT/DIPS. -> Create");
255 255
256 if (!gauge.hasDatums()) { 256 if (!gauge.hasDatums()) {
257 log.warn("FLYS: Gauge '" + 257 log.warn("DIPS: Gauge '" +
258 gauge.getAftName() + "' has no datum. Ignored."); 258 gauge.getAftName() + "' has no datum. Ignored.");
259 continue; 259 continue;
260 } 260 }
261 261
262 ResultSet rs = null; 262 ResultSet rs = null;

http://dive4elements.wald.intevation.org