diff --git a/ncep/gov.noaa.nws.ncep.staticdataprovider/src/gov/noaa/nws/ncep/staticdataprovider/ContinuingWatch.java b/ncep/gov.noaa.nws.ncep.staticdataprovider/src/gov/noaa/nws/ncep/staticdataprovider/ContinuingWatch.java index a883e9fc44..73f06d571f 100644 --- a/ncep/gov.noaa.nws.ncep.staticdataprovider/src/gov/noaa/nws/ncep/staticdataprovider/ContinuingWatch.java +++ b/ncep/gov.noaa.nws.ncep.staticdataprovider/src/gov/noaa/nws/ncep/staticdataprovider/ContinuingWatch.java @@ -43,7 +43,8 @@ import com.raytheon.uf.viz.core.requests.ThriftClient; * 08/12 #770 Q. Zhou Initial Creation. * 09/12 #770 Q. Zhou Clean up and change selectedWatch to a collection * 08/13 #1028 G. Hull rm dependency on viz.rsc.wtch project - * 12/14 ? B. Yin Remove ScriptCreator, use Thrift Client. + * 12/14 R5749 B. Yin Remove ScriptCreator, use Thrift Client. + * 12/14 R5749 B. Yin Removed try/catch block when querying. * * * @author Q. Zhou @@ -51,9 +52,6 @@ import com.raytheon.uf.viz.core.requests.ThriftClient; public class ContinuingWatch { - private static final transient IUFStatusHandler statusHandler = UFStatus - .getHandler(ContinuingWatch.class); - /* * WtchRscDataObj class */ @@ -156,25 +154,19 @@ public class ContinuingWatch { DbQueryRequest request = new DbQueryRequest(); request.setConstraints(metadataMap); - - try { - DbQueryResponse response = (DbQueryResponse) ThriftClient.sendRequest(request); - for (Map result : response.getResults()) { + DbQueryResponse response = (DbQueryResponse) ThriftClient.sendRequest(request); - for (Object pdo : result.values()) { - awwRecord = (AwwRecord) pdo; - Collection num = getAwwRecord( awwRecord ); - if (num != null && !num.isEmpty()) - contWatch.addAll( num ); - } + for (Map result : response.getResults()) { + + for (Object pdo : result.values()) { + awwRecord = (AwwRecord) pdo; + Collection num = getAwwRecord( awwRecord ); + if (num != null && !num.isEmpty()) + contWatch.addAll( num ); } } - catch (VizException e) { - statusHandler.handle(Priority.PROBLEM, e.getLocalizedMessage(), - e); - } - + //Retrieving unique items from the list Set set = new HashSet(contWatch); contWatch = new ArrayList(set);