Issue #2652. Fixed issue with edex-text-ingest log. Corrected.
Change-Id: I0064146b6b6d1c05955f513ab9eda9b6ba03de76 Former-commit-id:4786aa382b
[formerly dd0660d1b51aef2e3e703fd21c0f1d98f3484fbc] Former-commit-id:88fbcc2ca6
This commit is contained in:
parent
f08d4a827f
commit
c6f98da81c
1 changed files with 1 additions and 6 deletions
|
@ -140,13 +140,8 @@ public class StdCollectiveSeparator extends WMOMessageSeparator {
|
||||||
}
|
}
|
||||||
String rawMsg = new String(rawData, startIndex, endIndex - startIndex);
|
String rawMsg = new String(rawData, startIndex, endIndex - startIndex);
|
||||||
StringBuilder sb = null;
|
StringBuilder sb = null;
|
||||||
// This is a fake line "METXXX" to permit skipping of NNNXXX pattern
|
|
||||||
// line.
|
|
||||||
if ((rawMsg.indexOf(METAR) == 0) || (rawMsg.indexOf(SPECI) == 0)) {
|
if ((rawMsg.indexOf(METAR) == 0) || (rawMsg.indexOf(SPECI) == 0)) {
|
||||||
productType = (rawMsg.indexOf(METAR) == 0 ? METAR : SPECI);
|
productType = (rawMsg.indexOf(METAR) == 0 ? METAR : SPECI);
|
||||||
sb = new StringBuilder(rawMsg);
|
|
||||||
sb.insert(0, "METXXX\n");
|
|
||||||
rawMsg = sb.toString();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if ("TAF".equals(afos_id.getNnn())) {
|
if ("TAF".equals(afos_id.getNnn())) {
|
||||||
|
@ -161,7 +156,7 @@ public class StdCollectiveSeparator extends WMOMessageSeparator {
|
||||||
rawMsg = sb.toString();
|
rawMsg = sb.toString();
|
||||||
}
|
}
|
||||||
Matcher nnnxxxMatcher = NNNXXX.matcher(rawMsg);
|
Matcher nnnxxxMatcher = NNNXXX.matcher(rawMsg);
|
||||||
if (nnnxxxMatcher.find()) {
|
if (nnnxxxMatcher.find() && nnnxxxMatcher.start() == 0) {
|
||||||
rawMsg = rawMsg.substring(nnnxxxMatcher.end());
|
rawMsg = rawMsg.substring(nnnxxxMatcher.end());
|
||||||
}
|
}
|
||||||
StringBuilder buffer = new StringBuilder(rawMsg);
|
StringBuilder buffer = new StringBuilder(rawMsg);
|
||||||
|
|
Loading…
Add table
Reference in a new issue