From 33a2259cf464f5686cb482bd8ee1bdd963116c32 Mon Sep 17 00:00:00 2001 From: Mike Duff Date: Thu, 10 Apr 2014 13:31:42 -0500 Subject: [PATCH 001/188] Issue #2892 - Fix problems loading saved configs for data browser dialog. Change-Id: I73b98714642f5852f7209fd8533d49aa473412f9 Former-commit-id: 323badf58cf12a35b3a4d93ff0188b638e60969b --- .../datadelivery/browser/DataBrowserDlg.java | 7 +++--- .../datadelivery/filter/FilterExpandBar.java | 21 ++++++++++++---- .../filter/config/xml/FilterTypeXML.java | 24 ++++++++++++++++++- 3 files changed, 42 insertions(+), 10 deletions(-) diff --git a/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/browser/DataBrowserDlg.java b/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/browser/DataBrowserDlg.java index c529ec8b43..fe95371d7d 100644 --- a/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/browser/DataBrowserDlg.java +++ b/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/browser/DataBrowserDlg.java @@ -124,6 +124,7 @@ import com.vividsolutions.jts.geom.Coordinate; * Sep 26, 2013 2412 mpduff Handle auto selecting data type. * Sep 26, 2013 2413 mpduff Added isDirty check to New Configuration menu selection. * Oct 11, 2013 2386 mpduff Refactor DD Front end. + * Apr 10, 2014 2892 mpduff Fix problems with loading of saved configs. * * * @@ -371,7 +372,6 @@ public class DataBrowserDlg extends CaveSWTDialog implements IDataTableUpdate, @Override public void widgetSelected(SelectionEvent event) { displayLoadSaveConfigDlg(DialogType.OPEN); - setClean(); } }); @@ -970,7 +970,6 @@ public class DataBrowserDlg extends CaveSWTDialog implements IDataTableUpdate, "Selection Required", "Must make a selection before saving."); } - } else if (type == DialogType.OPEN) { setText(WINDOW_TITLE + " - (" + locFile.getFile().getName() + ")"); @@ -978,7 +977,7 @@ public class DataBrowserDlg extends CaveSWTDialog implements IDataTableUpdate, xml = fm.getXml(); updateFilters(); selectedFile = locFile.getFile().getName(); - + setClean(); } else if (type == DialogType.DELETE) { try { if (locFile != null) { @@ -1070,9 +1069,9 @@ public class DataBrowserDlg extends CaveSWTDialog implements IDataTableUpdate, int i = 0; for (String s : dataTypes) { if (s.equals(valueList.get(0))) { - i++; break; } + i++; } datatypeList.select(i); handleDataTypeSelection(); diff --git a/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/filter/FilterExpandBar.java b/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/filter/FilterExpandBar.java index 3caecb0620..55410bd8cd 100644 --- a/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/filter/FilterExpandBar.java +++ b/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/filter/FilterExpandBar.java @@ -85,7 +85,8 @@ import com.raytheon.viz.ui.widgets.duallist.DualListConfig; * Jul 05, 2013 2137 mpduff Only a single data type can be selected. * Jul 05, 2013 2138 mpduff Fixed to not use filter if filter is disabled. * Sep 26, 2013 2412 mpduff Don't create expand items if no data type is selected. - * + * Apr 10, 2014 2892 mpduff Clear selected items when changing data types. + * * * * @author lvenable @@ -93,6 +94,13 @@ import com.raytheon.viz.ui.widgets.duallist.DualListConfig; */ public class FilterExpandBar extends Composite implements IFilterUpdate, IExpandControlAction { + private final String DATA_PROVIDER = "Data Provider"; + + private final String DATA_SET = "Data Set"; + + private final String PARAMETER = "Parameter"; + + private final String LEVEL = "Level"; /** * Filter expand bar. @@ -290,10 +298,6 @@ public class FilterExpandBar extends Composite implements IFilterUpdate, * TODO : this needs to be reworked as this only has 4 display * (filters). This should be configurable. */ - final String DATA_PROVIDER = "Data Provider"; - final String DATA_SET = "Data Set"; - final String PARAMETER = "Parameter"; - final String LEVEL = "Level"; if (displayName.equals(DATA_PROVIDER)) { Set providerSet = dataManager .getAvailableDataProvidersByType(dataType); @@ -596,6 +600,13 @@ public class FilterExpandBar extends Composite implements IFilterUpdate, this.dataType = dataType; setEnvelope(envelope); disposeExpandItemsAndControls(); + + // Clear previously selected items + if (filterSettingsXml != null) { + for (FilterTypeXML xml : this.filterSettingsXml.getFilterTypeList()) { + xml.clearValues(); + } + } if (!dataType.isEmpty()) { createExpandItems(); } diff --git a/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/filter/config/xml/FilterTypeXML.java b/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/filter/config/xml/FilterTypeXML.java index 479e3e5cc8..3dbfa6a034 100644 --- a/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/filter/config/xml/FilterTypeXML.java +++ b/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/filter/config/xml/FilterTypeXML.java @@ -30,7 +30,7 @@ import javax.xml.bind.annotation.XmlElements; import com.raytheon.uf.viz.datadelivery.common.xml.IDisplayXml; /** - * Filter Type Definition object. + * Filter Type Definition object. Stores the filter type and values. * *
  * 
@@ -40,6 +40,7 @@ import com.raytheon.uf.viz.datadelivery.common.xml.IDisplayXml;
  * ------------ ---------- ----------- --------------------------
  * Jan 30, 2012            mpduff      Initial creation.
  * Jun 04, 2013            mpduff      Changed method name.
+ * Apr 10, 2014   2892     mpduff      Added javadoc comments and toString
  * 
  * 
* @@ -49,9 +50,11 @@ import com.raytheon.uf.viz.datadelivery.common.xml.IDisplayXml; @XmlAccessorType(XmlAccessType.NONE) public class FilterTypeXML implements IDisplayXml { + /** Type of filter */ @XmlAttribute(name = "type") protected String filterType; + /** Selected filter values */ @XmlElements({ @XmlElement(name = "Value", type = String.class) }) protected ArrayList values = new ArrayList(); @@ -89,6 +92,9 @@ public class FilterTypeXML implements IDisplayXml { this.values.add(value); } + /** + * Clear the selected values. + */ public void clearValues() { this.values.clear(); } @@ -113,4 +119,20 @@ public class FilterTypeXML implements IDisplayXml { return sb.toString(); } + + /* + * (non-Javadoc) + * + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append(this.filterType).append("||"); + for (String s : values) { + sb.append(s).append(" "); + } + + return sb.toString(); + } } From 81c4976c96b755ae180e09c1e1d88ef67b9709aa Mon Sep 17 00:00:00 2001 From: Matt Nash Date: Thu, 10 Apr 2014 14:47:42 -0500 Subject: [PATCH 002/188] Issue #2241 fix tear off menus in practice mode Change-Id: I52a2e9be64bff8a044b148666b7ad77670a6f64e Former-commit-id: 391655cd6a84c6cbf31e711ec5e1aa92833db896 --- .../META-INF/MANIFEST.MF | 3 ++- .../widgets/tearoff/MenuItemComposite.java | 18 +++++++++++------- 2 files changed, 13 insertions(+), 8 deletions(-) diff --git a/cave/com.raytheon.uf.viz.ui.menus/META-INF/MANIFEST.MF b/cave/com.raytheon.uf.viz.ui.menus/META-INF/MANIFEST.MF index f434922183..c4d8ab8033 100644 --- a/cave/com.raytheon.uf.viz.ui.menus/META-INF/MANIFEST.MF +++ b/cave/com.raytheon.uf.viz.ui.menus/META-INF/MANIFEST.MF @@ -13,7 +13,8 @@ Require-Bundle: org.eclipse.ui, com.raytheon.viz.ui, com.raytheon.uf.common.serialization, com.raytheon.uf.viz.core, - com.raytheon.uf.common.menus;bundle-version="1.0.0";visibility:=reexport + com.raytheon.uf.common.menus;bundle-version="1.0.0";visibility:=reexport, + com.raytheon.viz.core;bundle-version="1.12.1174" Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Bundle-ActivationPolicy: lazy Import-Package: com.raytheon.uf.common.localization, diff --git a/cave/com.raytheon.uf.viz.ui.menus/src/com/raytheon/uf/viz/ui/menus/widgets/tearoff/MenuItemComposite.java b/cave/com.raytheon.uf.viz.ui.menus/src/com/raytheon/uf/viz/ui/menus/widgets/tearoff/MenuItemComposite.java index 8a07838533..92be15d958 100644 --- a/cave/com.raytheon.uf.viz.ui.menus/src/com/raytheon/uf/viz/ui/menus/widgets/tearoff/MenuItemComposite.java +++ b/cave/com.raytheon.uf.viz.ui.menus/src/com/raytheon/uf/viz/ui/menus/widgets/tearoff/MenuItemComposite.java @@ -53,6 +53,7 @@ import org.eclipse.ui.menus.CommandContributionItem; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.viz.ui.menus.widgets.tearoff.TearOffMenuDialog.MenuPathElement; +import com.raytheon.viz.core.mode.CAVEMode; /** * Holds the information for all the menu items in the dialog @@ -65,7 +66,8 @@ import com.raytheon.uf.viz.ui.menus.widgets.tearoff.TearOffMenuDialog.MenuPathEl * ------------ ---------- ----------- -------------------------- * Sep 15, 2011 mnash Initial creation * Apr 10, 2013 DR 15185 D. Friedman Preserve tear-offs over perspective switches. - * Jev 26, 2014 2842 mpduff Utilize the command listener. + * Feb 26, 2014 2842 mpduff Utilize the command listener. + * Apr 10, 2014 2241 mnash Fix in practice mode, fixed the new month, Jev * * * @@ -106,6 +108,8 @@ public class MenuItemComposite extends Composite { /** Disabled color */ private final Color disabledColor; + private final Color backgroundColor = CAVEMode.getBackgroundColor(); + /** * @param parent * @param style @@ -256,9 +260,7 @@ public class MenuItemComposite extends Composite { setForeground(enabledColor); } else { setForeground(disabledColor); - setBackground(Display.getCurrent() - .getSystemColor( - SWT.COLOR_WIDGET_BACKGROUND)); + setBackground(backgroundColor); // changes the arrow image to the unhighlighted // version @@ -334,7 +336,9 @@ public class MenuItemComposite extends Composite { @Override public void setBackground(Color color) { firstItem.setBackground(color); - secondItem.setBackground(color); + if (secondItem != null) { + secondItem.setBackground(color); + } super.setBackground(color); } @@ -435,8 +439,8 @@ public class MenuItemComposite extends Composite { // and foreground, so we set that here, this is to // unhighlight the whole thing if (item.isEnabled()) { - setBackground(Display.getCurrent().getSystemColor( - SWT.COLOR_WIDGET_BACKGROUND)); + + setBackground(backgroundColor); setForeground(Display.getCurrent().getSystemColor( SWT.COLOR_WIDGET_FOREGROUND)); From b4e353332b10d2a9f4b2f940930ded7b26119b8b Mon Sep 17 00:00:00 2001 From: Everett Kladstrup Date: Thu, 10 Apr 2014 17:12:35 -0500 Subject: [PATCH 003/188] Issue #2725 Adding user/site derivparam migrate script Former-commit-id: 8c37f0716051384e6364ffa30a6dd0a4649fb96b --- deltaScripts/14.3.1/moveDerivedParameters.sh | 38 ++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100755 deltaScripts/14.3.1/moveDerivedParameters.sh diff --git a/deltaScripts/14.3.1/moveDerivedParameters.sh b/deltaScripts/14.3.1/moveDerivedParameters.sh new file mode 100755 index 0000000000..75d6403b3b --- /dev/null +++ b/deltaScripts/14.3.1/moveDerivedParameters.sh @@ -0,0 +1,38 @@ +#!/bin/bash +# This script will move any non-base derived parameter functions and definitions +# from cave_static to common_static. +# +# This update is required with 14.3.1. +# + +echo "INFO: Moving all derived parameter definitions and functions to common_static." + +IFS=$'\n' +# LEVEL NAME +definitionFiles=`find /awips2/edex/data/utility/cave_static/*/*/derivedParameters/definitions/ -maxdepth 1 -iname '*.xml'` +functionFiles=`find /awips2/edex/data/utility/cave_static/*/*/derivedParameters/functions/ -maxdepth 1 -iname '*.py'` + +for f in $definitionFiles; do + newf=${f//cave_static/common_static} + if [ -e "$newf" ]; then + echo cannot upgrade $f because $newf already exists + else + mkdir -p `dirname $newf` + #echo "moving $f" + mv "$f" "$newf" + fi +done + +for f in $functionFiles; do + newf=${f//cave_static/common_static} + if [ -e "$newf" ]; then + echo cannot upgrade $f because $newf already exists + else + mkdir -p `dirname $newf` + #echo "moving $f" + mv "$f" "$newf" + fi +done + +echo "INFO: The update finished successfully." +exit 0 From 069acec611e0b14ccb29c852e7aa1b88aa4040a7 Mon Sep 17 00:00:00 2001 From: Mike Duff Date: Thu, 10 Apr 2014 15:18:34 -0500 Subject: [PATCH 004/188] Issue #2675 - Change GAFF to be called from Quartz. Added spring file. Change-Id: I38f2890097e074cc42735657855ffff97a455707 Former-commit-id: c75780f9e3c7b9a5447b0f72b11e42a3c8dce68b --- .../res/spring/gaff-spring.xml | 37 +++++++++ .../com.raytheon.uf.edex.ohd.properties | 1 + .../uf/edex/ohd/pproc/DecodeDpaSrv.java | 7 +- .../com/raytheon/uf/edex/ohd/pproc/GAFF.java | 79 +++++-------------- 4 files changed, 60 insertions(+), 64 deletions(-) create mode 100644 edexOsgi/com.raytheon.uf.edex.ohd/res/spring/gaff-spring.xml diff --git a/edexOsgi/com.raytheon.uf.edex.ohd/res/spring/gaff-spring.xml b/edexOsgi/com.raytheon.uf.edex.ohd/res/spring/gaff-spring.xml new file mode 100644 index 0000000000..4cd2665193 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.ohd/res/spring/gaff-spring.xml @@ -0,0 +1,37 @@ + + + + + + + + + + + + + + + + + + + + + java.lang.Throwable + + + + + + + + + + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.ohd/resources/com.raytheon.uf.edex.ohd.properties b/edexOsgi/com.raytheon.uf.edex.ohd/resources/com.raytheon.uf.edex.ohd.properties index 338b02fdbd..134228a79e 100644 --- a/edexOsgi/com.raytheon.uf.edex.ohd/resources/com.raytheon.uf.edex.ohd.properties +++ b/edexOsgi/com.raytheon.uf.edex.ohd/resources/com.raytheon.uf.edex.ohd.properties @@ -10,3 +10,4 @@ arealqpegen.cron=0+10,25,40,55+*+*+*+? dqcpreprocessor.cron=0+20+0,6,12,18+*+*+? mpelightningsrv.cron=0+0/30+*+*+*+? freezingLevel.cron=0+5+2,8,14,20+*+*+? +gaff.cron=0+0/12+*+*+*+? diff --git a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/DecodeDpaSrv.java b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/DecodeDpaSrv.java index 8814a53a69..1a536360fb 100644 --- a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/DecodeDpaSrv.java +++ b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/DecodeDpaSrv.java @@ -51,6 +51,7 @@ import com.raytheon.uf.edex.ohd.MainMethod; * Mar 20, 2013 1804 bsteffen Switch all radar decompressing to be in * memory. * Mar 28, 2014 2952 mpduff Changed to use UFStatus for logging. + * Apr 10, 2014 2675 mpduff Removed call to GAFF. * * * @@ -82,12 +83,6 @@ public class DecodeDpaSrv { return null; } - // Run GAFF - GAFF gaff = new GAFF(); - if (gaff.shouldGAFFRun()) { - gaff.process(); - } - String path = appsDefaults.getToken("pproc_bin"); int exitValue = MainMethod.runProgram("ksh", path + "/Run_DecodeDPA", outFile.getAbsolutePath()); diff --git a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/GAFF.java b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/GAFF.java index 78a8b3fd72..24c61a89e3 100644 --- a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/GAFF.java +++ b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/GAFF.java @@ -46,6 +46,7 @@ import com.raytheon.uf.common.ohd.AppsDefaults; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; +import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.edex.database.DataAccessLayerException; import com.raytheon.uf.edex.database.plugin.PluginDao; import com.raytheon.uf.edex.database.plugin.PluginFactory; @@ -63,6 +64,7 @@ import com.vividsolutions.jts.geom.Coordinate; * Jan 5, 2011 mpduff Initial creation * Sep 5, 2013 16437 wkwock Fix the "HiRes" issue * Mar 28, 2014 2952 mpduff Changed to use UFStatus for logging. + * Apr 10, 2014 2675 mpduff Modified to be called from quartz timer. * * * @@ -135,11 +137,6 @@ public class GAFF { */ private String hsa = "XXX"; - /** - * Time of last run in millis. - */ - private long lastRunTime = 0; - /** * The previous Duration */ @@ -165,12 +162,6 @@ public class GAFF { */ private Rectangle wfoExtent = null; - /** Process start time */ - private final long start; - - /** Process end time */ - private long end; - private final GAFFDB db = new GAFFDB(); /** RFC Site name to RFC lookup map */ @@ -210,42 +201,18 @@ public class GAFF { } public GAFF() { - start = Calendar.getInstance().getTimeInMillis(); - log.debug("GAFF process is starting"); - - init(); - if (log.isPriorityEnabled(Priority.DEBUG)) { - log.debug(toString()); - } } private void init() { - // Only run every 12 minutes - this.lastRunTime = db.getLastRunTime(PROCESS_NAME); - getTokens(); this.hsa = db.getHsa(); } - public boolean shouldGAFFRun() { - // Only run every 12 minutes - final int minutesBetweenRuns = 12; - - Calendar cal = Calendar.getInstance(TimeZone.getTimeZone("GMT")); - if (cal.getTimeInMillis() - this.lastRunTime < minutesBetweenRuns * 60 * 1000) { - if (log.isPriorityEnabled(Priority.DEBUG)) { - float time = (cal.getTimeInMillis() - this.lastRunTime) / 1000 / 60; - log.debug("Only run every 12 minutes. " + time - + " minutes since last run."); - } - return false; - } - - return true; - } - public void process() { + long start = TimeUtil.currentTimeMillis(); + log.info("GAFF process starting"); + init(); Rectangle extent; HRAP hrap; HRAPSubGrid subGrid; @@ -268,12 +235,12 @@ public class GAFF { /* write record to PerfLog table */ try { - db.insertPerflog(PROCESS_NAME, this.start); + db.insertPerflog(PROCESS_NAME, start); } catch (DataAccessLayerException e) { log.error("Error updating perflog table", e); } - end = Calendar.getInstance().getTimeInMillis(); + long end = TimeUtil.currentTimeMillis(); log.info("GAFF Process complete in " + (end - start) + " millis"); } @@ -289,14 +256,13 @@ public class GAFF { */ private void createFFGMosaic(int dur, HRAP hrap, HRAPSubGrid subGrid) { - Calendar cal = Calendar.getInstance(TimeZone.getTimeZone("GMT")); - SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); - cal.set(Calendar.HOUR, 0); - cal.set(Calendar.HOUR_OF_DAY, 0); - cal.set(Calendar.MINUTE, 0); - cal.set(Calendar.SECOND, 0); - cal.set(Calendar.MILLISECOND, 0); - String today = sdf.format(cal.getTime()); + Calendar cal = TimeUtil.newGmtCalendar(); + TimeUtil.minCalendarFields(cal, Calendar.HOUR, Calendar.HOUR_OF_DAY, + Calendar.MINUTE, Calendar.SECOND, Calendar.MILLISECOND); + ThreadLocal sdf = TimeUtil + .buildThreadLocalSimpleDateFormat("yyyy-MM-dd HH:mm:ss", + TimeZone.getTimeZone("GMT")); + String today = sdf.get().format(cal.getTime()); String uri = null; IDataRecord dataRec; Rectangle rfcExtent = null; @@ -378,7 +344,6 @@ public class GAFF { dataRec = dataStore.retrieve(uri, "Data", Request.ALL); if (dataRec instanceof FloatDataRecord) { - // gridList.add(((FloatDataRecord) dataRec).getFloatData()); gridMap.put(rfc, ((FloatDataRecord) dataRec).getFloatData()); } @@ -444,7 +409,6 @@ public class GAFF { wfoExtent.width, this.mosaicFfgShort, minArea, dur, grReftime.getTime()); areaProcessor.processAreas(); - } } @@ -519,21 +483,20 @@ public class GAFF { public String toString() { StringBuilder sb = new StringBuilder( "***********************************\n"); - sb.append("siteId = " + this.siteId); - sb.append("\nmosaicDir = " + this.mosaicDir); - sb.append("\nlookbackLimit = " + this.lookbackLimit); - sb.append("\nminArea = " + this.minArea); + sb.append("siteId = ").append(this.siteId); + sb.append("\nmosaicDir = ").append(this.mosaicDir); + sb.append("\nlookbackLimit = ").append(this.lookbackLimit); + sb.append("\nminArea = ").append(this.minArea); sb.append("\nRFC Names"); for (String s : rfcNames) { - sb.append("\n " + s); + sb.append("\n ").append(s); } sb.append("\nDurations"); for (int i : this.durations) { - sb.append("\n " + i); + sb.append("\n ").append(i); } - sb.append("\nLast run time = " + this.lastRunTime); - sb.append("\nHSA = " + this.hsa); + sb.append("\nHSA = ").append(this.hsa); return sb.toString(); } From 1dce366e885ab9c3dcc7523b61cd25277daeb112 Mon Sep 17 00:00:00 2001 From: Slav Korolev Date: Mon, 7 Apr 2014 14:54:57 -0400 Subject: [PATCH 005/188] Issue #2971 - Added condition to avoid malformed parts in the message. Change-Id: Ic8e7351faad4e1b65939d568d307ec5a4789f4ec Former-commit-id: 4afbf3339470bec70c0cb958a0379c48c6103fd3 --- .../edex_static/base/distribution/warning.xml | 2 +- .../uf/edex/plugin/svrwx/SvrWxDecoder.java | 14 +- .../uf/edex/plugin/svrwx/SvrWxRecordDao.java | 48 +++++-- .../plugin/svrwx/decoder/InternalReport.java | 50 +++++-- .../plugin/svrwx/decoder/InternalType.java | 21 ++- .../plugin/svrwx/decoder/SvrWxParser.java | 122 +++++++++++++----- 6 files changed, 181 insertions(+), 76 deletions(-) diff --git a/edexOsgi/com.raytheon.edex.plugin.warning/utility/edex_static/base/distribution/warning.xml b/edexOsgi/com.raytheon.edex.plugin.warning/utility/edex_static/base/distribution/warning.xml index 0b937ed0e5..d874dc71b2 100644 --- a/edexOsgi/com.raytheon.edex.plugin.warning/utility/edex_static/base/distribution/warning.xml +++ b/edexOsgi/com.raytheon.edex.plugin.warning/utility/edex_static/base/distribution/warning.xml @@ -22,5 +22,5 @@ ^(W[FGHOTUW]|FZ)[ACHKMPU][AHKQSWY].* ^(WT)(NT|PZ)\d{2} KNHC.* ^(WTP)A\d{2} PHFO.* - ^(NWU)S\d{2} KWNS.* + ^NWUS([13-9]\\d|2[1-9]) KWNS.* diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/SvrWxDecoder.java b/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/SvrWxDecoder.java index dd330a6aed..5064aa7b24 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/SvrWxDecoder.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/SvrWxDecoder.java @@ -22,17 +22,16 @@ package com.raytheon.uf.edex.plugin.svrwx; import java.util.ArrayList; import java.util.List; -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; - import com.raytheon.edex.esb.Headers; import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.common.dataplugin.svrwx.SvrWxRecord; import com.raytheon.uf.common.pointdata.PointDataDescription; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.edex.plugin.svrwx.decoder.SvrWxParser; /** - * + * SvrWx Decoder. * *
  * 
@@ -47,7 +46,8 @@ import com.raytheon.uf.edex.plugin.svrwx.decoder.SvrWxParser;
  * @version 1.0
  */
 public class SvrWxDecoder {
-    private Log logger = LogFactory.getLog(getClass());
+    private static IUFStatusHandler logger = UFStatus
+            .getHandler(SvrWxDecoder.class);
 
     private final String pluginName;
 
@@ -84,10 +84,11 @@ public class SvrWxDecoder {
     }
 
     /**
+     * Decoded input data.
      * 
      * @param data
      * @param headers
-     * @return
+     * @return decodedData
      */
     public PluginDataObject[] decode(byte[] data, Headers headers) {
 
@@ -131,7 +132,6 @@ public class SvrWxDecoder {
             logger.info(traceId + "- No data in file");
             decodedData = new PluginDataObject[0];
         }
-
         return decodedData;
     }
 
diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/SvrWxRecordDao.java b/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/SvrWxRecordDao.java
index 2bcab3d194..f13f3613b6 100644
--- a/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/SvrWxRecordDao.java
+++ b/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/SvrWxRecordDao.java
@@ -26,33 +26,35 @@ import com.raytheon.uf.common.dataplugin.svrwx.SvrWxRecord;
 import com.raytheon.uf.edex.database.DataAccessLayerException;
 import com.raytheon.uf.edex.pointdata.PointDataPluginDao;
 
-
 /**
- * 
+ * SvrWxRecord Dao
  * 
  * 
- *
+ * 
  * SOFTWARE HISTORY
- *
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Jan 4, 2010            jsanchez     Initial creation
- *
+ * 
+ * Date          Ticket#    Engineer    Description
+ * ------------  ---------- ----------- --------------------------
+ * Jan  4, 2010            jsanchez     Initial creation
+ * Apr 10, 2014  2971      skorolev     Cleaned code.
+ * 
  * 
- * + * * @author jsanchez - * @version 1.0 + * @version 1.0 */ public class SvrWxRecordDao extends PointDataPluginDao { /** - * Creates a new TropicalCycloneGuidanceDao - * @throws PluginException + * Creates a new TropicalCycloneGuidance Dao + * + * @param pluginName + * @throws PluginException */ public SvrWxRecordDao(String pluginName) throws PluginException { super(pluginName); } - + /** * Retrieves an tcg report using the datauri . * @@ -73,6 +75,7 @@ public class SvrWxRecordDao extends PointDataPluginDao { } return report; } + /** * Queries for to determine if a given data uri exists on the tcg table. * @@ -91,16 +94,35 @@ public class SvrWxRecordDao extends PointDataPluginDao { return results; } + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.edex.pointdata.PointDataPluginDao#getKeysRequiredForFileName + * () + */ @Override public String[] getKeysRequiredForFileName() { return new String[] { "dataTime.refTime" }; } + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.edex.pointdata.PointDataPluginDao#getPointDataFileName + * (com.raytheon.uf.common.dataplugin.PluginDataObject) + */ @Override public String getPointDataFileName(SvrWxRecord p) { return "svrwx.h5"; } + /* + * (non-Javadoc) + * + * @see com.raytheon.uf.edex.pointdata.PointDataPluginDao#newObject() + */ @Override public SvrWxRecord newObject() { return new SvrWxRecord(); diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/decoder/InternalReport.java b/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/decoder/InternalReport.java index 171e14e8aa..9590aa732f 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/decoder/InternalReport.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/decoder/InternalReport.java @@ -28,11 +28,11 @@ import java.util.List; import java.util.regex.Matcher; import java.util.regex.Pattern; -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; /** - * TODO Add Description + * Internal Report * *
  * 
@@ -41,6 +41,7 @@ import org.apache.commons.logging.LogFactory;
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
  * Jan 10, 2010            jsanchez     Initial creation
+ * Apr 10, 2014  2971      skorolev     Cleaned code.
  * 
  * 
* @@ -49,10 +50,14 @@ import org.apache.commons.logging.LogFactory; */ public class InternalReport { - private static Log logger = LogFactory.getLog(InternalReport.class); + private static IUFStatusHandler logger = UFStatus + .getHandler(InternalReport.class); public static final String REPORT_TYPE_LN = "^((.*)(TORNADO REPORTS|LRG HAIL/STRONG WIND RPTS|OTHER SEVERE REPORTS)(.*))"; + private static final Pattern REPORT_TYPE_LN_PTRN = Pattern + .compile(REPORT_TYPE_LN); + public static final String EVENT_KEY = "(\\*TORN|WNDG|([AG]\\s{0,1}\\d{2,3}))"; public static final String TIME = "(\\d{1,2}/\\d{4,4})"; @@ -60,6 +65,8 @@ public class InternalReport { public static final String EVENT_LN = "^((.*)" + EVENT_KEY + "(.*)" + TIME + ")"; + private static final Pattern EVENT_LN_PTRN = Pattern.compile(EVENT_LN); + public static final String LATLON = "(\\d{4,4}\\s{0,1}\\d{4,5})"; public static final String STATIONID = "(\\w{3,3}/\\w{3,3})"; @@ -67,23 +74,35 @@ public class InternalReport { public static final String RMK_LN = "^((.*)" + STATIONID + "(.*)" + LATLON + ")"; + private static final Pattern RMK_LN_PTRN = Pattern.compile(RMK_LN); + public static final String REFTIME = "(\\d{2,2}CST\\s\\w{3,3}\\s\\w{3,3}\\s{1,2}\\d{1,2}\\s{1,2}\\d{4,4})"; public static final String TIME_RANGE_LN = "^((.*)FOR\\s" + REFTIME + "\\sTHRU\\s" + REFTIME + ")"; + private static final Pattern TIME_RANGE_LN_PTRN = Pattern + .compile(TIME_RANGE_LN); + private final InternalType lineType; private final String reportLine; private List subLines = null; + /** + * + * @param type + * @param line + */ public InternalReport(InternalType type, String line) { lineType = type; reportLine = line; } /** + * Get Line Type. + * * @return the lineType */ public InternalType getLineType() { @@ -91,6 +110,8 @@ public class InternalReport { } /** + * Get Report Line. + * * @return the reportLine */ public String getReportLine() { @@ -98,6 +119,7 @@ public class InternalReport { } /** + * Get SubLines. * * @return */ @@ -141,21 +163,23 @@ public class InternalReport { return sb.toString(); } + /** + * Message identification. + * + * @param message + * @return + */ public static List identifyMessage(byte[] message) { List reports = new ArrayList(); List lines = separateLines(message); if (lines != null) { - Pattern p1 = Pattern.compile(REPORT_TYPE_LN); - Pattern p2 = Pattern.compile(EVENT_LN); - Pattern p3 = Pattern.compile(RMK_LN); - Pattern p4 = Pattern.compile(TIME_RANGE_LN); - InternalType t1 = InternalType.REPORT_TYPE; InternalType t2 = InternalType.EVENT_LN; InternalType t3 = InternalType.REMARKS; InternalType t4 = InternalType.TIME_RANGE; - Pattern patterns[] = { p1, p2, p3, p4 }; + Pattern patterns[] = { REPORT_TYPE_LN_PTRN, EVENT_LN_PTRN, + RMK_LN_PTRN, TIME_RANGE_LN_PTRN }; InternalType types[] = { t1, t2, t3, t4 }; boolean found; for (String s : lines) { @@ -169,25 +193,23 @@ public class InternalReport { break; } } - if (!found) { InternalReport rptLine = new InternalReport( InternalType.EXTRA, s); reports.add(rptLine); } } - InternalReport rptLine = new InternalReport(InternalType.END, ""); reports.add(rptLine); - } return reports; } /** + * Separate Lines. * * @param message - * @return + * @return reportLines */ private static List separateLines(byte[] message) { List reportLines = null; diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/decoder/InternalType.java b/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/decoder/InternalType.java index bb9f69283c..6b42c1115a 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/decoder/InternalType.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/decoder/InternalType.java @@ -18,27 +18,24 @@ * further licensing information. **/ package com.raytheon.uf.edex.plugin.svrwx.decoder; + /** - * TODO Add Description + * Internal Line Type. * *
- *
+ * 
  * SOFTWARE HISTORY
- *
+ * 
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
  * Jan 05, 2010            jsanchez     Initial creation
- *
+ * Apr 10, 2014            skorolev     Cleaned code.
+ * 
  * 
- * + * * @author jsanchez - * @version 1.0 + * @version 1.0 */ public enum InternalType { - TIME_RANGE, - REPORT_TYPE, - EVENT_LN, - REMARKS, - EXTRA, - END; + TIME_RANGE, REPORT_TYPE, EVENT_LN, REMARKS, EXTRA, END, WRONG_LN; } diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/decoder/SvrWxParser.java b/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/decoder/SvrWxParser.java index 5497f0825c..0e858b18b9 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/decoder/SvrWxParser.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/src/com/raytheon/uf/edex/plugin/svrwx/decoder/SvrWxParser.java @@ -29,9 +29,6 @@ import java.util.TimeZone; import java.util.regex.Matcher; import java.util.regex.Pattern; -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; - import com.raytheon.edex.esb.Headers; import com.raytheon.uf.common.dataplugin.PluginException; import com.raytheon.uf.common.dataplugin.svrwx.SvrWxRecord; @@ -39,12 +36,14 @@ import com.raytheon.uf.common.pointdata.PointDataContainer; import com.raytheon.uf.common.pointdata.PointDataDescription; import com.raytheon.uf.common.pointdata.PointDataView; import com.raytheon.uf.common.pointdata.spatial.SurfaceObsLocation; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.time.DataTime; import com.raytheon.uf.edex.plugin.svrwx.SvrWxRecordDao; import com.raytheon.uf.edex.wmo.message.WMOHeader; /** - * + * SvrWx Parser * *
  * 
@@ -53,6 +52,7 @@ import com.raytheon.uf.edex.wmo.message.WMOHeader;
  * ------------ ---------- ----------- --------------------------
  * Jan 04, 2010            jsanchez    Initial creation
  * Aug 30, 2013 2298       rjpeter     Make getPluginName abstract
+ * Apr 07, 2014 2971       skorolev    Add condition to avoid malformed parts in the message.
  * 
  * 
* @@ -62,7 +62,8 @@ import com.raytheon.uf.edex.wmo.message.WMOHeader; public class SvrWxParser { /** The logger */ - private final Log logger = LogFactory.getLog(getClass()); + private static IUFStatusHandler logger = UFStatus + .getHandler(SvrWxParser.class); private final PointDataDescription pointDataDescription; @@ -108,6 +109,26 @@ public class SvrWxParser { private static final HashMap MONTH_MAP = new HashMap(); + /** List of lines with non-parsed location. */ + private List badLines; + + private static final Pattern EVENT_KEY_PTRN = Pattern + .compile(InternalReport.EVENT_KEY); + + private static final Pattern DATE_TIME_PTRN = Pattern + .compile(InternalReport.TIME); + + private static final Pattern LAT_LON_PTRN = Pattern + .compile(InternalReport.LATLON); + + private static final Pattern STATION_ID_PTRN = Pattern + .compile(InternalReport.STATIONID); + + private static final Pattern yearPtrn = Pattern.compile("\\d{4,4}"); + + private static final Pattern monthPtrn = Pattern + .compile("(JAN|FEB|MAR|APR|MAY|JUN|JUL|AUG|SEP|OCT|NOV|DEC)"); + static { MONTH_MAP.put("JAN", 1); MONTH_MAP.put("FEB", 2); @@ -124,10 +145,11 @@ public class SvrWxParser { } /** + * SvrWx Parser. * - * @param message - * @param wmoHeader + * @param dao * @param pdd + * @param name */ public SvrWxParser(SvrWxRecordDao dao, PointDataDescription pdd, String name) { pointDataDescription = pdd; @@ -143,13 +165,26 @@ public class SvrWxParser { * Raw message data. * @param traceId * Trace id for this data. + * @param headers */ public void setData(byte[] message, String traceId, Headers headers) { currentReport = -1; + badLines = new ArrayList(); this.traceId = traceId; wmoHeader = new WMOHeader(message, headers); if (wmoHeader != null) { reports = findReports(message); + if (!badLines.isEmpty()) { + StringBuilder warnMsg = new StringBuilder("Message "); + warnMsg.append(wmoHeader); + warnMsg.append(" skipped lines:"); + for (String s : badLines) { + warnMsg.append("\nUnrecognized location: "); + warnMsg.append(s); + } + logger.warn(warnMsg.toString()); + badLines.clear(); + } } else { logger.error(traceId + "- Missing or invalid WMOHeader"); } @@ -193,7 +228,6 @@ public class SvrWxParser { } else { report = reports.get(currentReport++); logger.debug("Getting report " + report); - try { report.constructDataURI(); if (URI_MAP.containsKey(report.getDataURI())) { @@ -227,6 +261,7 @@ public class SvrWxParser { } /** + * Gets Container * * @param obsData * @return @@ -243,9 +278,10 @@ public class SvrWxParser { } /** + * Collect Reports from svrWx Records. * - * @param start - * @return + * @param message + * @return reports */ private List findReports(byte[] message) { @@ -261,7 +297,8 @@ public class SvrWxParser { parseTimeRangeLine(rpt.getReportLine()); break; case REPORT_TYPE: - if ((reportType != null) && (eventKey != null)) { + if ((reportType != null && eventKey != null) + && isStationOk()) { SurfaceObsLocation location = new SurfaceObsLocation( stationId); location.setLongitude(longitude.doubleValue()); @@ -278,7 +315,8 @@ public class SvrWxParser { clearData(); break; case EVENT_LN: - if ((reportType != null) && (eventKey != null)) { + if ((reportType != null && eventKey != null) + && isStationOk()) { SurfaceObsLocation location = new SurfaceObsLocation( stationId); location.setLongitude(longitude.doubleValue()); @@ -303,9 +341,13 @@ public class SvrWxParser { if ((s.length() != 0) && (remarks != null)) { remarks += " " + s; } + if (s.length() != 0 && eventKey != null && !isStationOk()) { + badLines.add(s); + } break; case END: - if ((reportType != null) && (eventKey != null)) { + if ((reportType != null && eventKey != null) + && isStationOk()) { SurfaceObsLocation location = new SurfaceObsLocation( stationId); location.setLongitude(longitude.doubleValue()); @@ -327,26 +369,29 @@ public class SvrWxParser { return reports; } + /** + * Parse Time Range Line. + * + * @param timeRangeLine + */ private void parseTimeRangeLine(String timeRangeLine) { - Pattern yearPtrn = Pattern.compile("\\d{4,4}"); - Pattern monthPtrn = Pattern - .compile("(JAN|FEB|MAR|APR|MAY|JUN|JUL|AUG|SEP|OCT|NOV|DEC)"); - Matcher m = monthPtrn.matcher(timeRangeLine); if (m.find()) { month = MONTH_MAP.get(m.group()); } - m = yearPtrn.matcher(timeRangeLine); if (m.find()) { year = Integer.parseInt(m.group()); } } + /** + * Parse Event Key Line. + * + * @param eventKeyLine + */ private void parseEventKeyLine(String eventKeyLine) { - Pattern eventKeyPtrn = Pattern.compile(InternalReport.EVENT_KEY); - Pattern dateTimePtrn = Pattern.compile(InternalReport.TIME); - Matcher m = eventKeyPtrn.matcher(eventKeyLine); + Matcher m = EVENT_KEY_PTRN.matcher(eventKeyLine); if (m.find()) { String type = m.group(); if (type.equals(TORN)) { @@ -360,10 +405,9 @@ public class SvrWxParser { eventKey = type.replace(" ", ""); reportType = "A"; } - } - m = dateTimePtrn.matcher(eventKeyLine); + m = DATE_TIME_PTRN.matcher(eventKeyLine); if (m.find()) { String time = m.group(); greenTime = time.replace("/", "."); @@ -383,18 +427,19 @@ public class SvrWxParser { cal.set(Calendar.MILLISECOND, 0); cal.setTimeZone(TimeZone.getTimeZone("GMT")); refTime = new DataTime(cal); - } else { refTime = null; } } + /** + * Parse Remarks Line. + * + * @param remarksLine + */ private void parseRemarksLine(String remarksLine) { - Pattern latLonPtrn = Pattern.compile(InternalReport.LATLON); - Pattern stationIdPtrn = Pattern.compile(InternalReport.STATIONID); - - Matcher m = latLonPtrn.matcher(remarksLine); + Matcher m = LAT_LON_PTRN.matcher(remarksLine); if (m.find()) { String latLon = m.group(); String latStr = latLon.substring(0, 4); @@ -403,7 +448,7 @@ public class SvrWxParser { longitude = Float.parseFloat(lonStr) / -100; } - m = stationIdPtrn.matcher(remarksLine); + m = STATION_ID_PTRN.matcher(remarksLine); if (m.find()) { stationId = m.group(); } @@ -414,6 +459,9 @@ public class SvrWxParser { } } + /** + * Clear SvrWx Record. + */ private void clearData() { eventKey = null; refTime = null; @@ -424,6 +472,11 @@ public class SvrWxParser { greenTime = null; } + /** + * Get details of SvrWx Record. + * + * @return details + */ private String getDetails() { String details = eventKey + " " + greenTime + ":"; if (stationId != null) { @@ -432,4 +485,15 @@ public class SvrWxParser { details += " " + remarks; return details; } + + /** + * Checks if parsed location is valid. If it returns false it indicates the + * station or latitude/longitude was not parsed from the product since it + * didn't match. + * + * @return true if location is valid. + */ + private boolean isStationOk() { + return longitude != null && latitude != null && stationId != null; + } } From 3bae8533607d01c5d431a8260365e2fa2da7d1ac Mon Sep 17 00:00:00 2001 From: "Qinglu.Lin" Date: Fri, 11 Apr 2014 12:22:04 -0400 Subject: [PATCH 006/188] ASM #505 - Color table editor does not allow enough significant digits Change-Id: I2b98ec0de0ebef7b585574d063ddf87834edd44a Former-commit-id: 2b9cb3e46fbd1598e95a4ea3a866741fed6603d9 --- .../viz/ui/dialogs/colordialog/ColorBar.java | 48 ++++++++++++++++++- 1 file changed, 46 insertions(+), 2 deletions(-) diff --git a/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/colordialog/ColorBar.java b/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/colordialog/ColorBar.java index 5e9b643f7d..9147e28dba 100644 --- a/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/colordialog/ColorBar.java +++ b/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/colordialog/ColorBar.java @@ -21,8 +21,11 @@ package com.raytheon.viz.ui.dialogs.colordialog; import java.text.DecimalFormat; +import java.text.NumberFormat; import java.util.ArrayList; +import java.util.HashMap; import java.util.List; +import java.util.Map; import javax.measure.converter.UnitConverter; @@ -56,6 +59,20 @@ import org.eclipse.swt.widgets.Composite; import com.raytheon.uf.common.colormap.ColorMap; import com.raytheon.uf.common.colormap.prefs.ColorMapParameters; +/** + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 11, 2014 DR 15811   Qinglu Lin  Added decimalPlaceMap and logic to have 4 decimal places
+ *                                     for color editor's color bar for radar correlation coefficient.
+ * 
+ * 
+ * + */ public class ColorBar extends Composite implements MouseListener, MouseMoveListener { /** @@ -309,6 +326,18 @@ public class ColorBar extends Composite implements MouseListener, */ protected Image colorBarWithMask; + private final Map decimalPlaceMap = new HashMap() { + private static final long serialVersionUID = 1L; + { + // keys are the last portion of the title in the color table editor for + // a specific radar product, in lower case and value is the decimals expected + // to be displayed in color bar. + put("correlation coeff", "0000"); + } + }; + + private NumberFormat numberFormat = null; + /** * Constructor. * @@ -343,6 +372,13 @@ public class ColorBar extends Composite implements MouseListener, this.enabledColorMask = enableColorMask; this.cmapParams = cmapParams; + for (String s: decimalPlaceMap.keySet()) { + if (parent.getShell().getText().toLowerCase().contains(s)) { + numberFormat = new DecimalFormat("###,###,##0." + decimalPlaceMap.get(s)); + break; + } + } + initializeColorData(); this.callBack = callback; @@ -1500,7 +1536,11 @@ public class ColorBar extends Composite implements MouseListener, // If value is not a number then prepend ">" // to the value. if (((Double) value).isNaN()) { - textStr = "> " + lastVal; + if (numberFormat != null) { + textStr = "> " + numberFormat.format(lastVal); + } else { + textStr = "> " + lastVal; + } } else { lastVal = value; } @@ -1535,7 +1575,11 @@ public class ColorBar extends Composite implements MouseListener, * value variable. */ if (textStr.length() == 0) { - txt = format.format(value); + if (numberFormat != null ) { + txt = numberFormat.format(value); + } else { + txt = format.format(value); + } } else { txt = textStr; } From 9a4e61d5077753164b287c3314e3b23d1b534fcc Mon Sep 17 00:00:00 2001 From: Dave Hladky Date: Thu, 3 Apr 2014 16:55:12 -0500 Subject: [PATCH 007/188] Issue #2940 Better error message for bad XMRG config in FFMP Change-Id: I0ed88a33dc7fe78dcccb7af212a3180d3124ca4f Former-commit-id: b64527b6d538eafc4ae3cc49a32f54c9f44e118a --- .../plugin/ffmp/common/FFMPProcessor.java | 174 ++++++++++++------ 1 file changed, 120 insertions(+), 54 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java index 40aaded68b..c996d429b3 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java @@ -100,6 +100,7 @@ import com.vividsolutions.jts.geom.Polygon; * 05/01/2013 15684 zhao Unlock when Exception caught * Jul 15, 2013 2184 dhladky Remove all HUC's for storage except ALL * 09/03/2013 DR 13083 G. Zhang Added a fix in processRADAR(ArrayList). + * 03 April 2014 2940 dhladky Better error message for bad configurations. *
* @author dhladky * @version 1 @@ -237,25 +238,35 @@ public class FFMPProcessor { Date recdate = null; if (type == FFMPSourceConfigurationManager.DATA_TYPE.RADAR) { - radarRec = (RadarRecord) config.getSourceData( - source.getSourceName()).get(dataKey); + try { + radarRec = (RadarRecord) config.getSourceData( + source.getSourceName()).get(dataKey); - if (radarRec.getMnemonic().equals("DHR")) { - dhrMap = RadarRecordUtil.getDHRValues(radarRec); - statusHandler.handle(Priority.INFO, - "DHR Bias: " + dhrMap.get(DHRValues.BIAS_TO_USE)); - statusHandler.handle(Priority.INFO, - "DHR HailCap: " + dhrMap.get(DHRValues.MAXPRECIPRATEALLOW)); + if (radarRec.getMnemonic().equals("DHR")) { + dhrMap = RadarRecordUtil.getDHRValues(radarRec); + statusHandler.handle(Priority.INFO, "DHR Bias: " + + dhrMap.get(DHRValues.BIAS_TO_USE)); + statusHandler.handle(Priority.INFO, "DHR HailCap: " + + dhrMap.get(DHRValues.MAXPRECIPRATEALLOW)); + } + + recdate = radarRec.getDataTime().getRefTime(); + } catch (Exception e) { + fireBadConfigMessage(type, e); + return; } - recdate = radarRec.getDataTime().getRefTime(); - } else if (type == FFMPSourceConfigurationManager.DATA_TYPE.XMRG) { - xmrg = (XmrgFile) config.getSourceData(source.getSourceName()) - .get(dataKey); - this.extent = getExtents(source.getHrapGridFactor()); - setHRAPSubGrid(extent, source.getHrapGridFactor()); - xmrgData = xmrg.getData(extent); + try { + xmrg = (XmrgFile) config.getSourceData( + source.getSourceName()).get(dataKey); + this.extent = getExtents(source.getHrapGridFactor()); + setHRAPSubGrid(extent, source.getHrapGridFactor()); + xmrgData = xmrg.getData(extent); + } catch (Exception e) { + fireBadConfigMessage(type, e); + return; + } if (xmrg.getHeader().getValidDate().getTime() > 0l) { recdate = xmrg.getHeader().getValidDate(); @@ -285,15 +296,25 @@ public class FFMPProcessor { } } else if (type == FFMPSourceConfigurationManager.DATA_TYPE.PDO) { - imp = (IMonitorProcessing) config.getSourceData( - source.getSourceName()).get(dataKey); - recdate = imp.getDataTime().getRefTime(); + try { + imp = (IMonitorProcessing) config.getSourceData( + source.getSourceName()).get(dataKey); + recdate = imp.getDataTime().getRefTime(); + } catch (Exception e) { + fireBadConfigMessage(type, e); + return; + } } else if (type == FFMPSourceConfigurationManager.DATA_TYPE.GRID) { - gribRec = (GridRecord) config.getSourceData( - source.getSourceName()).get(dataKey); - gribData = config.getGribData(gribRec); - recdate = gribRec.getDataTime().getRefTime(); + try { + gribRec = (GridRecord) config.getSourceData( + source.getSourceName()).get(dataKey); + gribData = config.getGribData(gribRec); + recdate = gribRec.getDataTime().getRefTime(); + } catch (Exception e) { + fireBadConfigMessage(type, e); + return; + } } statusHandler.handle( @@ -350,7 +371,6 @@ public class FFMPProcessor { cwaGeometries, radarRec)); } catch (Exception e) { statusHandler.handle(Priority.WARN, "caught an Exception while generating Source Bin List"); - e.printStackTrace(); if (!checkLockStatus()) { ClusterLockUtils.unlock(sourceBinTaskName, sourceId); } @@ -502,7 +522,6 @@ public class FFMPProcessor { } } catch (Exception e) { - e.printStackTrace(); throw new Exception("FFMPProcessor: Failed to process source: " + source.getSourceName(), e); } @@ -591,7 +610,6 @@ public class FFMPProcessor { } catch (Exception e) { - e.printStackTrace(); throw new Exception( "FFMPProcessor: Failed to process source domain: " + source.getSourceName() + ": " @@ -679,7 +697,6 @@ public class FFMPProcessor { } } catch (Exception e) { - e.printStackTrace(); throw new Exception( "FFMPProcessor: Failed to Guidance Transition Delay source " + source.getSourceName()); @@ -687,7 +704,6 @@ public class FFMPProcessor { } } catch (Exception e) { - e.printStackTrace(); throw new Exception("FFMPProcessor: Failed to process source: " + source.getSourceName()); } @@ -703,20 +719,30 @@ public class FFMPProcessor { Date recdate = null; if (type == FFMPSourceConfigurationManager.DATA_TYPE.RADAR) { - radarRec = (RadarRecord) config.getSourceData( - source.getSourceName()).get(dataKey); - if (radarRec.getMnemonic().equals("DHR")) { - dhrMap = RadarRecordUtil.getDHRValues(radarRec); + try { + radarRec = (RadarRecord) config.getSourceData( + source.getSourceName()).get(dataKey); + if (radarRec.getMnemonic().equals("DHR")) { + dhrMap = RadarRecordUtil.getDHRValues(radarRec); + } + recdate = radarRec.getDataTime().getRefTime(); + } catch (Exception e) { + fireBadConfigMessage(type, e); + return; } - recdate = radarRec.getDataTime().getRefTime(); } else if (type == FFMPSourceConfigurationManager.DATA_TYPE.XMRG) { - xmrg = (XmrgFile) config.getSourceData(source.getSourceName()).get( - dataKey); - this.extent = getExtents(source.getHrapGridFactor()); - setHRAPSubGrid(extent, source.getHrapGridFactor()); - xmrgData = xmrg.getData(extent); - recdate = xmrg.getHeader().getValidDate(); + try { + xmrg = (XmrgFile) config.getSourceData(source.getSourceName()).get( + dataKey); + this.extent = getExtents(source.getHrapGridFactor()); + setHRAPSubGrid(extent, source.getHrapGridFactor()); + xmrgData = xmrg.getData(extent); + recdate = xmrg.getHeader().getValidDate(); + } catch (Exception e) { + fireBadConfigMessage(type, e); + return; + } } // set the time @@ -762,9 +788,11 @@ public class FFMPProcessor { coor = rc.asGridCell(imp.getGridGeometry(), PixelInCell.CELL_CENTER); } catch (TransformException e) { - e.printStackTrace(); + statusHandler.error("VGB PDO transform error!", e); + continue; } catch (FactoryException e) { - e.printStackTrace(); + statusHandler.error("VGB PDO factory error!", e); + continue; } val = processPDO(coor, 1.0); } else if (type == FFMPSourceConfigurationManager.DATA_TYPE.GRID) { @@ -776,7 +804,7 @@ public class FFMPProcessor { } } catch (Exception e) { - e.printStackTrace(); + statusHandler.error("Unable to process VGB: "+type, e); } } } @@ -833,7 +861,7 @@ public class FFMPProcessor { * @param geo * @return */ - private float processPDO(Long pfaf, String cwa) { + private float processPDO(Long pfaf, String cwa) throws Exception { ArrayList entries = null; float arealWeight = 0; @@ -861,9 +889,11 @@ public class FFMPProcessor { center = rc.asGridCell(imp.getGridGeometry(), PixelInCell.CELL_CENTER); } catch (TransformException e) { - e.printStackTrace(); + statusHandler.error("PDO transform error!", e); + throw new Exception(e); } catch (FactoryException e) { - e.printStackTrace(); + statusHandler.error("PDO factory error!", e); + throw new Exception(e); } if ((center.x >= 0) && (center.x < imp.getNx()) @@ -936,7 +966,7 @@ public class FFMPProcessor { * @param geo * @return */ - private float processXMRG(Long pfaf, String cwa) { + private float processXMRG(Long pfaf, String cwa) throws Exception { ArrayList entries = null; float arealWeight = 0.0f; @@ -965,11 +995,14 @@ public class FFMPProcessor { .getGridGeometry(), PixelInCell.CELL_CENTER); } catch (TransformException e) { - e.printStackTrace(); + statusHandler.error("SBL Transform exception: ", e); + throw new Exception(e); } catch (FactoryException e) { - e.printStackTrace(); + statusHandler.error("SBL Factory exception: ", e); + throw new Exception(e); } catch (Exception e) { - e.printStackTrace(); + statusHandler.error("SBL General exception: ", e); + throw new Exception(e); } double xx = center.x - hrapgrid.getExtent().x; @@ -1106,9 +1139,6 @@ public class FFMPProcessor { if (radarRec.getMnemonic().equals("DHR")) { for (int j = 0; j < dataVals.length; j++) { - - //float fval = (float) ScanUtils.getDecodedDHRValue(dataVals[j]); - try { val += ScanUtils.getZRvalue2(dataVals[j],//fval,// DR 13083 dhrMap.get(DHRValues.ZRMULTCOEFF), @@ -1151,7 +1181,7 @@ public class FFMPProcessor { * @param geo * @return */ - private float processGrib(Long pfaf, String cwa) { + private float processGrib(Long pfaf, String cwa) throws Exception { ArrayList entries = null; float arealWeight = 0.0f; @@ -1180,8 +1210,10 @@ public class FFMPProcessor { PixelInCell.CELL_CENTER); } catch (TransformException e) { statusHandler.handle(Priority.ERROR, "Error transforming pfaf! " +pfaf); + throw new Exception(e); } catch (FactoryException e) { statusHandler.handle(Priority.ERROR, "Error in geometry! " +pfaf); + throw new Exception(e); } if (((int) center.x >= 0) && ((int) center.x < getNx()) @@ -1264,7 +1296,7 @@ public class FFMPProcessor { try { hrapgrid = new HRAPSubGrid(rectangle, hrapGribFactor); } catch (Exception e) { - e.printStackTrace(); + statusHandler.error("Cant load HRAP sub grid!", e); } } @@ -1290,7 +1322,7 @@ public class FFMPProcessor { rect.setBounds(rect.x * hrapGridFactor, rect.y * hrapGridFactor, rect.width * hrapGridFactor, rect.height * hrapGridFactor); } catch (Exception e) { - e.printStackTrace(); + statusHandler.error("Can't get HRAP extents! ", e); } return rect; } @@ -1757,5 +1789,39 @@ public class FFMPProcessor { public String getSourceID() { return sourceId; } + + /** + * Fire off a semi-useful message for purpose of diagnostics. + * @param type + */ + private void fireBadConfigMessage( + FFMPSourceConfigurationManager.DATA_TYPE type, Exception e) { + + StringBuffer sb = new StringBuffer(); + sb.append(type + " Source: " + source.getSourceName() + + " has a non-functional configuration! \n"); + sb.append("DataKey: " + dataKey + " SiteKey: " + siteKey + " \n"); + + if (type == FFMPSourceConfigurationManager.DATA_TYPE.RADAR) { + if (radarRec != null) { + sb.append("Record: " + radarRec.getDataURI() + " \n"); + } + } else if (type == FFMPSourceConfigurationManager.DATA_TYPE.XMRG) { + if (xmrg != null) { + sb.append("XMRG File: " + xmrg.getFile().getAbsolutePath() + + " \n"); + } + } else if (type == FFMPSourceConfigurationManager.DATA_TYPE.PDO) { + if (imp != null) { + sb.append("PDO Record: " + imp.getClass().getName() + " Size: "+ imp.getDataArray().length+ "\n"); + } + } else if (type == FFMPSourceConfigurationManager.DATA_TYPE.GRID) { + if (gribRec != null) { + sb.append("Record: " + gribRec.getDataURI() + " \n"); + } + } + + statusHandler.handle(Priority.ERROR, sb.toString(), e); + } } From 5570261d74ce118ecda2972bf08b14e73b4a7c0b Mon Sep 17 00:00:00 2001 From: Roger Ferrel Date: Thu, 10 Apr 2014 13:39:16 -0500 Subject: [PATCH 008/188] Issue #2862 Implements locks on case creation. Change-Id: Ic0975b699e54b30f152422782e11ac04c310cb1b Former-commit-id: b10c78a4f3cb7abb265d8c383c6bc2912d166720 --- .../uf/viz/archive/ui/GenerateCaseDlg.java | 496 ++++++++++++++++-- .../archive/config/ArchiveConstants.java | 3 + .../dataquery/requests/SharedLockRequest.java | 135 +++++ .../responses/SharedLockResponse.java | 67 +++ .../uf/edex/archive/DatabaseArchiver.java | 9 +- .../archive/purge/ArchivePurgeManager.java | 5 +- .../ArchiveAdminPrivilegedRequestHandler.java | 13 +- .../res/spring/database-request.xml | 15 + .../cluster/handler/SharedLockHandler.java | 3 - .../handlers/SharedLockRequestHandler.java | 239 +++++++++ 10 files changed, 928 insertions(+), 57 deletions(-) create mode 100644 edexOsgi/com.raytheon.uf.common.dataquery/src/com/raytheon/uf/common/dataquery/requests/SharedLockRequest.java create mode 100644 edexOsgi/com.raytheon.uf.common.dataquery/src/com/raytheon/uf/common/dataquery/responses/SharedLockResponse.java create mode 100644 edexOsgi/com.raytheon.uf.edex.database/res/spring/database-request.xml create mode 100644 edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/handlers/SharedLockRequestHandler.java diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/GenerateCaseDlg.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/GenerateCaseDlg.java index 2dc0b715b2..0bfe8c942f 100644 --- a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/GenerateCaseDlg.java +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/GenerateCaseDlg.java @@ -27,8 +27,13 @@ import java.io.IOException; import java.util.ArrayList; import java.util.Arrays; import java.util.Calendar; +import java.util.HashMap; import java.util.HashSet; +import java.util.Iterator; import java.util.List; +import java.util.Map; +import java.util.Timer; +import java.util.TimerTask; import java.util.concurrent.atomic.AtomicBoolean; import java.util.zip.GZIPOutputStream; @@ -59,15 +64,22 @@ import org.eclipse.swt.widgets.Shell; import com.raytheon.uf.common.archive.config.ArchiveConfigManager; import com.raytheon.uf.common.archive.config.ArchiveConstants; import com.raytheon.uf.common.archive.config.DisplayData; +import com.raytheon.uf.common.dataquery.requests.SharedLockRequest; +import com.raytheon.uf.common.dataquery.requests.SharedLockRequest.RequestType; +import com.raytheon.uf.common.dataquery.responses.SharedLockResponse; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; +import com.raytheon.uf.common.time.util.ITimer; +import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.common.util.FileUtil; import com.raytheon.uf.viz.core.VizApp; +import com.raytheon.uf.viz.core.exception.VizException; +import com.raytheon.uf.viz.core.requests.ThriftClient; import com.raytheon.viz.ui.dialogs.CaveSWTDialog; /** - * This class performs the desired type of case creation and display a + * This class performs the desired type of case creation and displays a * progress/status message dialog. * *
@@ -81,7 +93,8 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog;
  *                                     archive and category directory and 
  *                                     implementation of compression.
  * Oct 08, 2013 2442       rferrel     Remove category directory.
- * Feb 04, 2013 2270       rferrel     Move HDF files to parent's directory.
+ * Feb 04, 2014 2270       rferrel     Move HDF files to parent's directory.
+ * Apr 03, 2014 2862       rferrel     Logic for shared locking of top level directories.
  * 
  * 
* @@ -91,12 +104,12 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; public class GenerateCaseDlg extends CaveSWTDialog { - /** Extension for HDF files. */ - private static final String hdfExt = ".h5"; - private final IUFStatusHandler statusHandler = UFStatus .getHandler(GenerateCaseDlg.class); + /** Extension for HDF files. */ + private static final String hdfExt = ".h5"; + /** Use to display the current state of the case generation. */ private Label stateLbl; @@ -121,7 +134,7 @@ public class GenerateCaseDlg extends CaveSWTDialog { /** End time for the case. */ private final Calendar endCal; - /** Data list for the case. */ + /** Data list for the case sorted by archive and category names. */ private final DisplayData[] sourceDataList; /** When true compress the case directory. */ @@ -372,24 +385,74 @@ public class GenerateCaseDlg extends CaveSWTDialog { } /** - * The performs the work of generating the case on a non-UI thread. + * This performs the work of generating the case on a non-UI thread. */ private class GenerateJob extends Job { + /** Parent flag to shutdown the job. */ private final AtomicBoolean shutdown = new AtomicBoolean(false); + /** How long to wait before making another request for a plug-in lock. */ + private final long LOCK_RETRY_TIME = 2 * TimeUtil.MILLIS_PER_MINUTE; + + /** Files/directories needing plug-in locks in order to copy. */ + private final Map>> caseCopyMap = new HashMap>>(); + + /** Timer to determine when to send another request for a plug-in lock. */ + private final ITimer retrytimer = TimeUtil.getTimer(); + + /** Timer to update current lock's last execute time. */ + private Timer updateTimer = null; + + /** + * Constructor. + */ public GenerateJob() { super("Generate Case"); } - @Override - protected IStatus run(IProgressMonitor monitor) { - if (monitor.isCanceled()) { - return Status.OK_STATUS; + /** + * Add file to the caseCopyMap. + * + * @param copyInfo + * @param plugin + * @param file + * @return + */ + private boolean putFile(CopyInfo copyInfo, String plugin, File file) { + if (caseCopyMap.size() == 0) { + retrytimer.start(); } + Map> pluginMap = caseCopyMap.get(copyInfo); + + if (pluginMap == null) { + pluginMap = new HashMap>(); + caseCopyMap.put(copyInfo, pluginMap); + } + + List files = pluginMap.get(plugin); + + if (files == null) { + files = new ArrayList(); + pluginMap.put(plugin, files); + } + return files.add(file); + } + + /** + * @param copyInfo + * @return true if locks needed to complete the copy. + */ + private boolean keepCaseCopy(CopyInfo copyInfo) { + return caseCopyMap.get(copyInfo) != null; + } + + /** + * @return true when valid case directory. + */ + private boolean validateCaseDirectory() { setStateLbl("Creating: " + caseDir.getName(), caseDir.getAbsolutePath()); - ICaseCopy caseCopy = null; String errorMessage = null; if (caseDir.exists()) { @@ -401,38 +464,95 @@ public class GenerateCaseDlg extends CaveSWTDialog { if (errorMessage != null) { setStateLbl(errorMessage, caseDir.getAbsolutePath()); setProgressBar(100, SWT.ERROR); - return Status.OK_STATUS; + return false; } if (shutdown.get()) { + return false; + } + return true; + } + + /* + * (non-Javadoc) + * + * @see org.eclipse.core.runtime.jobs.Job#run(org.eclipse.core.runtime. + * IProgressMonitor) + */ + @Override + protected IStatus run(IProgressMonitor monitor) { + if (monitor.isCanceled()) { return Status.OK_STATUS; } + if (!validateCaseDirectory()) { + return Status.OK_STATUS; + } + + ICaseCopy caseCopy = null; String currentArchive = null; String currentCategory = null; - boolean updateDestDir = false; + int rootDirLen = -1; + File rootDir = null; + String plugin = null; + boolean allowCopy = true; + CopyInfo copyInfo = null; try { + /* + * The sourceDataList is sorted so all the displayDatas for a + * given archive/category are grouped together in the loop. + */ for (DisplayData displayData : sourceDataList) { if (shutdown.get()) { return Status.OK_STATUS; } - if (!displayData.getArchiveName().equals(currentArchive)) { - updateDestDir = true; + /* + * The current display data is for a different + * archive/category then the previous one. + */ + if (!displayData.getArchiveName().equals(currentArchive) + || !displayData.getCategoryName().equals( + currentCategory)) { + + // Finish up previous archive/category. + if (caseCopy != null) { + if (allowCopy) { + releaseLock(plugin); + } + + /* + * The copyInfo needs locks in order to finish. + * Force creation of a new caseCopy for the new + * category. + */ + if (keepCaseCopy(copyInfo)) { + caseCopy = null; + copyInfo = null; + } else { + caseCopy.finishCase(); + } + plugin = null; + } + + // Set up for new category. currentArchive = displayData.getArchiveName(); currentCategory = displayData.getCategoryName(); - } else if (!displayData.getCategoryName().equals( - currentCategory)) { - updateDestDir = true; - currentCategory = displayData.getCategoryName(); - } + rootDir = new File(displayData.getRootDir()); + rootDirLen = displayData.getRootDir().length(); + allowCopy = true; - if (updateDestDir) { - updateDestDir = false; - if (caseCopy != null) { - caseCopy.finishCase(); - } else { + setStateLbl(currentArchive + " | " + currentCategory, + caseDir.getAbsolutePath() + "\n" + + currentArchive + "\n" + + currentCategory); + + /* + * When caseCopy is not null it is safe to reuse it for + * the new category. + */ + if (caseCopy == null) { if (!doCompress) { caseCopy = new CopyMove(); } else if (doMultiFiles) { @@ -440,33 +560,83 @@ public class GenerateCaseDlg extends CaveSWTDialog { } else { caseCopy = new CompressCopy(); } + copyInfo = new CopyInfo(caseCopy, currentArchive, + currentCategory, caseDir); } + caseCopy.startCase(caseDir, displayData, shutdown); - setStateLbl(currentArchive + " | " + currentCategory, - caseDir.getAbsolutePath() + "\n" - + currentArchive + "\n" - + currentCategory); } List files = archiveManager.getDisplayFiles( displayData, startCal, endCal); + + /* + * Check all files/directories in the displayData and + * attempt a recursive copy. + */ for (File source : files) { if (shutdown.get()) { return Status.OK_STATUS; } - caseCopy.copy(source); + String dirName = source.getAbsolutePath() + .substring(rootDirLen).split(File.separator)[0]; + String newPlugin = (new File(rootDir, dirName)) + .getAbsolutePath(); + + // Have new plugin. + if (!newPlugin.equals(plugin)) { + // Release the current lock. + if (allowCopy && (plugin != null)) { + releaseLock(plugin); + } + allowCopy = requestLock(newPlugin); + plugin = newPlugin; + } + + if (allowCopy) { + // Have lock safe to perform recursive copy. + caseCopy.copy(source); + } else { + // No lock add to Map of files needing locks. + putFile(copyInfo, plugin, source); + } + } // End of files loop + + /* + * The copy may have taken some time see if any pending + * copies can be completed. + */ + if (retrytimer.getElapsedTime() >= LOCK_RETRY_TIME) { + retryCasesCopy(); } - } - if (caseCopy != null) { - caseCopy.finishCase(); + } // End of sourceDataList loop + + // Finish up the loop's last plugin. + if (plugin != null) { + if (allowCopy) { + releaseLock(plugin); + } + + // Finish last case + if (!keepCaseCopy(copyInfo)) { + caseCopy.finishCase(); + } + plugin = null; } caseCopy = null; + // Finish pending copies needing locks. + waitForLocks(); + + if (shutdown.get()) { + return Status.OK_STATUS; + } + setStateLbl("Created: " + caseName, caseDir.getAbsolutePath()); setProgressBar(100, SWT.NORMAL); - } catch (CaseCreateException e) { + } catch (Exception e) { statusHandler.handle(Priority.PROBLEM, e.getLocalizedMessage(), e); setStateLbl( @@ -474,20 +644,220 @@ public class GenerateCaseDlg extends CaveSWTDialog { caseDir.getAbsolutePath() + "\n" + e.getLocalizedMessage()); setProgressBar(100, SWT.ERROR); + shutdown.set(true); } finally { + // shutdown the time. + if (updateTimer != null) { + updateTimer.cancel(); + updateTimer = null; + } + + // Release resources of active case copy. if (caseCopy != null) { - try { - caseCopy.finishCase(); - } catch (CaseCreateException ex) { - // Ignore + if (!keepCaseCopy(copyInfo)) { + try { + // Allow the caseCopy to clean its resources. + caseCopy.finishCase(); + } catch (CaseCreateException ex) { + // Ignore + } + caseCopy = null; } - caseCopy = null; + } + + // Release current lock. + if (allowCopy && (plugin != null)) { + releaseLock(plugin); + } + + // Release resources of any pending case copy. + if (caseCopyMap.size() > 0) { + for (CopyInfo cpi : caseCopyMap.keySet()) { + try { + cpi.caseCopy.finishCase(); + } catch (CaseCreateException ex) { + // Ignore + } + } + caseCopyMap.clear(); } } return Status.OK_STATUS; } + /** + * Finish copying all files needing locks. + * + * @throws CaseCreateException + * @throws InterruptedException + */ + private void waitForLocks() throws CaseCreateException, + InterruptedException { + int retryCount = 0; + boolean updateStatus = true; + while (caseCopyMap.size() > 0) { + if (updateStatus) { + ++retryCount; + StringBuilder tooltip = new StringBuilder(); + tooltip.append("Waiting to finish ").append( + caseCopyMap.size()); + if (caseCopyMap.size() == 1) { + tooltip.append(" category."); + } else { + tooltip.append(" categories."); + } + tooltip.append("\nAttempt: ").append(retryCount); + setStateLbl("Waiting for locks", tooltip.toString()); + updateStatus = false; + } + + synchronized (this) { + wait(TimeUtil.MILLIS_PER_SECOND / 2L); + } + + if (shutdown.get()) { + return; + } + + if (retrytimer.getElapsedTime() >= LOCK_RETRY_TIME) { + retryCasesCopy(); + updateStatus = true; + } + } + } + + /** + * Attempt to copy files still waiting on plug-in locks. + * + * @throws CaseCreateException + */ + private void retryCasesCopy() throws CaseCreateException { + if (shutdown.get()) { + return; + } + + if (caseCopyMap.size() > 0) { + retrytimer.stop(); + retrytimer.reset(); + String lockedPlugin = null; + try { + Iterator copyInfoIter = caseCopyMap.keySet() + .iterator(); + while (copyInfoIter.hasNext()) { + CopyInfo copyInfo = copyInfoIter.next(); + setStateLbl(copyInfo.archive + " | " + + copyInfo.category, + copyInfo.caseDir.getAbsolutePath() + "\n" + + copyInfo.archive + "\n" + + copyInfo.category); + + Map> pluginMap = caseCopyMap + .get(copyInfo); + Iterator pluginIter = pluginMap.keySet() + .iterator(); + while (pluginIter.hasNext()) { + String plugin = pluginIter.next(); + if (shutdown.get()) { + return; + } + + if (requestLock(plugin)) { + lockedPlugin = plugin; + for (File source : pluginMap.get(plugin)) { + copyInfo.caseCopy.copy(source); + if (shutdown.get()) { + return; + } + } + releaseLock(plugin); + lockedPlugin = null; + pluginIter.remove(); + } + } + if (pluginMap.size() == 0) { + copyInfo.caseCopy.finishCase(); + copyInfoIter.remove(); + } + } + } finally { + if (lockedPlugin != null) { + releaseLock(lockedPlugin); + } + } + } + + if (caseCopyMap.size() > 0) { + retrytimer.start(); + } + } + + /** + * Request a lock for the plug-in. + * + * @param details + * @return true when lock obtained otherwise false + */ + private boolean requestLock(String details) { + SharedLockRequest request = new SharedLockRequest( + ArchiveConstants.CLUSTER_NAME, details, + RequestType.READER_LOCK); + + try { + Object o = ThriftClient.sendRequest(request); + if (o instanceof SharedLockResponse) { + SharedLockResponse response = (SharedLockResponse) o; + if (response.isSucessful()) { + if (updateTimer == null) { + updateTimer = new Timer( + "Case Creation update timer", true); + } + TimerTask timerTask = new LockUpdateTask(details); + updateTimer.schedule(timerTask, + TimeUtil.MILLIS_PER_MINUTE, + TimeUtil.MILLIS_PER_MINUTE); + return true; + } + } + } catch (VizException e) { + statusHandler.handle(Priority.PROBLEM, e.getLocalizedMessage(), + e); + } + + return false; + } + + /** + * Release previously obtained lock for the details. + * + * @param details + * @return true when lock released otherwise false. + */ + private boolean releaseLock(String details) { + SharedLockRequest request = new SharedLockRequest( + ArchiveConstants.CLUSTER_NAME, details, + RequestType.READER_UNLOCK); + try { + if (updateTimer != null) { + updateTimer.cancel(); + updateTimer = null; + } + Object o = ThriftClient.sendRequest(request); + if (o instanceof SharedLockResponse) { + SharedLockResponse response = (SharedLockResponse) o; + if (response.isSucessful()) { + details = null; + return true; + } + } + } catch (VizException e) { + statusHandler.handle(Priority.PROBLEM, e.getLocalizedMessage(), + e); + } + + return false; + } + /* * (non-Javadoc) * @@ -543,7 +913,7 @@ public class GenerateCaseDlg extends CaveSWTDialog { copyFile(new File(source, file), new File(destination, file)); } - } else { + } else if (source.exists()) { // DR 2270 bump HDF files up a directory. if (destination.getName().endsWith(hdfExt)) { destination = new File(destination.getParentFile() @@ -661,7 +1031,7 @@ public class GenerateCaseDlg extends CaveSWTDialog { tarDirFile.add(file); addTarFiles(file.listFiles()); } - } else { + } else if (file.exists()) { // DR 2270 bump HDF files up a directory. if (name.endsWith(hdfExt)) { File destination = new File(file.getParentFile() @@ -1091,4 +1461,46 @@ public class GenerateCaseDlg extends CaveSWTDialog { // } } + + /** Task to update the lock plugin's last execute time. */ + private final class LockUpdateTask extends TimerTask { + /** The locked cluster task's details. */ + private final String details; + + public LockUpdateTask(String details) { + this.details = details; + } + + @Override + public void run() { + SharedLockRequest request = new SharedLockRequest( + ArchiveConstants.CLUSTER_NAME, details, + RequestType.READER_UPDATE_TIME); + try { + ThriftClient.sendRequest(request); + } catch (VizException e) { + statusHandler.handle(Priority.PROBLEM, e.getLocalizedMessage(), + e); + } + } + } + + /** Information needed to update status when retrying a copy. */ + private static class CopyInfo { + protected final ICaseCopy caseCopy; + + protected final String archive; + + protected final String category; + + protected final File caseDir; + + public CopyInfo(ICaseCopy caseCopy, String archive, String category, + File caseDir) { + this.caseCopy = caseCopy; + this.archive = archive; + this.category = category; + this.caseDir = caseDir; + } + } } diff --git a/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/ArchiveConstants.java b/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/ArchiveConstants.java index 71f1e6af2c..aa3012c97b 100644 --- a/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/ArchiveConstants.java +++ b/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/ArchiveConstants.java @@ -34,6 +34,7 @@ import com.raytheon.uf.common.localization.IPathManager; * ------------ ---------- ----------- -------------------------- * Jul 23, 2013 #2221 rferrel Initial creation * Aug 26, 2013 #2225 rferrel Added tar extension. + * Apr 11, 2014 #2862 rferrel Added cluster name. * * * @@ -42,6 +43,8 @@ import com.raytheon.uf.common.localization.IPathManager; */ public class ArchiveConstants { + /** The value for the cluster tasks' name column. */ + public static final String CLUSTER_NAME = "Archive Shared Lock"; /** Pattern to find slashes in a string. */ private final static Pattern slashPattern = Pattern.compile("[/\\\\]+"); diff --git a/edexOsgi/com.raytheon.uf.common.dataquery/src/com/raytheon/uf/common/dataquery/requests/SharedLockRequest.java b/edexOsgi/com.raytheon.uf.common.dataquery/src/com/raytheon/uf/common/dataquery/requests/SharedLockRequest.java new file mode 100644 index 0000000000..45252b14e0 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.dataquery/src/com/raytheon/uf/common/dataquery/requests/SharedLockRequest.java @@ -0,0 +1,135 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.common.dataquery.requests; + +import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; +import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; +import com.raytheon.uf.common.serialization.comm.IServerRequest; + +/** + * The request class to coordinate with the shared locks in the + * awips.custer_task table. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 1, 2014  2862       rferrel     Initial creation
+ * 
+ * 
+ * + * @author rferrel + * @version 1.0 + */ + +@DynamicSerialize +public class SharedLockRequest implements IServerRequest { + /** The types of requests. */ + public static enum RequestType { + READER_LOCK, READER_UNLOCK, READER_UPDATE_TIME, WRITER_LOCK, WRITER_UNLOCK, WRITER_UPDATE_TIME + } + + /** The name column entry. */ + @DynamicSerializeElement + private String name; + + /** The details column entry. */ + @DynamicSerializeElement + private String details; + + /* The desired request. */ + @DynamicSerializeElement + private RequestType requestType; + + /** + * Default constructor should only be used for serialization. + */ + public SharedLockRequest() { + } + + /** + * Desired constructor. + * + * @param details + * @param requestType + */ + public SharedLockRequest(String name, String details, + RequestType requestType) { + setName(name); + setDetails(details); + setRequestType(requestType); + } + + /** + * Getter. + * + * @return requestType + */ + public RequestType getRequestType() { + return requestType; + } + + /** + * Setter should only be used for serialization. + * + * @param requestType + */ + public void setRequestType(RequestType requestType) { + this.requestType = requestType; + } + + /** + * Getter. + * + * @return name + */ + public String getName() { + return name; + } + + /** + * Setter. + * + * @param name + */ + public void setName(String name) { + this.name = name; + } + + /** + * Getter. + * + * @return details + */ + public String getDetails() { + return details; + } + + /** + * Setter should only be used for serialization. + * + * @param details + */ + public void setDetails(String details) { + this.details = details; + } +} diff --git a/edexOsgi/com.raytheon.uf.common.dataquery/src/com/raytheon/uf/common/dataquery/responses/SharedLockResponse.java b/edexOsgi/com.raytheon.uf.common.dataquery/src/com/raytheon/uf/common/dataquery/responses/SharedLockResponse.java new file mode 100644 index 0000000000..778267ee2e --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.dataquery/src/com/raytheon/uf/common/dataquery/responses/SharedLockResponse.java @@ -0,0 +1,67 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.common.dataquery.responses; + +import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; +import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; + +/** + * Response from the shared lock request handler. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 8, 2014  2862       rferrel     Initial creation
+ * 
+ * 
+ * + * @author rferrel + * @version 1.0 + */ + +@DynamicSerialize +public class SharedLockResponse { + /** true when request was successful. */ + @DynamicSerializeElement + private boolean sucessful; + + /** Any error message from the handler. */ + @DynamicSerializeElement + private String errorMessage; + + public boolean isSucessful() { + return sucessful; + } + + public void setSucessful(boolean sucessful) { + this.sucessful = sucessful; + } + + public String getErrorMessage() { + return errorMessage; + } + + public void setErrorMessage(String errorMessage) { + this.errorMessage = errorMessage; + } +} diff --git a/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/DatabaseArchiver.java b/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/DatabaseArchiver.java index 4abce3c143..4f762aa9ff 100644 --- a/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/DatabaseArchiver.java +++ b/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/DatabaseArchiver.java @@ -30,6 +30,7 @@ import java.util.TimeZone; import java.util.Timer; import java.util.TimerTask; +import com.raytheon.uf.common.archive.config.ArchiveConstants; import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.common.dataplugin.PluginException; import com.raytheon.uf.common.dataplugin.PluginProperties; @@ -127,8 +128,8 @@ public class DatabaseArchiver implements IPluginArchiver { @Override public void run() { long currentTime = System.currentTimeMillis(); - ClusterLockUtils.updateLockTime(SharedLockHandler.name, details, - currentTime); + ClusterLockUtils.updateLockTime(ArchiveConstants.CLUSTER_NAME, + details, currentTime); } } @@ -170,8 +171,8 @@ public class DatabaseArchiver implements IPluginArchiver { */ private ClusterTask getWriteLock(String details) { SharedLockHandler lockHandler = new SharedLockHandler(LockType.WRITER); - ClusterTask ct = ClusterLockUtils.lock(SharedLockHandler.name, details, - lockHandler, false); + ClusterTask ct = ClusterLockUtils.lock(ArchiveConstants.CLUSTER_NAME, + details, lockHandler, false); if (LockState.SUCCESSFUL.equals(ct.getLockState())) { if (statusHandler.isPriorityEnabled(Priority.INFO)) { statusHandler.handle(Priority.INFO, String.format( diff --git a/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/purge/ArchivePurgeManager.java b/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/purge/ArchivePurgeManager.java index e7ff3d48ed..a559eb5e37 100644 --- a/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/purge/ArchivePurgeManager.java +++ b/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/purge/ArchivePurgeManager.java @@ -34,6 +34,7 @@ import org.apache.commons.io.filefilter.IOFileFilter; import com.raytheon.uf.common.archive.config.ArchiveConfig; import com.raytheon.uf.common.archive.config.ArchiveConfigManager; +import com.raytheon.uf.common.archive.config.ArchiveConstants; import com.raytheon.uf.common.archive.config.CategoryConfig; import com.raytheon.uf.common.archive.config.CategoryFileDateHelper; import com.raytheon.uf.common.archive.config.DataSetStatus; @@ -264,8 +265,8 @@ public class ArchivePurgeManager { */ private ClusterTask getWriteLock(String details) { SharedLockHandler lockHandler = new SharedLockHandler(LockType.WRITER); - ClusterTask ct = ClusterLockUtils.lock(SharedLockHandler.name, details, - lockHandler, false); + ClusterTask ct = ClusterLockUtils.lock(ArchiveConstants.CLUSTER_NAME, + details, lockHandler, false); if (ct.getLockState().equals(LockState.SUCCESSFUL)) { if (statusHandler.isPriorityEnabled(Priority.INFO)) { statusHandler.handle(Priority.INFO, String.format( diff --git a/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/useradmin/ArchiveAdminPrivilegedRequestHandler.java b/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/useradmin/ArchiveAdminPrivilegedRequestHandler.java index 7d68c406ff..788a610c2f 100644 --- a/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/useradmin/ArchiveAdminPrivilegedRequestHandler.java +++ b/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/useradmin/ArchiveAdminPrivilegedRequestHandler.java @@ -64,8 +64,10 @@ public class ArchiveAdminPrivilegedRequestHandler extends @Override public ArchiveAdminAuthRequest handleRequest(ArchiveAdminAuthRequest request) throws Exception { - // If it reaches this point in the code, then the user is authorized, so - // just return the request object with authorized set to true + /* + * If it reaches this point in the code, then the user is authorized, so + * just return the request object with authorized set to true. + */ request.setAuthorized(true); return request; } @@ -85,14 +87,13 @@ public class ArchiveAdminPrivilegedRequestHandler extends AuthManager manager = AuthManagerFactory.getInstance().getManager(); IRoleStorage roleStorage = manager.getRoleStorage(); - boolean authorized = roleStorage.isAuthorized((request).getRoleId(), - user.uniqueId().toString(), APPLICATION); + boolean authorized = roleStorage.isAuthorized(request.getRoleId(), user + .uniqueId().toString(), APPLICATION); if (authorized) { return new AuthorizationResponse(authorized); } else { - return new AuthorizationResponse( - (request).getNotAuthorizedMessage()); + return new AuthorizationResponse(request.getNotAuthorizedMessage()); } } } diff --git a/edexOsgi/com.raytheon.uf.edex.database/res/spring/database-request.xml b/edexOsgi/com.raytheon.uf.edex.database/res/spring/database-request.xml new file mode 100644 index 0000000000..9ea7332d58 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.database/res/spring/database-request.xml @@ -0,0 +1,15 @@ + + + + + + + + + + + + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/cluster/handler/SharedLockHandler.java b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/cluster/handler/SharedLockHandler.java index 1f2e4e03b3..2edf27089f 100644 --- a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/cluster/handler/SharedLockHandler.java +++ b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/cluster/handler/SharedLockHandler.java @@ -56,9 +56,6 @@ public final class SharedLockHandler extends CurrentTimeClusterLockHandler { WRITER }; - /** The value for the cluster tasks' name column. */ - public static final String name = "Shared Lock"; - /** * Common override time out. Clients need to rely on this value in order to * update last execution time to maintain the lock. diff --git a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/handlers/SharedLockRequestHandler.java b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/handlers/SharedLockRequestHandler.java new file mode 100644 index 0000000000..0d01f118c3 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/handlers/SharedLockRequestHandler.java @@ -0,0 +1,239 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.database.handlers; + +import java.util.List; + +import com.raytheon.uf.common.dataquery.requests.SharedLockRequest; +import com.raytheon.uf.common.dataquery.requests.SharedLockRequest.RequestType; +import com.raytheon.uf.common.dataquery.responses.SharedLockResponse; +import com.raytheon.uf.common.serialization.comm.IRequestHandler; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.status.UFStatus.Priority; +import com.raytheon.uf.edex.database.cluster.ClusterLockUtils; +import com.raytheon.uf.edex.database.cluster.ClusterLockUtils.LockState; +import com.raytheon.uf.edex.database.cluster.ClusterTask; +import com.raytheon.uf.edex.database.cluster.handler.SharedLockHandler; +import com.raytheon.uf.edex.database.cluster.handler.SharedLockHandler.LockType; + +/** + * This is the handler class for a shared lock request. It coordinates with the + * shared lock handler to perform the desired request. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 2, 2014  2862       rferrel     Initial creation
+ * 
+ * 
+ * + * @author rferrel + * @version 1.0 + */ + +public class SharedLockRequestHandler implements + IRequestHandler { + + private final IUFStatusHandler statusHander = UFStatus + .getHandler(SharedLockRequestHandler.class); + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.common.serialization.comm.IRequestHandler#handleRequest + * (com.raytheon.uf.common.serialization.comm.IServerRequest) + */ + @Override + public SharedLockResponse handleRequest(SharedLockRequest request) + throws Exception { + + SharedLockResponse response = new SharedLockResponse(); + String name = request.getName(); + String details = request.getDetails(); + RequestType type = request.getRequestType(); + response.setSucessful(false); + + try { + switch (type) { + case READER_LOCK: + if (lock(name, details, LockType.READER)) { + response.setSucessful(true); + } else { + response.setSucessful(false); + response.setErrorMessage(String.format( + "Unable to obtain %s lock.", LockType.READER)); + } + break; + case READER_UNLOCK: + if (unlock(name, details, LockType.READER)) { + response.setSucessful(true); + } else { + response.setSucessful(false); + response.setErrorMessage(String.format( + "Unable to unlock %s.", LockType.READER)); + } + break; + case READER_UPDATE_TIME: + if (updateTime(name, details, LockType.READER)) { + response.setSucessful(true); + } else { + response.setSucessful(false); + response.setErrorMessage(String.format( + "Unable to update %s last exection time.", + LockType.READER)); + } + break; + case WRITER_LOCK: + if (lock(name, details, LockType.WRITER)) { + response.setSucessful(true); + } else { + response.setSucessful(false); + response.setErrorMessage(String.format( + "Unable to obtain %s lock.", LockType.WRITER)); + } + break; + case WRITER_UNLOCK: + if (unlock(name, details, LockType.WRITER)) { + response.setSucessful(true); + } else { + response.setSucessful(false); + response.setErrorMessage(String.format( + "Unable to unlock %s.", LockType.WRITER)); + } + break; + case WRITER_UPDATE_TIME: + if (updateTime(name, details, LockType.WRITER)) { + response.setSucessful(false); + response.setErrorMessage(String.format( + "Unable to update %s last execution time.", + LockType.WRITER)); + } + break; + default: + String message = "Unimplemented request type: " + type; + statusHander.error(message); + response.setErrorMessage(message); + response.setSucessful(false); + } + } catch (Exception ex) { + response.setSucessful(false); + String message = String.format( + "Request type %s for details %s failed %s", type, details, + ex.getMessage()); + response.setErrorMessage(message); + if (statusHander.isPriorityEnabled(Priority.PROBLEM)) { + statusHander.handle(Priority.PROBLEM, message, ex); + } + } + return response; + } + + /** + * Request details lock of the desired lock type. + * + * @param details + * @param lockType + * @return true when obtaining lock is successful + */ + private boolean lock(String name, String details, LockType lockType) { + SharedLockHandler lockHandler = new SharedLockHandler(lockType); + ClusterTask ct = ClusterLockUtils.lock(name, details, lockHandler, + false); + return LockState.SUCCESSFUL.equals(ct.getLockState()); + } + + /** + * Release lock for given details. The unlock request is only attempted when + * the details' lock type matches and the count is a positive number. + * + * @param details + * @param lockType + * @return true when successful + */ + private boolean unlock(String name, String details, LockType lockType) { + ClusterTask ct = findCluster(name, details, lockType); + if (ct != null) { + SharedLockHandler handler = (SharedLockHandler) ct.getLockHandler(); + if (handler.getLockCount() > 0) { + return ClusterLockUtils.unlock(ct, false); + } + } + return false; + } + + /** + * Find the details' cluster task with latest extrainfo and set up its + * handler. The found cluster task is only returned if its lock type matches + * the requested type and it is in the run state. + * + * @param details + * - Whose cluster task to find + * @param lockType + * - Expected lock type for the cluster + * @return ct when found, matches lockType, and is running else null. + */ + private ClusterTask findCluster(String name, String details, + LockType lockType) { + ClusterTask ct = null; + List cts = ClusterLockUtils.getLocks(name); + + if ((cts != null) && (cts.size() > 0)) { + for (ClusterTask tmpCt : cts) { + if (details.equals(tmpCt.getId().getDetails())) { + if (tmpCt.isRunning()) { + SharedLockHandler handler = new SharedLockHandler( + lockType); + handler.parseExtraInfoString(tmpCt.getExtraInfo()); + if (handler.locksMatch() + && (handler.getLockCount() > 0)) { + ct = tmpCt; + ct.setLockHandler(handler); + } + } + break; + } + } + } + return ct; + } + + /** + * Update the last execution time for the detail's lock. + * + * @param details + * @param lockType + * @return true when update successful + */ + private boolean updateTime(String name, String details, LockType lockType) { + ClusterTask ct = findCluster(name, details, lockType); + if (ct != null) { + if (ClusterLockUtils.updateLockTime(ct.getId().getName(), ct + .getId().getDetails(), System.currentTimeMillis())) { + return true; + } + } + return false; + } +} From 037ed878b7cae99a00ea171bfa46a259277f99c9 Mon Sep 17 00:00:00 2001 From: Ben Steffensmeier Date: Fri, 11 Apr 2014 16:43:10 -0500 Subject: [PATCH 009/188] Issue #2947 Make GridCoverage implement IGridGeometryProvider. Former-commit-id: f2a204c593f65c67c87e16fa513d00383ad568e5 --- .../dataplugin/gfe/db/objects/GridLocation.java | 15 ++------------- .../uf/common/gridcoverage/GridCoverage.java | 5 ++++- 2 files changed, 6 insertions(+), 14 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/db/objects/GridLocation.java b/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/db/objects/GridLocation.java index 4b4d997446..b867eb2bf3 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/db/objects/GridLocation.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/db/objects/GridLocation.java @@ -99,6 +99,8 @@ import com.vividsolutions.jts.simplify.TopologyPreservingSimplifier; * made init method public for use in GFEDao * 09/30/13 #2333 mschenke Added method to construct from {@link IGridGeometryProvider} * 10/22/13 #2361 njensen Remove XML annotations + * 04/11/14 #2947 bsteffen Remove ISpatialObject constructor. + * * * * @@ -343,19 +345,6 @@ public class GridLocation extends PersistableDataObject implements "GMT"); } - /** - * @param id - * @param coverage - */ - public GridLocation(String id, ISpatialObject coverage) { - this.siteId = id; - this.crsObject = coverage.getCrs(); - this.crsWKT = this.crsObject.toWKT(); - this.geometry = (Polygon) coverage.getGeometry(); - this.nx = coverage.getNx(); - this.ny = coverage.getNy(); - } - /** * @param id * @param provider diff --git a/edexOsgi/com.raytheon.uf.common.gridcoverage/src/com/raytheon/uf/common/gridcoverage/GridCoverage.java b/edexOsgi/com.raytheon.uf.common.gridcoverage/src/com/raytheon/uf/common/gridcoverage/GridCoverage.java index ca5763679e..2e7213a6d5 100644 --- a/edexOsgi/com.raytheon.uf.common.gridcoverage/src/com/raytheon/uf/common/gridcoverage/GridCoverage.java +++ b/edexOsgi/com.raytheon.uf.common.gridcoverage/src/com/raytheon/uf/common/gridcoverage/GridCoverage.java @@ -51,6 +51,7 @@ import org.opengis.referencing.operation.MathTransform; import com.raytheon.uf.common.dataplugin.annotations.DataURI; import com.raytheon.uf.common.dataplugin.persist.PersistableDataObject; import com.raytheon.uf.common.geospatial.CRSCache; +import com.raytheon.uf.common.geospatial.IGridGeometryProvider; import com.raytheon.uf.common.geospatial.ISpatialObject; import com.raytheon.uf.common.geospatial.MapUtil; import com.raytheon.uf.common.gridcoverage.exception.GridCoverageException; @@ -77,6 +78,7 @@ import com.vividsolutions.jts.geom.Geometry; * spatial * Oct 15, 2013 2473 bsteffen add @XmlSeeAlso for self contained JAXB * context. + * Apr 11, 2014 2947 bsteffen Implement IGridGeometryProvider. * * * @@ -93,7 +95,7 @@ import com.vividsolutions.jts.geom.Geometry; StereographicGridCoverage.class }) @DynamicSerialize public abstract class GridCoverage extends PersistableDataObject - implements ISpatialObject { + implements ISpatialObject, IGridGeometryProvider { private static final long serialVersionUID = -1355232934065074837L; @@ -394,6 +396,7 @@ public abstract class GridCoverage extends PersistableDataObject this.description = description; } + @Override public GridGeometry2D getGridGeometry() { if (gridGeometry == null) { gridGeometry = MapUtil.getGridGeometry(this); From d5b91d8846dfae587b47c450ecc176c669145e38 Mon Sep 17 00:00:00 2001 From: Ben Steffensmeier Date: Fri, 11 Apr 2014 17:31:00 -0500 Subject: [PATCH 010/188] Issue #2947 Switch derived parameter space amtching to use IGridGeometryProvider. Former-commit-id: c5c0dcaab8e495970438f134625ac2847f9bcf9f --- .../viz/grid/inv/GridRequestableNode.java | 22 +- .../viz/grid/inv/ImportLevelNode.java | 22 +- .../common/derivparam/tree/OrLevelNode.java | 26 ++- .../IGridGeometryProviderComparable.java | 59 +++++ .../uf/common/inventory/TimeAndSpace.java | 49 ++-- .../common/inventory/TimeAndSpaceMatcher.java | 213 +++++++++--------- .../data/AbstractRequestableData.java | 20 +- 7 files changed, 234 insertions(+), 177 deletions(-) create mode 100644 edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/IGridGeometryProviderComparable.java diff --git a/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/inv/GridRequestableNode.java b/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/inv/GridRequestableNode.java index 56f1cf509d..37fe344244 100644 --- a/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/inv/GridRequestableNode.java +++ b/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/inv/GridRequestableNode.java @@ -26,10 +26,6 @@ import java.util.Map; import java.util.Map.Entry; import java.util.Set; -import com.raytheon.uf.common.inventory.data.AbstractRequestableData; -import com.raytheon.uf.common.inventory.exception.DataCubeException; -import com.raytheon.uf.common.inventory.TimeAndSpace; -import com.raytheon.uf.common.inventory.tree.LevelNode; import com.raytheon.uf.common.dataplugin.grid.GridConstants; import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataquery.requests.DbQueryRequest; @@ -37,9 +33,13 @@ import com.raytheon.uf.common.dataquery.requests.RequestConstraint; import com.raytheon.uf.common.dataquery.requests.RequestConstraint.ConstraintType; import com.raytheon.uf.common.dataquery.responses.DbQueryResponse; import com.raytheon.uf.common.derivparam.tree.AbstractBaseDataNode; -import com.raytheon.uf.common.geospatial.ISpatialObject; +import com.raytheon.uf.common.geospatial.IGridGeometryProvider; import com.raytheon.uf.common.gridcoverage.GridCoverage; import com.raytheon.uf.common.gridcoverage.lookup.GridCoverageLookup; +import com.raytheon.uf.common.inventory.TimeAndSpace; +import com.raytheon.uf.common.inventory.data.AbstractRequestableData; +import com.raytheon.uf.common.inventory.exception.DataCubeException; +import com.raytheon.uf.common.inventory.tree.LevelNode; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.time.DataTime; @@ -55,9 +55,11 @@ import com.raytheon.viz.grid.util.CoverageUtils; *
  * 
  * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Jan 19, 2010            bsteffen     Initial creation
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Jan 19, 2010           bsteffen    Initial creation
+ * Apr 11, 2014  2947     bsteffen    Switch spatial matching to use
+ *                                    IGridGeometryProvider
  * 
  * 
* @@ -130,7 +132,7 @@ public class GridRequestableNode extends AbstractBaseDataNode { boolean timeAgnostic = false; boolean spaceAgnostic = false; Set times = new HashSet(); - Set spaces = new HashSet(); + Set spaces = new HashSet(); for (TimeAndSpace ast : availability) { if (ast.isTimeAgnostic()) { timeAgnostic = true; @@ -162,7 +164,7 @@ public class GridRequestableNode extends AbstractBaseDataNode { if (!spaceAgnostic) { RequestConstraint spaceRc = new RequestConstraint(); spaceRc.setConstraintType(ConstraintType.IN); - for (ISpatialObject space : spaces) { + for (IGridGeometryProvider space : spaces) { if (space instanceof GridCoverage) { spaceRc.addToConstraintValueList(Integer .toString(((GridCoverage) space).getId())); diff --git a/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/inv/ImportLevelNode.java b/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/inv/ImportLevelNode.java index c58e6ce3c8..fd7b585ad3 100644 --- a/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/inv/ImportLevelNode.java +++ b/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/inv/ImportLevelNode.java @@ -28,10 +28,6 @@ import java.util.NavigableSet; import java.util.Set; import java.util.TreeSet; -import com.raytheon.uf.common.inventory.data.AbstractRequestableData; -import com.raytheon.uf.common.inventory.exception.DataCubeException; -import com.raytheon.uf.common.inventory.TimeAndSpace; -import com.raytheon.uf.common.inventory.tree.AbstractRequestableNode; import com.raytheon.uf.common.dataplugin.grid.dataset.DatasetInfo; import com.raytheon.uf.common.dataplugin.grid.dataset.DatasetInfoLookup; import com.raytheon.uf.common.dataplugin.level.Level; @@ -39,8 +35,12 @@ import com.raytheon.uf.common.derivparam.inv.AvailabilityContainer; import com.raytheon.uf.common.derivparam.library.DerivParamDesc; import com.raytheon.uf.common.derivparam.library.DerivParamMethod; import com.raytheon.uf.common.derivparam.tree.AbstractAliasLevelNode; -import com.raytheon.uf.common.geospatial.ISpatialObject; +import com.raytheon.uf.common.geospatial.IGridGeometryProvider; import com.raytheon.uf.common.gridcoverage.GridCoverage; +import com.raytheon.uf.common.inventory.TimeAndSpace; +import com.raytheon.uf.common.inventory.data.AbstractRequestableData; +import com.raytheon.uf.common.inventory.exception.DataCubeException; +import com.raytheon.uf.common.inventory.tree.AbstractRequestableNode; import com.raytheon.uf.common.time.DataTime; import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.viz.grid.data.ImportRequestableData; @@ -50,15 +50,17 @@ import com.raytheon.viz.grid.util.RadarAdapter; /** * This node handles all Alias derived parameters which includes Import in AWIPS * I. Data requests and Time queries are simply forwarded to the source nodes. - * Returned records are wrapped in an ALiasRecord which can handle unit + * Returned records are wrapped in an AliasRecord which can handle unit * conversion and model conversion if necessary. * *
  * 
  * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Jan 15, 2010 #3965      rjpeter     Initial creation
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Jan 15, 2010  3965     rjpeter     Initial creation
+ * Apr 11, 2014  2947     bsteffen    Switch spatial matching to use
+ *                                    IGridGeometryProvider
  * 
  * 
* @@ -113,7 +115,7 @@ public class ImportLevelNode extends AbstractAliasLevelNode { } } Collection spaces = null; - ISpatialObject space = time.getSpace(); + IGridGeometryProvider space = time.getSpace(); if (space.equals(TimeAndSpace.SPACE_AGNOSTIC)) { try { spaces = CoverageUtils.getInstance().getCoverages( diff --git a/edexOsgi/com.raytheon.uf.common.derivparam/src/com/raytheon/uf/common/derivparam/tree/OrLevelNode.java b/edexOsgi/com.raytheon.uf.common.derivparam/src/com/raytheon/uf/common/derivparam/tree/OrLevelNode.java index c13d83d0e5..0323c380ed 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam/src/com/raytheon/uf/common/derivparam/tree/OrLevelNode.java +++ b/edexOsgi/com.raytheon.uf.common.derivparam/src/com/raytheon/uf/common/derivparam/tree/OrLevelNode.java @@ -27,17 +27,17 @@ import java.util.List; import java.util.Map; import java.util.Set; -import com.raytheon.uf.common.inventory.data.AbstractRequestableData; -import com.raytheon.uf.common.inventory.exception.DataCubeException; -import com.raytheon.uf.common.inventory.TimeAndSpace; -import com.raytheon.uf.common.inventory.TimeAndSpaceMatcher; -import com.raytheon.uf.common.inventory.TimeAndSpaceMatcher.MatchResult; -import com.raytheon.uf.common.inventory.tree.AbstractRequestableNode; import com.raytheon.uf.common.dataplugin.level.Level; import com.raytheon.uf.common.derivparam.inv.AvailabilityContainer; import com.raytheon.uf.common.derivparam.library.DerivParamDesc; import com.raytheon.uf.common.derivparam.library.DerivParamMethod; -import com.raytheon.uf.common.geospatial.ISpatialObject; +import com.raytheon.uf.common.geospatial.IGridGeometryProvider; +import com.raytheon.uf.common.inventory.TimeAndSpace; +import com.raytheon.uf.common.inventory.TimeAndSpaceMatcher; +import com.raytheon.uf.common.inventory.TimeAndSpaceMatcher.MatchResult; +import com.raytheon.uf.common.inventory.data.AbstractRequestableData; +import com.raytheon.uf.common.inventory.exception.DataCubeException; +import com.raytheon.uf.common.inventory.tree.AbstractRequestableNode; /** * @@ -50,9 +50,11 @@ import com.raytheon.uf.common.geospatial.ISpatialObject; *
  * 
  * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Jan 29, 2010            bsteffen     Initial creation
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Jan 29, 2010           bsteffen    Initial creation
+ * Apr 11, 2014  2947     bsteffen    Switch spatial matching to use
+ *                                    IGridGeometryProvider
  * 
  * 
* @@ -214,8 +216,8 @@ public class OrLevelNode extends AbstractDerivedDataNode { Collection matches = matcher.match(myAvailability, nodeAvail).values(); for (MatchResult match : matches) { - ISpatialObject space1 = match.get1().getSpace(); - ISpatialObject space2 = match.get2().getSpace(); + IGridGeometryProvider space1 = match.get1().getSpace(); + IGridGeometryProvider space2 = match.get2().getSpace(); // if the spaces are equal then remove the new time so it is not // added. This will remove identical times and times that match // ignoring range. diff --git a/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/IGridGeometryProviderComparable.java b/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/IGridGeometryProviderComparable.java new file mode 100644 index 0000000000..a0dd9ecc21 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/IGridGeometryProviderComparable.java @@ -0,0 +1,59 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.common.inventory; + +import org.geotools.coverage.grid.GridGeometry2D; + +import com.raytheon.uf.common.geospatial.IGridGeometryProvider; + +/** + * Interace for {@link IGridGeometryProvider} that can compare itself to other + * IGridGeometryProviders and provide an intersecting IGridGeometryProvider. + * This method can be used by the {@link TimeAndSpaceMatcher} to match different + * spaces. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Apr 11, 2014           bsteffen    Initial creation
+ * 
+ * 
+ * + * @author bsteffen + * @version 1.0 + */ +public interface IGridGeometryProviderComparable extends IGridGeometryProvider { + + /** + * Compare another IGridGeometryProvider to this one. If the two are + * compatible return a provider that will generate a {@link GridGeometry2D} + * representing the intersection. If the two are incompatible or + * nonintersecting null should be returned to indicate no space matching is + * possible. + * + * @param other + * @return + */ + public IGridGeometryProvider compare(IGridGeometryProvider other); + +} diff --git a/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/TimeAndSpace.java b/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/TimeAndSpace.java index b00baaedc6..b0ae680765 100644 --- a/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/TimeAndSpace.java +++ b/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/TimeAndSpace.java @@ -19,11 +19,10 @@ **/ package com.raytheon.uf.common.inventory; -import org.opengis.referencing.crs.CoordinateReferenceSystem; +import org.geotools.coverage.grid.GridGeometry2D; -import com.raytheon.uf.common.geospatial.ISpatialObject; +import com.raytheon.uf.common.geospatial.IGridGeometryProvider; import com.raytheon.uf.common.time.DataTime; -import com.vividsolutions.jts.geom.Geometry; /** * Represents a time and space(location) where data can exist. This is used in @@ -34,9 +33,10 @@ import com.vividsolutions.jts.geom.Geometry; * * SOFTWARE HISTORY * - * Date Ticket# Engineer Description - * ------------ ---------- ----------- -------------------------- - * Apr 11, 2012 bsteffen Initial creation + * Date Ticket# Engineer Description + * ------------- -------- ----------- -------------------------- + * Apr 11, 2012 bsteffen Initial creation + * Apr 11, 2014 2947 bsteffen Switch space to use IGridGeometryProvider * * * @@ -73,40 +73,23 @@ public class TimeAndSpace { * elevation angle for a grid coverage, this can be calculated for any * gridcoverage. */ - public static final ISpatialObject SPACE_AGNOSTIC = new ISpatialObject() { - - private static final long serialVersionUID = 1L; - - @Override - public Integer getNy() { - return null; - } - - @Override - public Integer getNx() { - return null; - } - - @Override - public Geometry getGeometry() { - return null; - } - - @Override - public CoordinateReferenceSystem getCrs() { - return null; - } + public static final IGridGeometryProvider SPACE_AGNOSTIC = new IGridGeometryProvider() { @Override public String toString() { return "SPACE_AGNOSTIC"; } + @Override + public GridGeometry2D getGridGeometry() { + return null; + } + }; private final DataTime time; - private final ISpatialObject space; + private final IGridGeometryProvider space; public TimeAndSpace() { this(TIME_AGNOSTIC, SPACE_AGNOSTIC); @@ -117,11 +100,11 @@ public class TimeAndSpace { } - public TimeAndSpace(ISpatialObject space) { + public TimeAndSpace(IGridGeometryProvider space) { this(TIME_AGNOSTIC, space); } - public TimeAndSpace(DataTime time, ISpatialObject space) { + public TimeAndSpace(DataTime time, IGridGeometryProvider space) { this.time = time; this.space = space; } @@ -130,7 +113,7 @@ public class TimeAndSpace { return time; } - public ISpatialObject getSpace() { + public IGridGeometryProvider getSpace() { return space; } diff --git a/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/TimeAndSpaceMatcher.java b/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/TimeAndSpaceMatcher.java index df6e649b4c..c4f7284bb7 100644 --- a/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/TimeAndSpaceMatcher.java +++ b/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/TimeAndSpaceMatcher.java @@ -25,7 +25,7 @@ import java.util.HashSet; import java.util.Map; import java.util.Set; -import com.raytheon.uf.common.geospatial.ISpatialObject; +import com.raytheon.uf.common.geospatial.IGridGeometryProvider; import com.raytheon.uf.common.time.DataTime; /** @@ -54,9 +54,11 @@ import com.raytheon.uf.common.time.DataTime; * * SOFTWARE HISTORY * - * Date Ticket# Engineer Description - * ------------ ---------- ----------- -------------------------- - * May 8, 2012 bsteffen Initial creation + * Date Ticket# Engineer Description + * ------------- -------- ----------- -------------------------- + * May 08, 2012 bsteffen Initial creation + * Apr 11, 2014 2947 bsteffen Switch spatial matching to use + * IGridGeometryProvider * * * @@ -112,9 +114,7 @@ public class TimeAndSpaceMatcher { MatchResult res = createMatchResult(t1, t2); if (res != null) { MatchResult prev = result.get(res.getMerge()); - if (prev == null - || prev.getMatchValue().compareTo( - res.getMatchValue()) > 0) { + if (prev == null || prev.compareTo(res) > 0) { result.put(res.getMerge(), res); } } @@ -133,55 +133,38 @@ public class TimeAndSpaceMatcher { * @return */ private MatchResult createMatchResult(TimeAndSpace t1, TimeAndSpace t2) { - MatchType matchValue; + TimeMatchType timeMatchType; DataTime time = null; - ISpatialObject space = null; - // first determine what space a match between these two times would have - boolean spaceAgn = false; - if (t1.getSpace().equals(t2.getSpace())) { - // If they match that is best - space = t1.getSpace(); - } else if (t1.isSpaceAgnostic()) { - // space agnostic will match something with space. - spaceAgn = true; - space = t2.getSpace(); - } else if (t2.isSpaceAgnostic()) { - // again one is agnostic - spaceAgn = true; - space = t1.getSpace(); - } else { - // no spatial match, means no match at all. - return null; - } - // Next determine how well the times match + /* Determine how well the times match */ if (t1.isTimeAgnostic()) { - // When one is agnostic it will match anything. + /* When one is agnostic it will match anything. */ time = t2.getTime(); - matchValue = spaceAgn ? MatchType.AGNOSTIC_MATCH - : MatchType.SPACE_MATCH; + timeMatchType = TimeMatchType.AGNOSTIC; } else if (t2.isTimeAgnostic()) { - // again one is agnostic + /* again one is agnostic */ time = t1.getTime(); - matchValue = spaceAgn ? MatchType.AGNOSTIC_MATCH - : MatchType.SPACE_MATCH; + timeMatchType = TimeMatchType.AGNOSTIC; } else if (t1.getTime().equals(t2.getTime())) { - // A perfect time match is always best. + /* A perfect time match is always best. */ time = t1.getTime(); - matchValue = spaceAgn ? MatchType.TIME_MATCH : MatchType.BOTH_MATCH; + timeMatchType = TimeMatchType.MATCH; } else if (ignoreRange && t1.getTime().getMatchRef() == t2.getTime().getMatchRef() && t1.getTime().getMatchFcst() == t2.getTime().getMatchFcst()) { - // If the ignoreRanfe flag is set then it is still considered a - // match even if the ranges are different. + /* + * If the ignoreRanfe flag is set then it is still considered a + * match even if the ranges are different. + */ time = new DataTime(t1.getTime().getRefTime(), t1.getTime() .getFcstTime()); - matchValue = spaceAgn ? MatchType.TIME_IGNORE_RANGE - : MatchType.BOTH_IGNORE_RANGE; + timeMatchType = TimeMatchType.IGNORE_RANGE; } else if (matchValid && t1.getTime().getMatchValid() == t2.getTime().getMatchValid()) { - // finally last valid allows us to mix different - // refTime/forecastTimes as long as valid matches. + /* + * finally last valid allows us to mix different + * refTime/forecastTimes as long as valid matches. + */ if (t1.getTime().getMatchRef() > t2.getTime().getMatchRef()) { time = new DataTime(t1.getTime().getRefTime(), t1.getTime() .getFcstTime()); @@ -189,12 +172,46 @@ public class TimeAndSpaceMatcher { time = new DataTime(t2.getTime().getRefTime(), t2.getTime() .getFcstTime()); } - matchValue = spaceAgn ? MatchType.TIME_VALID : MatchType.BOTH_VALID; + timeMatchType = TimeMatchType.VALID_TIME; } else { + /* no time match, means no match at all. */ return null; } + + SpaceMatchType spaceMatchType = null; + IGridGeometryProvider space = null; + + /* Determine how well the spaces match */ + if (t1.isSpaceAgnostic()) { + /* When one is agnostic it will match anything. */ + space = t2.getSpace(); + spaceMatchType = SpaceMatchType.AGNOSTIC; + } else if (t2.isSpaceAgnostic()) { + /* again one is agnostic */ + space = t1.getSpace(); + spaceMatchType = SpaceMatchType.AGNOSTIC; + } else if (t1.getSpace().equals(t2.getSpace())) { + /* A perfect space match is always best. */ + space = t1.getSpace(); + spaceMatchType = SpaceMatchType.MATCH; + } else { + if(t1.getSpace() instanceof IGridGeometryProviderComparable){ + space = ((IGridGeometryProviderComparable) t1.getSpace()) + .compare(t2.getSpace()); + } + if (space == null + && (t2.getSpace() instanceof IGridGeometryProviderComparable)) { + space = ((IGridGeometryProviderComparable) t2.getSpace()) + .compare(t1.getSpace()); + } + if(space != null){ + spaceMatchType = SpaceMatchType.COMPARABLE; + }else{ + return null; + } + } return new MatchResult(t1, t2, new TimeAndSpace(time, space), - matchValue); + timeMatchType, spaceMatchType); } /** @@ -215,34 +232,32 @@ public class TimeAndSpaceMatcher { * @author bsteffen * @version 1.0 */ - public static class MatchResult { + public static class MatchResult implements Comparable { - /** - * The TimeAndSpace from the first collection that matches - */ + /** The TimeAndSpace from the first collection that matches */ private final TimeAndSpace t1; - /** - * The TimeAndSpace from the second collection that matches - */ + /** The TimeAndSpace from the second collection that matches */ private final TimeAndSpace t2; - /** - * The TimeAndSpace from the first collection that matches - */ + /** The TimeAndSpace from the first collection that matches */ private final TimeAndSpace merge; - /** - * How good of a match is this. - */ - private final MatchType matchValue; + /** How good of a time match is this. */ + private final TimeMatchType timeMatchType; - public MatchResult(TimeAndSpace t1, TimeAndSpace t2, - TimeAndSpace merge, MatchType matchValue) { + /** How good of a space match is this. */ + private final SpaceMatchType spaceMatchType; + + private MatchResult(TimeAndSpace t1, TimeAndSpace t2, + TimeAndSpace merge, TimeMatchType timeMatchType, + SpaceMatchType spaceMatchType) { + super(); this.t1 = t1; this.t2 = t2; this.merge = merge; - this.matchValue = matchValue; + this.timeMatchType = timeMatchType; + this.spaceMatchType = spaceMatchType; } public TimeAndSpace get1() { @@ -257,59 +272,51 @@ public class TimeAndSpaceMatcher { return merge; } - public MatchType getMatchValue() { - return matchValue; + public TimeMatchType getTimeMatchType() { + return timeMatchType; + } + + public SpaceMatchType getSpaceMatchType() { + return spaceMatchType; + } + + @Override + public int compareTo(MatchResult o) { + int result = timeMatchType.compareTo(o.getTimeMatchType()); + if (result == 0) { + result = spaceMatchType.compareTo(o.getSpaceMatchType()); + } + return result; } } - /** - * - * An enum which represents the quality of the match, The best matches are - * when both Time and Space objects are matches, but there are other - * matches, usually involving either Time or Space agnostic that are not as - * ideal but are suitable. - * - *
-     * 
-     * SOFTWARE HISTORY
-     * 
-     * Date         Ticket#    Engineer    Description
-     * ------------ ---------- ----------- --------------------------
-     * Sep 27, 2012            bsteffen     Initial creation
-     * 
-     * 
- * - * @author bsteffen - * @version 1.0 - */ - public static enum MatchType { + public static enum TimeMatchType { + /* Perfect match */ + MATCH, - // Time and space match perfectly - BOTH_MATCH, + /* Reftime and forecast time match but ranges do not */ + IGNORE_RANGE, - // Space matches perfectly but time only matches if you ignore range - BOTH_IGNORE_RANGE, + /* Only valid time matches, not ref/forectast time. */ + VALID_TIME, - // Space matches perfectly but time only matches valid time - BOTH_VALID, + /* One is time or both are time agnostic so it matches everything. */ + AGNOSTIC + } - // one is space agnostic and time matches - TIME_MATCH, + public static enum SpaceMatchType { + /* Perfect match */ + MATCH, - // one is space agnostic but time only matches if you ignore range - TIME_IGNORE_RANGE, - - // one is space agnostic but time only matches valid time - TIME_VALID, - - // space matches perfectly and one is time agnostic - SPACE_MATCH, - - // one is both time and space agnostic so they match even though - // they have nothing in common - AGNOSTIC_MATCH; + /* + * One or both implements IGridGeometryProviderComparable and found a + * suitable intersection + */ + COMPARABLE, + /* One is time or both are space agnostic so it matches everything. */ + AGNOSTIC } /** diff --git a/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/data/AbstractRequestableData.java b/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/data/AbstractRequestableData.java index 68126737f0..f0feaa2022 100644 --- a/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/data/AbstractRequestableData.java +++ b/edexOsgi/com.raytheon.uf.common.inventory/src/com/raytheon/uf/common/inventory/data/AbstractRequestableData.java @@ -24,10 +24,10 @@ import java.util.List; import javax.measure.unit.Unit; -import com.raytheon.uf.common.inventory.exception.DataCubeException; -import com.raytheon.uf.common.inventory.TimeAndSpace; import com.raytheon.uf.common.dataplugin.level.Level; -import com.raytheon.uf.common.geospatial.ISpatialObject; +import com.raytheon.uf.common.geospatial.IGridGeometryProvider; +import com.raytheon.uf.common.inventory.TimeAndSpace; +import com.raytheon.uf.common.inventory.exception.DataCubeException; import com.raytheon.uf.common.time.DataTime; /** @@ -40,9 +40,11 @@ import com.raytheon.uf.common.time.DataTime; *
  * 
  * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Mar 17, 2010            bsteffen     Initial creation
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Mar 17, 2010           bsteffen    Initial creation
+ * Apr 11, 2014  2947     bsteffen    Switch spatial matching to use
+ *                                    IGridGeometryProvider
  * 
  * 
* @@ -64,7 +66,7 @@ public abstract class AbstractRequestableData { protected DataTime dataTime = TimeAndSpace.TIME_AGNOSTIC; - protected ISpatialObject space = TimeAndSpace.SPACE_AGNOSTIC; + protected IGridGeometryProvider space = TimeAndSpace.SPACE_AGNOSTIC; public AbstractRequestableData() { @@ -162,11 +164,11 @@ public abstract class AbstractRequestableData { this.level = level; } - public ISpatialObject getSpace() { + public IGridGeometryProvider getSpace() { return space; } - public void setSpace(ISpatialObject space) { + public void setSpace(IGridGeometryProvider space) { this.space = space; } From 7e8e7567989918ab8fdfeac7a1bbedde7b8a8265 Mon Sep 17 00:00:00 2001 From: Everett Kladstrup Date: Mon, 14 Apr 2014 09:35:59 -0500 Subject: [PATCH 011/188] Issue #2725 Fix imports in python after derived param move Former-commit-id: 1680849c4b86113b74228d54b058d6af89311514 --- .../common_static/base/derivedParameters/functions/Cape.py | 2 +- .../common_static/base/derivedParameters/functions/Dcape.py | 2 +- .../common_static/base/derivedParameters/functions/Filter.py | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Cape.py b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Cape.py index a7682df622..da98d5c111 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Cape.py +++ b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Cape.py @@ -18,7 +18,7 @@ # further licensing information. ## -from com.raytheon.uf.viz.derivparam.python.function import CapeFuncPythonAdapter as CapeFunc +from com.raytheon.uf.common.derivparam.python.function import CapeFuncPythonAdapter as CapeFunc from numpy import zeros def execute(*args): diff --git a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Dcape.py b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Dcape.py index 49ffc2748e..778bab0f56 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Dcape.py +++ b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Dcape.py @@ -26,7 +26,7 @@ # Jun 05, 2013 2043 bsteffen Ported from meteolib C from numpy import zeros -from com.raytheon.uf.viz.derivparam.python.function import DCapeFuncPythonAdapter as DCapeFunc +from com.raytheon.uf.common.derivparam.python.function import DCapeFuncPythonAdapter as DCapeFunc def execute(threeDtemperature, threeDdewpoint, pressure, potentialTemperature, specificHumidity,maxEvaporation,maxRelativeHumidity,useVirtualTemp): diff --git a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Filter.py b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Filter.py index 72a2b6293b..3689fccf16 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Filter.py +++ b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Filter.py @@ -20,7 +20,7 @@ from numpy import ndarray, float32, NaN from numpy import sin, isnan, invert -from com.raytheon.uf.viz.derivparam.python.function import DistFilterPythonAdapter as DistFilter +from com.raytheon.uf.common.derivparam.python.function import DistFilterPythonAdapter as DistFilter MAX_WAVE_NUMBER = 15 From 9a72fdc4e22347259e744fa34abc5389bd3c1b69 Mon Sep 17 00:00:00 2001 From: Melissa Porricel Date: Mon, 14 Apr 2014 11:48:00 -0400 Subject: [PATCH 012/188] ASM #530 - Enable calculation/display of snow accum for GFSEnsemble Change-Id: I0036ab27ba16fc530d48853e9de4b3f7e763dc43 Former-commit-id: fe1d0f147e2b0e4106afd092bb381e7958ca7a6e --- .../edex/grid/staticdata/StaticDataGenerator.java | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/edexOsgi/com.raytheon.uf.edex.grid.staticdata/src/com/raytheon/uf/edex/grid/staticdata/StaticDataGenerator.java b/edexOsgi/com.raytheon.uf.edex.grid.staticdata/src/com/raytheon/uf/edex/grid/staticdata/StaticDataGenerator.java index 7bd4e1ec92..84dc2726fe 100644 --- a/edexOsgi/com.raytheon.uf.edex.grid.staticdata/src/com/raytheon/uf/edex/grid/staticdata/StaticDataGenerator.java +++ b/edexOsgi/com.raytheon.uf.edex.grid.staticdata/src/com/raytheon/uf/edex/grid/staticdata/StaticDataGenerator.java @@ -72,6 +72,9 @@ import com.raytheon.uf.edex.plugin.grid.dao.GridDao; * Feb 15, 2013 1638 mschenke Moved DataURINotificationMessage to uf.common.dataplugin * Mar 07, 2013 1587 bsteffen rewrite static data generation. * Mar 14, 2013 1587 bsteffen Fix persisting to datastore. + * Apr 14, 2014 DR 16752 MPorricelli Add ensembleid to hash key to allow + * creation of static data for all perturbations + * of Ensemble models * * * @@ -445,12 +448,15 @@ public class StaticDataGenerator { private final int forecastTime; private final int coverageid; + + private final String ensembleid; public CacheKey(GridRecord record) { this.datasetid = record.getDatasetId(); this.refTime = record.getDataTime().getRefTime(); this.forecastTime = record.getDataTime().getFcstTime(); this.coverageid = record.getLocation().getId(); + this.ensembleid = record.getEnsembleId(); } @Override @@ -463,6 +469,8 @@ public class StaticDataGenerator { result = (prime * result) + forecastTime; result = (prime * result) + ((refTime == null) ? 0 : refTime.hashCode()); + result = (prime * result) + + ((ensembleid == null) ? 0 : ensembleid.hashCode()); return result; } @@ -498,6 +506,13 @@ public class StaticDataGenerator { } else if (!refTime.equals(other.refTime)) { return false; } + if (ensembleid == null) { + if (other.ensembleid != null) { + return false; + } + } else if (!ensembleid.equals(other.ensembleid)) { + return false; + } return true; } From dbba727f3d97dedf782c75edd5e8c7f53ff03427 Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Wed, 19 Mar 2014 14:23:52 -0500 Subject: [PATCH 013/188] Issue #2726: Edex graceful shutdown. Refactored to use inheritance and separate logic where possible. Addressed comments. Change-Id: I9e62414cd83121575bdf99a3b47466a7585bedb6 Former-commit-id: 6e015b3f61c20635077d6e8271e9b763e5a32fe1 --- .../src/com/raytheon/uf/viz/core/VizApp.java | 15 +- .../esb/conf/res/base/attributeNames.xml | 1 - .../esb/conf/res/base/environment.xml | 1 - .../spring/32-bit/architecture.properties | 7 - .../spring/64-bit/architecture.properties | 7 - edexOsgi/build.edex/esb/conf/spring/edex.xml | 212 ++++--- edexOsgi/build.edex/esb/conf/wrapper.conf | 4 + edexOsgi/build.edex/esb/etc/default.sh | 2 - edexOsgi/build.edex/esb/etc/ingestDat.sh | 2 - edexOsgi/build.edex/esb/etc/ingestGrib.sh | 2 - edexOsgi/build.edex/esb/etc/request.sh | 2 - edexOsgi/build.edex/esb/etc/requestHydro.sh | 2 - .../res/spring/subscription-common.xml | 6 +- .../res/spring/subscription-request.xml | 10 +- .../res/spring/subscription-spring.xml | 4 +- .../raytheon/edex/plugin/InitializerBean.java | 72 --- .../res/spring/binlightning_ep-ingest.xml | 12 +- .../res/spring/bufrmos-ingest.xml | 8 +- .../res/spring/bufrua-ingest.xml | 8 +- .../res/spring/ccfp-ingest.xml | 7 +- .../build.properties | 3 +- .../res/spring/gfe-common.xml | 3 +- .../res/spring/gfe-request.xml | 27 +- .../res/spring/gfe-spring.xml | 34 +- .../com.raytheon.edex.plugin.gfe.properties | 2 + .../plugin/gfe/config/GFESiteActivation.java | 48 +- .../edex/plugin/gfe/isc/IscSendJob.java | 267 --------- .../edex/plugin/gfe/isc/SendIscSrv.java | 209 ++++++- .../edex/plugin/gfe/isc/SendIscSrvConfig.java | 82 --- .../plugin/gfe/smartinit/SmartInitSrv.java | 268 ++++----- .../gfe/smartinit/SmartInitSrvConfig.java | 91 --- .../res/spring/goessounding-ingest.xml | 9 +- .../res/spring/grib-decode.xml | 17 +- .../base/grib/thinnedModels/UkmetHR-NH.xml | 2 +- .../res/spring/ldadhydro-ingest.xml | 8 +- .../res/spring/ldadmanual-ingest.xml | 8 +- .../res/spring/ldadprofiler-ingest.xml | 8 +- .../res/spring/obs-ingest-decode.xml | 10 +- .../res/spring/obs-ingest-metarshef.xml | 9 +- .../res/spring/obs-ingest.xml | 3 +- .../res/spring/poessounding-ingest.xml | 8 +- .../res/spring/profiler-ingest.xml | 8 +- .../res/spring/radar-ingest.xml | 8 +- .../res/spring/recco-ingest.xml | 8 +- .../res/spring/redbook-ingest.xml | 17 +- .../res/spring/satellite-ingest.xml | 10 +- .../res/spring/sfcobs-ingest.xml | 8 +- .../res/spring/shef-ingest.xml | 11 +- .../res/spring/taf-ingest.xml | 8 +- .../res/spring/text-ingest.xml | 6 +- .../res/spring/textlightning_ep-ingest.xml | 8 +- .../res/spring/warning-ingest.xml | 8 +- .../res/spring/warning-request.xml | 48 +- .../GenerateGeospatialDataRequestHandler.java | 17 +- .../warning/gis/GeospatialDataGenerator.java | 135 +++-- .../warning/gis/GeospatialDataUpdater.java | 140 ----- .../res/spring/rpgenvdata-spring.xml | 2 +- .../res/spring/textdb-ingest.xml | 1 - .../res/spring/utility-request.xml | 2 +- .../META-INF/MANIFEST.MF | 1 - .../common/dataplugin/PluginProperties.java | 54 +- .../defaults/PluginPropertyDefaults.java | 120 ---- .../META-INF/MANIFEST.MF | 3 +- .../com/raytheon/uf/common/message/WsId.java | 84 +-- .../raytheon/uf/common/util/SystemUtil.java | 127 +++- .../res/spring/activetable-ingest.xml | 10 +- .../res/spring/activetable-request.xml | 5 +- .../com/raytheon/uf/edex/core/EDEXUtil.java | 49 +- .../uf/edex/core/EdexTimerBasedThread.java | 172 ++++++ .../uf/edex/core/IContextStateProcessor.java} | 50 +- .../edex/core/dataplugin/PluginRegistry.java | 34 +- .../res/spring/cpgsrv-spring.xml | 14 +- .../res/spring/database-common.xml | 4 +- .../edex/database/DatabasePluginRegistry.java | 33 +- .../edex/database/plugin/PluginFactory.java | 19 +- .../res/spring/event-datadelivery-ingest.xml | 7 +- .../res/spring/harvester-datadelivery.xml | 20 +- .../res/spring/registry-datadelivery.xml | 3 +- .../registry-federation-datadelivery.xml | 3 +- .../res/spring/grid-metadata.xml | 3 +- .../res/spring/dissemination-request.xml | 26 +- .../res/spring/distribution-spring.xml | 7 +- .../META-INF/MANIFEST.MF | 4 +- .../raytheon/uf/edex/esb/camel/Executor.java | 39 +- .../uf/edex/esb/camel/MessageProducer.java | 366 ++++++++---- .../uf/edex/esb/camel/StringToFile.java | 21 +- .../context/ClusteredContextManager.java | 190 ------ .../context/ClusteredContextStateManager.java | 144 +++++ .../edex/esb/camel/context/ContextData.java | 222 +++++++ .../context/ContextDependencyMapping.java | 268 +++++++++ .../esb/camel/context/ContextManager.java | 559 ++++++++++++++++-- .../context/DefaultContextStateManager.java | 215 +++++++ .../DependencyContextStateManager.java | 229 +++++++ .../esb/camel/context/DependencyNode.java | 145 +++++ .../camel/context/IContextStateManager.java | 96 +++ .../esb/camel/directvm/DirectVMComponent.java | 100 ---- .../esb/camel/directvm/DirectVMEndpoint.java | 102 ---- .../esb/camel/directvm/DirectVMProducer.java | 111 ---- .../jms/DedicatedThreadJmsComponent.java | 1 - .../spring/JmsThreadPoolTaskExecutor.java | 23 +- .../res/spring/persist-ingest.xml | 6 +- .../res/spring/persist-request.xml | 1 - .../ingest/notification/PluginNotifier.java | 27 +- .../res/spring/metartohmdb-plugin.xml | 7 +- .../res/spring/ndm-ingest.xml | 10 +- .../res/spring/ogc-common-convert.xml | 4 +- .../res/spring/ogc-common.xml | 4 +- .../res/spring/arealQpeGen-spring.xml | 6 +- .../res/spring/gaff-spring.xml | 8 +- .../res/spring/hpeDHRDecoder-spring.xml | 8 +- .../res/spring/mpeLightningSrv-ingest.xml | 2 +- .../res/spring/satpre-spring.xml | 6 +- .../res/spring/acars-ingest.xml | 10 +- .../res/spring/acarssounding-ingest.xml | 8 +- .../res/spring/bufrascat-ingest.xml | 8 +- .../res/spring/bufrhdw-ingest.xml | 8 +- .../res/spring/bufrmthdw-ingest.xml | 8 +- .../res/spring/bufrncwf-ingest.xml | 8 +- .../res/spring/bufrobs-ingest.xml | 7 +- .../res/spring/bufrquikscat-ingest.xml | 8 +- .../res/spring/bufrsigwx-ingest.xml | 8 +- .../res/spring/bufrssmi-ingest.xml | 8 +- .../res/spring/cwa-ingest.xml | 8 +- .../res/spring/cwat-ingest.xml | 2 +- .../res/spring/retrieval-common.xml | 3 +- .../res/spring/retrieval-ingest.xml | 3 +- .../res/spring/ffmp-ingest.xml | 2 +- .../res/spring/fog-ingest.xml | 2 +- .../res/spring/fssobs-ingest.xml | 2 +- .../res/spring/ldadmesonet-ingest.xml | 12 +- .../res/spring/lsr-ingest.xml | 8 +- .../res/spring/madis-ogc-routes.xml | 8 +- .../res/spring/madis-ogc.xml | 3 +- .../res/spring/madis-ogc-registry.xml | 8 +- .../res/spring/madis-common.xml | 3 +- .../res/spring/manualIngest-request.xml | 2 +- .../res/spring/manualIngest-spring.xml | 5 +- .../res/spring/modelsounding-ingest.xml | 28 +- .../modelsounding/ModelSoundingDecoder.java | 8 - .../ModelSoundingPersistenceManager.java | 85 ++- .../res/spring/crimss-ingest.xml | 8 +- .../res/spring/nucaps-ingest.xml | 8 +- .../res/spring/viirs-ingest.xml | 8 +- .../res/spring/obs-dpa-ingest.xml | 9 +- .../res/spring/obs-ogc-routes.xml | 8 +- .../res/spring/obs-ogc.xml | 5 +- .../res/spring/obs-ogc-registry.xml | 6 - .../res/spring/preciprate-ingest.xml | 2 +- .../res/spring/qc-ingest.xml | 8 +- .../res/spring/qpf-ingest.xml | 2 +- .../res/spring/satellite-mcidas-ingest.xml | 8 +- .../res/spring/scan-ingest.xml | 9 +- .../res/spring/svrwx-ingest.xml | 8 +- .../res/spring/tcg-ingest.xml | 8 +- .../res/spring/tcs-ingest.xml | 8 +- .../res/spring/vaa-ingest.xml | 8 +- .../res/spring/vil-ingest.xml | 2 +- .../res/spring/purge-spring.xml | 5 +- .../res/spring/ebxml-webserver.xml | 4 +- .../res/spring/site-common.xml | 8 +- .../res/spring/stats-ingest.xml | 7 +- .../res/spring/tafqueue-request.xml | 5 +- .../res/spring/textdbsrv-request.xml | 4 +- .../res/spring/wfs-ogc-soap-request.xml | 6 +- .../res/spring/ncinventory-request.xml | 28 +- .../spring/ncep-util-on-edex-ingestGrib.xml | 3 +- .../res/spring/ncep-util-on-edex-ingest.xml | 3 +- .../res/spring/airep-ingest.xml | 8 +- .../res/spring/airmet-ingest.xml | 8 +- .../res/spring/atcf-ingest.xml | 8 +- .../res/spring/aww-ingest.xml | 8 +- .../res/spring/convsigmet-ingest.xml | 8 +- .../res/spring/ffg-ingest.xml | 8 +- .../res/spring/geomag-common.xml | 6 +- .../res/spring/geomag-ingest.xml | 13 +- .../res/spring/gpd-common.xml | 3 +- .../res/spring/gpd-request.xml | 6 +- .../res/spring/idft-ingest.xml | 8 +- .../res/spring/intlsigmet-ingest.xml | 8 +- .../res/spring/mcidas-ingest.xml | 8 +- .../res/spring/mosaic-ingest.xml | 8 +- .../res/spring/ncgrib-file-endpoint.xml | 6 +- .../res/spring/ncpafm-ingest.xml | 8 +- .../res/spring/ncscat-ingest.xml | 8 +- .../res/spring/ncscd-ingest.xml | 7 +- .../res/spring/nctaf-ingest.xml | 8 +- .../res/spring/nctext-ingest.xml | 8 +- .../res/spring/ncuair-ingest.xml | 8 +- .../res/spring/nonconvsigmet-ingest.xml | 8 +- .../res/spring/ntrans-ingest.xml | 8 +- .../res/spring/pirep-ingest.xml | 8 +- .../res/spring/sgwh-ingest.xml | 8 +- .../res/spring/sgwhv-ingest.xml | 8 +- .../res/spring/solarimage-ingest.xml | 8 +- .../res/spring/ssha-ingest.xml | 8 +- .../res/spring/stormtrack-ingest.xml | 8 +- .../res/spring/tcm-ingest.xml | 8 +- .../res/spring/wcp-ingest.xml | 8 +- .../res/spring/regionalsat-ingest.xml | 8 +- tools/scripts/commit-msg | 0 tools/scripts/git-u-setup | 0 tools/scripts/uamend | 0 tools/scripts/ucommit | 0 tools/scripts/upull | 0 tools/scripts/upush | 0 tools/scripts/ustat | 0 206 files changed, 3562 insertions(+), 2865 deletions(-) delete mode 100644 edexOsgi/build.edex/esb/conf/spring/32-bit/architecture.properties delete mode 100644 edexOsgi/build.edex/esb/conf/spring/64-bit/architecture.properties delete mode 100644 edexOsgi/com.raytheon.edex.common/src/com/raytheon/edex/plugin/InitializerBean.java create mode 100644 edexOsgi/com.raytheon.edex.plugin.gfe/resources/com.raytheon.edex.plugin.gfe.properties delete mode 100644 edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/isc/IscSendJob.java delete mode 100644 edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/isc/SendIscSrvConfig.java delete mode 100644 edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/SmartInitSrvConfig.java delete mode 100644 edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataUpdater.java delete mode 100644 edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/defaults/PluginPropertyDefaults.java create mode 100644 edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/EdexTimerBasedThread.java rename edexOsgi/{com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataGeneratorThread.java => com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/IContextStateProcessor.java} (53%) delete mode 100644 edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ClusteredContextManager.java create mode 100644 edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ClusteredContextStateManager.java create mode 100644 edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextData.java create mode 100644 edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextDependencyMapping.java create mode 100644 edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/DefaultContextStateManager.java create mode 100644 edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/DependencyContextStateManager.java create mode 100644 edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/DependencyNode.java create mode 100644 edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/IContextStateManager.java delete mode 100644 edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/directvm/DirectVMComponent.java delete mode 100644 edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/directvm/DirectVMEndpoint.java delete mode 100644 edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/directvm/DirectVMProducer.java mode change 100644 => 100755 tools/scripts/commit-msg mode change 100644 => 100755 tools/scripts/git-u-setup mode change 100644 => 100755 tools/scripts/uamend mode change 100644 => 100755 tools/scripts/ucommit mode change 100644 => 100755 tools/scripts/upull mode change 100644 => 100755 tools/scripts/upush mode change 100644 => 100755 tools/scripts/ustat diff --git a/cave/com.raytheon.uf.viz.core/src/com/raytheon/uf/viz/core/VizApp.java b/cave/com.raytheon.uf.viz.core/src/com/raytheon/uf/viz/core/VizApp.java index 40bd59022a..a10b88e1df 100644 --- a/cave/com.raytheon.uf.viz.core/src/com/raytheon/uf/viz/core/VizApp.java +++ b/cave/com.raytheon.uf.viz.core/src/com/raytheon/uf/viz/core/VizApp.java @@ -31,6 +31,7 @@ import org.eclipse.ui.statushandlers.StatusManager; import com.raytheon.uf.common.localization.LocalizationContext.LocalizationLevel; import com.raytheon.uf.common.message.WsId; +import com.raytheon.uf.common.util.SystemUtil; import com.raytheon.uf.viz.core.localization.LocalizationManager; /** @@ -49,7 +50,7 @@ import com.raytheon.uf.viz.core.localization.LocalizationManager; * Aug 27, 2013 2295 bkowal Removed the jms server property; added * jms connection string * Feb 17, 2014 2812 njensen getHostName() now uses getWsId()'s hostname - * + * Mar 20, 2014 2726 rjpeter Moved host processing to SystemUtil. * * * @author chammack @@ -252,21 +253,13 @@ public final class VizApp { private static String host = null; /** - * Gets the host name from the WsId of the host machine calling the function + * Gets the host name of the machine calling the function * * @return */ public static synchronized String getHostName() { if (host == null) { - host = getWsId().getHostName(); - if (host == null) { - String hostname = System.getenv("HOSTNAME"); - if (hostname != null && hostname.trim().length() > 0) { - host = hostname; - } else { - host = "localhost"; - } - } + host = SystemUtil.getHostName(); } return host; } diff --git a/edexOsgi/build.edex/esb/conf/res/base/attributeNames.xml b/edexOsgi/build.edex/esb/conf/res/base/attributeNames.xml index c6e6cd6568..6566c0bfd5 100644 --- a/edexOsgi/build.edex/esb/conf/res/base/attributeNames.xml +++ b/edexOsgi/build.edex/esb/conf/res/base/attributeNames.xml @@ -233,7 +233,6 @@ utilityDir staticDir sitename - gfeSmartInitEnable logDir fxaDebugSaveBadTextFiles archiveDir diff --git a/edexOsgi/build.edex/esb/conf/res/base/environment.xml b/edexOsgi/build.edex/esb/conf/res/base/environment.xml index f76a4ebefe..d86d21241a 100644 --- a/edexOsgi/build.edex/esb/conf/res/base/environment.xml +++ b/edexOsgi/build.edex/esb/conf/res/base/environment.xml @@ -48,7 +48,6 @@ ${env:edex.home}/data/share ${env:edex.home}/data/utility ${env:edex.home}/data/static - true false ${env:edex.home}/../GFESuite/ /data/fxa/mhs diff --git a/edexOsgi/build.edex/esb/conf/spring/32-bit/architecture.properties b/edexOsgi/build.edex/esb/conf/spring/32-bit/architecture.properties deleted file mode 100644 index ce5c79eac6..0000000000 --- a/edexOsgi/build.edex/esb/conf/spring/32-bit/architecture.properties +++ /dev/null @@ -1,7 +0,0 @@ -# The following properties are used to define the EDEX system configuration. -# Modifying these values will affect system performance. - -smartinit.threadpoolsize=3 -# smartinit.threads should be 2 less than smartinit.threadpoolszie -# to account for reading from the notify topic and the manual queue -smartinit.threads=1 diff --git a/edexOsgi/build.edex/esb/conf/spring/64-bit/architecture.properties b/edexOsgi/build.edex/esb/conf/spring/64-bit/architecture.properties deleted file mode 100644 index dd5c190435..0000000000 --- a/edexOsgi/build.edex/esb/conf/spring/64-bit/architecture.properties +++ /dev/null @@ -1,7 +0,0 @@ -# The following properties are used to define the EDEX system configuration. -# Modifying these values will affect system performance. - -smartinit.threadpoolsize=4 -# smartinit.threads should be 2 less than smartinit.threadpoolszie -# to account for reading from the notify topic and the manual queue -smartinit.threads=2 diff --git a/edexOsgi/build.edex/esb/conf/spring/edex.xml b/edexOsgi/build.edex/esb/conf/spring/edex.xml index fd937b7deb..457fbdef65 100644 --- a/edexOsgi/build.edex/esb/conf/spring/edex.xml +++ b/edexOsgi/build.edex/esb/conf/spring/edex.xml @@ -3,14 +3,14 @@ xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:util="http://www.springframework.org/schema/util" - xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd + xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-3.1.xsd"> - - - - + + + + @@ -24,7 +24,7 @@ - + @@ -64,12 +64,14 @@ - + + + - + - + - - - + + + - + - + - + - + - - + @@ -136,53 +137,84 @@ - + - - - - + + + + - - + + + + + + - + + + + + + + + + + + + + + + + + + + + + + - - - - - - - + + + + + + + - - - - - + + + + + + + + + + - - - - - - - - - - - + - - + + - + @@ -193,38 +225,10 @@ - + - - - - - - - - - - - - - - - - - - - - - - + class="com.raytheon.uf.edex.esb.camel.EDEXParameterMappingStrategy" /> @@ -248,7 +252,7 @@ - + @@ -263,13 +267,6 @@ - - - - - - - @@ -281,16 +278,15 @@ - + + errorHandlerRef="errorHandler"> - + java.lang.Throwable @@ -298,10 +294,6 @@ - - - @@ -314,7 +306,6 @@ file:${edex.home}/conf/spring/cron.properties - file:${edex.home}/conf/spring/${edex.arch}/architecture.properties @@ -322,11 +313,11 @@ - + - + @@ -341,7 +332,7 @@ - + @@ -353,14 +344,10 @@ - - - - + Single scheduler used by all endpoints so there is only one threadpool. + Thread pool configured in edex/config/resources/quartz.properties. + Requires work around in ContextManager.postProcessBeanFactory when JMX is disabled --> @@ -376,5 +363,4 @@ class="com.raytheon.uf.edex.esb.camel.cluster.quartz.ClusteredQuartzComponent"> - diff --git a/edexOsgi/build.edex/esb/conf/wrapper.conf b/edexOsgi/build.edex/esb/conf/wrapper.conf index f9a378082f..a42d5cf480 100644 --- a/edexOsgi/build.edex/esb/conf/wrapper.conf +++ b/edexOsgi/build.edex/esb/conf/wrapper.conf @@ -160,6 +160,10 @@ wrapper.app.parameter.2=start wrapper.ping.timeout=300 +# jvm will be hard killed after 5 minutes of trying to shutdown +wrapper.jvm_exit.timeout=0 +wrapper.shutdown.timeout=300 + #******************************************************************** # Monitor the Application #******************************************************************** diff --git a/edexOsgi/build.edex/esb/etc/default.sh b/edexOsgi/build.edex/esb/etc/default.sh index 7d2a181151..a9c35fdd80 100644 --- a/edexOsgi/build.edex/esb/etc/default.sh +++ b/edexOsgi/build.edex/esb/etc/default.sh @@ -23,8 +23,6 @@ export MAX_MEM=1300 # in Meg export MAX_PERM_SIZE=128m export EDEX_JMX_PORT=1616 export EDEX_DEBUG_PORT=5005 -export JMS_POOL_MIN=64 -export JMS_POOL_MAX=128 export METADATA_POOL_MIN=5 export METADATA_POOL_MAX=50 export METADATA_POOL_TIMEOUT=300 diff --git a/edexOsgi/build.edex/esb/etc/ingestDat.sh b/edexOsgi/build.edex/esb/etc/ingestDat.sh index 473b30db5d..2c551e3f81 100644 --- a/edexOsgi/build.edex/esb/etc/ingestDat.sh +++ b/edexOsgi/build.edex/esb/etc/ingestDat.sh @@ -21,8 +21,6 @@ export INIT_MEM=256 # in Meg export MAX_MEM=1792 # in Meg -export JMS_POOL_MIN=16 -export JMS_POOL_MAX=32 export METADATA_POOL_MIN=15 export METADATA_POOL_MAX=30 export EDEX_DEBUG_PORT=5008 diff --git a/edexOsgi/build.edex/esb/etc/ingestGrib.sh b/edexOsgi/build.edex/esb/etc/ingestGrib.sh index 971f85c6fd..0c424d1638 100644 --- a/edexOsgi/build.edex/esb/etc/ingestGrib.sh +++ b/edexOsgi/build.edex/esb/etc/ingestGrib.sh @@ -21,8 +21,6 @@ export INIT_MEM=128 # in Meg export MAX_MEM=512 # in Meg -export JMS_POOL_MIN=4 -export JMS_POOL_MAX=16 export METADATA_POOL_MIN=4 export METADATA_POOL_MAX=10 export EDEX_DEBUG_PORT=5007 diff --git a/edexOsgi/build.edex/esb/etc/request.sh b/edexOsgi/build.edex/esb/etc/request.sh index 4a7303b979..536081a2f2 100644 --- a/edexOsgi/build.edex/esb/etc/request.sh +++ b/edexOsgi/build.edex/esb/etc/request.sh @@ -29,8 +29,6 @@ export SERIALIZE_STREAM_INIT_SIZE_MB=2 export SERIALIZE_STREAM_MAX_SIZE_MB=8 -export JMS_POOL_MIN=16 -export JMS_POOL_MAX=32 export EDEX_DEBUG_PORT=5005 export EDEX_JMX_PORT=1616 export MGMT_PORT=9601 diff --git a/edexOsgi/build.edex/esb/etc/requestHydro.sh b/edexOsgi/build.edex/esb/etc/requestHydro.sh index 4d07d95073..37e80657b7 100644 --- a/edexOsgi/build.edex/esb/etc/requestHydro.sh +++ b/edexOsgi/build.edex/esb/etc/requestHydro.sh @@ -29,8 +29,6 @@ export SERIALIZE_STREAM_INIT_SIZE_MB=2 export SERIALIZE_STREAM_MAX_SIZE_MB=8 -export JMS_POOL_MIN=8 -export JMS_POOL_MAX=24 export EDEX_DEBUG_PORT=5005 export EDEX_JMX_PORT=1616 export MGMT_PORT=9601 diff --git a/edexOsgi/com.raytheon.edex.autobldsrv/res/spring/subscription-common.xml b/edexOsgi/com.raytheon.edex.autobldsrv/res/spring/subscription-common.xml index 766bbba845..24d5dc5b41 100644 --- a/edexOsgi/com.raytheon.edex.autobldsrv/res/spring/subscription-common.xml +++ b/edexOsgi/com.raytheon.edex.autobldsrv/res/spring/subscription-common.xml @@ -20,8 +20,8 @@ depends-on="metadataTxManager"> - - + @@ -34,7 +34,7 @@ - + diff --git a/edexOsgi/com.raytheon.edex.autobldsrv/res/spring/subscription-request.xml b/edexOsgi/com.raytheon.edex.autobldsrv/res/spring/subscription-request.xml index 789fd319d9..c40e01ac60 100644 --- a/edexOsgi/com.raytheon.edex.autobldsrv/res/spring/subscription-request.xml +++ b/edexOsgi/com.raytheon.edex.autobldsrv/res/spring/subscription-request.xml @@ -5,13 +5,13 @@ http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd"> - - - + uri="jetty:http://0.0.0.0:${HTTP_PORT}/services/subscribe?disableStreamCache=true" /> + + diff --git a/edexOsgi/com.raytheon.edex.autobldsrv/res/spring/subscription-spring.xml b/edexOsgi/com.raytheon.edex.autobldsrv/res/spring/subscription-spring.xml index cdf139c5bf..9674008e75 100644 --- a/edexOsgi/com.raytheon.edex.autobldsrv/res/spring/subscription-spring.xml +++ b/edexOsgi/com.raytheon.edex.autobldsrv/res/spring/subscription-spring.xml @@ -8,14 +8,14 @@ - + - diff --git a/edexOsgi/com.raytheon.edex.common/src/com/raytheon/edex/plugin/InitializerBean.java b/edexOsgi/com.raytheon.edex.common/src/com/raytheon/edex/plugin/InitializerBean.java deleted file mode 100644 index 6e8de257ad..0000000000 --- a/edexOsgi/com.raytheon.edex.common/src/com/raytheon/edex/plugin/InitializerBean.java +++ /dev/null @@ -1,72 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ - -package com.raytheon.edex.plugin; - -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; - -/** - * This class is instantiated on startup by the ESB spring container context - * before any other beans. Therefore, any system level initialization activities - * may be placed here. - *

- * The basic functionality of this class will initialize all the plugins - * - *

- * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * 02/06/09     1990       bphillip    Initial creation
- * 
- * - * @author bphillip - * @version 1.0 - */ -public class InitializerBean { - - /** The logger */ - protected transient Log logger = LogFactory.getLog(getClass()); - - /** - * Creates a new Initializer bean - *

- * This bean should never be explicitly instantiated - */ - public InitializerBean() { - // Check to see if the plugin version table exists. If not, the schema - // needs to be exported to the database - /* - * pvd = new PluginVersionDao(); if (!pvd.isDbInitialized()) { - * logger.warn("Databases have not been initialized..."); - * logger.info("Initializing Databases..."); - * logger.info("Exporting common table ddls..."); - * SchemaManager.getInstance().createCommonTables(); - * logger.info("Running setup scripts..."); try { - * SchemaManager.getInstance().runCommonScripts(); } catch - * (PluginException e) { logger.fatal("ERROR RUNNING COMMON SCRIPTS!", - * e); } - * - * } - */ - logger.info("Database initialization complete!"); - } - -} diff --git a/edexOsgi/com.raytheon.edex.plugin.binlightning/res/spring/binlightning_ep-ingest.xml b/edexOsgi/com.raytheon.edex.plugin.binlightning/res/spring/binlightning_ep-ingest.xml index 4c60b738c3..d8a0ea3c5f 100644 --- a/edexOsgi/com.raytheon.edex.plugin.binlightning/res/spring/binlightning_ep-ingest.xml +++ b/edexOsgi/com.raytheon.edex.plugin.binlightning/res/spring/binlightning_ep-ingest.xml @@ -4,7 +4,7 @@ http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd"> + class="com.raytheon.edex.plugin.binlightning.BinLightningDecoder" /> @@ -12,16 +12,14 @@ - + - + - - - - - - - - - + - - + + + + @@ -420,6 +415,7 @@ + @@ -488,11 +484,16 @@ + + + + + + - + @@ -512,7 +513,7 @@ - + diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/res/spring/gfe-spring.xml b/edexOsgi/com.raytheon.edex.plugin.gfe/res/spring/gfe-spring.xml index 64d9cced5c..c41d88919f 100644 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/res/spring/gfe-spring.xml +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/res/spring/gfe-spring.xml @@ -4,24 +4,20 @@ http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd"> - - - + + + - - - + + - - - - - - + + + @@ -29,8 +25,10 @@ - + + + @@ -72,6 +70,12 @@ + + + + + + + errorHandlerRef="errorHandler"> @@ -134,7 +138,7 @@ - + diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/resources/com.raytheon.edex.plugin.gfe.properties b/edexOsgi/com.raytheon.edex.plugin.gfe/resources/com.raytheon.edex.plugin.gfe.properties new file mode 100644 index 0000000000..a5529c1a1c --- /dev/null +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/resources/com.raytheon.edex.plugin.gfe.properties @@ -0,0 +1,2 @@ +# The number of smart init threads to use +smartinit.threads=2 diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/config/GFESiteActivation.java b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/config/GFESiteActivation.java index 0f6e90ccdc..938f49ac8f 100644 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/config/GFESiteActivation.java +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/config/GFESiteActivation.java @@ -59,20 +59,21 @@ import com.raytheon.uf.edex.site.notify.SendSiteActivationNotifications; * SOFTWARE HISTORY * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Jul 9, 2009 njensen Initial creation - * Oct 26, 2010 #6811 jclark changed listener type - * Apr 06, 2012 #457 dgilling Clear site's ISCSendRecords on - * site deactivation. - * Jul 12, 2012 15162 ryu added check for invalid db at activation - * Dec 11, 2012 14360 ryu log a clean message in case of - * missing configuration (no stack trace). - * Feb 15, 2013 1638 mschenke Moved sending of site notification messages to edex plugin - * Feb 28, 2013 #1447 dgilling Enable active table fetching on site - * activation. - * Mar 20, 2013 #1774 randerso Changed to use GFED2DDao - * May 02, 2013 #1969 randerso Moved updateDbs method into IFPGridDatabase - * Jun 13, 2013 #2044 randerso Refactored to use IFPServer - * Oct 16, 2013 #2475 dgilling Better error handling for IRT activation. + * Jul 9, 2009 njensen Initial creation + * Oct 26, 2010 #6811 jclark changed listener type + * Apr 06, 2012 #457 dgilling Clear site's ISCSendRecords on + * site deactivation. + * Jul 12, 2012 15162 ryu added check for invalid db at activation + * Dec 11, 2012 14360 ryu log a clean message in case of + * missing configuration (no stack trace). + * Feb 15, 2013 1638 mschenke Moved sending of site notification messages to edex plugin + * Feb 28, 2013 #1447 dgilling Enable active table fetching on site + * activation. + * Mar 20, 2013 #1774 randerso Changed to use GFED2DDao + * May 02, 2013 #1969 randerso Moved updateDbs method into IFPGridDatabase + * Jun 13, 2013 #2044 randerso Refactored to use IFPServer + * Oct 16, 2013 #2475 dgilling Better error handling for IRT activation. + * Mar 21, 2014 2726 rjpeter Updated wait for running loop. * * * @author njensen @@ -87,14 +88,8 @@ public class GFESiteActivation implements ISiteActivationListener { private static final String INIT_TASK_DETAILS = "Initialization:"; - private static final String SMART_INIT_TASK_DETAILS = "SmartInit:"; - private static final int LOCK_TASK_TIMEOUT = 180000; - // don't rerun the smart init fire if they have been run in the last 30 - // minutes - private static final int SMART_INIT_TIMEOUT = 1800000; - private static GFESiteActivation instance = new GFESiteActivation(); private boolean intialized = false; @@ -297,7 +292,7 @@ public class GFESiteActivation implements ISiteActivationListener { statusHandler.info("IFPServerConfigManager initializing..."); config = IFPServerConfigManager.initializeSite(siteID); statusHandler.info("Activating IFPServer..."); - IFPServer ifpServer = IFPServer.activateServer(siteID, config); + IFPServer.activateServer(siteID, config); } finally { statusHandler .handle(Priority.INFO, @@ -345,16 +340,7 @@ public class GFESiteActivation implements ISiteActivationListener { @Override public void run() { - long startTime = System.currentTimeMillis(); - // wait for system startup or at least 3 minutes - while (!EDEXUtil.isRunning() - || (System.currentTimeMillis() > (startTime + 180000))) { - try { - Thread.sleep(15000); - } catch (InterruptedException e) { - - } - } + EDEXUtil.waitForRunning(); Map fetchATConfig = new HashMap(); fetchATConfig.put("siteId", configRef.getSiteID().get(0)); diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/isc/IscSendJob.java b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/isc/IscSendJob.java deleted file mode 100644 index e96d5562ad..0000000000 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/isc/IscSendJob.java +++ /dev/null @@ -1,267 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ - -package com.raytheon.edex.plugin.gfe.isc; - -import java.net.InetAddress; -import java.text.SimpleDateFormat; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.Date; -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import jep.JepException; - -import com.raytheon.edex.plugin.gfe.config.GFESiteActivation; -import com.raytheon.edex.plugin.gfe.config.IFPServerConfig; -import com.raytheon.edex.plugin.gfe.config.IFPServerConfigManager; -import com.raytheon.edex.plugin.gfe.exception.GfeConfigurationException; -import com.raytheon.edex.plugin.gfe.server.IFPServer; -import com.raytheon.edex.plugin.gfe.server.database.GridDatabase; -import com.raytheon.edex.plugin.gfe.util.SendNotifications; -import com.raytheon.uf.common.dataplugin.gfe.GridDataHistory; -import com.raytheon.uf.common.dataplugin.gfe.db.objects.DatabaseID; -import com.raytheon.uf.common.dataplugin.gfe.db.objects.ParmID; -import com.raytheon.uf.common.dataplugin.gfe.server.message.ServerResponse; -import com.raytheon.uf.common.dataplugin.gfe.server.notify.GridHistoryUpdateNotification; -import com.raytheon.uf.common.message.WsId; -import com.raytheon.uf.common.status.IUFStatusHandler; -import com.raytheon.uf.common.status.UFStatus; -import com.raytheon.uf.common.time.TimeRange; -import com.raytheon.uf.edex.core.EDEXUtil; - -/** - * Class to for running the isc scripts - * - *

- * 
- * SOFTWARE HISTORY
- * 
- * Date         Ticket#     Engineer    Description
- * ------------ ----------  ----------- --------------------------
- * 07/06/09      1995       bphillip    Initial release
- * 04/06/12      #457       dgilling    Move call to delete records
- *                                      from queue into run().
- * 04/23/13      #1949      rjpeter     Move setting of lastSentTime to dao
- *                                      and removed initial delay.
- * 06/13/13      2044       randerso    Refactored to use IFPServer
- * 
- * - * @author bphillip - * @version 1 - */ -public class IscSendJob implements Runnable { - - private static final transient IUFStatusHandler statusHandler = UFStatus - .getHandler(IscSendJob.class); - - /** Date format for formatting dates for use with iscExtract script */ - private static final SimpleDateFormat ISC_EXTRACT_DATE = new SimpleDateFormat( - "yyyyMMdd_HHmm"); - - private final Map scripts; - - private int runningTimeOutMillis; - - private int threadSleepInterval; - - /** - * Constructs a new IscSendJob - * - * @param siteID - * the site ID - * - * @param cmdQueue - */ - public IscSendJob() { - scripts = new HashMap(); - runningTimeOutMillis = 300000; - threadSleepInterval = 30000; - } - - @Override - public void run() { - while (!EDEXUtil.isRunning()) { - try { - Thread.sleep(threadSleepInterval); - } catch (Throwable t) { - // ignore - } - } - - try { - // run forever - while (true) { - IscSendRecord record = SendIscTransactions - .getNextSendJob(runningTimeOutMillis); - if (record != null) { - runIscSend(record); - SendIscTransactions.removeSendJob(record); - } else { - try { - Thread.sleep(threadSleepInterval); - } catch (Exception e) { - // ignore - } - } - } - } finally { - // Make sure OS resources are released at thread death - for (IscSendScript script : scripts.values()) { - script.dispose(); - } - } - } - - private void runIscSend(IscSendRecord request) { - try { - ParmID id = request.getParmID(); - TimeRange tr = request.getTimeRange(); - String xmlDest = request.getXmlDest(); - String siteId = id.getDbId().getSiteId(); - - if (!GFESiteActivation.getInstance().getActiveSites() - .contains(siteId)) { - statusHandler.warn("Attempted to send " + id - + " for deactivated site " + siteId + "."); - return; - } - - statusHandler.info("Starting isc for " + id.toString() + " " - + tr.toString() + " " + xmlDest); - - Map cmd = new HashMap(); - cmd.put("parmNames", Arrays.asList(id.getParmName())); - cmd.put("databaseName", id.getDbId().getModelId()); - cmd.put("startTime", ISC_EXTRACT_DATE.format(tr.getStart())); - cmd.put("endTime", ISC_EXTRACT_DATE.format(tr.getEnd())); - - // destination server XML, might be empty - // the -D switch is a file location containing the xml - // information - if (!xmlDest.isEmpty()) { - cmd.put("destinations", xmlDest); - } - - try { - IFPServerConfig config = IFPServerConfigManager - .getServerConfig(siteId); - // IRT table address - cmd.put("irtTableAddressA", config.iscRoutingTableAddress() - .get("ANCF")); - cmd.put("irtTableAddressB", config.iscRoutingTableAddress() - .get("BNCF")); - // xmt script - cmd.put("transmitScript", config.transmitScript()); - // our server host, port, protocol, our mhs id, and our site id - cmd.put("ourServerHost", config.getServerHost()); - cmd.put("ourServerPort", String.valueOf(config.getRpcPort())); - cmd.put("ourServerProtocol", - String.valueOf(config.getProtocolVersion())); - cmd.put("ourMHSid", config.getMhsid()); - cmd.put("ourSiteID", config.getSiteID().get(0)); - } catch (GfeConfigurationException e) { - statusHandler.error( - "Unable to retrieve site configuration for site " - + siteId, e); - return; - } - - try { - IscSendScript script = scripts.get(siteId); - if (script == null) { - script = IscSendScriptFactory - .constructIscSendScript(siteId); - scripts.put(siteId, script); - } - script.execute(cmd); - } catch (JepException e) { - statusHandler.error("Error executing iscExtract.", e); - return; - } - - try { - DatabaseID dbId = id.getDbId(); - IFPServer ifpServer = IFPServer.getActiveServer(dbId - .getSiteId()); - if (ifpServer != null) { - GridDatabase gridDb = ifpServer.getGridParmMgr() - .getDatabase(dbId); - if (gridDb != null) { - ServerResponse>> sr = gridDb - .updateSentTime(id, tr, new Date()); - if (sr.isOkay()) { - WsId wsId = new WsId(InetAddress.getLocalHost(), - "ISC", "ISC"); - List notifications = new ArrayList( - 1); - Map> histories = sr - .getPayload(); - notifications - .add(new GridHistoryUpdateNotification(id, - histories, wsId, siteId)); - SendNotifications.send(notifications); - - } else { - statusHandler - .error("Error updating last sent times in GFERecords: " - + sr.getMessages()); - } - } else { - // no such database exists - statusHandler - .error("Error processing ISC send request for :" - + dbId - + ", the database does not exist."); - } - } else { - // no active server for request - statusHandler - .error("Error processing ISC send request for :" - + dbId + ", no active IFPServer for site."); - } - } catch (Exception e) { - statusHandler.error( - "Error updating last sent times in GFERecords.", e); - } - - } catch (Throwable t) { - statusHandler.error("Exception in ISCSendJob: ", t); - } - } - - public int getRunningTimeOutMillis() { - return runningTimeOutMillis; - } - - public void setRunningTimeOutMillis(int runningTimeOutMillis) { - this.runningTimeOutMillis = runningTimeOutMillis; - } - - public int getThreadSleepInterval() { - return threadSleepInterval; - } - - public void setThreadSleepInterval(int threadSleepInterval) { - this.threadSleepInterval = threadSleepInterval; - } -} \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/isc/SendIscSrv.java b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/isc/SendIscSrv.java index 5e703ab8c9..a5368f1ebd 100644 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/isc/SendIscSrv.java +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/isc/SendIscSrv.java @@ -19,7 +19,33 @@ **/ package com.raytheon.edex.plugin.gfe.isc; -import java.util.concurrent.Executor; +import java.text.SimpleDateFormat; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Date; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import jep.JepException; + +import com.raytheon.edex.plugin.gfe.config.GFESiteActivation; +import com.raytheon.edex.plugin.gfe.config.IFPServerConfig; +import com.raytheon.edex.plugin.gfe.config.IFPServerConfigManager; +import com.raytheon.edex.plugin.gfe.exception.GfeConfigurationException; +import com.raytheon.edex.plugin.gfe.server.IFPServer; +import com.raytheon.edex.plugin.gfe.server.database.GridDatabase; +import com.raytheon.edex.plugin.gfe.util.SendNotifications; +import com.raytheon.uf.common.dataplugin.gfe.GridDataHistory; +import com.raytheon.uf.common.dataplugin.gfe.db.objects.DatabaseID; +import com.raytheon.uf.common.dataplugin.gfe.db.objects.ParmID; +import com.raytheon.uf.common.dataplugin.gfe.server.message.ServerResponse; +import com.raytheon.uf.common.dataplugin.gfe.server.notify.GridHistoryUpdateNotification; +import com.raytheon.uf.common.message.WsId; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.time.TimeRange; +import com.raytheon.uf.edex.core.EdexTimerBasedThread; /** * Service that runs ISC send jobs. Along with IscSendQueue, this class roughly @@ -31,28 +57,183 @@ import java.util.concurrent.Executor; * * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Oct 20, 2011 dgilling Initial creation - * + * Oct 20, 2011 dgilling Initial creation + * May 19, 2014 2726 rjpeter Integrate IscSendJob for graceful shutdown. * * * @author dgilling * @version 1.0 */ -public class SendIscSrv { +public class SendIscSrv extends EdexTimerBasedThread { + private final transient IUFStatusHandler statusHandler = UFStatus + .getHandler(SendIscSrv.class); - private final SendIscSrvConfig cfg; + protected int runningTimeOutMillis; - private final Executor executor; + /** Date format for formatting dates for use with iscExtract script */ + protected static final SimpleDateFormat ISC_EXTRACT_DATE = new SimpleDateFormat( + "yyyyMMdd_HHmm"); - public SendIscSrv(SendIscSrvConfig config) { - this.cfg = config; - this.executor = config.getExecutor(); - for (int i = 0; i < cfg.getThreads(); i++) { - IscSendJob thread = new IscSendJob(); - thread.setRunningTimeOutMillis(cfg.getRunningTimeOutMillis()); - thread.setThreadSleepInterval(cfg.getThreadSleepInterval()); - executor.execute(thread); + protected final ThreadLocal> scripts = new ThreadLocal>() { + + @Override + protected Map initialValue() { + return new HashMap(); + } + + }; + + public SendIscSrv() { + } + + public int getRunningTimeOutMillis() { + return runningTimeOutMillis; + } + + public void setRunningTimeOutMillis(int runningTimeOutMillis) { + this.runningTimeOutMillis = runningTimeOutMillis; + } + + @Override + public String getThreadGroupName() { + return "iscSendThreadPool"; + } + + @Override + public void process() throws Exception { + IscSendRecord record = null; + do { + record = SendIscTransactions.getNextSendJob(runningTimeOutMillis); + if (record != null) { + runIscSend(record); + SendIscTransactions.removeSendJob(record); + } + } while (record != null); + } + + @Override + public void dispose() { + super.dispose(); + // Make sure OS resources are released at thread death + for (IscSendScript script : scripts.get().values()) { + script.dispose(); + } + } + + private void runIscSend(IscSendRecord request) { + try { + ParmID id = request.getParmID(); + TimeRange tr = request.getTimeRange(); + String xmlDest = request.getXmlDest(); + String siteId = id.getDbId().getSiteId(); + + if (!GFESiteActivation.getInstance().getActiveSites() + .contains(siteId)) { + statusHandler.warn("Attempted to send " + id + + " for deactivated site " + siteId + "."); + return; + } + + statusHandler.info("Starting isc for " + id.toString() + " " + + tr.toString() + " " + xmlDest); + + Map cmd = new HashMap(); + cmd.put("parmNames", Arrays.asList(id.getParmName())); + cmd.put("databaseName", id.getDbId().getModelId()); + cmd.put("startTime", ISC_EXTRACT_DATE.format(tr.getStart())); + cmd.put("endTime", ISC_EXTRACT_DATE.format(tr.getEnd())); + + // destination server XML, might be empty + // the -D switch is a file location containing the xml + // information + if (!xmlDest.isEmpty()) { + cmd.put("destinations", xmlDest); + } + + try { + IFPServerConfig config = IFPServerConfigManager + .getServerConfig(siteId); + // IRT table address + cmd.put("irtTableAddressA", config.iscRoutingTableAddress() + .get("ANCF")); + cmd.put("irtTableAddressB", config.iscRoutingTableAddress() + .get("BNCF")); + // xmt script + cmd.put("transmitScript", config.transmitScript()); + // our server host, port, protocol, our mhs id, and our site id + cmd.put("ourServerHost", config.getServerHost()); + cmd.put("ourServerPort", String.valueOf(config.getRpcPort())); + cmd.put("ourServerProtocol", + String.valueOf(config.getProtocolVersion())); + cmd.put("ourMHSid", config.getMhsid()); + cmd.put("ourSiteID", config.getSiteID().get(0)); + } catch (GfeConfigurationException e) { + statusHandler.error( + "Unable to retrieve site configuration for site " + + siteId, e); + return; + } + + try { + IscSendScript script = scripts.get().get(siteId); + if (script == null) { + script = IscSendScriptFactory + .constructIscSendScript(siteId); + scripts.get().put(siteId, script); + } + script.execute(cmd); + } catch (JepException e) { + statusHandler.error("Error executing iscExtract.", e); + return; + } + + try { + DatabaseID dbId = id.getDbId(); + IFPServer ifpServer = IFPServer.getActiveServer(dbId + .getSiteId()); + if (ifpServer != null) { + GridDatabase gridDb = ifpServer.getGridParmMgr() + .getDatabase(dbId); + if (gridDb != null) { + ServerResponse>> sr = gridDb + .updateSentTime(id, tr, new Date()); + if (sr.isOkay()) { + WsId wsId = new WsId(null, "ISC", "ISC"); + List notifications = new ArrayList( + 1); + Map> histories = sr + .getPayload(); + notifications + .add(new GridHistoryUpdateNotification(id, + histories, wsId, siteId)); + SendNotifications.send(notifications); + + } else { + statusHandler + .error("Error updating last sent times in GFERecords: " + + sr.getMessages()); + } + } else { + // no such database exists + statusHandler + .error("Error processing ISC send request for :" + + dbId + + ", the database does not exist."); + } + } else { + // no active server for request + statusHandler + .error("Error processing ISC send request for :" + + dbId + ", no active IFPServer for site."); + } + } catch (Exception e) { + statusHandler.error( + "Error updating last sent times in GFERecords.", e); + } + + } catch (Throwable t) { + statusHandler.error("Exception in SendIscSrv: ", t); } } } diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/isc/SendIscSrvConfig.java b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/isc/SendIscSrvConfig.java deleted file mode 100644 index 92e62c3ef9..0000000000 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/isc/SendIscSrvConfig.java +++ /dev/null @@ -1,82 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ -package com.raytheon.edex.plugin.gfe.isc; - -import java.util.concurrent.Executor; - -/** - * Send ISC service configuration. - * - *
- * 
- * SOFTWARE HISTORY
- * 
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Oct 20, 2011            dgilling    Initial creation
- * Apr 30, 2013 1949       rjpeter     Removed initial delay.
- * 
- * - * @author dgilling - * @version 1.0 - */ - -public class SendIscSrvConfig { - - protected int threads; - - protected Executor executor; - - protected int runningTimeOutMillis; - - protected int threadSleepInterval; - - public int getThreads() { - return threads; - } - - public void setThreads(int threads) { - this.threads = threads; - } - - public Executor getExecutor() { - return executor; - } - - public void setExecutor(Executor executor) { - this.executor = executor; - } - - public int getRunningTimeOutMillis() { - return runningTimeOutMillis; - } - - public void setRunningTimeOutMillis(int runningTimeOutMillis) { - this.runningTimeOutMillis = runningTimeOutMillis; - } - - public int getThreadSleepInterval() { - return threadSleepInterval; - } - - public void setThreadSleepInterval(int threadSleepInterval) { - this.threadSleepInterval = threadSleepInterval; - } -} diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/SmartInitSrv.java b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/SmartInitSrv.java index 2b68e40722..6e8f75ddfb 100644 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/SmartInitSrv.java +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/SmartInitSrv.java @@ -25,13 +25,9 @@ import java.util.Date; import java.util.HashMap; import java.util.List; import java.util.Map; -import java.util.concurrent.Executor; import jep.JepException; -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; - import com.raytheon.edex.plugin.gfe.server.IFPServer; import com.raytheon.uf.common.dataplugin.gfe.db.objects.DatabaseID; import com.raytheon.uf.common.localization.IPathManager; @@ -39,10 +35,10 @@ import com.raytheon.uf.common.localization.LocalizationContext; import com.raytheon.uf.common.localization.LocalizationContext.LocalizationLevel; import com.raytheon.uf.common.localization.LocalizationContext.LocalizationType; import com.raytheon.uf.common.localization.PathManagerFactory; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.util.FileUtil; -import com.raytheon.uf.edex.core.EDEXUtil; -import com.raytheon.uf.edex.core.props.EnvProperties; -import com.raytheon.uf.edex.core.props.PropertiesFactory; +import com.raytheon.uf.edex.core.EdexTimerBasedThread; /** * Service that runs smart inits @@ -58,168 +54,154 @@ import com.raytheon.uf.edex.core.props.PropertiesFactory; * Aug 24, 2013 #1949 rjpeter Updated start up logic * Jun 13, 2013 #2044 randerso Refactored to use IFPServer, * added support to run init for all valid times + * Mar 14, 2014 2726 rjpeter Implement graceful shutdown. * * * @author njensen * @version 1.0 */ -public class SmartInitSrv { +public class SmartInitSrv extends EdexTimerBasedThread { + protected static final transient IUFStatusHandler statusHandler = UFStatus + .getHandler(SmartInitSrv.class); private final Map cachedInterpreters = new HashMap(); - private static boolean enabled = true; + protected int pendingInitMinTimeMillis = 120000; - protected final SmartInitSrvConfig cfg; + protected int runningInitTimeOutMillis = 600000; - protected final Executor executor; - - static { - EnvProperties env = PropertiesFactory.getInstance().getEnvProperties(); - enabled = Boolean.parseBoolean(env.getEnvValue("GFESMARTINIT")); + public SmartInitSrv() { } - public SmartInitSrv(SmartInitSrvConfig config) { - cfg = config; - this.executor = config.getExecutor(); - for (int i = 0; i < cfg.getThreads(); i++) { - SmartInitThread thread = new SmartInitThread(); - thread.pendingInitMinTimeMillis = cfg.getPendingInitMinTimeMillis(); - thread.runningInitTimeOutMillis = cfg.getRunningInitTimeOutMillis(); - thread.threadSleepInterval = cfg.getThreadSleepInterval(); - executor.execute(thread); - } + @Override + public String getThreadGroupName() { + return "smartInitThreadPool"; } - protected class SmartInitThread implements Runnable { - // default of 2 minutes - private int pendingInitMinTimeMillis = 120000; - - private int runningInitTimeOutMillis = 600000; - - private int threadSleepInterval = 30000; - - private final transient Log logger = LogFactory.getLog(getClass()); - - @Override - public void run() { - try { - // Wait for server to come fully up due to route dependencies - while (!EDEXUtil.isRunning()) { - try { - Thread.sleep(threadSleepInterval); - } catch (InterruptedException e) { - // ignore - } - } - - // run forever - while (true) { - SmartInitRecord record = SmartInitTransactions - .getSmartInitToRun(pendingInitMinTimeMillis, - runningInitTimeOutMillis); - if (record != null) { - runSmartInit(record); - } else { - try { - Thread.sleep(threadSleepInterval); - } catch (Exception e) { - // ignore - } - } - } - } finally { - // Make sure OS resources are released at thread death - SmartInitScript script = cachedInterpreters.remove(Thread - .currentThread().getId()); - script.dispose(); + @Override + public void process() throws Exception { + SmartInitRecord record = null; + do { + record = SmartInitTransactions.getSmartInitToRun( + pendingInitMinTimeMillis, runningInitTimeOutMillis); + if (record != null) { + runSmartInit(record); } - } + } while (record != null); + } - public void runSmartInit(SmartInitRecord record) { - if (enabled) { + @Override + public void dispose() { + super.dispose(); + + // Make sure OS resources are released at thread death + SmartInitScript script = cachedInterpreters.remove(Thread + .currentThread().getId()); + if (script != null) { + script.dispose(); + } + } + + public void runSmartInit(SmartInitRecord record) { + try { + SmartInitScript initScript = null; + List sitePathsAdded = new ArrayList(2); + + String init = record.getSmartInit(); + String dbName = record.getDbName() + + (record.isManual() ? ":1" : ":0"); + Date validTime = record.getId().getValidTime(); + if (SmartInitRecord.ALL_TIMES.equals(validTime)) { + validTime = null; + } + + DatabaseID db = new DatabaseID(record.getDbName()); + if (IFPServer.getActiveSites().contains(db.getSiteId())) { try { - SmartInitScript initScript = null; - List sitePathsAdded = new ArrayList(2); + long id = Thread.currentThread().getId(); + initScript = cachedInterpreters.get(id); - String init = record.getSmartInit(); - String dbName = record.getDbName() - + (record.isManual() ? ":1" : ":0"); - Date validTime = record.getId().getValidTime(); - if (SmartInitRecord.ALL_TIMES.equals(validTime)) { - validTime = null; + if (initScript == null) { + initScript = SmartInitFactory.constructInit(); + cachedInterpreters.put(id, initScript); } - DatabaseID db = new DatabaseID(record.getDbName()); - if (IFPServer.getActiveSites().contains(db.getSiteId())) { - try { - long id = Thread.currentThread().getId(); - initScript = cachedInterpreters.get(id); + IPathManager pathMgr = PathManagerFactory.getPathManager(); + LocalizationContext ctx = pathMgr.getContextForSite( + LocalizationType.EDEX_STATIC, db.getSiteId()); + LocalizationContext baseCtx = pathMgr.getContext( + LocalizationType.EDEX_STATIC, + LocalizationLevel.BASE); - if (initScript == null) { - initScript = SmartInitFactory.constructInit(); - cachedInterpreters.put(id, initScript); - } - - IPathManager pathMgr = PathManagerFactory - .getPathManager(); - LocalizationContext ctx = pathMgr - .getContextForSite( - LocalizationType.EDEX_STATIC, - db.getSiteId()); - LocalizationContext baseCtx = pathMgr.getContext( - LocalizationType.EDEX_STATIC, - LocalizationLevel.BASE); - - File file = pathMgr.getFile(ctx, "smartinit"); - if ((file != null) && file.exists()) { - initScript.addSitePath(file.getPath(), pathMgr - .getFile(baseCtx, "smartinit") - .getPath()); - sitePathsAdded.add(file.getPath()); - } - file = pathMgr.getFile(ctx, - FileUtil.join("config", "gfe")); - if ((file != null) && file.exists()) { - initScript.addSitePath( - file.getPath(), - pathMgr.getFile(baseCtx, - FileUtil.join("config", "gfe")) + File file = pathMgr.getFile(ctx, "smartinit"); + if ((file != null) && file.exists()) { + initScript + .addSitePath(file.getPath(), + pathMgr.getFile(baseCtx, "smartinit") .getPath()); - sitePathsAdded.add(file.getPath()); - } - - HashMap argMap = new HashMap(); - argMap.put("dbName", dbName); - argMap.put("model", init); - argMap.put("validTime", validTime); - - initScript.execute(argMap); - } catch (Throwable e) { - logger.error("Error running smart init for " - + record.getId(), e); - } finally { - try { - for (String path : sitePathsAdded) { - initScript.removeSitePath(path); - } - } catch (JepException e) { - this.logger - .error("Error cleaning up smart init interpreter's sys.path", - e); - } - } - } else { - this.logger.warn("Site " + db.getSiteId() - + " has been disabled. Smart init for " - + record.getDbName() - + " will not be processed."); + sitePathsAdded.add(file.getPath()); + } + file = pathMgr.getFile(ctx, FileUtil.join("config", "gfe")); + if ((file != null) && file.exists()) { + initScript.addSitePath( + file.getPath(), + pathMgr.getFile(baseCtx, + FileUtil.join("config", "gfe")) + .getPath()); + sitePathsAdded.add(file.getPath()); + } + + HashMap argMap = new HashMap(); + argMap.put("dbName", dbName); + argMap.put("model", init); + argMap.put("validTime", validTime); + + initScript.execute(argMap); + } catch (Throwable e) { + statusHandler.error("Error running smart init for " + + record.getId(), e); + } finally { + try { + for (String path : sitePathsAdded) { + initScript.removeSitePath(path); + } + } catch (JepException e) { + statusHandler + .error("Error cleaning up smart init interpreter's sys.path", + e); } - } catch (Throwable t) { - this.logger.error("Error in SmartInitSrv", t); } - SmartInitTransactions.removeSmartInit(record); + } else { + statusHandler.warn("Site " + db.getSiteId() + + " has been disabled. Smart init for " + + record.getDbName() + " will not be processed."); } + } catch (Throwable t) { + statusHandler.error("Error in SmartInitSrv", t); } + SmartInitTransactions.removeSmartInit(record); + } + + @Override + public void postStop() { + SmartInitQueue.getQueue().fireSmartInit(); + super.postStop(); + } + + public int getPendingInitMinTimeMillis() { + return pendingInitMinTimeMillis; + } + + public void setPendingInitMinTimeMillis(int pendingInitMinTimeMillis) { + this.pendingInitMinTimeMillis = pendingInitMinTimeMillis; + } + + public int getRunningInitTimeOutMillis() { + return runningInitTimeOutMillis; + } + + public void setRunningInitTimeOutMillis(int runningInitTimeOutMillis) { + this.runningInitTimeOutMillis = runningInitTimeOutMillis; } } diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/SmartInitSrvConfig.java b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/SmartInitSrvConfig.java deleted file mode 100644 index cf463847b5..0000000000 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/SmartInitSrvConfig.java +++ /dev/null @@ -1,91 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ -package com.raytheon.edex.plugin.gfe.smartinit; - -import java.util.concurrent.Executor; - -/** - * Smart Init Server config. - * - *
- * 
- * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Sep 24, 2010 #7277      rjpeter     Initial creation
- * Apr 23, 2013 #1949      rjpeter     Removed initial delay
- * 
- * - * @author rjpeter - * @version 1.0 - */ - -public class SmartInitSrvConfig { - protected int threads; - - protected Executor executor; - - protected int pendingInitMinTimeMillis; - - protected int runningInitTimeOutMillis; - - protected int threadSleepInterval; - - public int getThreads() { - return threads; - } - - public void setThreads(int threads) { - this.threads = threads; - } - - public Executor getExecutor() { - return executor; - } - - public void setExecutor(Executor executor) { - this.executor = executor; - } - - public int getPendingInitMinTimeMillis() { - return pendingInitMinTimeMillis; - } - - public void setPendingInitMinTimeMillis(int pendingInitMinTimeMillis) { - this.pendingInitMinTimeMillis = pendingInitMinTimeMillis; - } - - public int getRunningInitTimeOutMillis() { - return runningInitTimeOutMillis; - } - - public void setRunningInitTimeOutMillis(int runningInitTimeOutMillis) { - this.runningInitTimeOutMillis = runningInitTimeOutMillis; - } - - public int getThreadSleepInterval() { - return threadSleepInterval; - } - - public void setThreadSleepInterval(int threadSleepInterval) { - this.threadSleepInterval = threadSleepInterval; - } - -} diff --git a/edexOsgi/com.raytheon.edex.plugin.goessounding/res/spring/goessounding-ingest.xml b/edexOsgi/com.raytheon.edex.plugin.goessounding/res/spring/goessounding-ingest.xml index 5f7aa56c3c..7ff0af9962 100644 --- a/edexOsgi/com.raytheon.edex.plugin.goessounding/res/spring/goessounding-ingest.xml +++ b/edexOsgi/com.raytheon.edex.plugin.goessounding/res/spring/goessounding-ingest.xml @@ -15,16 +15,9 @@
- - - - + errorHandlerRef="errorHandler"> - + @@ -63,14 +55,15 @@
- + - + + diff --git a/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/thinnedModels/UkmetHR-NH.xml b/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/thinnedModels/UkmetHR-NH.xml index 5325335d6b..964db69089 100644 --- a/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/thinnedModels/UkmetHR-NH.xml +++ b/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/thinnedModels/UkmetHR-NH.xml @@ -1,4 +1,4 @@ - + diff --git a/edexOsgi/com.raytheon.edex.plugin.obs/res/spring/obs-ingest-metarshef.xml b/edexOsgi/com.raytheon.edex.plugin.obs/res/spring/obs-ingest-metarshef.xml index 3fa8f85c54..d8aae45577 100644 --- a/edexOsgi/com.raytheon.edex.plugin.obs/res/spring/obs-ingest-metarshef.xml +++ b/edexOsgi/com.raytheon.edex.plugin.obs/res/spring/obs-ingest-metarshef.xml @@ -5,15 +5,8 @@ http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd"> - - - - - + errorHandlerRef="errorHandler"> diff --git a/edexOsgi/com.raytheon.edex.plugin.obs/res/spring/obs-ingest.xml b/edexOsgi/com.raytheon.edex.plugin.obs/res/spring/obs-ingest.xml index ed112a4f3f..ef1a7969e7 100644 --- a/edexOsgi/com.raytheon.edex.plugin.obs/res/spring/obs-ingest.xml +++ b/edexOsgi/com.raytheon.edex.plugin.obs/res/spring/obs-ingest.xml @@ -1,8 +1,7 @@ + xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd"> diff --git a/edexOsgi/com.raytheon.edex.plugin.poessounding/res/spring/poessounding-ingest.xml b/edexOsgi/com.raytheon.edex.plugin.poessounding/res/spring/poessounding-ingest.xml index a5acee9edc..70b7d67a9b 100644 --- a/edexOsgi/com.raytheon.edex.plugin.poessounding/res/spring/poessounding-ingest.xml +++ b/edexOsgi/com.raytheon.edex.plugin.poessounding/res/spring/poessounding-ingest.xml @@ -12,15 +12,9 @@ - - - - + errorHandlerRef="errorHandler"> - - - - + + + + errorHandlerRef="errorHandler"> diff --git a/edexOsgi/com.raytheon.edex.plugin.shef/res/spring/shef-ingest.xml b/edexOsgi/com.raytheon.edex.plugin.shef/res/spring/shef-ingest.xml index cbeb83d0e8..e63a4bf572 100644 --- a/edexOsgi/com.raytheon.edex.plugin.shef/res/spring/shef-ingest.xml +++ b/edexOsgi/com.raytheon.edex.plugin.shef/res/spring/shef-ingest.xml @@ -44,22 +44,17 @@
- - - - - + + errorHandlerRef="errorHandler"> @@ -75,7 +70,7 @@ + errorHandlerRef="errorHandler"> diff --git a/edexOsgi/com.raytheon.edex.plugin.taf/res/spring/taf-ingest.xml b/edexOsgi/com.raytheon.edex.plugin.taf/res/spring/taf-ingest.xml index 651083abdb..63a6bb5378 100644 --- a/edexOsgi/com.raytheon.edex.plugin.taf/res/spring/taf-ingest.xml +++ b/edexOsgi/com.raytheon.edex.plugin.taf/res/spring/taf-ingest.xml @@ -18,15 +18,9 @@ - - - - + errorHandlerRef="errorHandler"> @@ -232,8 +231,7 @@ - + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.plugin.textlightning/res/spring/textlightning_ep-ingest.xml b/edexOsgi/com.raytheon.edex.plugin.textlightning/res/spring/textlightning_ep-ingest.xml index 5f5ada5907..8808d585c8 100644 --- a/edexOsgi/com.raytheon.edex.plugin.textlightning/res/spring/textlightning_ep-ingest.xml +++ b/edexOsgi/com.raytheon.edex.plugin.textlightning/res/spring/textlightning_ep-ingest.xml @@ -12,15 +12,9 @@ - - - - + errorHandlerRef="errorHandler"> - - - - - - - + + uri="clusteredquartz://warning/checkGeospatialData/?cron=${geospatial.updater.cron}" /> - - - + + + + - - + + + - + java.lang.Throwable - - \ No newline at end of file + + + + + + + + diff --git a/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GenerateGeospatialDataRequestHandler.java b/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GenerateGeospatialDataRequestHandler.java index 0fb5496a5f..8dc921c1c9 100644 --- a/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GenerateGeospatialDataRequestHandler.java +++ b/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GenerateGeospatialDataRequestHandler.java @@ -23,7 +23,7 @@ import com.raytheon.uf.common.dataplugin.warning.gis.GenerateGeospatialDataReque import com.raytheon.uf.common.serialization.comm.IRequestHandler; /** - * TODO Add Description + * Generates geospatial data on demand. * *
  * 
@@ -31,8 +31,8 @@ import com.raytheon.uf.common.serialization.comm.IRequestHandler;
  * 
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
- * Jul 22, 2011            rjpeter     Initial creation
- * 
+ * Jul 22, 2011            rjpeter     Initial creation.
+ * May 19, 2014 2726       rjpeter     Updated call to GeospatialDataGenerator.
  * 
* * @author rjpeter @@ -41,6 +41,13 @@ import com.raytheon.uf.common.serialization.comm.IRequestHandler; public class GenerateGeospatialDataRequestHandler implements IRequestHandler { + final GeospatialDataGenerator dataGenerator; + + public GenerateGeospatialDataRequestHandler( + GeospatialDataGenerator dataGenerator) { + this.dataGenerator = dataGenerator; + } + /* * (non-Javadoc) * @@ -51,8 +58,8 @@ public class GenerateGeospatialDataRequestHandler implements @Override public Object handleRequest(GenerateGeospatialDataRequest request) throws Exception { - return GeospatialDataGenerator.generateGeoSpatialList( - request.getSite(), request.getMetaData()); + return dataGenerator.generateGeoSpatialList(request.getSite(), + request.getMetaData()); } } diff --git a/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataGenerator.java b/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataGenerator.java index 2ac8e2ef02..4af2dce791 100644 --- a/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataGenerator.java +++ b/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataGenerator.java @@ -20,13 +20,16 @@ package com.raytheon.edex.plugin.warning.gis; import java.sql.Timestamp; +import java.text.SimpleDateFormat; import java.util.ArrayList; import java.util.Arrays; +import java.util.Calendar; import java.util.HashMap; import java.util.HashSet; import java.util.List; import java.util.Map; import java.util.Set; +import java.util.TimeZone; import javax.xml.bind.JAXBException; @@ -62,6 +65,8 @@ import com.raytheon.uf.common.serialization.SingleTypeJAXBManager; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; +import com.raytheon.uf.edex.core.EDEXUtil; +import com.raytheon.uf.edex.core.EdexException; import com.raytheon.uf.edex.database.cluster.ClusterLockUtils; import com.raytheon.uf.edex.database.cluster.ClusterLockUtils.LockState; import com.raytheon.uf.edex.database.cluster.ClusterTask; @@ -97,6 +102,7 @@ import com.vividsolutions.jts.simplify.TopologyPreservingSimplifier; * May 7, 2013 15690 Qinglu Lin Added convertToMultiPolygon() and updated queryGeospatialData(). * Oct 22, 2013 2361 njensen Use JAXBManager for XML * Feb 07, 2014 16090 mgamazaychikov Changed visibility of some methods + * Mar 19, 2014 2726 rjpeter Made singleton instance. * * * @author rjpeter @@ -104,14 +110,19 @@ import com.vividsolutions.jts.simplify.TopologyPreservingSimplifier; */ public class GeospatialDataGenerator { - - private static final transient IUFStatusHandler statusHandler = UFStatus + private final IUFStatusHandler statusHandler = UFStatus .getHandler(GeospatialDataGenerator.class); - private static final SingleTypeJAXBManager jaxb = SingleTypeJAXBManager + private final SingleTypeJAXBManager jaxb = SingleTypeJAXBManager .createWithoutException(GeospatialTimeSet.class); - public static void generateUniqueGeospatialMetadataGeometries() { + private final String updaterEndpoint; + + public GeospatialDataGenerator(String updaterEndpoint) { + this.updaterEndpoint = updaterEndpoint; + } + + public void generateUniqueGeospatialMetadataGeometries() { String mySite = SiteUtil.getSite(); DialogConfiguration dialogConfig = null; @@ -129,7 +140,7 @@ public class GeospatialDataGenerator { for (String site : sites) { statusHandler.handle(Priority.INFO, - "Generating warngen geometries for site: " + site); + "Checking warngen geometries for site: " + site); for (GeospatialMetadata md : metaDataSet) { try { generateGeoSpatialList(site, md); @@ -143,7 +154,7 @@ public class GeospatialDataGenerator { } } - public static Set getMetaDataSet(List sites, + public Set getMetaDataSet(List sites, List templates) { Set metaDataSet = new HashSet(); @@ -178,7 +189,8 @@ public class GeospatialDataGenerator { } return metaDataSet; } - static List getBackupSites(DialogConfiguration dialogConfig) { + + public static List getBackupSites(DialogConfiguration dialogConfig) { String[] CWAs = dialogConfig.getBackupCWAs().split(","); List rval = new ArrayList(CWAs.length + 1); for (String s : CWAs) { @@ -189,7 +201,7 @@ public class GeospatialDataGenerator { return rval; } - static List getTemplates(DialogConfiguration dialogConfig) { + public static List getTemplates(DialogConfiguration dialogConfig) { String[] mainProducts = dialogConfig.getMainWarngenProducts() .split(","); String[] otherProducts = dialogConfig.getOtherWarngenProducts().split( @@ -209,7 +221,7 @@ public class GeospatialDataGenerator { return rval; } - public static GeospatialDataSet generateGeoSpatialList(String site, + public GeospatialDataSet generateGeoSpatialList(String site, GeospatialMetadata metaData) throws SpatialException { GeospatialDataSet dataSet = null; String file = generateGeoDataFilename(metaData); @@ -307,6 +319,19 @@ public class GeospatialDataGenerator { // save to disk try { persistGeoData(site, lastRunTimeMap, curTime, dataSet); + + if (updaterEndpoint != null) { + String updatedTimeStamp = getTimeStamp(curTime, + lastRunTime); + + try { + EDEXUtil.getMessageProducer().sendAsync( + updaterEndpoint, updatedTimeStamp); + } catch (EdexException e) { + statusHandler.error("Could not send message to " + + updaterEndpoint, e); + } + } } catch (Exception e) { statusHandler.handle(Priority.WARN, "Error occurred persisting area geometry data", e); @@ -320,7 +345,7 @@ public class GeospatialDataGenerator { return dataSet; } - public static GeospatialMetadata getMetaData(WarngenConfiguration template) { + public GeospatialMetadata getMetaData(WarngenConfiguration template) { GeospatialMetadata rval = new GeospatialMetadata(); GeospatialConfiguration geoConfig = template.getGeospatialConfig(); AreaSourceConfiguration areaConfig = template.getHatchedAreaSource(); @@ -346,7 +371,7 @@ public class GeospatialDataGenerator { return rval; } - static GeospatialTime queryForCurrentTimes( + public static GeospatialTime queryForCurrentTimes( GeospatialMetadata metaData) throws Exception { GeospatialTime rval = new GeospatialTime(); String areaSource = metaData.getAreaSource().toLowerCase(); @@ -355,12 +380,12 @@ public class GeospatialDataGenerator { StringBuilder sql = new StringBuilder(200); sql.append("SELECT table_name, import_time FROM mapdata.map_version WHERE table_name in ('"); sql.append(areaSource.toLowerCase()); - if (tzSource != null && tzSource.length() > 0) { + if ((tzSource != null) && (tzSource.length() > 0)) { tzSource = tzSource.toLowerCase(); sql.append("', '"); sql.append(tzSource); } - if (pAreaSource != null && pAreaSource.length() > 0) { + if ((pAreaSource != null) && (pAreaSource.length() > 0)) { pAreaSource = pAreaSource.toLowerCase(); sql.append("', '"); sql.append(pAreaSource); @@ -390,7 +415,7 @@ public class GeospatialDataGenerator { return rval; } - private static GeospatialData[] queryGeospatialData(String site, + private GeospatialData[] queryGeospatialData(String site, GeospatialMetadata metaData) throws SpatialException { String areaSource = metaData.getAreaSource(); @@ -423,22 +448,24 @@ public class GeospatialDataGenerator { Geometry clippedGeom = null; for (int i = 0; i < features.length; i++) { multiPolygon = null; - for (int j = 0; j < cwaFeatures.length; j++) { + for (SpatialQueryResult cwaFeature : cwaFeatures) { clippedGeom = features[i].geometry - .intersection(cwaFeatures[j].geometry); + .intersection(cwaFeature.geometry); if (clippedGeom instanceof GeometryCollection) { GeometryCollection gc = (GeometryCollection) clippedGeom; - if (multiPolygon != null) + if (multiPolygon != null) { multiPolygon = multiPolygon .union(convertToMultiPolygon(gc)); - else + } else { multiPolygon = convertToMultiPolygon(gc); + } } } - if (multiPolygon != null) + if (multiPolygon != null) { features[i].geometry = multiPolygon; - else if (clippedGeom != null) + } else if (clippedGeom != null) { features[i].geometry = clippedGeom; + } } } @@ -463,7 +490,7 @@ public class GeospatialDataGenerator { * * @param gc */ - private static MultiPolygon convertToMultiPolygon(GeometryCollection gc) { + private MultiPolygon convertToMultiPolygon(GeometryCollection gc) { GeometryCollectionIterator iter = new GeometryCollectionIterator(gc); Set polygons = new HashSet(); MultiPolygon mp = null; @@ -471,52 +498,59 @@ public class GeospatialDataGenerator { while (iter.hasNext()) { Object o = iter.next(); if (o instanceof MultiPolygon) { - if (mp == null) + if (mp == null) { mp = (MultiPolygon) o; - else + } else { mp = (MultiPolygon) mp.union((MultiPolygon) o); + } } else if (o instanceof Polygon) { polygons.add((Polygon) o); - } else if (o instanceof LineString || o instanceof Point) { + } else if ((o instanceof LineString) || (o instanceof Point)) { LinearRing lr = null; Coordinate[] coords = null; if (o instanceof LineString) { Coordinate[] cs = ((LineString) o).getCoordinates(); if (cs.length < 4) { coords = new Coordinate[4]; - for (int j = 0; j < cs.length; j++) + for (int j = 0; j < cs.length; j++) { coords[j] = new Coordinate(cs[j]); - for (int j = cs.length; j < 4; j++) + } + for (int j = cs.length; j < 4; j++) { coords[j] = new Coordinate(cs[3 - j]); + } } else { coords = new Coordinate[cs.length + 1]; - for (int j = 0; j < cs.length; j++) + for (int j = 0; j < cs.length; j++) { coords[j] = new Coordinate(cs[j]); + } coords[cs.length] = new Coordinate(cs[0]); } } else { coords = new Coordinate[4]; - for (int i = 0; i < 4; i++) + for (int i = 0; i < 4; i++) { coords[i] = ((Point) o).getCoordinate(); + } } lr = (((Geometry) o).getFactory()).createLinearRing(coords); Polygon poly = (new GeometryFactory()).createPolygon(lr, null); - polygons.add((Polygon) poly); + polygons.add(poly); } else { statusHandler.handle(Priority.WARN, "Unprocessed Geometry object: " + o.getClass().getName()); } } - if (mp == null && polygons.size() == 0) + if ((mp == null) && (polygons.size() == 0)) { return null; + } if (polygons.size() > 0) { Polygon[] p = polygons.toArray(new Polygon[0]); - if (mp != null) + if (mp != null) { mp = (MultiPolygon) mp.union(new MultiPolygon(p, gc .getFactory())); - else + } else { mp = new MultiPolygon(p, gc.getFactory()); + } } return mp; } @@ -527,8 +561,7 @@ public class GeospatialDataGenerator { * * @param results */ - private static void topologySimplifyQueryResults( - SpatialQueryResult[] results) { + private void topologySimplifyQueryResults(SpatialQueryResult[] results) { GeometryFactory gf = new GeometryFactory(); Geometry[] geoms = new Geometry[results.length]; for (int i = 0; i < results.length; i++) { @@ -571,7 +604,7 @@ public class GeospatialDataGenerator { * @param hull * @param geoData */ - private static GeospatialData[] queryTimeZones(GeospatialMetadata metaData, + private GeospatialData[] queryTimeZones(GeospatialMetadata metaData, Geometry hull, GeospatialData[] geoData) throws SpatialException { GeospatialData[] rval = null; String timezonePathcastTable = metaData.getTimeZoneSource(); @@ -627,8 +660,8 @@ public class GeospatialDataGenerator { * @return * @throws SpatialException */ - private static GeospatialData[] queryParentAreas( - GeospatialMetadata metaData, Geometry hull) throws SpatialException { + private GeospatialData[] queryParentAreas(GeospatialMetadata metaData, + Geometry hull) throws SpatialException { GeospatialData[] rval = null; String parentAreaSource = metaData.getParentAreaSource(); if (parentAreaSource != null) { @@ -653,7 +686,7 @@ public class GeospatialDataGenerator { return rval; } - private static void persistGeoData(String site, + private void persistGeoData(String site, Map times, GeospatialTime curTime, GeospatialDataSet geoData) throws SerializationException, LocalizationException, JAXBException { @@ -681,7 +714,7 @@ public class GeospatialDataGenerator { lf.write(xml.getBytes()); } - private static void deleteGeomFiles(String site, GeospatialTime time) { + private void deleteGeomFiles(String site, GeospatialTime time) { String fileName = time.getFileName(); IPathManager pathMgr = PathManagerFactory.getPathManager(); @@ -701,8 +734,28 @@ public class GeospatialDataGenerator { } } - private static final String generateGeoDataFilename( - GeospatialMetadata metaData) { + private String generateGeoDataFilename(GeospatialMetadata metaData) { return metaData.getAreaSource() + "_" + metaData.hashCode() + ".bin"; } + + private String getTimeStamp(GeospatialTime curTime, + GeospatialTime lastRunTime) { + long tmStampMs = 0; + if (curTime.getAreaSourceTime() != lastRunTime.getAreaSourceTime()) { + tmStampMs = curTime.getAreaSourceTime(); + } else if (curTime.getParentSourceTime() != lastRunTime + .getParentSourceTime()) { + tmStampMs = curTime.getParentSourceTime(); + } else if (curTime.getTimeZoneSourceTime() != lastRunTime + .getTimeZoneSourceTime()) { + tmStampMs = curTime.getTimeZoneSourceTime(); + } + + SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss.SSS"); + sdf.setTimeZone(TimeZone.getTimeZone("GMT")); + Calendar calendar = Calendar.getInstance(); + calendar.setTimeZone(TimeZone.getTimeZone("GMT")); + calendar.setTimeInMillis(tmStampMs); + return sdf.format(calendar.getTime()); + } } diff --git a/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataUpdater.java b/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataUpdater.java deleted file mode 100644 index f32777475d..0000000000 --- a/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataUpdater.java +++ /dev/null @@ -1,140 +0,0 @@ -package com.raytheon.edex.plugin.warning.gis; - -import java.text.SimpleDateFormat; -import java.util.Calendar; -import java.util.List; -import java.util.Map; -import java.util.Set; -import java.util.TimeZone; - -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; - -import com.raytheon.edex.site.SiteUtil; -import com.raytheon.edex.util.Util; -import com.raytheon.uf.common.dataplugin.warning.config.DialogConfiguration; -import com.raytheon.uf.common.dataplugin.warning.gis.GeospatialFactory; -import com.raytheon.uf.common.dataplugin.warning.gis.GeospatialMetadata; -import com.raytheon.uf.common.dataplugin.warning.gis.GeospatialTime; -import com.raytheon.uf.common.geospatial.SpatialException; -import com.raytheon.uf.common.status.IUFStatusHandler; -import com.raytheon.uf.common.status.UFStatus; -import com.raytheon.uf.common.status.UFStatus.Priority; -import com.raytheon.uf.edex.core.EDEXUtil; -import com.raytheon.uf.edex.core.EdexException; - -/** - * Compares current time in the database against the time of last run - * generated geometry and if they differ regenerates the files. - * - *
- * 
- * SOFTWARE HISTORY
- * 
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Feb 07, 2014  16090  mgamazaychikov Initial creation
- * 
- * - * @author mgamazaychikov - * @version 1.0 - */ - -public class GeospatialDataUpdater { - private final static IUFStatusHandler statusHandler = UFStatus - .getHandler(GeospatialDataUpdater.class); - private static final String UPDATER_ENDPOINT = "geospatialUpdateNotify"; - private static Log logger = LogFactory.getLog(Util.class); - - private static Set metaDataSet = null; - private static Map map = null; - - public static void runCheckUpdate() throws SpatialException { - StringBuilder sb = new StringBuilder(); - if (metaDataSet == null){ - runInit(); - } - GeospatialTime curTime = null; - GeospatialTime lastRunTime = null; - boolean generate = false; - sb.append("GeospatialDataUpdater: "); - for (GeospatialMetadata md : metaDataSet) { - lastRunTime = map.get(md); - try { - curTime = GeospatialDataGenerator.queryForCurrentTimes(md); - } catch (Exception e) { - throw new SpatialException( - "Unable to look up database version times.", - e); - } - if (!curTime.equals(lastRunTime)) { - generate = true; - break; - } - else { - generate = false; - } - } - if (generate){ - sb.append("Geometry database time differs from current geometry metadata time: regenerating geometries"); - } - else { - return; - } - if (statusHandler.isPriorityEnabled(Priority.INFO)) { - statusHandler.info(sb.toString()); - } - GeospatialDataGenerator.generateUniqueGeospatialMetadataGeometries(); - - String updatedTimeStamp = getTimeStamp(curTime, lastRunTime); - try { - EDEXUtil.getMessageProducer().sendAsync(UPDATER_ENDPOINT, updatedTimeStamp); - } catch (EdexException e) { - logger.error("Could not send message to alarm/alert", e); - } - metaDataSet = null; - } - - private static String getTimeStamp(GeospatialTime curTime, - GeospatialTime lastRunTime) { - long tmStampMs = 0; - if (curTime.getAreaSourceTime() != lastRunTime.getAreaSourceTime()) { - tmStampMs = curTime.getAreaSourceTime(); - } else if (curTime.getParentSourceTime() != lastRunTime.getParentSourceTime()) { - tmStampMs = curTime.getParentSourceTime(); - } else if (curTime.getTimeZoneSourceTime() != lastRunTime.getTimeZoneSourceTime()) { - tmStampMs = curTime.getTimeZoneSourceTime(); - } - - SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss.SSS"); - sdf.setTimeZone(TimeZone.getTimeZone("GMT")); - Calendar calendar = Calendar.getInstance(); - calendar.setTimeZone(TimeZone.getTimeZone("GMT")); - calendar.setTimeInMillis(tmStampMs); - return sdf.format(calendar.getTime()); - } - - private static void runInit() { - String mySite = SiteUtil.getSite(); - DialogConfiguration dialogConfig = null; - - try { - dialogConfig = DialogConfiguration.loadDialogConfig(mySite); - } catch (Exception e) { - statusHandler.handle(Priority.ERROR, - "Error loading warngen config.xml", e); - return; - } - List sites = GeospatialDataGenerator.getBackupSites(dialogConfig); - sites.add(0, mySite); - List templates = GeospatialDataGenerator.getTemplates(dialogConfig); - metaDataSet = GeospatialDataGenerator.getMetaDataSet(sites, templates); - map = GeospatialFactory.loadLastRunGeoTimeSet(mySite); - StringBuilder sb = new StringBuilder(); - if (statusHandler.isPriorityEnabled(Priority.INFO)) { - sb.append("GeospatialDataUpdater has been re-inited"); - statusHandler.info(sb.toString()); - } - } - -} diff --git a/edexOsgi/com.raytheon.edex.rpgenvdata/res/spring/rpgenvdata-spring.xml b/edexOsgi/com.raytheon.edex.rpgenvdata/res/spring/rpgenvdata-spring.xml index ea6bff1198..a7b6d0cd84 100644 --- a/edexOsgi/com.raytheon.edex.rpgenvdata/res/spring/rpgenvdata-spring.xml +++ b/edexOsgi/com.raytheon.edex.rpgenvdata/res/spring/rpgenvdata-spring.xml @@ -33,7 +33,7 @@
- + diff --git a/edexOsgi/com.raytheon.edex.textdb/res/spring/textdb-ingest.xml b/edexOsgi/com.raytheon.edex.textdb/res/spring/textdb-ingest.xml index d447a300cc..ca6c7af184 100644 --- a/edexOsgi/com.raytheon.edex.textdb/res/spring/textdb-ingest.xml +++ b/edexOsgi/com.raytheon.edex.textdb/res/spring/textdb-ingest.xml @@ -5,7 +5,6 @@ - diff --git a/edexOsgi/com.raytheon.edex.utilitysrv/res/spring/utility-request.xml b/edexOsgi/com.raytheon.edex.utilitysrv/res/spring/utility-request.xml index 2639e15829..2388a9a6c0 100644 --- a/edexOsgi/com.raytheon.edex.utilitysrv/res/spring/utility-request.xml +++ b/edexOsgi/com.raytheon.edex.utilitysrv/res/spring/utility-request.xml @@ -37,7 +37,7 @@ - + diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.dataplugin/META-INF/MANIFEST.MF index 7528d681f3..f9d11b5733 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.dataplugin/META-INF/MANIFEST.MF @@ -8,7 +8,6 @@ Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Eclipse-RegisterBuddy: com.raytheon.uf.common.serialization Export-Package: com.raytheon.uf.common.dataplugin, com.raytheon.uf.common.dataplugin.annotations, - com.raytheon.uf.common.dataplugin.defaults, com.raytheon.uf.common.dataplugin.exception, com.raytheon.uf.common.dataplugin.message, com.raytheon.uf.common.dataplugin.persist, diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/PluginProperties.java b/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/PluginProperties.java index 5855566dba..70f6738b6c 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/PluginProperties.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/PluginProperties.java @@ -21,7 +21,6 @@ package com.raytheon.uf.common.dataplugin; import java.util.List; -import com.raytheon.uf.common.dataplugin.defaults.PluginPropertyDefaults; import com.raytheon.uf.common.dataplugin.persist.IHDFFilePathProvider; /** @@ -32,8 +31,8 @@ import com.raytheon.uf.common.dataplugin.persist.IHDFFilePathProvider; * SOFTWARE HISTORY * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Mar 20, 2009 njensen Initial creation - * + * Mar 20, 2009 njensen Initial creation. + * Mar 13, 2014 2726 rjpeter Moved default values to set on plugin registration. * * * @author njensen @@ -54,7 +53,7 @@ public class PluginProperties { protected Class record; - protected int initialRetentionTime; + protected Integer initialRetentionTime; protected String pluginFQN; @@ -62,22 +61,40 @@ public class PluginProperties { protected IHDFFilePathProvider pathProvider; + /** + * Set the defaults for any fields that haven't already been set to a not + * null value. + * + * @param defaults + */ + public void setDefaults(PluginProperties defaults) { + /* + * pluginName, pluginFQN, dependencyFQNs, and record have no defaults to + * inherit + */ + + if (database == null) { + database = defaults.getDatabase(); + } + if (initializer == null) { + initializer = defaults.getInitializer(); + } + if (dao == null) { + dao = defaults.getDao(); + } + if (initialRetentionTime == null) { + initialRetentionTime = defaults.getInitialRetentionTime(); + } + if (pathProvider == null) { + pathProvider = defaults.getPathProvider(); + } + } + /** * Compression to use on storage, if null, no compression */ protected String compression; - /** - * Constructor that initializes values to default values - */ - public PluginProperties() { - database = PluginPropertyDefaults.getDatabase(); - initializer = PluginPropertyDefaults.getInitializer(); - dao = PluginPropertyDefaults.getDao(); - initialRetentionTime = PluginPropertyDefaults.getInitialRetentionTime(); - pathProvider = PluginPropertyDefaults.getPathProvider(); - } - /** * @return the database */ @@ -112,7 +129,11 @@ public class PluginProperties { * @return the initialRetentionTime */ public int getInitialRetentionTime() { - return initialRetentionTime; + if (initialRetentionTime != null) { + return initialRetentionTime; + } + + return 0; } /** @@ -199,5 +220,4 @@ public class PluginProperties { public void setCompression(String compression) { this.compression = compression; } - } diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/defaults/PluginPropertyDefaults.java b/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/defaults/PluginPropertyDefaults.java deleted file mode 100644 index 92dcc50e22..0000000000 --- a/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/defaults/PluginPropertyDefaults.java +++ /dev/null @@ -1,120 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ -package com.raytheon.uf.common.dataplugin.defaults; - -import com.raytheon.uf.common.dataplugin.persist.IHDFFilePathProvider; - -/** - * Defaults for the data plugins. Setters should only be called once through - * Spring XML configuration. - * - *
- * 
- * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Mar 20, 2009            njensen     Initial creation
- * 
- * 
- * - * @author njensen - * @version 1.0 - */ - -public class PluginPropertyDefaults { - - protected static String database; - - protected static Class initializer; - - protected static Class dao; - - protected static int initialRetentionTime; - - protected static IHDFFilePathProvider pathProvider; - - /** - * @return the database - */ - public static String getDatabase() { - return database; - } - - /** - * @param database - * the database to set - */ - public void setDatabase(String database) { - PluginPropertyDefaults.database = database; - } - - /** - * @return the initialRetentionTime - */ - public static int getInitialRetentionTime() { - return initialRetentionTime; - } - - /** - * @param initialRetentionTime - * the initialRetentionTime to set - */ - public void setInitialRetentionTime(int initialRetentionTime) { - PluginPropertyDefaults.initialRetentionTime = initialRetentionTime; - } - - /** - * @return the initializer - */ - public static Class getInitializer() { - return initializer; - } - - /** - * @param initializer - * the initializer to set - */ - public void setInitializer(Class initializer) { - PluginPropertyDefaults.initializer = initializer; - } - - /** - * @return the dao - */ - public static Class getDao() { - return dao; - } - - /** - * @param dao - * the dao to set - */ - public void setDao(Class dao) { - PluginPropertyDefaults.dao = dao; - } - - public static IHDFFilePathProvider getPathProvider() { - return pathProvider; - } - - public void setPathProvider(IHDFFilePathProvider pathProvider) { - PluginPropertyDefaults.pathProvider = pathProvider; - } -} diff --git a/edexOsgi/com.raytheon.uf.common.message/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.message/META-INF/MANIFEST.MF index 955d1c0a0c..52565ea439 100644 --- a/edexOsgi/com.raytheon.uf.common.message/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.message/META-INF/MANIFEST.MF @@ -13,4 +13,5 @@ Import-Package: com.raytheon.uf.common.serialization, com.raytheon.uf.common.serialization.annotations, org.apache.commons.lang Require-Bundle: net.sf.cglib;bundle-version="2.1.3", - com.raytheon.uf.common.status;bundle-version="1.11.11" + com.raytheon.uf.common.status;bundle-version="1.11.11", + com.raytheon.uf.common.util diff --git a/edexOsgi/com.raytheon.uf.common.message/src/com/raytheon/uf/common/message/WsId.java b/edexOsgi/com.raytheon.uf.common.message/src/com/raytheon/uf/common/message/WsId.java index 2a2a279cc2..bade300b25 100644 --- a/edexOsgi/com.raytheon.uf.common.message/src/com/raytheon/uf/common/message/WsId.java +++ b/edexOsgi/com.raytheon.uf.common.message/src/com/raytheon/uf/common/message/WsId.java @@ -20,18 +20,13 @@ package com.raytheon.uf.common.message; import java.io.Serializable; -import java.lang.management.ManagementFactory; import java.net.InetAddress; -import java.net.UnknownHostException; -import java.util.Collections; -import java.util.LinkedHashMap; -import java.util.Map; -import java.util.Map.Entry; import com.raytheon.uf.common.message.adapter.WsIdAdapter; import com.raytheon.uf.common.serialization.ISerializableObject; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; import com.raytheon.uf.common.serialization.annotations.DynamicSerializeTypeAdapter; +import com.raytheon.uf.common.util.SystemUtil; /** * The WsId contains the work station identification for the user. * @@ -41,12 +36,12 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeTypeAdap * SOFTWARE HISTORY * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Jun 10, 2009 randerso Initial creation - * Apr 25, 2012 545 randerso Repurposed the lockKey field as threadId - * Sep 19, 2012 #1190 dgilling Cache host names so toPrettyString() doesn't - * get delayed behind DNS requests. - * Sep 20, 2012 #1190 dgilling Create method getHostName(). - * + * Jun 10, 2009 randerso Initial creation + * Apr 25, 2012 545 randerso Repurposed the lockKey field as threadId + * Sep 19, 2012 #1190 dgilling Cache host names so toPrettyString() doesn't + * get delayed behind DNS requests. + * Sep 20, 2012 #1190 dgilling Create method getHostName(). + * Mar 20, 2014 2726 rjpeter Moved hostNameCache to SystemUtil. * * * @author randerso @@ -57,32 +52,8 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeTypeAdap @DynamicSerializeTypeAdapter(factory = WsIdAdapter.class) public class WsId implements Serializable, ISerializableObject { - private static class BoundedMap extends LinkedHashMap { - private static final long serialVersionUID = 1L; - - private final int maxSize; - - public BoundedMap(int maxSize) { - super(16, 0.75f, true); - this.maxSize = maxSize; - } - - /* - * (non-Javadoc) - * - * @see java.util.LinkedHashMap#removeEldestEntry(java.util.Map.Entry) - */ - @Override - protected boolean removeEldestEntry(Entry eldest) { - return size() > maxSize; - } - } - private static final long serialVersionUID = 1L; - private static final Map hostNameCache = Collections - .synchronizedMap(new BoundedMap(100)); - private final InetAddress networkId; private final String userName; @@ -169,25 +140,14 @@ public class WsId implements Serializable, ISerializableObject { this.progName = "unknown"; } - this.pid = Integer.parseInt(ManagementFactory.getRuntimeMXBean() - .getName().split("@")[0]); + this.pid = SystemUtil.getPid(); this.threadId = Thread.currentThread().getId(); if (networkId != null) { this.networkId = networkId; } else { - InetAddress addr = null; - try { - addr = InetAddress.getLocalHost(); - } catch (UnknownHostException e) { - try { - addr = InetAddress.getByAddress(new byte[] { 0, 0, 0, 0 }); - } catch (UnknownHostException e1) { - // won't happen - } - } - this.networkId = addr; + this.networkId = SystemUtil.getLocalAddress(); } } @@ -203,7 +163,7 @@ public class WsId implements Serializable, ISerializableObject { long addr = 0; byte[] bytes = networkId.getAddress(); for (int i = bytes.length - 1; i >= 0; i--) { - addr = addr << 8 | (0xff & bytes[i]); + addr = (addr << 8) | (0xff & bytes[i]); } o.append(addr).append(':').append(userName).append(':') @@ -219,7 +179,7 @@ public class WsId implements Serializable, ISerializableObject { * @return WsId as pretty string */ public String toPrettyString() { - String hostname = retrieveFromHostCache(networkId); + String hostname = SystemUtil.getHostName(networkId); StringBuilder o = new StringBuilder(); o.append(userName).append('@').append(hostname).append(':') @@ -229,16 +189,6 @@ public class WsId implements Serializable, ISerializableObject { return o.toString(); } - private String retrieveFromHostCache(InetAddress address) { - String hostName = hostNameCache.get(address); - if (hostName == null) { - hostName = address.getHostName(); - hostNameCache.put(address, hostName); - } - - return hostName; - } - /** * @return the _networkId */ @@ -247,7 +197,7 @@ public class WsId implements Serializable, ISerializableObject { } public String getHostName() { - return retrieveFromHostCache(networkId); + return SystemUtil.getHostName(networkId); } /** @@ -287,13 +237,13 @@ public class WsId implements Serializable, ISerializableObject { public int hashCode() { final int prime = 31; int result = 1; - result = prime * result + (int) (threadId ^ (threadId >>> 32)); - result = prime * result + result = (prime * result) + (int) (threadId ^ (threadId >>> 32)); + result = (prime * result) + ((networkId == null) ? 0 : networkId.hashCode()); - result = prime * result + pid; - result = prime * result + result = (prime * result) + pid; + result = (prime * result) + ((progName == null) ? 0 : progName.hashCode()); - result = prime * result + result = (prime * result) + ((userName == null) ? 0 : userName.hashCode()); return result; } diff --git a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SystemUtil.java b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SystemUtil.java index f1a5903d74..a113752e68 100644 --- a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SystemUtil.java +++ b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SystemUtil.java @@ -21,9 +21,11 @@ package com.raytheon.uf.common.util; import java.lang.management.ManagementFactory; import java.net.InetAddress; -import java.net.NetworkInterface; -import java.net.SocketException; -import java.util.Enumeration; +import java.net.UnknownHostException; +import java.util.Collections; +import java.util.LinkedHashMap; +import java.util.Map; +import java.util.Map.Entry; /** * System utilities such as hostname and pid lookup. @@ -35,18 +37,57 @@ import java.util.Enumeration; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Sep 26, 2011 rjpeter Initial creation - * + * Apr 10, 2014 2726 rjpeter Moved hostName caching logic from WsId to here. * * * @author rjpeter * @version 1.0 */ - public class SystemUtil { + /** + * Map that can be limited to a given number of entries. + */ + private static class BoundedMap extends LinkedHashMap { + private static final long serialVersionUID = 1L; + + private final int maxSize; + + public BoundedMap(int maxSize) { + super(16, 0.75f, true); + this.maxSize = maxSize; + } + + /* + * (non-Javadoc) + * + * @see java.util.LinkedHashMap#removeEldestEntry(java.util.Map.Entry) + */ + @Override + protected boolean removeEldestEntry(Entry eldest) { + return size() > maxSize; + } + } + + private static final Map hostNameCache = Collections + .synchronizedMap(new BoundedMap(100)); + protected static String hostName; protected static Integer pid; + protected static InetAddress addr; + + static { + /* attempt to initialize fields */ + getPid(); + getHostName(); + } + + /** + * Returns the pid of the current process. + * + * @return + */ public static int getPid() { if (pid == null) { pid = new Integer(ManagementFactory.getRuntimeMXBean().getName() @@ -56,43 +97,65 @@ public class SystemUtil { return pid.intValue(); } + /** + * Returns the local INetAddress. + * + * @return + */ + public static InetAddress getLocalAddress() { + if (addr == null) { + try { + addr = InetAddress.getLocalHost(); + } catch (UnknownHostException e) { + try { + return InetAddress.getByAddress(new byte[] { 0, 0, 0, 0 }); + } catch (UnknownHostException e1) { + // won't happen + } + } + } + return addr; + } + + /** + * Returns the hostName for the given inet address. The address is cached + * for the lifetime of the jvm after first look up. If a machine changes IPs + * it will get mapped to the wrong hostName until a reboot. + * + * @param address + * @return + */ + public static String getHostName(InetAddress address) { + String hostName = hostNameCache.get(address); + if (hostName == null) { + hostName = address.getHostName(); + hostNameCache.put(address, hostName); + } + + return hostName; + } + + /** + * Returns local host name. + * + * @return + */ public static String getHostName() { if (hostName == null) { - InetAddress addrToUse = null; - boolean found = false; - try { - Enumeration nis = NetworkInterface - .getNetworkInterfaces(); - while (nis.hasMoreElements() && !found) { - NetworkInterface ni = nis.nextElement(); - ni.isVirtual(); - ni.isUp(); - Enumeration addrs = ni.getInetAddresses(); - while (addrs.hasMoreElements() && !found) { - InetAddress addr = addrs.nextElement(); - if (addr.isLinkLocalAddress() == false - && addr.isSiteLocalAddress() == false - && addr.isLoopbackAddress() == false) { - addrToUse = addr; - found = true; - } - } - } - } catch (SocketException e) { - e.printStackTrace(); - } + InetAddress addr = getLocalAddress(); + hostName = getHostName(addr); - if (addrToUse == null) { + if (hostName == null) { String hostNameProp = System.getenv("HOSTNAME"); - if (hostNameProp != null && hostNameProp.trim().length() == 0) { + if ((hostNameProp != null) + && (hostNameProp.trim().length() == 0)) { hostName = hostNameProp; } else { hostName = "localhost"; } - } else { - hostName = addrToUse.getHostName(); } } + return hostName; } } diff --git a/edexOsgi/com.raytheon.uf.edex.activetable/res/spring/activetable-ingest.xml b/edexOsgi/com.raytheon.uf.edex.activetable/res/spring/activetable-ingest.xml index 434c097ac8..1a9ee5f976 100644 --- a/edexOsgi/com.raytheon.uf.edex.activetable/res/spring/activetable-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.activetable/res/spring/activetable-ingest.xml @@ -1,14 +1,11 @@ + http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd"> + errorHandlerRef="errorHandler"> @@ -37,8 +34,7 @@ - + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.activetable/res/spring/activetable-request.xml b/edexOsgi/com.raytheon.uf.edex.activetable/res/spring/activetable-request.xml index de0604e03e..a5e9dd59a7 100644 --- a/edexOsgi/com.raytheon.uf.edex.activetable/res/spring/activetable-request.xml +++ b/edexOsgi/com.raytheon.uf.edex.activetable/res/spring/activetable-request.xml @@ -89,7 +89,7 @@ + errorHandlerRef="errorHandler"> @@ -102,8 +102,7 @@ - + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/EDEXUtil.java b/edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/EDEXUtil.java index 5def363804..e7680772f8 100644 --- a/edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/EDEXUtil.java +++ b/edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/EDEXUtil.java @@ -22,9 +22,7 @@ package com.raytheon.uf.edex.core; import java.io.File; import java.io.IOException; -import java.net.InetAddress; import java.net.URL; -import java.net.UnknownHostException; import java.util.Calendar; import java.util.Date; import java.util.TimeZone; @@ -52,12 +50,13 @@ import com.raytheon.uf.edex.core.props.PropertiesFactory; * SOFTWARE HISTORY * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * 04/23/08 1088 chammack Split from Util + * 04/23/2008 1088 chammack Split from Util * 11/22/2010 2235 cjeanbap Added audio file to StatusMessage. * 02/02/2011 6500 cjeanbap Added paramter to method signature and * properly assign source value. * 06/12/2012 0609 djohnson Use EDEXUtil for EDEX_HOME. - * 3/18/2013 1802 bphillip Added getList utility function + * 03/18/2013 1802 bphillip Added getList utility function + * 04/10/2014 2726 rjpeter Added methods for waiting for edex to be running. * * * @author chammack @@ -81,20 +80,7 @@ public class EDEXUtil implements ApplicationContextAware { // TODO private static final String alertEndpoint = "alertVizNotify"; - private static int serverId; - static { - try { - String hostname = InetAddress.getLocalHost().getCanonicalHostName(); - serverId = hostname.hashCode(); - } catch (UnknownHostException e) { - serverId = 0; - // assume localhost, no network connection - } - } - - public static int getServerId() { - return serverId; - } + private static final Object waiter = new Object(); @Override public void setApplicationContext(ApplicationContext context) @@ -146,6 +132,30 @@ public class EDEXUtil implements ApplicationContextAware { return "Operational".equals(System.getProperty("System.status")); } + /** + * Blocks until EDEX is in the running state. + */ + public static void waitForRunning() { + synchronized (waiter) { + try { + while (!isRunning()) { + waiter.wait(15000); + } + } catch (InterruptedException e) { + // ignore + } + } + } + + /** + * Called once EDEX is in a running state to notify all waiting clients. + */ + public static void notifyIsRunning() { + synchronized (waiter) { + waiter.notifyAll(); + } + } + public static boolean containsESBComponent(String name) { return CONTEXT.containsBean(name); } @@ -176,9 +186,10 @@ public class EDEXUtil implements ApplicationContextAware { persistDir = envProperties.getEnvValue("PERSISTDIR"); persistDir = FileUtil.convertFilePath(persistDir); - if (persistDir == null) + if (persistDir == null) { throw new PluginException( "Unable to retrieve value for the PERSISTDIR"); + } dbDirectory = new File(persistDir); dbDirectory.mkdirs(); diff --git a/edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/EdexTimerBasedThread.java b/edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/EdexTimerBasedThread.java new file mode 100644 index 0000000000..ecc24dcd00 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/EdexTimerBasedThread.java @@ -0,0 +1,172 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.core; + +import java.util.LinkedList; +import java.util.List; +import java.util.concurrent.atomic.AtomicInteger; + +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; + +/** + * Base class for Timer based threading. Allows previous thread based paradigms + * to hook in to a camel context with minimal work. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Mar 19, 2014 2826       rjpeter     Initial creation.
+ * 
+ * 
+ * + * @author rjpeter + * @version 1.0 + */ +public abstract class EdexTimerBasedThread implements IContextStateProcessor { + /** + * Number of threads that have been started. + */ + protected final AtomicInteger threadCount = new AtomicInteger(0); + + /** + * Current active threads. + */ + protected final List threads = new LinkedList(); + + /** + * Whether the container is running or not. + */ + protected volatile boolean running = true; + + /** + * Interval thread should sleep between calls. + */ + protected int threadSleepInterval = 30000; + + /** + * The name to use for the threads. + * + * @return + */ + public abstract String getThreadGroupName(); + + /** + * Method to do the work. Should return when done. Run method handles start + * up/shutdown mechanism. + * + * @throws Exception + */ + public abstract void process() throws Exception; + + /** + * Can be overridden to do any work to cleanup the thread on shutdown. + */ + public void dispose() { + + } + + /** + * Called by camel to do the processing. Will run until the context is + * shutdown. + */ + public void run() { + synchronized (threads) { + threads.add(Thread.currentThread()); + } + + try { + Thread.currentThread().setName( + getThreadGroupName() + "-" + threadCount.incrementAndGet()); + + while (running) { + try { + process(); + } catch (Exception e) { + UFStatus.getHandler().error( + "Error occurred during processing", e); + } + + try { + /* + * use waiter to allow shutdown to wake thread for immediate + * shutdown + */ + synchronized (threads) { + threads.wait(threadSleepInterval); + } + } catch (InterruptedException e) { + // ignore + } + } + } finally { + synchronized (threads) { + threads.remove(Thread.currentThread()); + threads.notify(); + } + dispose(); + } + } + + @Override + public void preStart() { + } + + @Override + public void postStart() { + } + + @Override + public void preStop() { + running = false; + synchronized (threads) { + threads.notifyAll(); + } + } + + @Override + public void postStop() { + IUFStatusHandler statusHandler = UFStatus.getHandler(); + String msg = "Waiting for " + getThreadGroupName() + + " threads to finish"; + + synchronized (threads) { + while (!threads.isEmpty()) { + statusHandler.info(msg); + try { + threads.wait(10000); + } catch (Exception e) { + // ignore + } + } + } + } + + public int getThreadSleepInterval() { + return threadSleepInterval; + } + + public void setThreadSleepInterval(int threadSleepInterval) { + this.threadSleepInterval = threadSleepInterval; + } +} diff --git a/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataGeneratorThread.java b/edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/IContextStateProcessor.java similarity index 53% rename from edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataGeneratorThread.java rename to edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/IContextStateProcessor.java index 4bcb51188c..fe0e5af288 100644 --- a/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataGeneratorThread.java +++ b/edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/IContextStateProcessor.java @@ -17,10 +17,11 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.warning.gis; +package com.raytheon.uf.edex.core; /** - * TODO Add Description + * Methods to be called as part of the context life cycle for starting and + * stopping the context. * *
  * 
@@ -28,31 +29,36 @@ package com.raytheon.edex.plugin.warning.gis;
  * 
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
- * Jul 24, 2011            rjpeter     Initial creation
+ * Feb 26, 2014 2726       rjpeter     Initial creation
  * 
  * 
* * @author rjpeter * @version 1.0 */ +public interface IContextStateProcessor { -public class GeospatialDataGeneratorThread { - public GeospatialDataGeneratorThread() { - Thread t = new Thread("WarngenGeometryGenerator") { - public void run() { - // TODO: Move to camel timer, when camel upgraded to at least - // 2.8 and take advantage of single run timer - try { - // delay to allow server to start - Thread.sleep(120000); - } catch (InterruptedException e) { - // ignore - } - GeospatialDataGenerator - .generateUniqueGeospatialMetadataGeometries(); - // scan and clean old geometries - } - }; - t.start(); - } + /** + * Perform any work that needs to be done before the context is started, + * such as initialization. + */ + public void preStart(); + + /** + * Perform any work that needs to be done after the context is started, such + * as sending notifications to clients. + */ + public void postStart(); + + /** + * Perform any work that needs to be done before context is stopped, such as + * notifying async threads to stop. + */ + public void preStop(); + + /** + * Perform any work that needs to be done after the context is stopped, such + * as sending in memory data. + */ + public void postStop(); } diff --git a/edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/dataplugin/PluginRegistry.java b/edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/dataplugin/PluginRegistry.java index 5b1d410f0a..ade941c9aa 100644 --- a/edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/dataplugin/PluginRegistry.java +++ b/edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/dataplugin/PluginRegistry.java @@ -35,8 +35,8 @@ import com.raytheon.uf.common.util.registry.RegistryException; * SOFTWARE HISTORY * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Aug 6, 2009 mschenke Initial creation - * + * Aug 6, 2009 mschenke Initial creation. + * Mar 19, 2014 2726 rjpeter Updated for graceful shutdown and easier spring dependency management. * * * @author mschenke @@ -47,7 +47,15 @@ public class PluginRegistry extends GenericRegistry { private static PluginRegistry instance = new PluginRegistry(); - private List listeners = new ArrayList(); + /** + * Plugin registry listeners. + */ + private final List listeners = new ArrayList(); + + /** + * Default values for plugins registered with the registry. + */ + private PluginProperties defaultPluginProperties; private PluginRegistry() { super(); @@ -61,6 +69,8 @@ public class PluginRegistry extends GenericRegistry { public Object register(String pluginName, PluginProperties pluginProperties) throws RegistryException { if (!registry.containsKey(pluginName)) { + pluginProperties.setDefaults(defaultPluginProperties); + super.register(pluginName, pluginProperties); for (IPluginRegistryChanged iprc : listeners) { iprc.pluginAdded(pluginName); @@ -77,4 +87,22 @@ public class PluginRegistry extends GenericRegistry { return this; } + public PluginProperties getDefaultPluginProperties() { + return defaultPluginProperties; + } + + public void setDefaultPluginProperties( + PluginProperties defaultPluginProperties) { + this.defaultPluginProperties = defaultPluginProperties; + } + + /** + * The initial listeners to the plugin registry to ensure minimum + * requirements are meant via spring launching. + * + * @param listeners + */ + public void setInitialListeners(List listeners) { + this.listeners.addAll(listeners); + } } diff --git a/edexOsgi/com.raytheon.uf.edex.cpgsrv/res/spring/cpgsrv-spring.xml b/edexOsgi/com.raytheon.uf.edex.cpgsrv/res/spring/cpgsrv-spring.xml index c1dd697082..bcc6a25751 100644 --- a/edexOsgi/com.raytheon.uf.edex.cpgsrv/res/spring/cpgsrv-spring.xml +++ b/edexOsgi/com.raytheon.uf.edex.cpgsrv/res/spring/cpgsrv-spring.xml @@ -4,16 +4,10 @@ xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd"> - - - - + errorHandlerRef="errorHandler"> @@ -21,8 +15,7 @@ + errorHandlerRef="errorHandler"> @@ -38,8 +31,7 @@ - + diff --git a/edexOsgi/com.raytheon.uf.edex.database/res/spring/database-common.xml b/edexOsgi/com.raytheon.uf.edex.database/res/spring/database-common.xml index 993ed67877..f8eb24d779 100644 --- a/edexOsgi/com.raytheon.uf.edex.database/res/spring/database-common.xml +++ b/edexOsgi/com.raytheon.uf.edex.database/res/spring/database-common.xml @@ -49,7 +49,9 @@ - + + + diff --git a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/DatabasePluginRegistry.java b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/DatabasePluginRegistry.java index 0ce6efef40..79dff30c5d 100644 --- a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/DatabasePluginRegistry.java +++ b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/DatabasePluginRegistry.java @@ -40,8 +40,8 @@ import com.raytheon.uf.edex.core.dataplugin.PluginRegistry; * SOFTWARE HISTORY * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Apr 28, 2010 #5050 rjpeter Initial creation - * + * Apr 28, 2010 #5050 rjpeter Initial creation + * May 29, 2014 2726 rjpeter Added initial listeners and properties for easier spring dependency management. * * * @author rjpeter @@ -56,7 +56,9 @@ public class DatabasePluginRegistry extends private static DatabasePluginRegistry instance = new DatabasePluginRegistry(); - private List listeners = new ArrayList(); + private final List listeners = new ArrayList(); + + private List initialProperties; private DatabasePluginRegistry() { super(); @@ -66,6 +68,18 @@ public class DatabasePluginRegistry extends return instance; } + /** + * Called by spring to initialize the registry. Mainly used to ensure the + * base database plugin is always loaded. + */ + public void init() throws RegistryException { + if ((initialProperties != null) && !initialProperties.isEmpty()) { + for (DatabasePluginProperties dbProp : initialProperties) { + register(dbProp.getPluginFQN(), dbProp); + } + } + } + @Override public Object register(String pluginFQN, DatabasePluginProperties pluginProperties) throws RegistryException { @@ -95,7 +109,8 @@ public class DatabasePluginRegistry extends public void pluginAdded(String pluginName) { PluginProperties props = PluginRegistry.getInstance() .getRegisteredObject(pluginName); - if (props.getPluginFQN() != null && props.getPluginFQN().length() > 0) { + if ((props.getPluginFQN() != null) + && (props.getPluginFQN().length() > 0)) { // multiple plugins may use the same jar file. if (!registry.containsKey(props.getPluginFQN())) { try { @@ -109,4 +124,14 @@ public class DatabasePluginRegistry extends } } } + + public void setInitialListeners( + List listeners) { + this.listeners.addAll(listeners); + } + + public void setInitialProperties( + List initialProperties) { + this.initialProperties = initialProperties; + } } diff --git a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/PluginFactory.java b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/PluginFactory.java index fb3024071d..cfe5243eab 100644 --- a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/PluginFactory.java +++ b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/PluginFactory.java @@ -31,7 +31,6 @@ import com.raytheon.uf.common.dataplugin.IPluginClassMapper; import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.common.dataplugin.PluginException; import com.raytheon.uf.common.dataplugin.PluginProperties; -import com.raytheon.uf.common.dataplugin.defaults.PluginPropertyDefaults; import com.raytheon.uf.common.dataplugin.persist.IHDFFilePathProvider; import com.raytheon.uf.edex.core.dataplugin.PluginRegistry; @@ -50,7 +49,7 @@ import com.raytheon.uf.edex.core.dataplugin.PluginRegistry; * Feb 06, 2009 1990 bphillip Refactored to use spring container * Mar 20, 2009 njensen Refactored to use PluginProperties * May 16, 2013 1869 bsteffen Rewrite dataURI property mappings. - * + * Mar 19, 2014 2726 rjpeter Added defaultPathProvider field. * * * @author garmendariz @@ -75,7 +74,9 @@ public class PluginFactory implements IPluginClassMapper { private Map pluginDaoMap = new HashMap(); - private Object daoMapLock = new Object(); + private final Object daoMapLock = new Object(); + + private IHDFFilePathProvider defaultPathProvider = null; /** * Private constructor @@ -173,6 +174,7 @@ public class PluginFactory implements IPluginClassMapper { * @throws PluginException * If the class cannot be determined */ + @Override public Class getPluginRecordClass(String pluginName) throws PluginException { PluginProperties props = PluginRegistry.getInstance() @@ -233,7 +235,7 @@ public class PluginFactory implements IPluginClassMapper { if (props != null) { rval = props.getPathProvider(); } else { - rval = PluginPropertyDefaults.getPathProvider(); + rval = defaultPathProvider; } return rval; } @@ -280,4 +282,13 @@ public class PluginFactory implements IPluginClassMapper { + " is not registered with the PluginRegistry"); } } + + /** + * Set the default path provider. Used by spring to configure the factory. + * + * @param defaultPathProvider + */ + public void setDefaultPathProvider(IHDFFilePathProvider defaultPathProvider) { + this.defaultPathProvider = defaultPathProvider; + } } diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.event/res/spring/event-datadelivery-ingest.xml b/edexOsgi/com.raytheon.uf.edex.datadelivery.event/res/spring/event-datadelivery-ingest.xml index 6b0bf48923..c6205fff12 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.event/res/spring/event-datadelivery-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.event/res/spring/event-datadelivery-ingest.xml @@ -20,13 +20,8 @@ class="com.raytheon.uf.edex.datadelivery.event.notification.NotificationPurge" depends-on="ddEventRegister" /> - - - - + errorHandlerRef="errorHandler"> diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.harvester/res/spring/harvester-datadelivery.xml b/edexOsgi/com.raytheon.uf.edex.datadelivery.harvester/res/spring/harvester-datadelivery.xml index bfe8a42ca9..3781db8a84 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.harvester/res/spring/harvester-datadelivery.xml +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.harvester/res/spring/harvester-datadelivery.xml @@ -10,12 +10,17 @@ + + + + @@ -35,19 +40,6 @@ - - - - - - - - - - @@ -67,6 +59,4 @@ - - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.registry/res/spring/registry-datadelivery.xml b/edexOsgi/com.raytheon.uf.edex.datadelivery.registry/res/spring/registry-datadelivery.xml index ff513c5867..58ffd772e8 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.registry/res/spring/registry-datadelivery.xml +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.registry/res/spring/registry-datadelivery.xml @@ -1,7 +1,6 @@ + xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd"> diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.registry/res/spring/registry-federation-datadelivery.xml b/edexOsgi/com.raytheon.uf.edex.datadelivery.registry/res/spring/registry-federation-datadelivery.xml index 47f4fcb0e9..fd619e27e0 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.registry/res/spring/registry-federation-datadelivery.xml +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.registry/res/spring/registry-federation-datadelivery.xml @@ -1,7 +1,6 @@ + xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd"> diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/res/spring/grid-metadata.xml b/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/res/spring/grid-metadata.xml index f8fd0a929a..9107a68a81 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/res/spring/grid-metadata.xml +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/res/spring/grid-metadata.xml @@ -1,7 +1,6 @@ + xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd"> diff --git a/edexOsgi/com.raytheon.uf.edex.dissemination/res/spring/dissemination-request.xml b/edexOsgi/com.raytheon.uf.edex.dissemination/res/spring/dissemination-request.xml index 83c351e7f2..dcdf235bb0 100644 --- a/edexOsgi/com.raytheon.uf.edex.dissemination/res/spring/dissemination-request.xml +++ b/edexOsgi/com.raytheon.uf.edex.dissemination/res/spring/dissemination-request.xml @@ -20,20 +20,6 @@ - - - - - - java.lang.Throwable - - - - - - - @@ -50,11 +36,21 @@ java.lang.Throwable + uri="log:oup?level=ERROR&showBody=true" />
+ + + + + + java.lang.Throwable + + + +
diff --git a/edexOsgi/com.raytheon.uf.edex.distribution/res/spring/distribution-spring.xml b/edexOsgi/com.raytheon.uf.edex.distribution/res/spring/distribution-spring.xml index 38cd142db1..e62a728e1b 100644 --- a/edexOsgi/com.raytheon.uf.edex.distribution/res/spring/distribution-spring.xml +++ b/edexOsgi/com.raytheon.uf.edex.distribution/res/spring/distribution-spring.xml @@ -10,8 +10,7 @@ + errorHandlerRef="errorHandler"> @@ -59,8 +58,4 @@
- - - diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.esb.camel/META-INF/MANIFEST.MF index 0ced6fe5ae..cf2c77856c 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Camel Plug-in Bundle-SymbolicName: com.raytheon.uf.edex.esb.camel -Bundle-Version: 1.12.1174.qualifier +Bundle-Version: 1.14.0 Bundle-Vendor: Raytheon Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Require-Bundle: org.apache.camel;bundle-version="1.0.0", @@ -19,7 +19,7 @@ Require-Bundle: org.apache.camel;bundle-version="1.0.0", com.raytheon.uf.common.comm;bundle-version="1.12.1174", com.raytheon.uf.common.json;bundle-version="1.0.0" Export-Package: com.raytheon.uf.edex.esb.camel, - com.raytheon.uf.edex.esb.camel.directvm, + com.raytheon.uf.edex.esb.camel.context, com.raytheon.uf.edex.esb.camel.jms Import-Package: com.raytheon.uf.common.event, com.raytheon.uf.common.message, diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/Executor.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/Executor.java index 7434b48ce8..2a11413746 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/Executor.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/Executor.java @@ -31,7 +31,9 @@ import java.util.concurrent.CountDownLatch; import org.springframework.context.support.ClassPathXmlApplicationContext; +import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.common.util.PropertiesUtil; +import com.raytheon.uf.edex.core.EDEXUtil; import com.raytheon.uf.edex.core.modes.EDEXModesUtil; import com.raytheon.uf.edex.esb.camel.context.ContextManager; @@ -54,7 +56,7 @@ import com.raytheon.uf.edex.esb.camel.context.ContextManager; * Feb 14, 2013 1638 mschenke Removing activemq reference in stop * Apr 22, 2013 #1932 djohnson Use countdown latch for a shutdown hook. * Dec 04, 2013 2566 bgonzale refactored mode methods to a utility in edex.core. - * + * Mar 19, 2014 2726 rjpeter Added graceful shutdown. * * * @author chammack @@ -66,15 +68,36 @@ public class Executor { private static final CountDownLatch shutdownLatch = new CountDownLatch(1); public static void start() throws Exception { + final long t0 = System.currentTimeMillis(); Runtime.getRuntime().addShutdownHook(new Thread() { @Override public void run() { + ContextManager ctxMgr = ContextManager.getInstance(); + + long t1 = System.currentTimeMillis(); + System.out + .println("**************************************************"); + System.out + .println("* EDEX ESB is shutting down *"); + System.out + .println("**************************************************"); + ctxMgr.stopContexts(); + long t2 = System.currentTimeMillis(); + System.out + .println("**************************************************"); + System.out + .println("* EDEX ESB is shut down *"); + System.out.println("* Total time to shutdown: " + + TimeUtil.prettyDuration(t2 - t1)); + System.out.println("* EDEX ESB uptime: " + + TimeUtil.prettyDuration(t2 - t0)); + System.out + .println("**************************************************"); shutdownLatch.countDown(); } }); - long t0 = System.currentTimeMillis(); Thread.currentThread().setName("EDEXMain"); System.setProperty("System.status", "Starting"); @@ -113,7 +136,7 @@ public class Executor { String modeName = System.getProperty("edex.run.mode"); - if (modeName != null && modeName.length() > 0) { + if ((modeName != null) && (modeName.length() > 0)) { System.out.println("EDEX run configuration: " + modeName); } else { System.out @@ -123,8 +146,7 @@ public class Executor { + System.getProperty("aw.site.identifier")); List discoveredPlugins = EDEXModesUtil.extractSpringXmlFiles( - xmlFiles, - modeName); + xmlFiles, modeName); System.out.println(); System.out.println(" "); @@ -141,8 +163,10 @@ public class Executor { ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext( xmlFiles.toArray(new String[xmlFiles.size()])); + ContextManager ctxMgr = (ContextManager) context .getBean("contextManager"); + // start final routes ctxMgr.startContexts(); @@ -151,11 +175,12 @@ public class Executor { .println("**************************************************"); System.out .println("* EDEX ESB is now operational *"); - System.out.println("* Total startup time: " + ((t1 - t0) / 1000) - + " seconds"); + System.out.println("* Total startup time: " + + TimeUtil.prettyDuration(t1 - t0)); System.out .println("**************************************************"); System.setProperty("System.status", "Operational"); + EDEXUtil.notifyIsRunning(); shutdownLatch.await(); } diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/MessageProducer.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/MessageProducer.java index 3e590f25bf..b0a1e9f366 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/MessageProducer.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/MessageProducer.java @@ -19,51 +19,106 @@ **/ package com.raytheon.uf.edex.esb.camel; -import java.util.ArrayList; import java.util.HashMap; +import java.util.LinkedList; import java.util.List; import java.util.Map; +import java.util.concurrent.ConcurrentHashMap; +import java.util.concurrent.ConcurrentMap; +import javax.naming.ConfigurationException; + +import org.apache.camel.AsyncCallback; +import org.apache.camel.AsyncProcessor; import org.apache.camel.CamelContext; -import org.apache.camel.CamelExecutionException; +import org.apache.camel.Exchange; import org.apache.camel.ExchangePattern; +import org.apache.camel.Processor; import org.apache.camel.ProducerTemplate; import org.apache.camel.Route; -import org.springframework.beans.BeansException; -import org.springframework.context.ApplicationContext; -import org.springframework.context.ApplicationContextAware; +import org.apache.camel.model.ProcessorDefinition; +import org.apache.camel.spi.InterceptStrategy; import com.raytheon.uf.common.message.IMessage; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.util.Pair; import com.raytheon.uf.edex.core.EDEXUtil; import com.raytheon.uf.edex.core.EdexException; import com.raytheon.uf.edex.core.IMessageProducer; +import com.raytheon.uf.edex.esb.camel.context.ContextData; +import com.raytheon.uf.edex.esb.camel.context.ContextManager; /** - * Sends message to endpoints programmatically. + * Sends message to endpoints programmatically. Implements the camel + * {@link InterceptStrategy} to allow for tracking of camel dependencies where + * possible so that the ProducerTemplate is created from the correct context. * *
  * SOFTWARE HISTORY
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
- * Nov 14, 2008            njensen     Initial creation
+ * Nov 14, 2008            njensen     Initial creation.
+ * Mar 27, 2014 2726       rjpeter     Modified for graceful shutdown changes.
  * 
* * @author njensen * @version 1.0 */ -public class MessageProducer implements ApplicationContextAware, - IMessageProducer { +public class MessageProducer implements IMessageProducer, InterceptStrategy { + private final IUFStatusHandler statusHandler = UFStatus + .getHandler(MessageProducer.class); - private static ApplicationContext springContext; + /* + * setup via an interceptor used for tracking what context the current + * thread is participating in for dependency management of runtime + * IMessageProducer message sends. + */ + private final ThreadLocal currentThreadContext = new ThreadLocal(); - private static List camelContextList; + private final ConcurrentMap contextProducerMap = new ConcurrentHashMap(); - private static Map endpointIdUriMap = new HashMap(); + /** + * List of messages waiting to be sent. + */ + private final List waitingMessages = new LinkedList(); - private static Map endpointContextMap = new HashMap(); + /** + * Internal variable for tracking if messages should be queued or not. + */ + private volatile boolean started = false; - private static Map contextProducerMap = new HashMap(); + /** + * Constructor that launches an internal thread that will send all async + * messages that queue up while camel starts up. + */ + public MessageProducer() { + Thread t = new Thread() { + @Override + public void run() { + EDEXUtil.waitForRunning(); + started = true; + sendPendingAsyncMessages(); + } + }; + t.setName("MessageProducer-pendingMessageSender"); + t.start(); + } + + /** + * Returns the ContextData + * + * @return + * @throws EdexException + */ + protected ContextData getContextData() throws EdexException { + try { + return ContextManager.getInstance().getContextData(); + } catch (ConfigurationException e) { + throw new EdexException("Unable to look up camel context data", e); + } + } /* * (non-Javadoc) @@ -72,21 +127,42 @@ public class MessageProducer implements ApplicationContextAware, * com.raytheon.uf.edex.esb.camel.IMessageProducer#sendAsync(java.lang.String * , java.lang.Object) */ + @Override public void sendAsync(String endpoint, Object message) throws EdexException { - CamelContext camelContext = getCamelContext(endpoint); - ProducerTemplate template = getProducerTemplate(camelContext); - String uri = endpointIdUriMap.get(endpoint); - Map headers = getHeaders(message); + if (!started && queueWaitingMessage(WaitingType.ID, endpoint, message)) { + return; + } + + String uri = getContextData().getEndpointUriForRouteId(endpoint); + sendAsyncUri(uri, message); + } + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.edex.core.IMessageProducer#sendAsyncUri(java.lang.String, + * java.lang.Object) + */ + @Override + public void sendAsyncUri(String uri, Object message) throws EdexException { + if (!started && queueWaitingMessage(WaitingType.URI, uri, message)) { + return; + } + try { + ProducerTemplate template = getProducerTemplateForUri(uri); + Map headers = getHeaders(message); + if (headers != null) { template.sendBodyAndHeaders(uri, ExchangePattern.InOnly, message, headers); } else { template.sendBody(uri, ExchangePattern.InOnly, message); } - } catch (CamelExecutionException e) { + } catch (Exception e) { throw new EdexException("Error sending asynchronous message: " - + message + " to endpoint: " + uri, e); + + message + " to uri: " + uri, e); } } @@ -97,114 +173,112 @@ public class MessageProducer implements ApplicationContextAware, * com.raytheon.uf.edex.esb.camel.IMessageProducer#sendSync(java.lang.String * , java.lang.Object) */ + @Override public Object sendSync(String endpoint, Object message) throws EdexException { - CamelContext camelContext = getCamelContext(endpoint); - ProducerTemplate template = getProducerTemplate(camelContext); - String uri = endpointIdUriMap.get(endpoint); - Map headers = getHeaders(message); + if (!started) { + throw new EdexException("Cannot send synchronous message to " + + endpoint + " before EDEX has started"); + } + + String uri = getContextData().getEndpointUriForRouteId(endpoint); + try { + ProducerTemplate template = getProducerTemplateForUri(uri); + Map headers = getHeaders(message); + if (headers != null) { return template.sendBodyAndHeaders(uri, ExchangePattern.OutIn, message, headers); } else { return template.sendBody(uri, ExchangePattern.OutIn, message); } - } catch (CamelExecutionException e) { + } catch (Exception e) { throw new EdexException("Error sending synchronous message: " + message + " to uri: " + uri, e); } } - private synchronized CamelContext getCamelContext(String endpointId) - throws EdexException { - CamelContext ctx = endpointContextMap.get(endpointId); + /** + * Queues up an async message for sending to an endpoint. + * + * @param type + * @param endpoint + * @param message + * @return + */ + private boolean queueWaitingMessage(WaitingType type, String endpoint, + Object message) { + synchronized (waitingMessages) { + // make sure container hasn't started while waiting + if (!started) { + WaitingMessage wm = new WaitingMessage(); + wm.type = type; + wm.dest = endpoint; + wm.msg = message; + waitingMessages.add(wm); + return true; + } + + return false; + } + } + + /** + * Returns the a producer template for the CamelContext this thread is + * currently a part of. If thread is not part of a context, will use context + * of the uri. If the uri is not registered in this jvm, will use the first + * context available. + * + * @return + */ + protected ProducerTemplate getProducerTemplateForUri(String uri) + throws ConfigurationException, EdexException { + CamelContext ctx = currentThreadContext.get(); + if (ctx == null) { - List list = getCamelContextList(); - boolean found = false; - for (CamelContext c : list) { - List routes = c.getRoutes(); - for (Route r : routes) { - if (r.getProperties() != null - && endpointId.equals(r.getProperties().get( - Route.ID_PROPERTY))) { - ctx = c; - endpointContextMap.put(endpointId, ctx); - endpointIdUriMap.put(endpointId, r.getEndpoint() - .getEndpointUri()); - found = true; - break; - } - } - if (found) { - break; + ContextData contextData = getContextData(); + Pair typeAndName = ContextData + .getEndpointTypeAndName(uri); + if (typeAndName != null) { + Route route = contextData.getRouteForEndpointName(typeAndName + .getSecond()); + if (route != null) { + ctx = route.getRouteContext().getCamelContext(); } } + if (ctx == null) { - throw new EdexException("Route id " + endpointId - + " not found. Check loaded spring configurations."); + // this jvm does not consume from this route, use first context + List contexts = contextData.getContexts(); + if (contexts.size() > 0) { + // should always be a context defined + ctx = contexts.iterator().next(); + } } } - return ctx; - } + if (ctx != null) { + ProducerTemplate tmp = contextProducerMap.get(ctx); + if (tmp == null) { + tmp = ctx.createProducerTemplate(); + ProducerTemplate prev = contextProducerMap + .putIfAbsent(ctx, tmp); + if ((prev != null) && (prev != tmp)) { + try { + tmp.stop(); + } catch (Exception e) { - private ProducerTemplate getProducerTemplate(CamelContext ctx) { - ProducerTemplate tmp = contextProducerMap.get(ctx); - if (tmp == null) { - tmp = ctx.createProducerTemplate(); - contextProducerMap.put(ctx, tmp); - } - - return tmp; - } - - private synchronized List getCamelContextList() { - if (springContext == null) { - springContext = EDEXUtil.getSpringContext(); - } - - if (springContext == null) { - - throw new IllegalStateException( - "Spring context has not been initialized on " - + MessageProducer.class.getName()); - } - - if (camelContextList == null) { - camelContextList = new ArrayList(); - String[] camelContexts = springContext - .getBeanNamesForType(CamelContext.class); - for (String name : camelContexts) { - CamelContext c = (CamelContext) springContext.getBean(name); - camelContextList.add(c); + } + tmp = prev; + } } + return tmp; } - return camelContextList; - } - @Override - public void setApplicationContext(ApplicationContext context) - throws BeansException { - springContext = context; - } - - @Override - public void sendAsyncUri(String uri, Object message) throws EdexException { - CamelContext ctx = getCamelContextList().get(0); - ProducerTemplate template = getProducerTemplate(ctx); - Map headers = getHeaders(message); - try { - if (headers != null) { - template.sendBodyAndHeaders(uri, ExchangePattern.InOnly, - message, headers); - } else { - template.sendBody(uri, ExchangePattern.InOnly, message); - } - } catch (CamelExecutionException e) { - throw new EdexException("Error sending asynchronous message: " + message - + " to uri: " + uri, e); - } + throw new ConfigurationException( + "Could not find a CamelContext for routing to uri [" + uri + + "]. Check loaded spring configurations."); } private Map getHeaders(Object message) { @@ -224,4 +298,90 @@ public class MessageProducer implements ApplicationContextAware, return headers; } + /** + * Sends any messages that were queued up while Camel started. + */ + protected void sendPendingAsyncMessages() { + synchronized (waitingMessages) { + for (WaitingMessage wm : waitingMessages) { + try { + switch (wm.type) { + case ID: + sendAsync(wm.dest, wm.msg); + break; + case URI: + sendAsyncUri(wm.dest, wm.msg); + break; + } + } catch (Exception e) { + statusHandler + .error("Error occurred sending startup delayed async message", + e); + } + } + } + } + + /** + * Setup for use with MessageProducer to track what context the current + * operating thread is using. + */ + @Override + public Processor wrapProcessorInInterceptors(final CamelContext context, + final ProcessorDefinition definition, final Processor target, + final Processor nextTarget) throws Exception { + return new AsyncProcessor() { + @Override + public void process(Exchange exchange) throws Exception { + /* + * track the thread this context is using for proper dependency + * management. + */ + MessageProducer.this.currentThreadContext.set(context); + target.process(exchange); + } + + @Override + public boolean process(Exchange exchange, AsyncCallback callback) { + /* + * track the thread this context is using for proper dependency + * management. + */ + MessageProducer.this.currentThreadContext.set(context); + + try { + target.process(exchange); + } catch (Throwable e) { + exchange.setException(e); + } + callback.done(true); + return true; + } + + @Override + public String toString() { + return "MessageProducer - ContainerWideInterceptor[" + target + + "]"; + } + + }; + } + + /** + * Enum for handling whether the waiting type was uri or msg. + */ + private enum WaitingType { + ID, URI + }; + + /** + * Inner class for handling messages sent before edex is up. + */ + private class WaitingMessage { + private WaitingType type; + + private String dest; + + private Object msg; + } } diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/StringToFile.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/StringToFile.java index d20bf6f7e8..1aeaf3a1a4 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/StringToFile.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/StringToFile.java @@ -20,12 +20,13 @@ package com.raytheon.uf.edex.esb.camel; import java.io.File; -import java.io.FileNotFoundException; import org.apache.camel.Exchange; import org.apache.camel.Processor; -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; + +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.status.UFStatus.Priority; /** * Performs a transform from Strings to Files @@ -38,9 +39,9 @@ import org.apache.commons.logging.LogFactory; * SOFTWARE HISTORY * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Dec 1, 2008 chammack Initial creation - * 15Jul2010 6624 garmendariz Log error and interrupt if file missing - * + * Dec 1, 2008 chammack Initial creation. + * 15Jul2010 6624 garmendariz Log error and interrupt if file missing. + * Mar 19, 2014 2726 rjpeter Added debug logging of file being processed. * * * @author chammack @@ -49,7 +50,8 @@ import org.apache.commons.logging.LogFactory; public class StringToFile implements Processor { - protected transient Log logger = LogFactory.getLog(getClass()); + protected final IUFStatusHandler statusHandler = UFStatus + .getHandler(StringToFile.class); /* * (non-Javadoc) @@ -69,12 +71,15 @@ public class StringToFile implements Processor { // if file does not exist, set fault to interrupt processing if (!file.exists()) { - logger.error("File does not exist : " + bodyString); + statusHandler.error("File does not exist : " + bodyString); arg0.getOut().setFault(true); } else { arg0.getIn().setBody(file); arg0.getIn().setHeader("ingestFileName", file.toString()); arg0.getIn().setHeader("dequeueTime", System.currentTimeMillis()); + if (statusHandler.isPriorityEnabled(Priority.DEBUG)) { + statusHandler.debug("Processing file: " + file.toString()); + } } } } diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ClusteredContextManager.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ClusteredContextManager.java deleted file mode 100644 index 910a3d06a4..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ClusteredContextManager.java +++ /dev/null @@ -1,190 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ -package com.raytheon.uf.edex.esb.camel.context; - -import java.net.InetAddress; -import java.net.NetworkInterface; -import java.net.SocketException; -import java.util.ArrayList; -import java.util.Enumeration; -import java.util.List; - -import org.apache.camel.CamelContext; -import org.apache.camel.Route; -import org.apache.camel.ServiceStatus; - -import com.raytheon.uf.common.status.IUFStatusHandler; -import com.raytheon.uf.common.status.UFStatus; -import com.raytheon.uf.common.status.UFStatus.Priority; -import com.raytheon.uf.edex.database.cluster.ClusterLockUtils; -import com.raytheon.uf.edex.database.cluster.ClusterTask; - -/** - * Dynamically starts/stops a context and its associated routes so that only one - * context in the cluster is running. This should mainly be used for reading - * from topics so that only box is processing the topic data in the cluster for - * singleton type events. - * - *
- * SOFTWARE HISTORY
- * 
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Nov 10, 2010 5050       rjpeter     Initial creation
- * Jul 16, 2012 DR 15073   D. Friedman Stop consumers instead of whole context
- * May 14, 2013 1989       njensen     Camel 2.11 compatibility
- * Aug 26, 2013 DR 2272    bkowal      Append an optional suffix to the cluster task details
- * 
- * - * @author rjpeter - * @version 1.0 - */ -public class ClusteredContextManager { - private static final transient IUFStatusHandler statusHandler = UFStatus - .getHandler(ClusteredContextManager.class); - - private static final String taskName = "ClusteredContext"; - - private String myName; - - private List clusteredContextList = new ArrayList(); - - private int timeOutMillis; - - private static ClusteredContextManager instance = new ClusteredContextManager(); - - public static ClusteredContextManager getInstance() { - return instance; - } - - private ClusteredContextManager() { - myName = getHostName() + ":" + System.getProperty("edex.run.mode"); - } - - private static String getHostName() { - String hostname = System.getenv("HOSTNAME"); - if (hostname == null) { - hostname = System.getenv("COMPUTERNAME"); - } - if (hostname == null) { - hostname = System.getenv("HOST"); - } - if (hostname == null) { - try { - Enumeration nis = NetworkInterface - .getNetworkInterfaces(); - while (nis.hasMoreElements()) { - NetworkInterface ni = nis.nextElement(); - ni.isVirtual(); - ni.isUp(); - Enumeration addrs = ni.getInetAddresses(); - while (addrs.hasMoreElements()) { - InetAddress addr = addrs.nextElement(); - if (addr.isLinkLocalAddress() == false - && addr.isSiteLocalAddress() == false - && addr.isLoopbackAddress() == false) { - hostname = addr.getHostName(); - } - } - } - } catch (SocketException e) { - statusHandler.handle(Priority.ERROR, - "Failed to determine hostname", e); - } - } - return hostname; - } - - public void checkClusteredContexts() { - String suffix = ClusterLockUtils.CLUSTER_SUFFIX; - for (CamelContext camelContext : clusteredContextList) { - String contextName = camelContext.getName() + suffix; - ClusterTask lock = ClusterLockUtils.lock(taskName, contextName, - myName, timeOutMillis, false); - boolean activateRoute = false; - - switch (lock.getLockState()) { - case ALREADY_RUNNING: - // check if we already have lock - activateRoute = lock.getExtraInfo().equals(myName); - break; - case SUCCESSFUL: - activateRoute = true; - break; - default: - } - - try { - if (activateRoute) { - ClusterLockUtils.updateLockTime(taskName, contextName, - System.currentTimeMillis()); - - for (Route route : camelContext.getRoutes()) { - String routeId = route.getId(); - ServiceStatus status = camelContext - .getRouteStatus(routeId); - if (status == ServiceStatus.Stopped - || status == ServiceStatus.Stopping) { - camelContext.startRoute(routeId); - } else if (status == ServiceStatus.Suspended - || status == ServiceStatus.Suspending) { - camelContext.resumeRoute(routeId); - } - } - } else { - for (Route route : camelContext.getRoutes()) { - String routeId = route.getId(); - ServiceStatus status = camelContext - .getRouteStatus(routeId); - if (status == ServiceStatus.Started - || status == ServiceStatus.Starting) { - // CamelContext API says to use suspend, not stop - camelContext.suspendRoute(routeId); - } - } - } - } catch (Exception e) { - StringBuilder msg = new StringBuilder(); - msg.append("Failed to "); - if (activateRoute) { - msg.append("start "); - } else { - msg.append("suspend "); - } - msg.append("context "); - msg.append(camelContext.getName()); - statusHandler.handle(Priority.ERROR, msg.toString(), e); - } - } - } - - public ClusteredContextManager register(CamelContext context) { - clusteredContextList.add(context); - return this; - } - - public int getTimeOutMillis() { - return timeOutMillis; - } - - public void setTimeOutMillis(int timeOutMillis) { - this.timeOutMillis = timeOutMillis; - } -} diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ClusteredContextStateManager.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ClusteredContextStateManager.java new file mode 100644 index 0000000000..a673e5754c --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ClusteredContextStateManager.java @@ -0,0 +1,144 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.esb.camel.context; + +import java.util.concurrent.ExecutorService; + +import org.apache.camel.CamelContext; + +import com.raytheon.uf.common.util.SystemUtil; +import com.raytheon.uf.edex.database.cluster.ClusterLockUtils; +import com.raytheon.uf.edex.database.cluster.ClusterTask; + +/** + * Implementation of {@link IContextStateManager} that handles clustered + * contexts. Extends {@code DependencyContextStateManager} to allow for + * clustered contexts to work with dependencies also. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 10, 2014 2726       rjpeter     Initial creation
+ * 
+ * 
+ * + * @author rjpeter + * @version 1.0 + */ +public class ClusteredContextStateManager extends DependencyContextStateManager { + + /** + * Name field for cluster task. + */ + private static final String taskName = "ClusteredContext"; + + /** + * Field for extra-info to designate this host. + */ + private final String myName; + + /** + * Constructor that takes an {@code ExecutorService}. The + * {@code ExecutorService} is used for starting/stopping dependent contexts. + * + * @param service + */ + public ClusteredContextStateManager(ExecutorService service) { + super(service); + myName = SystemUtil.getHostName() + ":" + + System.getProperty("edex.run.mode"); + } + + /** + * Get the {@code ClusterLock} details field. + * + * @param context + * @return + */ + protected static String getLockDetails(CamelContext context) { + return context.getName() + ClusterLockUtils.CLUSTER_SUFFIX; + } + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.edex.esb.camel.context.DependencyContextStateManager# + * isContextStartable(org.apache.camel.CamelContext) + */ + @Override + public boolean isContextStartable(CamelContext context) throws Exception { + boolean canStartContext = super.isContextStartable(context); + + /* + * Check cluster lock if we can start the context or if context is + * already started in case we need to update the cluster lock. + */ + if (canStartContext || context.getStatus().isStarted()) { + ClusterTask lock = ClusterLockUtils.lock(taskName, + getLockDetails(context), myName, ContextManager + .getInstance().getTimeOutMillis(), false); + + switch (lock.getLockState()) { + case ALREADY_RUNNING: + // check if we already have lock + canStartContext = lock.getExtraInfo().equals(myName); + if (canStartContext) { + // update the lock time + ClusterLockUtils + .updateLockTime(taskName, getLockDetails(context), + System.currentTimeMillis()); + } + break; + case SUCCESSFUL: + canStartContext = true; + break; + + default: + canStartContext = false; + } + } + + return canStartContext; + } + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.edex.esb.camel.context.DependencyContextStateManager# + * stopContext(org.apache.camel.CamelContext) + */ + @Override + public boolean stopContext(CamelContext context) throws Exception { + // on stop, unlock the cluster lock if we own it + String contextName = context.getName() + + ClusterLockUtils.CLUSTER_SUFFIX; + ClusterTask lock = ClusterLockUtils.lookupLock(taskName, contextName); + if (lock.getExtraInfo().equals(myName) && lock.isRunning()) { + ClusterLockUtils.unlock(taskName, contextName); + } + + return super.stopContext(context); + } +} diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextData.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextData.java new file mode 100644 index 0000000000..bf6b01c8ac --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextData.java @@ -0,0 +1,222 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.esb.camel.context; + +import java.util.Collections; +import java.util.HashMap; +import java.util.LinkedList; +import java.util.List; +import java.util.Map; +import java.util.regex.Matcher; +import java.util.regex.Pattern; + +import javax.naming.ConfigurationException; + +import org.apache.camel.CamelContext; +import org.apache.camel.Route; + +import com.raytheon.uf.common.util.Pair; +import com.raytheon.uf.edex.core.EdexException; + +/** + * Contains all known contexts and parsed data about the contexts. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 10, 2014 2726       rjpeter     Initial creation
+ * 
+ * 
+ * + * @author rjpeter + * @version 1.0 + */ +public class ContextData { + private final List contexts; + + private final Map consumerRouteMapping; + + private final Map routeIdUriMapping; + + /** + * Pulls the direct-vm:name, vm:name, queue:name, topic:name section from + * the endpoint URI. + */ + private static final Pattern endpointUriParsePattern = Pattern + .compile("([^:]+)://([^?]+)"); + + /** + * Parses passed contexts for route and endpoint data about all contexts. + * + * @param contexts + * @throws ConfigurationException + */ + public ContextData(List contexts) + throws ConfigurationException { + this.contexts = Collections.unmodifiableList(contexts); + this.consumerRouteMapping = Collections + .unmodifiableMap(generateRouteMappings(this.contexts)); + Map idUriMapping = new HashMap( + consumerRouteMapping.size(), 1); + for (Route route : consumerRouteMapping.values()) { + idUriMapping.put(route.getId(), route.getEndpoint() + .getEndpointUri()); + } + + this.routeIdUriMapping = Collections.unmodifiableMap(idUriMapping); + } + + /** + * Populates an endpointName to {@code Route} mapping for the passed + * {@code CamelContext}s. + * + * @return + * @throws ConfigurationException + */ + protected static Map generateRouteMappings( + List contexts) throws ConfigurationException { + Map routeMapping = new HashMap( + contexts.size() * 2, 1); + + // populate the consumer definitions + for (CamelContext context : contexts) { + List routes = context.getRoutes(); + if ((routes != null) && (routes.size() > 0)) { + for (Route route : routes) { + String uri = route.getEndpoint().getEndpointUri(); + Pair typeAndName = getEndpointTypeAndName(uri); + if (typeAndName != null) { + String endpointName = typeAndName.getSecond(); + + Route prev = routeMapping.put(endpointName, route); + if (prev != null) { + throw new ConfigurationException( + "Two contexts listen to the same endpoint name [" + + endpointName + + "]. ContextManager cannot handle this situation. Double check configuration. Conflicting contexts [" + + prev.getRouteContext() + .getCamelContext() + .getName() + "] and [" + + context.getName() + "]"); + } + } + } + } + } + return routeMapping; + } + + /** + * Returns the known contexts. + * + * @return + */ + public List getContexts() { + return contexts; + } + + /** + * Parses URI for component type and endpoint name. + * + * @param uri + * @return + */ + public static Pair getEndpointTypeAndName(String uri) { + Pair rval = null; + Matcher m = endpointUriParsePattern.matcher(uri); + + if (m.find()) { + String endpointType = m.group(1); + String endpointName = m.group(2); + rval = new Pair(endpointType, endpointName); + } + + return rval; + } + + /** + * Scans the camel context and associated routes. Groups the routes by + * consumer type. + * + * @return + */ + public Map> getContextRoutesByEndpointType() + throws ConfigurationException { + Map> routesByType = new HashMap>(); + for (CamelContext context : contexts) { + List routes = context.getRoutes(); + if ((routes != null) && (routes.size() > 0)) { + for (Route route : routes) { + String uri = route.getEndpoint().getEndpointUri(); + Pair typeAndName = getEndpointTypeAndName(uri); + String type = typeAndName.getFirst(); + List routesForType = routesByType.get(type); + if (routesForType == null) { + routesForType = new LinkedList(); + routesByType.put(type, routesForType); + } + routesForType.add(route); + } + } + } + + return routesByType; + } + + /** + * Returns the uri for the consumer endpoint of the route with the specified + * routeId. + * + * @param routeId + * @return + * @throws EdexException + */ + public String getEndpointUriForRouteId(String routeId) throws EdexException { + String uri = routeIdUriMapping.get(routeId); + if (uri == null) { + throw new EdexException("Route id " + routeId + + " not found. Check loaded spring configurations."); + } + + return uri; + } + + /** + * Returns the route for the endpoint with the passed name as returned from + * getEndpointTypeAndName(). + * + * @param endpointName + * @return + * @throws EdexException + */ + public Route getRouteForEndpointName(String endpointName) + throws EdexException { + Route route = consumerRouteMapping.get(endpointName); + if (route == null) { + throw new EdexException("Endpoint " + endpointName + + " not found. Check loaded spring configurations."); + } + + return route; + } +} diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextDependencyMapping.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextDependencyMapping.java new file mode 100644 index 0000000000..b556459528 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextDependencyMapping.java @@ -0,0 +1,268 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.esb.camel.context; + +import java.util.Collection; +import java.util.Collections; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Iterator; +import java.util.LinkedHashMap; +import java.util.LinkedList; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import javax.naming.ConfigurationException; + +import org.apache.camel.CamelContext; +import org.apache.camel.Endpoint; +import org.apache.camel.Route; + +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.util.Pair; + +/** + * Contains context dependency mappings. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Mar 26, 2014 2726       rjpeter     Initial creation
+ * 
+ * 
+ * + * @author rjpeter + * @version 1.0 + */ +public class ContextDependencyMapping { + /** + * Endpoint types that should be tracked for dependency mapping + */ + protected static final Set DEPENDENCY_ENDPOINT_TYPES; + + static { + /* + * Endpoint types that are used for inner context routing. If we add + * other inner jvm routing types, they should be added here. + */ + Set types = new HashSet(8); + types.add("vm"); + types.add("direct-vm"); + types.add("seda"); + types.add("jmx"); + types.add("guava-eventbus"); + DEPENDENCY_ENDPOINT_TYPES = Collections.unmodifiableSet(types); + } + + /** + * The dependency mappings. + */ + protected final Map dependencyMapping; + + /** + * Populates the dependency mappings for all camel contexts. + * {@code suppressExceptions} can be used to differentiate between + * startup/shutdown conditions to allow the map to be populated regardless + * of detected issues. + * + * @param contextData + * @param suppressExceptions + * @throws ConfigurationException + */ + public ContextDependencyMapping(ContextData contextData, + boolean suppressExceptions) throws ConfigurationException { + dependencyMapping = Collections + .unmodifiableMap(populateDependencyMapping(contextData, + suppressExceptions)); + } + + /** + * Returns a {@code IUFStatusHandler}. Not cached as rarely used. + * + * @return + */ + private static IUFStatusHandler getHandler() { + return UFStatus.getHandler(ContextDependencyMapping.class); + } + + /** + * Dependency mappings per context. The dependency mapping is only for + * internal vm types that have a direct dependency. Indirect dependency via + * a JMS queue for example is not returned/enforced. + * + * @param contextData + * @param suppressExceptions + * Done in a shutdown scenario to get the dependencyMapping as + * close as possible. + */ + protected static Map populateDependencyMapping( + ContextData contextData, boolean suppressExceptions) + throws ConfigurationException { + List contexts = contextData.getContexts(); + Map dependencyMapping = new LinkedHashMap( + contexts.size()); + + // set up dependency nodes for internal types + Map consumesFrom = new HashMap(); + Map> producesTo = new HashMap>(); + Set consumers = new HashSet(); + + // scan for consuming and producing internal endpoints + for (CamelContext context : contexts) { + dependencyMapping.put(context, new DependencyNode(context)); + consumers.clear(); + List routes = context.getRoutes(); + if ((routes != null) && (routes.size() > 0)) { + for (Route route : routes) { + String uri = route.getEndpoint().getEndpointUri(); + Pair typeAndName = ContextData + .getEndpointTypeAndName(uri); + if ((typeAndName != null) + && DEPENDENCY_ENDPOINT_TYPES.contains(typeAndName + .getFirst())) { + String endpointName = typeAndName.getSecond(); + consumers.add(endpointName); + + /* + * Internal types don't support a fanout type policy + * where multiple routes can listen to the same + * endpoint. + */ + CamelContext prev = consumesFrom.put(endpointName, + context); + if (prev != null) { + String msg = "Two contexts listen to the same internal endpoint [" + + endpointName + + "]. ContextManager cannot handle this situation. Double check configuration. Conflicting contexts [" + + prev.getName() + + "] and [" + + context.getName() + "]"; + if (suppressExceptions) { + getHandler().error(msg); + } else { + throw new ConfigurationException(msg); + } + } + } + } + } + + Collection endpoints = context.getEndpoints(); + if ((endpoints != null) && (endpoints.size() > 0)) { + for (Endpoint ep : endpoints) { + String uri = ep.getEndpointUri(); + Pair typeAndName = ContextData + .getEndpointTypeAndName(uri); + if ((typeAndName != null) + && DEPENDENCY_ENDPOINT_TYPES.contains(typeAndName + .getFirst())) { + String endpointName = typeAndName.getSecond(); + if (!consumers.contains(endpointName)) { + List producerCtxs = producesTo + .get(endpointName); + if (producerCtxs == null) { + producerCtxs = new LinkedList(); + producesTo.put(endpointName, producerCtxs); + } + producerCtxs.add(context); + } + } + } + } + } + + // setup dependencies for internal routes + for (Map.Entry> producersEntry : producesTo + .entrySet()) { + String endpoint = producersEntry.getKey(); + CamelContext consumer = consumesFrom.get(endpoint); + List producers = producersEntry.getValue(); + + if (consumer == null) { + StringBuilder msg = new StringBuilder(200); + msg.append("Internal Routing Endpoint [") + .append(endpoint) + .append("] has no defined consumers. This is endpoint is used in contexts ["); + Iterator producerIter = producers.iterator(); + + while (producerIter.hasNext()) { + CamelContext producer = producerIter.next(); + msg.append(producer.getName()); + + if (producerIter.hasNext()) { + msg.append(", "); + } + } + + msg.append("]"); + if (suppressExceptions) { + getHandler().error(msg.toString()); + } else { + throw new ConfigurationException(msg.toString()); + } + } else { + DependencyNode consumerNode = dependencyMapping.get(consumer); + for (CamelContext producer : producers) { + DependencyNode producerNode = dependencyMapping + .get(producer); + consumerNode.addDependentNode(producerNode); + } + } + } + return dependencyMapping; + } + + /** + * Get the contexts that depend upon the passed context to work. If the + * passed context is unknown null will be returned. + * + * @param context + * @return + */ + public Set getDependentContexts(CamelContext context) { + DependencyNode dNode = dependencyMapping.get(context); + if (dNode == null) { + return null; + } + + return dNode.getDependentContexts(); + } + + /** + * Get the contexts that the passed context requires to be running to work. + * If the passed context is unknown null will be returned. + * + * @param context + * @return + */ + public Set getRequiredContexts(CamelContext context) { + DependencyNode dNode = dependencyMapping.get(context); + if (dNode == null) { + return null; + } + + return dNode.getRequiredContexts(); + } +} diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java index 4a8e4dd72b..325d76314e 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java @@ -1,96 +1,587 @@ /** * This software was developed and / or modified by Raytheon Company, * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * + * * U.S. EXPORT CONTROLLED TECHNICAL DATA * This software product contains export-restricted data whose * export/transfer/disclosure is restricted by U.S. law. Dissemination * to non-U.S. persons whether in the United States or abroad requires * an export license or other authorization. - * + * * Contractor Name: Raytheon Company * Contractor Address: 6825 Pine Street, Suite 340 * Mail Stop B8 * Omaha, NE 68106 * 402.291.0100 - * + * * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ package com.raytheon.uf.edex.esb.camel.context; import java.util.ArrayList; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Iterator; +import java.util.LinkedList; import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.concurrent.Callable; +import java.util.concurrent.ExecutorService; +import java.util.concurrent.Executors; +import java.util.concurrent.Future; +import java.util.concurrent.atomic.AtomicBoolean; + +import javax.naming.ConfigurationException; import org.apache.camel.CamelContext; +import org.apache.camel.Route; +import org.apache.camel.impl.DefaultCamelContext; +import org.springframework.beans.BeansException; +import org.springframework.beans.factory.config.BeanFactoryPostProcessor; +import org.springframework.beans.factory.config.ConfigurableListableBeanFactory; +import org.springframework.context.ApplicationContext; +import org.springframework.context.ApplicationContextAware; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; +import com.raytheon.uf.common.time.util.TimeUtil; +import com.raytheon.uf.common.util.Pair; +import com.raytheon.uf.edex.core.IContextStateProcessor; /** - * Dynamically starts/stops a context and its associated routes so that only one - * context in the cluster is running. This should mainly be used for reading - * from topics so that only box is processing the topic data in the cluster for - * singleton type events. + * Tracks all contexts and is used to auto determine context dependencies and + * start/stop them in the right order. Dynamically starts/stops a clustered + * context and its associated routes so that only one context in the cluster is + * running. This should mainly be used for reading from topics so that only box + * is processing the topic data in the cluster for singleton type events. * *
  * SOFTWARE HISTORY
  * 
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
- * Nov 10, 2010 5050       rjpeter     Initial creation
- * May 13, 2013 1989       njensen     Camel 2.11 compatibility
+ * Nov 10, 2010 5050       rjpeter     Initial creation.
+ * May 13, 2013 1989       njensen     Camel 2.11 compatibility.
+ * Mar 11, 2014 2726       rjpeter     Implemented graceful shutdown.
  * 
* * @author rjpeter * @version 1.0 */ -public class ContextManager { +public class ContextManager implements ApplicationContextAware, + BeanFactoryPostProcessor { private static final transient IUFStatusHandler statusHandler = UFStatus .getHandler(ContextManager.class); - private List contextList = new ArrayList(); - private static ContextManager instance = new ContextManager(); + /** + * Service used for start up and shut down threading. + */ + private final ExecutorService service = Executors.newCachedThreadPool(); + + private final Set clusteredContexts = new HashSet(); + + /** + * State Manager for all contexts that are not clustered. + */ + private final IContextStateManager defaultStateManager = new DependencyContextStateManager( + service); + + /** + * State Manager used for all clustered contexts. + */ + private final IContextStateManager clusteredStateManager = new ClusteredContextStateManager( + service); + + /** + * Spring context. Set by the spring container after bean construction. + */ + private ApplicationContext springCtx = null; + + /** + * Endpoint types that are internal only. Mainly used at shutdown time to + * designate routes that shouldn't be shutdown immediately. + */ + private final Set internalEndpointTypes = new HashSet(); + + /** + * Map of context processors that have been registered for a given context. + * Used to allow contexts to do custom worn on startup/shutdown. + */ + private final Map contextProcessors = new HashMap(); + + /** + * Cluster lock timeout for clustered contexts. + */ + private int timeOutMillis; + + /** + * Parsed context data for all contexts known in the spring container. + */ + private volatile ContextData contextData; + + /** + * Flag to control shutting down the jvm. This handles shutdown being called + * during startup to short circuit startup. + */ + private final AtomicBoolean shuttingDown = new AtomicBoolean(false); + + /** + * Dependency mappings for all camel contexts in the spring container. This + * should only be changed in a sync block. Otherwise mark as volatile. + */ + private ContextDependencyMapping dependencyMapping = null; + + /** + * Last time dependency mapping was generated. Used to periodically + * regenerate the dependency mappings. + */ + private final long lastDependencyTime = 0; + public static ContextManager getInstance() { return instance; } + /** + * Private constructor. Sets up internal types for prioritized stopping of + * routes on shutdown. + */ private ContextManager() { + internalEndpointTypes + .addAll(ContextDependencyMapping.DEPENDENCY_ENDPOINT_TYPES); + internalEndpointTypes.add("timer"); + internalEndpointTypes.add("quartz"); + internalEndpointTypes.add("clusteredquartz"); } + /** + * Gets the context data. + * + * @return + * @throws ConfigurationException + */ + public ContextData getContextData() throws ConfigurationException { + if (contextData == null) { + synchronized (this) { + if (contextData == null) { + contextData = new ContextData(new ArrayList( + springCtx.getBeansOfType(CamelContext.class) + .values())); + } + } + } + + return contextData; + } + + /** + * Get the {@link IContextStateManager} for the passed {@code CamelContext}. + * + * @param context + * @return + */ + protected IContextStateManager getStateManager(CamelContext context) { + if (clusteredContexts.contains(context)) { + return clusteredStateManager; + } + + return defaultStateManager; + } + + /** + * Get the {@link IContextStateProcessor} for the passed + * {@code CamelContext}. + * + * @param context + * @return + */ + public IContextStateProcessor getStateProcessor(CamelContext context) { + return contextProcessors.get(context); + } + + /** + * Get the {@link ContextDependencyMapping} for all contexts. + * + * @param suppressExceptions + * @return + * @throws ConfigurationException + */ + public ContextDependencyMapping getDependencyMapping( + boolean suppressExceptions) throws ConfigurationException { + /* + * This is not permanently cashed and regenerated periodically since + * routing via code can change at runtime. + */ + synchronized (this) { + long millis = System.currentTimeMillis(); + if ((dependencyMapping == null) + || (millis > (lastDependencyTime + TimeUtil.MILLIS_PER_MINUTE))) { + dependencyMapping = new ContextDependencyMapping( + getContextData(), suppressExceptions); + } + } + + return dependencyMapping; + + } + + /** + * Starts all routes for all contexts. If a route fails to start the entire + * jvm will be shutdown. + */ public void startContexts() { - statusHandler.info("Context Manager starting routes"); - for (CamelContext camelContext : contextList) { + statusHandler.info("Context Manager starting contexts"); + + try { + ContextData cxtData = getContextData(); + List>> callbacks = new LinkedList>>(); + + for (final CamelContext context : cxtData.getContexts()) { + final IContextStateManager stateManager = getStateManager(context); + if (stateManager.isContextStartable(context)) { + /* + * Have the ExecutorService start the context to allow for + * quicker startup. + */ + callbacks + .add(service + .submit(new Callable>() { + @Override + public Pair call() + throws Exception { + boolean rval = false; + try { + rval = stateManager + .startContext(context); + + if (!rval) { + statusHandler.error("Context [" + + context.getName() + + "] failed to start, shutting down"); + System.exit(1); + } + } catch (Throwable e) { + statusHandler.fatal( + "Error occurred starting context: " + + context + .getName(), + e); + System.exit(1); + } + + return new Pair( + context, rval); + } + })); + } + } + + /* + * Double check call backs that everything started successfully. If + * some did not start successfully, force shutdown. + */ + for (Future> callback : callbacks) { + Pair val = callback.get(); + if (!val.getSecond().booleanValue()) { + statusHandler.error("Context [" + val.getFirst().getName() + + "] failed to start, shutting down"); + System.exit(1); + } + } + + } catch (Throwable e) { + statusHandler.fatal( + "Error occurred starting contexts, shutting down", e); + System.exit(1); + } + } + + /** + * Register a clustered context that is meant to run as a singleton in the + * cluster. + * + * @param context + * @return + */ + public ContextManager registerClusteredContext(final CamelContext context) { + clusteredContexts.add(context); + return this; + } + + /** + * Register a context state processor to be called on start/stop of the + * context. + * + * @param context + * @param processor + * @return + */ + public ContextManager registerContextStateProcessor( + final CamelContext context, final IContextStateProcessor processor) { + contextProcessors.put(context, processor); + return this; + } + + /** + * Stops all contexts. Note this method can only be called once for the life + * of the jvm and will gracefully shut down all of camel. + */ + public void stopContexts() { + /* + * flag to ensure no one else runs shutdown also stops + * checkClusteredContext from starting contexts once shutdown has been + * initiated + */ + if (shuttingDown.compareAndSet(false, true)) { + if (springCtx == null) { + statusHandler + .info("Spring Context not set. Start up never completed, cannot orderly shutdown"); + } + + statusHandler.info("Context Manager stopping routes"); + try { /* - * In camel 2.11, all contexts are "started" automatically but - * the isAutoStartup() flag determines if the routes are - * automatically started. The code in DefaultCamelContext is - * safe to call start() on a second time to get the routes - * started. - * - * For more information, see: - * http://camel.465427.n5.nabble.com/Camel - * -context-autostartup-td5721638.html - * - * https://issues.apache.org/jira/browse/CAMEL-5759 + * begin immediate shutdown of routes that are not an internal + * type */ - if (!camelContext.isAutoStartup()) { - camelContext.start(); + LinkedList routesToStop = new LinkedList(); + ContextData ctxData = getContextData(); + List contexts = ctxData.getContexts(); + List>> callbacks = new LinkedList>>(); + + for (final CamelContext context : contexts) { + /* + * group routes by context due to sync lock at context level + * for stopping a route + */ + List routes = context.getRoutes(); + if ((routes != null) && (routes.size() > 0)) { + for (Route route : routes) { + String uri = route.getEndpoint().getEndpointUri(); + Pair typeAndName = ContextData + .getEndpointTypeAndName(uri); + String type = typeAndName.getFirst(); + if (!internalEndpointTypes.contains(type)) { + routesToStop.add(route); + } + } + } + if (routesToStop.size() > 0) { + final IContextStateManager stateMgr = getStateManager(context); + final List tmp = routesToStop; + callbacks + .add(service + .submit(new Callable>() { + @Override + public Pair call() + throws Exception { + boolean rval = true; + for (Route route : tmp) { + try { + statusHandler.info("Stopping route [" + + route.getId() + + "]"); + rval &= stateMgr + .stopRoute(route); + } catch (Exception e) { + statusHandler.error( + "Error occurred closing route: " + + route.getId(), + e); + } + } + + return new Pair( + context, rval); + } + })); + routesToStop = new LinkedList(); + } } - } catch (Exception e) { - statusHandler.handle(Priority.ERROR, - "Failed to start routes for " + camelContext.getName(), - e); + + List failures = waitForCallbacks(callbacks, + "Waiting for external routes to shutdown: ", 1000); + + for (CamelContext failure : failures) { + statusHandler.error("Context [" + failure.getName() + + "] has routes that failed to stop"); + } + + statusHandler.info("Shutting down contexts"); + + for (final CamelContext context : contexts) { + final IContextStateManager stateManager = getStateManager(context); + if (stateManager.isContextStoppable(context)) { + callbacks + .add(service + .submit(new Callable>() { + @Override + public Pair call() + throws Exception { + boolean rval = false; + try { + statusHandler.info("Stopping context [" + + context.getName() + + "]"); + rval = stateManager + .stopContext(context); + + if (!rval) { + statusHandler.error("Context [" + + context + .getName() + + "] failed to stop"); + } + } catch (Throwable e) { + statusHandler.fatal( + "Error occurred stopping context: " + + context + .getName(), + e); + } + + return new Pair( + context, rval); + } + })); + } + } + + failures = waitForCallbacks(callbacks, + "Waiting for contexts to shutdown: ", 1000); + + for (CamelContext failure : failures) { + statusHandler.error("Context [" + failure.getName() + + "] had a failure trying to stop"); + } + } catch (Throwable e) { + statusHandler.fatal("Error occurred during shutdown", e); } } } - public ContextManager register(CamelContext context) { - contextList.add(context); - return this; + /** + * Waits for all callbacks to finish printing a periodic message with number + * of remaining callbacks. Returns a list of contexts that had a failure + * status. + * + * @param callbacks + * @param message + * @param sleepInterval + * @return + */ + private static List waitForCallbacks( + List>> callbacks, + String message, long sleepInterval) { + statusHandler.info(message + callbacks.size() + " remaining"); + List failures = new LinkedList(); + + while (!callbacks.isEmpty()) { + boolean foundOne = false; + + Iterator>> callbackIter = callbacks + .iterator(); + while (callbackIter.hasNext()) { + Future> callback = callbackIter + .next(); + if (callback.isDone()) { + foundOne = true; + callbackIter.remove(); + try { + Pair val = callback.get(); + if (!val.getSecond().booleanValue()) { + failures.add(val.getFirst()); + } + } catch (Exception e) { + statusHandler.error("Failure in callback task", e); + } + } + } + + if (!foundOne) { + statusHandler.info(message + callbacks.size() + " remaining"); + try { + Thread.sleep(sleepInterval); + } catch (Exception e) { + // ignore + } + } + } + + return failures; + } + + /** + * Checks the clustered contexts. If context is not running in the cluster + * the context will be started. + */ + public void checkClusteredContexts() { + if (!shuttingDown.get()) { + for (CamelContext camelContext : clusteredContexts) { + boolean activateRoute = true; + try { + IContextStateManager stateManager = getStateManager(camelContext); + + if (stateManager.isContextStartable(camelContext)) { + stateManager.startContext(camelContext); + } else if (stateManager.isContextStoppable(camelContext)) { + activateRoute = false; + stateManager.stopContext(camelContext); + } + } catch (Exception e) { + StringBuilder msg = new StringBuilder(); + msg.append("Failed to "); + if (activateRoute) { + msg.append("start "); + } else { + msg.append("stop "); + } + msg.append("context "); + msg.append(camelContext.getName()); + statusHandler.handle(Priority.ERROR, msg.toString(), e); + } + } + } + } + + @Override + public void setApplicationContext(ApplicationContext context) + throws BeansException { + springCtx = context; + } + + public int getTimeOutMillis() { + return timeOutMillis; + } + + public void setTimeOutMillis(int timeOutMillis) { + this.timeOutMillis = timeOutMillis; + } + + public boolean isShuttingDown() { + return shuttingDown.get(); + } + + /** + * Update all camel beans to have autoStartup to false and handles quart + * workaround when JMX is disabled. + */ + @Override + public void postProcessBeanFactory( + ConfigurableListableBeanFactory beanFactory) throws BeansException { + for (CamelContext ctx : beanFactory.getBeansOfType(CamelContext.class) + .values()) { + ctx.setAutoStartup(false); + + if ((ctx instanceof DefaultCamelContext) + && (ctx.getManagementName() == null)) { + ((DefaultCamelContext) ctx).setManagementName(ctx.getName()); + } + } } } diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/DefaultContextStateManager.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/DefaultContextStateManager.java new file mode 100644 index 0000000000..e17a9e0701 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/DefaultContextStateManager.java @@ -0,0 +1,215 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.esb.camel.context; + +import java.util.EnumSet; +import java.util.Set; + +import org.apache.camel.CamelContext; +import org.apache.camel.Route; +import org.apache.camel.ServiceStatus; + +import com.raytheon.uf.edex.core.IContextStateProcessor; + +/** + * Implementation of IContextStateManager that does basic validation of context + * status as well as handling IContextStateProcessor for startup/shutdown of + * contexts. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 10, 2014 2726       rjpeter     Initial creation
+ * 
+ * 
+ * + * @author rjpeter + * @version 1.0 + */ +public class DefaultContextStateManager implements IContextStateManager { + private static final Set STARTABLE_STATES = EnumSet.of( + ServiceStatus.Stopped, ServiceStatus.Suspended, + ServiceStatus.Suspending); + + private static final Set SUSPENDABLE_STATES = EnumSet.of( + ServiceStatus.Starting, ServiceStatus.Started); + + private static final Set STOPPABLE_STATES = EnumSet.of( + ServiceStatus.Starting, ServiceStatus.Started, + ServiceStatus.Suspending, ServiceStatus.Suspended); + + /* + * (non-Javadoc) + * + * @see com.raytheon.uf.edex.esb.camel.context.IContextStateManager# + * isContextStartable(org.apache.camel.CamelContext) + */ + @Override + public boolean isContextStartable(CamelContext context) throws Exception { + ServiceStatus status = context.getStatus(); + return STARTABLE_STATES.contains(status) + || (status.isStarted() && !context.isAutoStartup()); + } + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.edex.esb.camel.context.IContextStateManager#startContext + * (org.apache.camel.CamelContext) + */ + @Override + public boolean startContext(CamelContext context) throws Exception { + ServiceStatus status = context.getStatus(); + + boolean rval = status.isStarted(); + if (rval && !context.isAutoStartup()) { + for (Route route : context.getRoutes()) { + rval &= context.getRouteStatus(route.getId()).isStarted(); + } + } + + if (!rval) { + IContextStateProcessor processor = ContextManager.getInstance() + .getStateProcessor(context); + if (processor != null) { + processor.preStart(); + } + + context.start(); + rval = context.getStatus().isStarted(); + + /* + * if a context has autoStartup = false, all of its routes are + * started on the second time context.start is called, adding route + * check for future proofing just in case. + */ + if (!context.isAutoStartup()) { + for (Route route : context.getRoutes()) { + rval &= startRoute(route); + } + + /* + * clear the auto start up flag since its an initial condition + * only + */ + context.setAutoStartup(true); + } + + if (processor != null) { + processor.postStart(); + } + } + + return rval; + } + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.edex.esb.camel.context.IContextStateManager#startRoute + * (org.apache.camel.Route) + */ + @Override + public boolean startRoute(Route route) throws Exception { + String routeId = route.getId(); + CamelContext ctx = route.getRouteContext().getCamelContext(); + ServiceStatus status = ctx.getRouteStatus(routeId); + if (STARTABLE_STATES.contains(status)) { + ctx.startRoute(routeId); + status = ctx.getRouteStatus(routeId); + } + + return status.isStarted(); + } + + /* + * (non-Javadoc) + * + * @see com.raytheon.uf.edex.esb.camel.context.IContextStateManager# + * isContextStoppable (org.apache.camel.CamelContext) + */ + @Override + public boolean isContextStoppable(CamelContext context) throws Exception { + ServiceStatus status = context.getStatus(); + boolean shuttingDown = ContextManager.getInstance().isShuttingDown(); + return (shuttingDown && STOPPABLE_STATES.contains(status)) + || (!shuttingDown && SUSPENDABLE_STATES.contains(status)); + } + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.edex.esb.camel.context.IContextStateManager#stopContext + * (org.apache.camel.CamelContext) + */ + @Override + public boolean stopContext(CamelContext context) throws Exception { + ServiceStatus status = context.getStatus(); + if (isContextStoppable(context)) { + IContextStateProcessor processor = ContextManager.getInstance() + .getStateProcessor(context); + if (processor != null) { + processor.preStop(); + } + + // a context will automatically stop all its routes + if (ContextManager.getInstance().isShuttingDown()) { + context.stop(); + } else { + context.suspend(); + } + + if (processor != null) { + processor.postStop(); + } + + status = context.getStatus(); + } + + return status.isStopped(); + } + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.edex.esb.camel.context.IContextStateManager#stopRoute + * (org.apache.camel.Route) + */ + @Override + public boolean stopRoute(Route route) throws Exception { + String routeId = route.getId(); + CamelContext ctx = route.getRouteContext().getCamelContext(); + ServiceStatus status = ctx.getRouteStatus(routeId); + if (STOPPABLE_STATES.contains(status)) { + ctx.stopRoute(routeId); + status = ctx.getRouteStatus(routeId); + } + + return status.isStopped(); + } + +} diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/DependencyContextStateManager.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/DependencyContextStateManager.java new file mode 100644 index 0000000000..3fb03ddb69 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/DependencyContextStateManager.java @@ -0,0 +1,229 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.esb.camel.context; + +import java.util.LinkedList; +import java.util.List; +import java.util.Set; +import java.util.concurrent.Callable; +import java.util.concurrent.ExecutorService; +import java.util.concurrent.Future; + +import org.apache.camel.CamelContext; +import org.apache.camel.Route; + +/** + * Implementation of IContextStateManager that handles dependencies between + * contexts so that contexts start/stop in the correct order. Can be given an + * ExecutorService to use to start/stop dependent contexts. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 10, 2014 2726       rjpeter     Initial creation
+ * 
+ * 
+ * + * @author rjpeter + * @version 1.0 + */ +public class DependencyContextStateManager extends DefaultContextStateManager { + + /** + * Service to use to start/stop dependent contexts. If null, context + * processing will happen on current thread. + */ + protected final ExecutorService service; + + public DependencyContextStateManager() { + this(null); + } + + public DependencyContextStateManager(ExecutorService service) { + this.service = service; + } + + /* + * (non-Javadoc) + * + * @see com.raytheon.uf.edex.esb.camel.context.DefaultContextStateManager# + * isContextStartable(org.apache.camel.CamelContext) + */ + @Override + public boolean isContextStartable(CamelContext context) throws Exception { + if (!super.isContextStartable(context)) { + return false; + } + + Set requiredContexts = ContextManager.getInstance() + .getDependencyMapping(false).getRequiredContexts(context); + + if (requiredContexts != null) { + for (CamelContext rContext : requiredContexts) { + if (!rContext.getStatus().isStarted()) { + return false; + } else { + for (Route rRoute : rContext.getRoutes()) { + if (!rContext.getRouteStatus(rRoute.getId()) + .isStarted()) { + return false; + } + } + } + } + } + + return true; + } + + /* + * (non-Javadoc) + * + * @see com.raytheon.uf.edex.esb.camel.context.DefaultContextStateManager# + * startContext(org.apache.camel.CamelContext) + */ + @Override + public boolean startContext(CamelContext context) throws Exception { + boolean rval = super.startContext(context); + ContextManager ctxMgr = ContextManager.getInstance(); + + if (rval) { + Set dContexts = ctxMgr.getDependencyMapping(false) + .getDependentContexts(context); + if (dContexts != null) { + List> callbacks = null; + + for (final CamelContext dCtx : dContexts) { + final IContextStateManager stateMgr = ctxMgr + .getStateManager(dCtx); + if (stateMgr.isContextStartable(dCtx)) { + if (service != null) { + if (callbacks == null) { + callbacks = new LinkedList>(); + } + + callbacks.add(service + .submit(new Callable() { + @Override + public Boolean call() throws Exception { + return stateMgr.startContext(dCtx); + } + })); + } else { + stateMgr.startContext(dCtx); + } + } + } + + if (callbacks != null) { + for (Future callback : callbacks) { + rval &= callback.get().booleanValue(); + } + } + } + } + + return rval; + } + + /* + * (non-Javadoc) + * + * @see com.raytheon.uf.edex.esb.camel.context.DefaultContextStateManager# + * isContextStoppable(org.apache.camel.CamelContext) + */ + @Override + public boolean isContextStoppable(CamelContext context) throws Exception { + if (!super.isContextStoppable(context)) { + return false; + } + + Set dContexts = ContextManager.getInstance() + .getDependencyMapping(true).getDependentContexts(context); + + if (dContexts != null) { + for (CamelContext dContext : dContexts) { + /* + * only need to check if the context has stopped, can't have a + * stopped context with started routes. + */ + if (!dContext.getStatus().isStopped()) { + return false; + } + } + } + + return true; + } + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.edex.esb.camel.context.DefaultContextStateManager#stopContext + * (org.apache.camel.CamelContext) + */ + @Override + public boolean stopContext(CamelContext context) throws Exception { + boolean rval = super.stopContext(context); + ContextManager ctxMgr = ContextManager.getInstance(); + + if (rval) { + Set rContexts = ctxMgr.getDependencyMapping(true) + .getRequiredContexts(context); + if (rContexts != null) { + List> callbacks = null; + + for (final CamelContext rCtx : rContexts) { + final IContextStateManager stateMgr = ctxMgr + .getStateManager(rCtx); + if (stateMgr.isContextStoppable(rCtx)) { + if (service != null) { + if (callbacks == null) { + callbacks = new LinkedList>(); + } + + callbacks.add(service + .submit(new Callable() { + @Override + public Boolean call() throws Exception { + return stateMgr.stopContext(rCtx); + } + })); + } else { + stateMgr.stopContext(rCtx); + } + } + } + + if (callbacks != null) { + for (Future callback : callbacks) { + rval &= callback.get().booleanValue(); + } + } + } + } + + return rval; + } +} diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/DependencyNode.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/DependencyNode.java new file mode 100644 index 0000000000..be26ee88c4 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/DependencyNode.java @@ -0,0 +1,145 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.esb.camel.context; + +import java.util.HashSet; +import java.util.Set; + +import org.apache.camel.CamelContext; +import org.apache.camel.Endpoint; +import org.apache.camel.Route; + +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.util.Pair; + +/** + * Class to map a context to its required and dependent contexts. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 10, 2014 2726       rjpeter     Initial creation
+ * 
+ * 
+ * + * @author rjpeter + * @version 1.0 + */ +public class DependencyNode { + private final CamelContext context; + + /** + * Contexts required by this context. + */ + private final Set requiredContexs = new HashSet(); + + /** + * Contexts that depend on this context. + */ + private final Set dependentContexts = new HashSet(); + + public DependencyNode(CamelContext context) { + this.context = context; + } + + /** + * Add a node who is dependent on this node. Applies linking in both + * directions. + * + * @param dNode + */ + public void addDependentNode(DependencyNode dNode) { + if (!requiredContexs.contains(dNode.context)) { + dependentContexts.add(dNode.context); + dNode.requiredContexs.add(context); + } else { + StringBuilder msg = new StringBuilder(300); + msg.append("Circular CamelContext dependency detected between ") + .append(context.getName()) + .append(" and ") + .append(dNode.context.getName()) + .append(". Removing dependency, startup/shutdown may be incorrect, verify configuration. "); + addRouteData(context, msg); + addRouteData(dNode.context, msg); + UFStatus.getHandler(DependencyNode.class).warn(msg.toString()); + } + } + + public CamelContext getContext() { + return context; + } + + /** + * Get all contexts that this context requires to be running. + * + * @return + */ + public Set getRequiredContexts() { + return requiredContexs; + } + + /** + * Get all contexts that depend on this context to be running. + * + * @return + */ + public Set getDependentContexts() { + return dependentContexts; + } + + /** + * Utility method for printing information about a context. + * + * @param ctx + * @param builder + */ + private static void addRouteData(CamelContext ctx, StringBuilder builder) { + builder.append("Context [").append(ctx.getName()) + .append("] consumes from ["); + Set consumerEndpoints = new HashSet(); + for (Route route : ctx.getRoutes()) { + Endpoint endpoint = route.getEndpoint(); + String uri = endpoint.getEndpointUri(); + Pair typeAndName = ContextData + .getEndpointTypeAndName(uri); + String name = typeAndName.getFirst() + ":" + + typeAndName.getSecond(); + builder.append(name).append(", "); + consumerEndpoints.add(name); + } + builder.delete(builder.length() - 2, builder.length()); + builder.append("] and produces to ["); + for (Endpoint endpoint : ctx.getEndpoints()) { + String uri = endpoint.getEndpointUri(); + Pair typeAndName = ContextData + .getEndpointTypeAndName(uri); + String name = typeAndName.getFirst() + ":" + + typeAndName.getSecond(); + if (!consumerEndpoints.contains(name)) { + builder.append(name).append(", "); + } + } + builder.delete(builder.length() - 2, builder.length()); + builder.append("]. "); + } +} \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/IContextStateManager.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/IContextStateManager.java new file mode 100644 index 0000000000..65c4409b66 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/IContextStateManager.java @@ -0,0 +1,96 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.esb.camel.context; + +import org.apache.camel.CamelContext; +import org.apache.camel.Route; + +/** + * Represents a way for managing a context for starting and stopping. Allows for + * Context with different purposes to be handled independently of each other. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 10, 2014 2726       rjpeter     Initial creation.
+ * 
+ * 
+ * + * @author rjpeter + * @version 1.0 + */ +public interface IContextStateManager { + /** + * Is the {@code CamelContext} startable? + * + * @param context + * @return + * @throws Exception + */ + public boolean isContextStartable(CamelContext context) throws Exception; + + /** + * Start the {@code CamelContext}. + * + * @param context + * @return + * @throws Exception + */ + public boolean startContext(CamelContext context) throws Exception; + + /** + * Start the {@code Route}. + * + * @param context + * @return + * @throws Exception + */ + public boolean startRoute(Route route) throws Exception; + + /** + * Is the {@code CamelContext} stoppable? + * + * @param context + * @return + * @throws Exception + */ + public boolean isContextStoppable(CamelContext context) throws Exception; + + /** + * Stop the {@code CamelContext}. + * + * @param context + * @return + * @throws Exception + */ + public boolean stopContext(CamelContext context) throws Exception; + + /** + * Stop the {@code Route}. + * + * @param context + * @return + * @throws Exception + */ + public boolean stopRoute(Route route) throws Exception; +} \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/directvm/DirectVMComponent.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/directvm/DirectVMComponent.java deleted file mode 100644 index 9d6324ecea..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/directvm/DirectVMComponent.java +++ /dev/null @@ -1,100 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ -package com.raytheon.uf.edex.esb.camel.directvm; - -import java.util.Collection; -import java.util.HashMap; -import java.util.Map; -import java.util.concurrent.CopyOnWriteArrayList; - -import org.apache.camel.Endpoint; -import org.apache.camel.component.direct.DirectComponent; -import org.apache.camel.impl.DefaultConsumer; -import org.apache.camel.impl.DefaultEndpoint; -import org.apache.camel.util.ServiceHelper; - -/** - * Provides a cross-context synchronous component. - * - *
- * 
- * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Nov 18, 2008            chammack     Initial creation
- * Jul 16, 2012 DR 15073   D. Friedman  Don't stop all consumer in doStop.
- * May 23, 2013 1989       njensen      Deprecated
- * 
- * 
- * - * @author chammack - * @version 1.0 - * @deprecated Use camel's built-in direct-vm component instead. This component - * can be deleted after that has been tested thoroughly. - */ - -@SuppressWarnings("unchecked") -@Deprecated -public class DirectVMComponent extends DirectComponent { - - private static Map> CONSUMERS = new HashMap>(); - - @Override - protected Endpoint createEndpoint(String uri, String remaining, - Map parameters) throws Exception { - - synchronized (CONSUMERS) { - - CopyOnWriteArrayList consumers = CONSUMERS - .get(uri); - - if (consumers == null) { - consumers = new CopyOnWriteArrayList(); - CONSUMERS.put(uri, consumers); - - } - - Endpoint endpoint = new DirectVMEndpoint(uri, this, consumers); - setProperties(endpoint, parameters); - return endpoint; - } - - } - - @Override - protected void doStop() throws Exception { - Collection> set = CONSUMERS - .values(); - - /* - * Stop only the consumers created through this instance of the - * component. - */ - for (CopyOnWriteArrayList consumerList : set) - for (DefaultConsumer consumer : consumerList) { - Endpoint endpoint = consumer.getEndpoint(); - if (endpoint instanceof DefaultEndpoint) - if (((DefaultEndpoint) endpoint).getComponent() == this) - ServiceHelper.stopService(consumer); - } - - super.doStop(); - } -} diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/directvm/DirectVMEndpoint.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/directvm/DirectVMEndpoint.java deleted file mode 100644 index 975131b0fc..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/directvm/DirectVMEndpoint.java +++ /dev/null @@ -1,102 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ -package com.raytheon.uf.edex.esb.camel.directvm; - -import java.util.List; -import java.util.concurrent.CopyOnWriteArrayList; - -import org.apache.camel.Consumer; -import org.apache.camel.Producer; -import org.apache.camel.component.direct.DirectEndpoint; -import org.apache.camel.impl.DefaultConsumer; - -/** - * - * Provides a cross-context synchronous component. - * - *
- * 
- * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Nov 18, 2008            chammack     Initial creation
- * Jul 16, 2012 DR 15073   D. Friedman  Override correct methods
- * May 09, 2013 1989       njensen      Camel 2.11 compatibility
- * May 23, 2013 1989       njensen      Deprecated
- * 
- * 
- * - * @author chammack - * @version 1.0 - * @deprecated Use camel's built-in direct-vm component instead. This component - * can be deleted after that has been tested thoroughly. - */ - -@Deprecated -public class DirectVMEndpoint extends DirectEndpoint { - private boolean allowMultipleConsumers = true; - - private CopyOnWriteArrayList consumers = new CopyOnWriteArrayList(); - - public DirectVMEndpoint(String uri, DirectVMComponent component) { - super(uri, component); - } - - public DirectVMEndpoint(String uri, DirectVMComponent component, - CopyOnWriteArrayList consumers) { - super(uri, component); - this.consumers = consumers; - } - - @Override - public Producer createProducer() throws Exception { - return new DirectVMProducer(this); - } - - @Override - public Consumer createConsumer(org.apache.camel.Processor processor) - throws Exception { - return new DefaultConsumer(this, processor) { - @Override - protected void doStart() throws Exception { - if (!allowMultipleConsumers && !consumers.isEmpty()) { - throw new IllegalStateException( - "Endpoint " - + getEndpointUri() - + " only allows 1 active consumer but you attempted to start a 2nd consumer."); - } - - consumers.add(this); - super.doStart(); - } - - @Override - protected void doStop() throws Exception { - super.doStop(); - consumers.remove(this); - } - }; - } - - public List getConsumers() { - return consumers; - } - -} diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/directvm/DirectVMProducer.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/directvm/DirectVMProducer.java deleted file mode 100644 index 89f835147b..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/directvm/DirectVMProducer.java +++ /dev/null @@ -1,111 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ -package com.raytheon.uf.edex.esb.camel.directvm; - -import java.util.List; - -import org.apache.camel.AsyncCallback; -import org.apache.camel.AsyncProcessor; -import org.apache.camel.CamelExchangeException; -import org.apache.camel.Exchange; -import org.apache.camel.component.direct.DirectProducer; -import org.apache.camel.impl.DefaultConsumer; -import org.apache.camel.impl.converter.AsyncProcessorTypeConverter; -import org.apache.camel.util.AsyncProcessorHelper; - -import com.raytheon.uf.common.status.IUFStatusHandler; -import com.raytheon.uf.common.status.UFStatus; -import com.raytheon.uf.common.status.UFStatus.Priority; - -/** - * Direct VM Producer used with DirectVMConsumer. - * - *
- * 
- * SOFTWARE HISTORY
- * 
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Oct 27, 2010            mschenke     Initial creation
- * May 23, 2013 1989       njensen      Deprecated
- * 
- * 
- * - * @author mschenke - * @version 1.0 - * @deprecated Use camel's built-in direct-vm component instead. This component - * can be deleted after that has been tested thoroughly. - */ - -@Deprecated -public class DirectVMProducer extends DirectProducer { - private static final transient IUFStatusHandler statusHandler = UFStatus - .getHandler(DirectVMProducer.class); - - private DirectVMEndpoint endpoint; - - /** - * @param endpoint - */ - public DirectVMProducer(DirectVMEndpoint endpoint) { - super(endpoint); - this.endpoint = endpoint; - } - - public void process(Exchange exchange) throws Exception { - List consumers = endpoint.getConsumers(); - if (consumers == null || consumers.size() == 0) { - statusHandler.handle(Priority.PROBLEM, - "No consumers available on endpoint: " + endpoint - + " to process: " + exchange); - throw new CamelExchangeException( - "No consumers available on endpoint: " + endpoint, exchange); - } else { - for (DefaultConsumer consumer : consumers) { - consumer.getProcessor().process(exchange); - } - } - } - - public boolean process(Exchange exchange, AsyncCallback callback) { - List consumers = endpoint.getConsumers(); - if (consumers == null || consumers.size() == 0) { - statusHandler.handle(Priority.PROBLEM, - "No consumers available on endpoint: " + endpoint - + " to process: " + exchange); - // indicate its done synchronously - exchange.setException(new CamelExchangeException( - "No consumers available on endpoint: " + endpoint, exchange)); - callback.done(true); - return true; - } else { - boolean sync = true; - for (DefaultConsumer consumer : consumers) { - AsyncProcessor processor = AsyncProcessorTypeConverter - .convert(consumer.getProcessor()); - sync &= AsyncProcessorHelper.process(processor, exchange, - callback); - } - - return sync; - } - } - -} diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/jms/DedicatedThreadJmsComponent.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/jms/DedicatedThreadJmsComponent.java index 978efdac8f..bd761c2b96 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/jms/DedicatedThreadJmsComponent.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/jms/DedicatedThreadJmsComponent.java @@ -86,7 +86,6 @@ public class DedicatedThreadJmsComponent extends JmsComponent { executor.setMaxPoolSize(Math.max(jmsE.getConcurrentConsumers(), jmsE.getMaxConcurrentConsumers())); executor.setQueueCapacity(0); - executor.afterPropertiesSet(); jmsE.setTaskExecutor(executor); jmsE.setMessageListenerContainerFactory(MonitoredDefaultMessageListenerContainerFactory diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/spring/JmsThreadPoolTaskExecutor.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/spring/JmsThreadPoolTaskExecutor.java index f8e83f62eb..b0bfac85a5 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/spring/JmsThreadPoolTaskExecutor.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/spring/JmsThreadPoolTaskExecutor.java @@ -19,6 +19,8 @@ **/ package com.raytheon.uf.edex.esb.camel.spring; +import java.util.concurrent.ThreadPoolExecutor; + import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor; /** @@ -32,7 +34,7 @@ import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Nov 15, 2010 rjpeter Initial creation - * + * Apr 10, 2014 2726 rjpeter Updated to create/initialize the ThreadPoolExecutor on demand. * * * @author rjpeter @@ -40,6 +42,25 @@ import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor; */ public class JmsThreadPoolTaskExecutor extends ThreadPoolTaskExecutor { + private static final long serialVersionUID = 1L; + + private volatile boolean needToInitialize = true; + + @Override + public ThreadPoolExecutor getThreadPoolExecutor() + throws IllegalStateException { + // don't initialize until first needed + if (needToInitialize) { + synchronized (this) { + if (needToInitialize) { + afterPropertiesSet(); + needToInitialize = false; + } + } + } + return super.getThreadPoolExecutor(); + } + @Override public boolean prefersShortLivedTasks() { return false; diff --git a/edexOsgi/com.raytheon.uf.edex.ingest/res/spring/persist-ingest.xml b/edexOsgi/com.raytheon.uf.edex.ingest/res/spring/persist-ingest.xml index e58c99323a..b14c671dbc 100644 --- a/edexOsgi/com.raytheon.uf.edex.ingest/res/spring/persist-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.ingest/res/spring/persist-ingest.xml @@ -12,11 +12,11 @@ - + + - + @@ -41,9 +41,7 @@ - @@ -62,7 +60,7 @@ - + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.ohd/res/spring/mpeLightningSrv-ingest.xml b/edexOsgi/com.raytheon.uf.edex.ohd/res/spring/mpeLightningSrv-ingest.xml index 2305af6fab..fe72681f62 100644 --- a/edexOsgi/com.raytheon.uf.edex.ohd/res/spring/mpeLightningSrv-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.ohd/res/spring/mpeLightningSrv-ingest.xml @@ -9,7 +9,7 @@ + errorHandlerRef="errorHandler"> diff --git a/edexOsgi/com.raytheon.uf.edex.ohd/res/spring/satpre-spring.xml b/edexOsgi/com.raytheon.uf.edex.ohd/res/spring/satpre-spring.xml index 41b88edc54..73174adcd5 100644 --- a/edexOsgi/com.raytheon.uf.edex.ohd/res/spring/satpre-spring.xml +++ b/edexOsgi/com.raytheon.uf.edex.ohd/res/spring/satpre-spring.xml @@ -9,8 +9,7 @@ + errorHandlerRef="errorHandler"> @@ -27,8 +26,7 @@ - + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.acars/res/spring/acars-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.acars/res/spring/acars-ingest.xml index e89bd76d0a..ab28897370 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.acars/res/spring/acars-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.acars/res/spring/acars-ingest.xml @@ -12,18 +12,10 @@ - - - - + errorHandlerRef="errorHandler"> + xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd"> diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.manualIngest/res/spring/manualIngest-request.xml b/edexOsgi/com.raytheon.uf.edex.plugin.manualIngest/res/spring/manualIngest-request.xml index 411d4428a0..37d44e970e 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.manualIngest/res/spring/manualIngest-request.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.manualIngest/res/spring/manualIngest-request.xml @@ -8,7 +8,7 @@ - + diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.manualIngest/res/spring/manualIngest-spring.xml b/edexOsgi/com.raytheon.uf.edex.plugin.manualIngest/res/spring/manualIngest-spring.xml index 0ec3a71073..af2f65b49b 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.manualIngest/res/spring/manualIngest-spring.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.manualIngest/res/spring/manualIngest-spring.xml @@ -6,7 +6,7 @@ + errorHandlerRef="errorHandler"> @@ -18,8 +18,7 @@ - + diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/res/spring/modelsounding-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/res/spring/modelsounding-ingest.xml index 0a56c9b988..518b24d3c4 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/res/spring/modelsounding-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/res/spring/modelsounding-ingest.xml @@ -2,15 +2,12 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd"> - - + + class="com.raytheon.uf.edex.plugin.modelsounding.ModelSoundingDecoder"> @@ -25,11 +22,6 @@ - - - - @@ -45,10 +37,14 @@ + + + + + + errorHandlerRef="errorHandler"> + + + + + diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingDecoder.java b/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingDecoder.java index 34dadeefe6..6492adfb5e 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingDecoder.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingDecoder.java @@ -125,14 +125,6 @@ public class ModelSoundingDecoder extends AbstractDecoder implements } } - public void start() { - this.modelSoundingPersistenceManager.start(); - } - - public void shutdown() { - this.modelSoundingPersistenceManager.shutdown(); - } - /** * Get one entry from the separator and interpret that data as a single * profiler observation. diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingPersistenceManager.java b/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingPersistenceManager.java index ca867f24d9..0528cd33c4 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingPersistenceManager.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingPersistenceManager.java @@ -22,7 +22,6 @@ package com.raytheon.uf.edex.plugin.modelsounding; import java.util.Iterator; import java.util.LinkedHashMap; import java.util.List; -import java.util.concurrent.atomic.AtomicBoolean; import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.common.status.IUFStatusHandler; @@ -30,6 +29,7 @@ import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.edex.core.EDEXUtil; import com.raytheon.uf.edex.core.EdexException; +import com.raytheon.uf.edex.core.IContextStateProcessor; /** * Thread for storing Model Soundings asynchronously. If decode thread decodes @@ -42,40 +42,41 @@ import com.raytheon.uf.edex.core.EdexException; * * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Jul 17, 2013 2161 bkowal Initial creation - * + * Jul 17, 2013 2161 bkowal Initial creation. + * Mar 11, 2014 2726 rjpeter Graceful shutdown. * * * @author bkowal * @version 1.0 */ -public class ModelSoundingPersistenceManager extends Thread { +public class ModelSoundingPersistenceManager implements IContextStateProcessor { /** The logger */ private final IUFStatusHandler logger = UFStatus .getHandler(ModelSoundingPersistenceManager.class); private final LinkedHashMap containerMap; - private final AtomicBoolean run = new AtomicBoolean(true); + private volatile boolean run = false; + + private volatile boolean shutdown = false; /** * */ public ModelSoundingPersistenceManager() { - super("ModelSoundingStore"); + // super("ModelSoundingStore"); this.containerMap = new LinkedHashMap( 64, 1); } - @Override public void run() { - boolean keepStoring = true; - while (keepStoring) { + run = true; + while (run) { try { ModelSoundingStorageContainer container = null; synchronized (containerMap) { - while (containerMap.isEmpty() && this.run.get()) { + while (containerMap.isEmpty() && run) { try { containerMap.wait(); } catch (InterruptedException e) { @@ -107,9 +108,6 @@ public class ModelSoundingPersistenceManager extends Thread { logger.error("Failed to persist " + pdos.length + " PluginDataObject(s)!", e); } - } else if (!this.run.get()) { - // received shutdown flag - keepStoring = false; } } catch (Throwable e) { // fail safe so store thread doesn't fail @@ -118,6 +116,24 @@ public class ModelSoundingPersistenceManager extends Thread { e); } } + + shutdown = true; + synchronized (containerMap) { + containerMap.notifyAll(); + } + } + + protected void storeContainer(ModelSoundingStorageContainer container) { + List pdoList = container.getPdos(); + PluginDataObject[] pdos = pdoList.toArray(new PluginDataObject[pdoList + .size()]); + try { + EDEXUtil.getMessageProducer().sendSync( + "modelSoundingPersistIndexAlert", pdos); + } catch (EdexException e) { + logger.error("Failed to persist " + pdos.length + + " PluginDataObject(s)!", e); + } } /** @@ -128,15 +144,15 @@ public class ModelSoundingPersistenceManager extends Thread { * * @param persistRecordKey * @param container - * @return */ - public boolean checkIn(String persistRecordKey, + public void checkIn(String persistRecordKey, ModelSoundingStorageContainer container) { - boolean rval = run.get(); + boolean storeLocal = true; synchronized (containerMap) { - if (rval) { + if (run) { ModelSoundingStorageContainer prev = containerMap.put( persistRecordKey, container); + storeLocal = false; if (prev != null) { // technically only possible in an environment where there // are multiple decode threads running, just append the @@ -151,7 +167,9 @@ public class ModelSoundingPersistenceManager extends Thread { } } - return rval; + if (storeLocal) { + storeContainer(container); + } } /** @@ -168,11 +186,34 @@ public class ModelSoundingPersistenceManager extends Thread { } } - public void shutdown() { - run.set(false); + @Override + public void preStart() { + } - synchronized (containerMap) { - containerMap.notify(); + @Override + public void postStart() { + } + + @Override + public void preStop() { + if (run) { + run = false; + + synchronized (containerMap) { + containerMap.notifyAll(); + + while (!shutdown) { + try { + containerMap.wait(1000); + } catch (Exception e) { + // ignore + } + } + } } } + + @Override + public void postStop() { + } } \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.npp.crimss/res/spring/crimss-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.npp.crimss/res/spring/crimss-ingest.xml index f40b7d96aa..e287dcda89 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.npp.crimss/res/spring/crimss-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.npp.crimss/res/spring/crimss-ingest.xml @@ -12,15 +12,9 @@ - - - - + errorHandlerRef="errorHandler"> diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.npp.nucaps/res/spring/nucaps-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.npp.nucaps/res/spring/nucaps-ingest.xml index 063e071ff1..041d9eb20a 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.npp.nucaps/res/spring/nucaps-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.npp.nucaps/res/spring/nucaps-ingest.xml @@ -12,15 +12,9 @@ - - - - + errorHandlerRef="errorHandler"> diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.npp.viirs/res/spring/viirs-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.npp.viirs/res/spring/viirs-ingest.xml index f32f770d16..f12f2a32ca 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.npp.viirs/res/spring/viirs-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.npp.viirs/res/spring/viirs-ingest.xml @@ -10,11 +10,6 @@ - - - - @@ -25,8 +20,7 @@ + errorHandlerRef="errorHandler"> diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.obs.ogc/res/spring/obs-dpa-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.obs.ogc/res/spring/obs-dpa-ingest.xml index d1d3ef8623..0f849a3090 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.obs.ogc/res/spring/obs-dpa-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.obs.ogc/res/spring/obs-dpa-ingest.xml @@ -17,18 +17,11 @@ - - - - + errorHandlerRef="errorHandler"> diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.obs.ogc/res/spring/obs-ogc-routes.xml b/edexOsgi/com.raytheon.uf.edex.plugin.obs.ogc/res/spring/obs-ogc-routes.xml index 22b4dd3a02..72600a2472 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.obs.ogc/res/spring/obs-ogc-routes.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.obs.ogc/res/spring/obs-ogc-routes.xml @@ -1,5 +1,5 @@ @@ -15,12 +15,6 @@ - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.obs.ogc/res/spring/obs-ogc.xml b/edexOsgi/com.raytheon.uf.edex.plugin.obs.ogc/res/spring/obs-ogc.xml index 59b7ebee1d..58d73aa17e 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.obs.ogc/res/spring/obs-ogc.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.obs.ogc/res/spring/obs-ogc.xml @@ -1,7 +1,6 @@ + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd"> diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.obs.registry/res/spring/obs-ogc-registry.xml b/edexOsgi/com.raytheon.uf.edex.plugin.obs.registry/res/spring/obs-ogc-registry.xml index 9853a10fed..c062cdca9d 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.obs.registry/res/spring/obs-ogc-registry.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.obs.registry/res/spring/obs-ogc-registry.xml @@ -27,12 +27,6 @@ - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.preciprate/res/spring/preciprate-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.preciprate/res/spring/preciprate-ingest.xml index eb49a866b7..195e2ea75b 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.preciprate/res/spring/preciprate-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.preciprate/res/spring/preciprate-ingest.xml @@ -10,7 +10,7 @@
- + diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.qc/res/spring/qc-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.qc/res/spring/qc-ingest.xml index 65dcbe6478..c5179f4a05 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.qc/res/spring/qc-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.qc/res/spring/qc-ingest.xml @@ -9,15 +9,9 @@
- - - - + errorHandlerRef="errorHandler"> diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.qpf/res/spring/qpf-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.qpf/res/spring/qpf-ingest.xml index 2b90e0b133..d645e01cf0 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.qpf/res/spring/qpf-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.qpf/res/spring/qpf-ingest.xml @@ -10,7 +10,7 @@
- + diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.satellite.mcidas/res/spring/satellite-mcidas-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.satellite.mcidas/res/spring/satellite-mcidas-ingest.xml index 988a5a7b45..d212f7ab03 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.satellite.mcidas/res/spring/satellite-mcidas-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.satellite.mcidas/res/spring/satellite-mcidas-ingest.xml @@ -11,15 +11,9 @@ - - - - + errorHandlerRef="errorHandler"> diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.scan/res/spring/scan-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.scan/res/spring/scan-ingest.xml index 863ea586b8..0d52c3d8e0 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.scan/res/spring/scan-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.scan/res/spring/scan-ingest.xml @@ -23,10 +23,7 @@ - + @@ -41,8 +38,8 @@ - + + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/res/spring/svrwx-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/res/spring/svrwx-ingest.xml index 58689cd836..d24cf70cee 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/res/spring/svrwx-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.svrwx/res/spring/svrwx-ingest.xml @@ -13,15 +13,9 @@ - - - - + errorHandlerRef="errorHandler"> diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.tcg/res/spring/tcg-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.tcg/res/spring/tcg-ingest.xml index 3a71efee64..5bec012152 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.tcg/res/spring/tcg-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.tcg/res/spring/tcg-ingest.xml @@ -13,15 +13,9 @@
- - - - + errorHandlerRef="errorHandler"> diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.tcs/res/spring/tcs-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.tcs/res/spring/tcs-ingest.xml index c6fd1f8d32..1c9610a805 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.tcs/res/spring/tcs-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.tcs/res/spring/tcs-ingest.xml @@ -13,15 +13,9 @@
- - - - + errorHandlerRef="errorHandler"> diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.vaa/res/spring/vaa-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.vaa/res/spring/vaa-ingest.xml index 2bb0092618..171ec133b1 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.vaa/res/spring/vaa-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.vaa/res/spring/vaa-ingest.xml @@ -11,15 +11,9 @@
- - - - + errorHandlerRef="errorHandler"> + errorHandlerRef="errorHandler"> @@ -54,8 +54,7 @@ - + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.textdbsrv/res/spring/textdbsrv-request.xml b/edexOsgi/com.raytheon.uf.edex.textdbsrv/res/spring/textdbsrv-request.xml index d0bbfc2f79..73917fc0e1 100644 --- a/edexOsgi/com.raytheon.uf.edex.textdbsrv/res/spring/textdbsrv-request.xml +++ b/edexOsgi/com.raytheon.uf.edex.textdbsrv/res/spring/textdbsrv-request.xml @@ -4,10 +4,10 @@ xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd"> - + - + diff --git a/edexOsgi/com.raytheon.uf.edex.wfs/res/spring/wfs-ogc-soap-request.xml b/edexOsgi/com.raytheon.uf.edex.wfs/res/spring/wfs-ogc-soap-request.xml index 67649049c1..dc7b1299f8 100644 --- a/edexOsgi/com.raytheon.uf.edex.wfs/res/spring/wfs-ogc-soap-request.xml +++ b/edexOsgi/com.raytheon.uf.edex.wfs/res/spring/wfs-ogc-soap-request.xml @@ -1,10 +1,8 @@ + http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-2.0.xsd"> diff --git a/ncep/gov.noaa.nws.ncep.edex.common/res/spring/ncinventory-request.xml b/ncep/gov.noaa.nws.ncep.edex.common/res/spring/ncinventory-request.xml index 5ed9a3a3d2..9a753329d9 100644 --- a/ncep/gov.noaa.nws.ncep.edex.common/res/spring/ncinventory-request.xml +++ b/ncep/gov.noaa.nws.ncep.edex.common/res/spring/ncinventory-request.xml @@ -25,15 +25,16 @@ - - - - + + + errorHandlerRef="errorHandler"> + + + + + @@ -72,17 +73,4 @@ - - - - - - - - - - - \ No newline at end of file diff --git a/ncep/gov.noaa.nws.ncep.edex.ingest.grib.util/res/spring/ncep-util-on-edex-ingestGrib.xml b/ncep/gov.noaa.nws.ncep.edex.ingest.grib.util/res/spring/ncep-util-on-edex-ingestGrib.xml index fd81e95b04..9e2b603312 100644 --- a/ncep/gov.noaa.nws.ncep.edex.ingest.grib.util/res/spring/ncep-util-on-edex-ingestGrib.xml +++ b/ncep/gov.noaa.nws.ncep.edex.ingest.grib.util/res/spring/ncep-util-on-edex-ingestGrib.xml @@ -1,8 +1,7 @@ + xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd"> diff --git a/ncep/gov.noaa.nws.ncep.edex.ingest.util/res/spring/ncep-util-on-edex-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.ingest.util/res/spring/ncep-util-on-edex-ingest.xml index 1bb57bd273..94f4f216ce 100644 --- a/ncep/gov.noaa.nws.ncep.edex.ingest.util/res/spring/ncep-util-on-edex-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.ingest.util/res/spring/ncep-util-on-edex-ingest.xml @@ -1,8 +1,7 @@ + xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.airep/res/spring/airep-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.airep/res/spring/airep-ingest.xml index b627390977..2ad9e217a2 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.airep/res/spring/airep-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.airep/res/spring/airep-ingest.xml @@ -16,16 +16,10 @@ - - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.aww/res/spring/aww-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.aww/res/spring/aww-ingest.xml index 42922eb7d5..3addea8068 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.aww/res/spring/aww-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.aww/res/spring/aww-ingest.xml @@ -27,15 +27,9 @@ - - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.convsigmet/res/spring/convsigmet-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.convsigmet/res/spring/convsigmet-ingest.xml index d4bbbbd516..0325113a3e 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.convsigmet/res/spring/convsigmet-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.convsigmet/res/spring/convsigmet-ingest.xml @@ -16,15 +16,9 @@ - - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.gpd/res/spring/gpd-common.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.gpd/res/spring/gpd-common.xml index aabd160479..d3449b6f8b 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.gpd/res/spring/gpd-common.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.gpd/res/spring/gpd-common.xml @@ -1,7 +1,6 @@ + xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.gpd/res/spring/gpd-request.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.gpd/res/spring/gpd-request.xml index 3c74e5713e..626214480f 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.gpd/res/spring/gpd-request.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.gpd/res/spring/gpd-request.xml @@ -1,8 +1,6 @@ + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" + xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.idft/res/spring/idft-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.idft/res/spring/idft-ingest.xml index 41ded2bf76..2b2abc547f 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.idft/res/spring/idft-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.idft/res/spring/idft-ingest.xml @@ -16,14 +16,8 @@ - - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.intlsigmet/res/spring/intlsigmet-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.intlsigmet/res/spring/intlsigmet-ingest.xml index 352d79ccc2..b0c2197d99 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.intlsigmet/res/spring/intlsigmet-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.intlsigmet/res/spring/intlsigmet-ingest.xml @@ -15,15 +15,9 @@ - - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.mosaic/res/spring/mosaic-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.mosaic/res/spring/mosaic-ingest.xml index 32178b148c..4a409932ab 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.mosaic/res/spring/mosaic-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.mosaic/res/spring/mosaic-ingest.xml @@ -26,15 +26,9 @@ - - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.ncgrib/res/spring/ncgrib-file-endpoint.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.ncgrib/res/spring/ncgrib-file-endpoint.xml index dc319c9a43..e364db945b 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.ncgrib/res/spring/ncgrib-file-endpoint.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.ncgrib/res/spring/ncgrib-file-endpoint.xml @@ -6,8 +6,7 @@ + errorHandlerRef="errorHandler"> @@ -23,8 +22,7 @@ - + diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.ncpafm/res/spring/ncpafm-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.ncpafm/res/spring/ncpafm-ingest.xml index 902d9bf772..5c3c4fa725 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.ncpafm/res/spring/ncpafm-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.ncpafm/res/spring/ncpafm-ingest.xml @@ -18,14 +18,8 @@ - - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.ncscd/res/spring/ncscd-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.ncscd/res/spring/ncscd-ingest.xml index 6b3ddfa68c..044cfc43ba 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.ncscd/res/spring/ncscd-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.ncscd/res/spring/ncscd-ingest.xml @@ -26,13 +26,8 @@ - - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.nctaf/res/spring/nctaf-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.nctaf/res/spring/nctaf-ingest.xml index 0cc91f22cb..bb46c904c1 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.nctaf/res/spring/nctaf-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.nctaf/res/spring/nctaf-ingest.xml @@ -15,15 +15,9 @@
- - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.nonconvsigmet/res/spring/nonconvsigmet-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.nonconvsigmet/res/spring/nonconvsigmet-ingest.xml index caa82e2c84..632ad8f69f 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.nonconvsigmet/res/spring/nonconvsigmet-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.nonconvsigmet/res/spring/nonconvsigmet-ingest.xml @@ -16,15 +16,9 @@
- - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.pirep/res/spring/pirep-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.pirep/res/spring/pirep-ingest.xml index 965e56bc2d..e6f754099a 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.pirep/res/spring/pirep-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.pirep/res/spring/pirep-ingest.xml @@ -18,14 +18,8 @@
- - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.sgwhv/res/spring/sgwhv-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.sgwhv/res/spring/sgwhv-ingest.xml index 52c60fae23..1f2760e60c 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.sgwhv/res/spring/sgwhv-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.sgwhv/res/spring/sgwhv-ingest.xml @@ -21,15 +21,9 @@
- - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.solarimage/res/spring/solarimage-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.solarimage/res/spring/solarimage-ingest.xml index f6b5665de9..5608a288f1 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.solarimage/res/spring/solarimage-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.solarimage/res/spring/solarimage-ingest.xml @@ -18,18 +18,12 @@
- - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.ssha/res/spring/ssha-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.ssha/res/spring/ssha-ingest.xml index 0abc5a6fe8..812701dc22 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.ssha/res/spring/ssha-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.ssha/res/spring/ssha-ingest.xml @@ -22,15 +22,9 @@
- - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.stormtrack/res/spring/stormtrack-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.stormtrack/res/spring/stormtrack-ingest.xml index aa1f96f9a9..ff59eea2d5 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.stormtrack/res/spring/stormtrack-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.stormtrack/res/spring/stormtrack-ingest.xml @@ -23,14 +23,8 @@
- - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.tcm/res/spring/tcm-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.tcm/res/spring/tcm-ingest.xml index ed77155176..2fae466e6a 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.tcm/res/spring/tcm-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.tcm/res/spring/tcm-ingest.xml @@ -16,14 +16,8 @@
- - - - + errorHandlerRef="errorHandler"> diff --git a/ncep/gov.noaa.nws.ncep.edex.plugin.wcp/res/spring/wcp-ingest.xml b/ncep/gov.noaa.nws.ncep.edex.plugin.wcp/res/spring/wcp-ingest.xml index b9589deea9..0617dd0d46 100644 --- a/ncep/gov.noaa.nws.ncep.edex.plugin.wcp/res/spring/wcp-ingest.xml +++ b/ncep/gov.noaa.nws.ncep.edex.plugin.wcp/res/spring/wcp-ingest.xml @@ -16,14 +16,8 @@
- - - - + errorHandlerRef="errorHandler"> diff --git a/ost/gov.noaa.nws.ost.edex.plugin.regionalsat/res/spring/regionalsat-ingest.xml b/ost/gov.noaa.nws.ost.edex.plugin.regionalsat/res/spring/regionalsat-ingest.xml index ff0a2d8eea..89da5f5eca 100644 --- a/ost/gov.noaa.nws.ost.edex.plugin.regionalsat/res/spring/regionalsat-ingest.xml +++ b/ost/gov.noaa.nws.ost.edex.plugin.regionalsat/res/spring/regionalsat-ingest.xml @@ -16,15 +16,9 @@ - - - - + errorHandlerRef="errorHandler"> diff --git a/tools/scripts/commit-msg b/tools/scripts/commit-msg old mode 100644 new mode 100755 diff --git a/tools/scripts/git-u-setup b/tools/scripts/git-u-setup old mode 100644 new mode 100755 diff --git a/tools/scripts/uamend b/tools/scripts/uamend old mode 100644 new mode 100755 diff --git a/tools/scripts/ucommit b/tools/scripts/ucommit old mode 100644 new mode 100755 diff --git a/tools/scripts/upull b/tools/scripts/upull old mode 100644 new mode 100755 diff --git a/tools/scripts/upush b/tools/scripts/upush old mode 100644 new mode 100755 diff --git a/tools/scripts/ustat b/tools/scripts/ustat old mode 100644 new mode 100755 From 7c618f20d7257a32ea187c834ea0ad3979467564 Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Mon, 14 Apr 2014 13:25:53 -0500 Subject: [PATCH 014/188] Issue #2726: Add BoundedMap Former-commit-id: bf56d51e161d00b3f5156b957203d616e971c23e --- .../raytheon/uf/common/util/SystemUtil.java | 28 +---- .../common/util/collections/BoundedMap.java | 109 ++++++++++++++++++ 2 files changed, 111 insertions(+), 26 deletions(-) create mode 100644 edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/collections/BoundedMap.java diff --git a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SystemUtil.java b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SystemUtil.java index a113752e68..c3d25a949e 100644 --- a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SystemUtil.java +++ b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SystemUtil.java @@ -23,9 +23,9 @@ import java.lang.management.ManagementFactory; import java.net.InetAddress; import java.net.UnknownHostException; import java.util.Collections; -import java.util.LinkedHashMap; import java.util.Map; -import java.util.Map.Entry; + +import com.raytheon.uf.common.util.collections.BoundedMap; /** * System utilities such as hostname and pid lookup. @@ -44,30 +44,6 @@ import java.util.Map.Entry; * @version 1.0 */ public class SystemUtil { - /** - * Map that can be limited to a given number of entries. - */ - private static class BoundedMap extends LinkedHashMap { - private static final long serialVersionUID = 1L; - - private final int maxSize; - - public BoundedMap(int maxSize) { - super(16, 0.75f, true); - this.maxSize = maxSize; - } - - /* - * (non-Javadoc) - * - * @see java.util.LinkedHashMap#removeEldestEntry(java.util.Map.Entry) - */ - @Override - protected boolean removeEldestEntry(Entry eldest) { - return size() > maxSize; - } - } - private static final Map hostNameCache = Collections .synchronizedMap(new BoundedMap(100)); diff --git a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/collections/BoundedMap.java b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/collections/BoundedMap.java new file mode 100644 index 0000000000..ad7b52006b --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/collections/BoundedMap.java @@ -0,0 +1,109 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.common.util.collections; + +import java.util.LinkedHashMap; +import java.util.Map.Entry; + +/** + * Map implementation that limits the map to a specified number of entries. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 14, 2014 2726       rjpeter     Initial creation
+ * 
+ * 
+ * + * @author rjpeter + * @version 1.0 + * @param + * @param + */ +public class BoundedMap extends LinkedHashMap { + private static final long serialVersionUID = 1L; + + private static final int DEFAULT_INITIAL_SIZE = 16; + + private static final float DEFAULT_LOAD_FACTOR = 0.75f; + + private final int maxSize; + + /** + * BoundedMap with specified max size. Defaults to accessOrder elimination. + * + * @param maxSize + */ + public BoundedMap(int maxSize) { + this(maxSize, DEFAULT_INITIAL_SIZE, DEFAULT_LOAD_FACTOR, true); + } + + /** + * BoundedMap with specified initial and max size. Defaults to accessOrder + * elimination. + * + * @param maxSize + * @param initialSize + */ + public BoundedMap(int maxSize, int initialSize) { + this(maxSize, initialSize, DEFAULT_LOAD_FACTOR, true); + } + + /** + * BoundedMap with specified initial size, max size, and loadFactor. + * Defaults to accessOrder elimination. + * + * @param maxSize + * @param initialSize + * @param loadFactor + */ + public BoundedMap(int maxSize, int initialSize, float loadFactor) { + this(maxSize, initialSize, loadFactor, true); + } + + /** + * BoundedMap with specified initial size, max size, loadFactor, and + * accessOrder elimination. If accessOrder is true, map is order by + * accessOrder, false is insertion order. + * + * @param maxSize + * @param initialSize + * @param loadFactor + * @param accessOrder + */ + public BoundedMap(int maxSize, int initialSize, float loadFactor, + boolean accessOrder) { + super(initialSize, loadFactor, accessOrder); + this.maxSize = maxSize; + } + + /* + * (non-Javadoc) + * + * @see java.util.LinkedHashMap#removeEldestEntry(java.util.Map.Entry) + */ + @Override + protected boolean removeEldestEntry(Entry eldest) { + return size() > maxSize; + } +} From f086bb0c9bac8e1981e9c3250aeb773a583f5b92 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Mon, 14 Apr 2014 14:28:11 -0500 Subject: [PATCH 015/188] Issue #2984 remove uEngineWeb, move gfe svc backup files to viz.gfe plugin Change-Id: I8fcd61af003366405b4b40661bb7e471bf03c64a Former-commit-id: e2feed87185e15d9e681ca0155b03d1d9ff29e25 --- .../help/GfeServiceBackup}/INSTRUCTIONS | 0 .../GfeServiceBackup}/banner_exprtGrdMode.gif | Bin .../GfeServiceBackup}/banner_exprtMode.gif | Bin .../banner_exprtbksiteGrdMode.gif | Bin .../banner_exprtbksiteGrdToCSMode.gif | Bin .../help/GfeServiceBackup}/banner_ghgMode.gif | Bin .../GfeServiceBackup}/banner_imprtGrdMode.gif | Bin .../GfeServiceBackup}/banner_imprtMode.gif | Bin .../GfeServiceBackup}/banner_no_backup.gif | Bin .../GfeServiceBackup}/banner_svcbuMode.gif | Bin .../GfeServiceBackup}/banner_waitMode.gif | Bin .../help/GfeServiceBackup}/choose_domain.jpg | Bin .../choose_domain_multi1.jpg | Bin .../choose_domain_multi2.jpg | Bin .../help/GfeServiceBackup}/clean_up.gif | Bin .../help/GfeServiceBackup}/do_not_cancel.gif | Bin .../help/GfeServiceBackup}/failed_site.jpg | Bin .../help/GfeServiceBackup}/gfe_startup.gif | Bin .../GfeServiceBackup}/multi_exprtGrdMode.gif | Bin .../GfeServiceBackup}/multi_exprtMode.gif | Bin .../multi_exprtbksiteGrdMode.gif | Bin .../multi_exprtbksiteGrdToCSMode.gif | Bin .../help/GfeServiceBackup}/multi_ghgMode.gif | Bin .../GfeServiceBackup}/multi_imprtGrdMode.gif | Bin .../GfeServiceBackup}/multi_imprtMode.gif | Bin .../GfeServiceBackup}/multi_no_backup.gif | Bin .../GfeServiceBackup}/multi_svcbuMode.gif | Bin .../help/GfeServiceBackup}/multi_waitMode.gif | Bin .../help/GfeServiceBackup}/option_both.jpg | Bin .../help/GfeServiceBackup}/option_gfe.jpg | Bin .../help/GfeServiceBackup}/option_import.jpg | Bin .../GfeServiceBackup}/option_import_gfe.jpg | Bin .../option_import_no_gfe.jpg | Bin .../help/GfeServiceBackup}/option_none.jpg | Bin .../help/GfeServiceBackup}/svcbu_faq.html | 0 .../help/GfeServiceBackup}/svcbu_help.html | 0 .../GfeServiceBackup}/svcbu_instructions.html | 0 .../GfeServiceBackup}/svcbu_multidom.html | 0 .../GfeServiceBackup}/xmessage_faq_01.jpg | Bin .../GfeServiceBackup}/xmessage_faq_02.jpg | Bin .../GfeServiceBackup}/xmessage_faq_03.jpg | Bin .../GfeServiceBackup}/xmessage_faq_04.jpg | Bin .../GfeServiceBackup}/xmessage_faq_05.jpg | Bin .../GfeServiceBackup}/xmessage_faq_06.jpg | Bin .../GfeServiceBackup}/xmessage_faq_07.jpg | Bin .../GfeServiceBackup}/xmessage_faq_08.jpg | Bin .../GfeServiceBackup}/xmessage_faq_09.jpg | Bin .../GfeServiceBackup}/xmessage_faq_10.jpg | Bin .../GfeServiceBackup}/xmessage_faq_11.jpg | Bin .../GfeServiceBackup}/xmessage_faq_12.jpg | Bin .../GfeServiceBackup}/xmessage_faq_13.jpg | Bin .../GfeServiceBackup}/xmessage_faq_14.jpg | Bin .../GfeServiceBackup}/xmessage_faq_15.jpg | Bin .../GfeServiceBackup}/xmessage_faq_16.jpg | Bin .../GfeServiceBackup}/xmessage_faq_17.jpg | Bin .../GfeServiceBackup}/xmessage_faq_18.jpg | Bin .../GfeServiceBackup}/xmessage_faq_19.jpg | Bin .../GfeServiceBackup}/xmessage_faq_20.jpg | Bin .../GfeServiceBackup}/xmessage_faq_21.jpg | Bin .../GfeServiceBackup}/xmessage_faq_22.jpg | Bin .../GfeServiceBackup}/xmessage_faq_23.jpg | Bin .../GfeServiceBackup}/xmessage_faq_24.jpg | Bin .../GfeServiceBackup}/xmessage_faq_25.jpg | Bin .../GfeServiceBackup}/xmessage_faq_26.jpg | Bin .../GfeServiceBackup}/xmessage_faq_27.jpg | Bin .../GfeServiceBackup}/xmessage_faq_28.jpg | Bin .../GfeServiceBackup}/xmessage_faq_29.jpg | Bin .../GfeServiceBackup}/xmessage_faq_30.jpg | Bin .../GfeServiceBackup}/xmessage_faq_31.jpg | Bin .../GfeServiceBackup}/xmessage_faq_32.jpg | Bin .../GfeServiceBackup}/xmessage_faq_33.jpg | Bin .../GfeServiceBackup}/xmessage_faq_34.jpg | Bin .../GfeServiceBackup}/xmessage_faq_35.jpg | Bin .../GfeServiceBackup}/xmessage_faq_36.jpg | Bin .../GfeServiceBackup}/xmessage_faq_37.jpg | Bin .../GfeServiceBackup}/xmessage_faq_38.jpg | Bin .../GfeServiceBackup}/xmessage_faq_39.jpg | Bin .../GfeServiceBackup}/xmessage_faq_40.jpg | Bin .../GfeServiceBackup}/xmessage_faq_41.jpg | Bin .../GfeServiceBackup}/xmessage_faq_42.jpg | Bin .../GfeServiceBackup}/xmessage_faq_43.jpg | Bin .../GfeServiceBackup}/xmessage_faq_44.jpg | Bin .../GfeServiceBackup}/xmessage_faq_45.jpg | Bin .../GfeServiceBackup}/xmessage_faq_46.jpg | Bin .../GfeServiceBackup}/xmessage_faq_47.jpg | Bin .../GfeServiceBackup}/xmessage_faq_48.jpg | Bin .../GfeServiceBackup}/xmessage_faq_49.jpg | Bin .../GfeServiceBackup}/xmessage_faq_50.jpg | Bin .../GfeServiceBackup}/xmessage_faq_51.jpg | Bin .../GfeServiceBackup}/xmessage_faq_52.jpg | Bin .../GfeServiceBackup}/xmessage_faq_53.jpg | Bin .../GfeServiceBackup}/xmessage_faq_54.jpg | Bin .../GfeServiceBackup}/xmessage_faq_55.jpg | Bin .../GfeServiceBackup}/xmessage_faq_56.jpg | Bin .../GfeServiceBackup}/xmessage_faq_57.jpg | Bin .../GfeServiceBackup}/xmessage_faq_58.jpg | Bin .../GfeServiceBackup}/xmessage_faq_59.jpg | Bin .../GfeServiceBackup}/xmessage_faq_60.jpg | Bin .../GfeServiceBackup}/xmessage_faq_61.jpg | Bin .../GfeServiceBackup}/xmessage_faq_62.jpg | Bin .../GfeServiceBackup}/xmessage_faq_63.jpg | Bin .../GfeServiceBackup}/xmessage_faq_64.jpg | Bin .../GfeServiceBackup}/xmessage_faq_65.jpg | Bin .../GfeServiceBackup}/xmessage_faq_66.jpg | Bin .../GfeServiceBackup}/xmessage_faq_67.jpg | Bin .../GfeServiceBackup}/xmessage_faq_68.jpg | Bin .../GfeServiceBackup}/xmessage_faq_69.gif | Bin .../GfeServiceBackup}/xmessage_faq_70.gif | Bin .../GfeServiceBackup}/xmessage_faq_71.gif | Bin .../GfeServiceBackup}/xmessage_faq_72.gif | Bin .../GfeServiceBackup}/xmessage_faq_73.gif | Bin .../GfeServiceBackup}/xmessage_faq_74.gif | Bin .../GfeServiceBackup}/xmessage_faq_75.gif | Bin .../GfeServiceBackup}/xmessage_faq_76.gif | Bin .../GfeServiceBackup}/xmessage_faq_77.gif | Bin .../GfeServiceBackup}/xmessage_faq_78.gif | Bin .../GfeServiceBackup}/xmessage_faq_79.gif | Bin .../GfeServiceBackup}/xmessage_faq_80.gif | Bin .../GfeServiceBackup}/xmessage_faq_81.gif | Bin .../GfeServiceBackup}/xmessage_faq_82.gif | Bin .../GfeServiceBackup}/xmessage_inst_01.jpg | Bin .../GfeServiceBackup}/xmessage_inst_02.jpg | Bin .../GfeServiceBackup}/xmessage_inst_03.jpg | Bin .../GfeServiceBackup}/xmessage_inst_04.jpg | Bin .../xmessage_multidom_01.jpg | Bin .../xmessage_multidom_02.jpg | Bin .../xmessage_multidom_03.jpg | Bin .../xmessage_multidom_04.jpg | Bin .../xmessage_multidom_05.jpg | Bin .../xmessage_multidom_06.jpg | Bin .../viz/gfe/dialogs/sbu/ServiceBackupDlg.java | 56 +- .../esb/conf/res/response-ngats.xml | 28 - edexOsgi/build.edex/esb/conf/wrapper.conf | 4 - .../esb/webapps/admin/META-INF/LICENSE | 1026 ---- .../esb/webapps/admin/META-INF/NOTICE | 107 - .../esb/webapps/admin/WEB-INF/decorators.xml | 49 - .../admin/WEB-INF/dispatcher-servlet.xml | 80 - .../admin/WEB-INF/jspf/headertags.jspf | 21 - .../esb/webapps/admin/WEB-INF/jspf/old.jspf | 21 - .../admin/WEB-INF/tags/form/checkbox.tag | 18 - .../WEB-INF/tags/form/forEachMapEntry.tag | 29 - .../admin/WEB-INF/tags/form/option.tag | 20 - .../webapps/admin/WEB-INF/tags/form/short.tag | 27 - .../webapps/admin/WEB-INF/tags/form/text.tag | 28 - .../admin/WEB-INF/tags/form/tooltip.tag | 29 - .../webapps/admin/WEB-INF/tags/form/uri.tag | 18 - .../admin/WEB-INF/tags/jms/forEachMessage.tag | 34 - .../WEB-INF/tags/jms/formatTimestamp.tag | 29 - .../admin/WEB-INF/tags/jms/persistent.tag | 27 - .../esb/webapps/admin/WEB-INF/web.xml | 181 - .../admin/WEB-INF/webconsole-default.xml | 45 - .../admin/WEB-INF/webconsole-embedded.xml | 56 - .../webapps/admin/WEB-INF/webconsole-invm.xml | 62 - .../webapps/admin/WEB-INF/webconsole-jndi.xml | 65 - .../admin/WEB-INF/webconsole-properties.xml | 64 - .../build.edex/esb/webapps/admin/browse.jsp | 68 - .../esb/webapps/admin/decorators/main.jsp | 149 - .../esb/webapps/admin/decorators/panel.jsp | 31 - .../webapps/admin/decorators/printable.jsp | 31 - .../build.edex/esb/webapps/admin/graph.jsp | 67 - .../webapps/admin/images/activemq-logo.png | Bin 6819 -> 0 bytes .../esb/webapps/admin/images/asf-logo.png | Bin 4735 -> 0 bytes .../esb/webapps/admin/images/big-bullet.png | Bin 325 -> 0 bytes .../admin/images/black-footer-bottom.png | Bin 265 -> 0 bytes .../admin/images/black-footer-left.png | Bin 433 -> 0 bytes .../admin/images/black-footer-right.png | Bin 473 -> 0 bytes .../webapps/admin/images/bottom-red-bar.png | Bin 282 -> 0 bytes .../esb/webapps/admin/images/checker-bg.png | Bin 25888 -> 0 bytes .../esb/webapps/admin/images/content-left.png | Bin 231 -> 0 bytes .../webapps/admin/images/content-right.png | Bin 249 -> 0 bytes .../esb/webapps/admin/images/feed_atom.png | Bin 1548 -> 0 bytes .../esb/webapps/admin/images/feed_rss.png | Bin 1488 -> 0 bytes .../webapps/admin/images/left-box-bottom.png | Bin 430 -> 0 bytes .../webapps/admin/images/left-box-right.png | Bin 248 -> 0 bytes .../esb/webapps/admin/images/left-box-top.png | Bin 376 -> 0 bytes .../esb/webapps/admin/images/oval-arrow.png | Bin 3878 -> 0 bytes .../webapps/admin/images/right-box-bottom.png | Bin 390 -> 0 bytes .../webapps/admin/images/right-box-left.png | Bin 248 -> 0 bytes .../webapps/admin/images/right-box-top.png | Bin 415 -> 0 bytes .../admin/images/small-bullet-gray.png | Bin 215 -> 0 bytes .../webapps/admin/images/small-bullet-red.png | Bin 215 -> 0 bytes .../esb/webapps/admin/images/spacer.gif | Bin 43 -> 0 bytes .../esb/webapps/admin/images/top-red-bar.png | Bin 233 -> 0 bytes .../admin/images/white-header-left.png | Bin 317 -> 0 bytes .../admin/images/white-header-right.png | Bin 362 -> 0 bytes .../webapps/admin/images/white-header-top.png | Bin 248 -> 0 bytes .../build.edex/esb/webapps/admin/index.jsp | 61 - .../build.edex/esb/webapps/admin/js/common.js | 121 - .../build.edex/esb/webapps/admin/js/css.js | 145 - .../esb/webapps/admin/js/mochi/MochiKit.js | 4804 ----------------- .../esb/webapps/admin/js/mochi/__package__.js | 14 - .../esb/webapps/admin/js/plotkit/Base.js | 332 -- .../esb/webapps/admin/js/plotkit/Canvas.js | 707 --- .../esb/webapps/admin/js/plotkit/Layout.js | 588 -- .../esb/webapps/admin/js/plotkit/SVG.js | 677 --- .../webapps/admin/js/plotkit/SweetCanvas.js | 281 - .../esb/webapps/admin/js/plotkit/SweetSVG.js | 196 - .../esb/webapps/admin/js/plotkit/dummy.svg | 15 - .../esb/webapps/admin/js/plotkit/iecanvas.htc | 389 -- .../admin/js/standardista-table-sorting.js | 428 -- .../build.edex/esb/webapps/admin/message.jsp | 186 - .../esb/webapps/admin/queueGraph.jsp | 68 - .../build.edex/esb/webapps/admin/queues.jsp | 78 - .../build.edex/esb/webapps/admin/send.jsp | 144 - .../esb/webapps/admin/styles/site.css | 206 - .../esb/webapps/admin/styles/sorttable.css | 70 - .../webapps/admin/styles/type-settings.css | 171 - .../esb/webapps/admin/subscribers.jsp | 115 - .../esb/webapps/admin/test/dummy.jsp | 52 - .../esb/webapps/admin/test/index.jsp | 84 - .../webapps/admin/test/systemProperties.jsp | 53 - .../build.edex/esb/webapps/admin/topics.jsp | 65 - .../esb/webapps/admin/xml/queues.jsp | 34 - .../res/NGATS_binding.xsd | 232 - .../res/spring/uengine-request.xml | 50 - .../META-INF/MANIFEST.MF | 13 +- .../NGATS_Schema.xsd | 230 - .../scripts/ObAndTaf.js | 53 - .../scripts/SpatialQueryDemo.js | 106 - .../scripts/applicationExecute.js | 41 - .../scripts/compactBarnesAnalysisWinds.js | 169 - .../compactBarnesTemperatureAnalysis.js | 26 - .../scripts/compactFilteredImage.js | 10 - .../scripts/compactHelloWorld.js | 5 - .../scripts/compactImageFormat.js | 7 - .../scripts/compactStopLightImage.js | 10 - .../scripts/compactWindSpeedImage.js | 110 - .../scripts/compactWindStopLight.js | 14 - .../scripts/helloWorld.js | 26 - .../scripts/makeASCIIandImage.js | 38 - .../scripts/makeBarnesAnalysisWinds.js | 386 -- .../scripts/makeBarnesTemperatureAnalysis.js | 184 - .../scripts/makeFilteredImage.js | 133 - .../scripts/makeStopLightImage.js | 124 - .../scripts/makeWindSpeedImage.js | 261 - .../scripts/makeWindStopLight.js | 155 - .../scripts/sampleVtecEventUpdate.js | 12 - .../scripts/sampleVtecObjectRetrieval.js | 13 - .../scripts/sampleVtecRetrieval.js | 12 - .../scripts/scriptExecute.js | 31 - .../scripts/testMessageFormat.js | 83 - .../com/raytheon/edex/uengine/Activator.java | 41 - .../com/raytheon/edex/uengine/TaskParam.java | 84 - .../edex/uengine/chain/ChainAttributes.java | 138 - .../chain/SpatialChaindataAdapter.java | 529 -- .../edex/uengine/chain/package-info.java | 26 - .../uengine/subscription/Subscription.java | 106 - .../uengine/tasks/process/ExecuteCommand.java | 108 - .../edex/uengine/web/RequestTestDriver.java | 507 -- .../raytheon/edex/uengine/web/RunAction.java | 1609 ------ .../edex/uengine/web/ScriptTestDriver.java | 123 - .../edex/uengine/web/TestDataDriver.java | 161 - .../src/test/JmsEngineTest.java | 184 - .../src/test/ProducerTool.javaorg | 158 - .../src/test/ToolSupport.java | 107 - .../src/test/build.xml | 49 - .../src/test/imageDecodeAction.xml | 17 - .../com.raytheon.edex.uengine/testScript.bat | 12 - edexOsgi/com.raytheon.edex.uengine/web.deploy | 1 - .../web/AsciiInterface.js | 133 - .../web/GridInterface.js | 234 - .../web/HelloWorld.jsp | 61 - .../web/METARandTAF.jsp | 124 - .../web/RadarInterface.js | 178 - .../web/SatelliteInterface.js | 153 - .../web/StringBuffer.js | 12 - .../web/TestDriverUI.js | 13 - .../web/WEB-INF/classes/log4j.properties | 16 - .../web/WEB-INF/dwr.xml | 27 - .../web/WEB-INF/web.xml | 59 - .../web/applicationExecute.jsp | 92 - .../web/asciiDemoUnsubscribe.jsp | 81 - .../web/compactBarnesAnalysisWinds.jsp | 249 - .../web/compactBarnesTemperature.jsp | 100 - .../web/compactFilteredImage.jsp | 85 - .../web/compactMessageFormat.jsp | 78 - .../web/compactSpatialQuery.jsp | 82 - .../web/compactStopLightImage.jsp | 86 - .../web/compactStopLightWinds.jsp | 91 - .../web/compactWindSpeedImage.jsp | 188 - .../web/dataPurge/dataPurge.html | 132 - .../com.raytheon.edex.uengine/web/expand.gif | Bin 870 -> 0 bytes .../web/getASCII.jsp | 89 - .../web/goesDemoSubscribe.jsp | 148 - .../web/goesDemoUnsubscribe.jsp | 72 - .../web/gribDemoUnsubscribe.jsp | 72 - .../com.raytheon.edex.uengine/web/hide.gif | Bin 868 -> 0 bytes .../com.raytheon.edex.uengine/web/index.html | 457 -- .../com.raytheon.edex.uengine/web/index.jsp | 194 - .../web/jsGetVTECAction.jsp | 82 - .../web/jsGetVTECActionNew.jsp | 83 - .../web/jsRunScript.jsp | 70 - .../web/jsUnsubscribe.jsp | 63 - .../web/jsVTECEventQuery.jsp | 100 - .../web/jsVTECEventUpdate.jsp | 103 - .../web/makeASCIIandImage.jsp | 116 - .../web/makeBarnesAnalysisWinds.jsp | 466 -- .../web/makeBarnesTemperature.jsp | 263 - .../web/makeEventUpdate.jsp | 90 - .../web/makeFilteredImage.jsp | 204 - .../web/makeHelloWorld.jsp | 114 - .../web/makeSpatialQuery.jsp | 165 - .../web/makeStopLightImage.jsp | 200 - .../web/makeStopLightWinds.jsp | 223 - .../web/makeWindSpeedImage.jsp | 336 -- .../web/radarSubscribe.jsp | 151 - .../web/radarUnsubscribe.jsp | 84 - .../web/rayAWIPS.jpg | Bin 5217 -> 0 bytes .../web/scriptExecute.jsp | 92 - .../web/simpleGrib.jsp | 174 - edexOsgi/com.raytheon.edex.uengine/web/td.css | 51 - .../web/templates/VM_global_library.vm | 204 - .../web/templates/standardTemplate.vm | 18 - .../web/testDriverControls.js | 347 -- .../web/testMessageFormat.jsp | 152 - 315 files changed, 27 insertions(+), 26278 deletions(-) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/INSTRUCTIONS (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/banner_exprtGrdMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/banner_exprtMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/banner_exprtbksiteGrdMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/banner_exprtbksiteGrdToCSMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/banner_ghgMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/banner_imprtGrdMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/banner_imprtMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/banner_no_backup.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/banner_svcbuMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/banner_waitMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/choose_domain.jpg (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/choose_domain_multi1.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/choose_domain_multi2.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/clean_up.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/do_not_cancel.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/failed_site.jpg (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/gfe_startup.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/multi_exprtGrdMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/multi_exprtMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/multi_exprtbksiteGrdMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/multi_exprtbksiteGrdToCSMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/multi_ghgMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/multi_imprtGrdMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/multi_imprtMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/multi_no_backup.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/multi_svcbuMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/multi_waitMode.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/option_both.jpg (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/option_gfe.jpg (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/option_import.jpg (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/option_import_gfe.jpg (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/option_import_no_gfe.jpg (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/option_none.jpg (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/svcbu_faq.html (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/svcbu_help.html (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/svcbu_instructions.html (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/svcbu_multidom.html (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_01.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_02.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_03.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_04.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_05.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_06.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_07.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_08.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_09.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_10.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_11.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_12.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_13.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_14.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_15.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_16.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_17.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_18.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_19.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_20.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_21.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_22.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_23.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_24.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_25.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_26.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_27.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_28.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_29.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_30.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_31.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_32.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_33.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_34.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_35.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_36.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_37.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_38.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_39.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_40.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_41.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_42.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_43.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_44.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_45.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_46.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_47.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_48.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_49.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_50.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_51.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_52.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_53.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_54.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_55.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_56.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_57.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_58.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_59.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_60.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_61.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_62.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_63.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_64.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_65.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_66.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_67.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_68.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_69.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_70.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_71.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_72.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_73.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_74.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_75.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_76.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_77.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_78.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_79.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_80.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_81.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_faq_82.gif (100%) mode change 100755 => 100644 rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_inst_01.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_inst_02.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_inst_03.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_inst_04.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_multidom_01.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_multidom_02.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_multidom_03.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_multidom_04.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_multidom_05.jpg (100%) rename {edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help => cave/com.raytheon.viz.gfe/help/GfeServiceBackup}/xmessage_multidom_06.jpg (100%) delete mode 100755 edexOsgi/build.edex/esb/conf/res/response-ngats.xml delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/META-INF/LICENSE delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/META-INF/NOTICE delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/decorators.xml delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/dispatcher-servlet.xml delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/jspf/headertags.jspf delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/jspf/old.jspf delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/checkbox.tag delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/forEachMapEntry.tag delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/option.tag delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/short.tag delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/text.tag delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/tooltip.tag delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/uri.tag delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/jms/forEachMessage.tag delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/jms/formatTimestamp.tag delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/jms/persistent.tag delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/web.xml delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-default.xml delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-embedded.xml delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-invm.xml delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-jndi.xml delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-properties.xml delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/browse.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/decorators/main.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/decorators/panel.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/decorators/printable.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/graph.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/activemq-logo.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/asf-logo.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/big-bullet.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/black-footer-bottom.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/black-footer-left.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/black-footer-right.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/bottom-red-bar.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/checker-bg.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/content-left.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/content-right.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/feed_atom.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/feed_rss.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/left-box-bottom.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/left-box-right.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/left-box-top.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/oval-arrow.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/right-box-bottom.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/right-box-left.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/right-box-top.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/small-bullet-gray.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/small-bullet-red.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/spacer.gif delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/top-red-bar.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/white-header-left.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/white-header-right.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/images/white-header-top.png delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/index.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/js/common.js delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/js/css.js delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/js/mochi/MochiKit.js delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/js/mochi/__package__.js delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/js/plotkit/Base.js delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/js/plotkit/Canvas.js delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/js/plotkit/Layout.js delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/js/plotkit/SVG.js delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/js/plotkit/SweetCanvas.js delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/js/plotkit/SweetSVG.js delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/js/plotkit/dummy.svg delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/js/plotkit/iecanvas.htc delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/js/standardista-table-sorting.js delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/message.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/queueGraph.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/queues.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/send.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/styles/site.css delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/styles/sorttable.css delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/styles/type-settings.css delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/subscribers.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/test/dummy.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/test/index.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/test/systemProperties.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/topics.jsp delete mode 100644 edexOsgi/build.edex/esb/webapps/admin/xml/queues.jsp delete mode 100644 edexOsgi/com.raytheon.edex.common/res/NGATS_binding.xsd delete mode 100644 edexOsgi/com.raytheon.edex.uengine/NGATS_Schema.xsd delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/ObAndTaf.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/SpatialQueryDemo.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/applicationExecute.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/compactBarnesAnalysisWinds.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/compactBarnesTemperatureAnalysis.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/compactFilteredImage.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/compactHelloWorld.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/compactImageFormat.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/compactStopLightImage.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/compactWindSpeedImage.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/compactWindStopLight.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/helloWorld.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/makeASCIIandImage.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/makeBarnesAnalysisWinds.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/makeBarnesTemperatureAnalysis.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/makeFilteredImage.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/makeStopLightImage.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/makeWindSpeedImage.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/makeWindStopLight.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/sampleVtecEventUpdate.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/sampleVtecObjectRetrieval.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/sampleVtecRetrieval.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/scriptExecute.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/scripts/testMessageFormat.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/Activator.java delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/TaskParam.java delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/chain/ChainAttributes.java delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/chain/SpatialChaindataAdapter.java delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/chain/package-info.java delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/subscription/Subscription.java delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/tasks/process/ExecuteCommand.java delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/RequestTestDriver.java delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/RunAction.java delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/ScriptTestDriver.java delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/TestDataDriver.java delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/test/JmsEngineTest.java delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/test/ProducerTool.javaorg delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/test/ToolSupport.java delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/test/build.xml delete mode 100644 edexOsgi/com.raytheon.edex.uengine/src/test/imageDecodeAction.xml delete mode 100644 edexOsgi/com.raytheon.edex.uengine/testScript.bat delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web.deploy delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/AsciiInterface.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/GridInterface.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/HelloWorld.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/METARandTAF.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/RadarInterface.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/SatelliteInterface.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/StringBuffer.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/TestDriverUI.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/WEB-INF/classes/log4j.properties delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/WEB-INF/dwr.xml delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/WEB-INF/web.xml delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/applicationExecute.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/asciiDemoUnsubscribe.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/compactBarnesAnalysisWinds.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/compactBarnesTemperature.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/compactFilteredImage.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/compactMessageFormat.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/compactSpatialQuery.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/compactStopLightImage.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/compactStopLightWinds.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/compactWindSpeedImage.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/dataPurge/dataPurge.html delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/expand.gif delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/getASCII.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/goesDemoSubscribe.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/goesDemoUnsubscribe.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/gribDemoUnsubscribe.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/hide.gif delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/index.html delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/index.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/jsGetVTECAction.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/jsGetVTECActionNew.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/jsRunScript.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/jsUnsubscribe.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/jsVTECEventQuery.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/jsVTECEventUpdate.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/makeASCIIandImage.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/makeBarnesAnalysisWinds.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/makeBarnesTemperature.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/makeEventUpdate.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/makeFilteredImage.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/makeHelloWorld.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/makeSpatialQuery.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/makeStopLightImage.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/makeStopLightWinds.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/makeWindSpeedImage.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/radarSubscribe.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/radarUnsubscribe.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/rayAWIPS.jpg delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/scriptExecute.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/simpleGrib.jsp delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/td.css delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/templates/VM_global_library.vm delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/templates/standardTemplate.vm delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/testDriverControls.js delete mode 100644 edexOsgi/com.raytheon.edex.uengine/web/testMessageFormat.jsp diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/INSTRUCTIONS b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/INSTRUCTIONS similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/INSTRUCTIONS rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/INSTRUCTIONS diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_exprtGrdMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_exprtGrdMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_exprtGrdMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_exprtGrdMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_exprtMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_exprtMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_exprtMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_exprtMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_exprtbksiteGrdMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_exprtbksiteGrdMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_exprtbksiteGrdMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_exprtbksiteGrdMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_exprtbksiteGrdToCSMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_exprtbksiteGrdToCSMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_exprtbksiteGrdToCSMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_exprtbksiteGrdToCSMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_ghgMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_ghgMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_ghgMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_ghgMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_imprtGrdMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_imprtGrdMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_imprtGrdMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_imprtGrdMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_imprtMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_imprtMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_imprtMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_imprtMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_no_backup.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_no_backup.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_no_backup.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_no_backup.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_svcbuMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_svcbuMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_svcbuMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_svcbuMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_waitMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_waitMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/banner_waitMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/banner_waitMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/choose_domain.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/choose_domain.jpg old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/choose_domain.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/choose_domain.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/choose_domain_multi1.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/choose_domain_multi1.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/choose_domain_multi1.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/choose_domain_multi1.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/choose_domain_multi2.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/choose_domain_multi2.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/choose_domain_multi2.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/choose_domain_multi2.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/clean_up.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/clean_up.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/clean_up.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/clean_up.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/do_not_cancel.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/do_not_cancel.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/do_not_cancel.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/do_not_cancel.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/failed_site.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/failed_site.jpg old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/failed_site.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/failed_site.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/gfe_startup.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/gfe_startup.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/gfe_startup.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/gfe_startup.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_exprtGrdMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_exprtGrdMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_exprtGrdMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_exprtGrdMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_exprtMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_exprtMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_exprtMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_exprtMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_exprtbksiteGrdMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_exprtbksiteGrdMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_exprtbksiteGrdMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_exprtbksiteGrdMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_exprtbksiteGrdToCSMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_exprtbksiteGrdToCSMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_exprtbksiteGrdToCSMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_exprtbksiteGrdToCSMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_ghgMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_ghgMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_ghgMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_ghgMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_imprtGrdMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_imprtGrdMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_imprtGrdMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_imprtGrdMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_imprtMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_imprtMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_imprtMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_imprtMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_no_backup.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_no_backup.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_no_backup.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_no_backup.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_svcbuMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_svcbuMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_svcbuMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_svcbuMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_waitMode.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_waitMode.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/multi_waitMode.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/multi_waitMode.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/option_both.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/option_both.jpg old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/option_both.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/option_both.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/option_gfe.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/option_gfe.jpg old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/option_gfe.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/option_gfe.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/option_import.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/option_import.jpg old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/option_import.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/option_import.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/option_import_gfe.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/option_import_gfe.jpg old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/option_import_gfe.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/option_import_gfe.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/option_import_no_gfe.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/option_import_no_gfe.jpg old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/option_import_no_gfe.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/option_import_no_gfe.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/option_none.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/option_none.jpg old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/option_none.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/option_none.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/svcbu_faq.html b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/svcbu_faq.html old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/svcbu_faq.html rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/svcbu_faq.html diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/svcbu_help.html b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/svcbu_help.html old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/svcbu_help.html rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/svcbu_help.html diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/svcbu_instructions.html b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/svcbu_instructions.html old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/svcbu_instructions.html rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/svcbu_instructions.html diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/svcbu_multidom.html b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/svcbu_multidom.html old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/svcbu_multidom.html rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/svcbu_multidom.html diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_01.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_01.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_01.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_01.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_02.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_02.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_02.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_02.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_03.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_03.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_03.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_03.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_04.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_04.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_04.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_04.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_05.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_05.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_05.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_05.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_06.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_06.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_06.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_06.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_07.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_07.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_07.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_07.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_08.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_08.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_08.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_08.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_09.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_09.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_09.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_09.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_10.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_10.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_10.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_10.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_11.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_11.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_11.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_11.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_12.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_12.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_12.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_12.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_13.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_13.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_13.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_13.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_14.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_14.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_14.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_14.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_15.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_15.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_15.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_15.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_16.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_16.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_16.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_16.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_17.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_17.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_17.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_17.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_18.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_18.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_18.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_18.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_19.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_19.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_19.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_19.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_20.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_20.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_20.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_20.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_21.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_21.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_21.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_21.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_22.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_22.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_22.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_22.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_23.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_23.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_23.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_23.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_24.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_24.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_24.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_24.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_25.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_25.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_25.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_25.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_26.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_26.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_26.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_26.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_27.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_27.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_27.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_27.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_28.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_28.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_28.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_28.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_29.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_29.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_29.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_29.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_30.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_30.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_30.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_30.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_31.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_31.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_31.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_31.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_32.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_32.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_32.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_32.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_33.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_33.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_33.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_33.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_34.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_34.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_34.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_34.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_35.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_35.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_35.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_35.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_36.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_36.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_36.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_36.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_37.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_37.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_37.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_37.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_38.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_38.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_38.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_38.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_39.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_39.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_39.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_39.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_40.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_40.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_40.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_40.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_41.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_41.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_41.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_41.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_42.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_42.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_42.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_42.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_43.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_43.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_43.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_43.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_44.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_44.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_44.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_44.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_45.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_45.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_45.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_45.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_46.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_46.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_46.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_46.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_47.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_47.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_47.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_47.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_48.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_48.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_48.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_48.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_49.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_49.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_49.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_49.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_50.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_50.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_50.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_50.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_51.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_51.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_51.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_51.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_52.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_52.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_52.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_52.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_53.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_53.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_53.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_53.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_54.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_54.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_54.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_54.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_55.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_55.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_55.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_55.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_56.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_56.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_56.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_56.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_57.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_57.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_57.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_57.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_58.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_58.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_58.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_58.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_59.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_59.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_59.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_59.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_60.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_60.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_60.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_60.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_61.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_61.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_61.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_61.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_62.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_62.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_62.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_62.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_63.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_63.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_63.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_63.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_64.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_64.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_64.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_64.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_65.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_65.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_65.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_65.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_66.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_66.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_66.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_66.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_67.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_67.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_67.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_67.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_68.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_68.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_68.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_68.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_69.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_69.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_69.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_69.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_70.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_70.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_70.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_70.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_71.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_71.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_71.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_71.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_72.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_72.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_72.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_72.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_73.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_73.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_73.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_73.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_74.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_74.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_74.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_74.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_75.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_75.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_75.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_75.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_76.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_76.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_76.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_76.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_77.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_77.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_77.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_77.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_78.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_78.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_78.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_78.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_79.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_79.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_79.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_79.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_80.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_80.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_80.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_80.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_81.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_81.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_81.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_81.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_82.gif b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_82.gif old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_faq_82.gif rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_faq_82.gif diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_inst_01.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_inst_01.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_inst_01.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_inst_01.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_inst_02.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_inst_02.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_inst_02.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_inst_02.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_inst_03.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_inst_03.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_inst_03.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_inst_03.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_inst_04.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_inst_04.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_inst_04.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_inst_04.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_multidom_01.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_multidom_01.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_multidom_01.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_multidom_01.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_multidom_02.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_multidom_02.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_multidom_02.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_multidom_02.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_multidom_03.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_multidom_03.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_multidom_03.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_multidom_03.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_multidom_04.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_multidom_04.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_multidom_04.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_multidom_04.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_multidom_05.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_multidom_05.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_multidom_05.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_multidom_05.jpg diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_multidom_06.jpg b/cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_multidom_06.jpg similarity index 100% rename from edexOsgi/com.raytheon.edex.uengine/web/GfeServiceBackup/help/xmessage_multidom_06.jpg rename to cave/com.raytheon.viz.gfe/help/GfeServiceBackup/xmessage_multidom_06.jpg diff --git a/cave/com.raytheon.viz.gfe/src/com/raytheon/viz/gfe/dialogs/sbu/ServiceBackupDlg.java b/cave/com.raytheon.viz.gfe/src/com/raytheon/viz/gfe/dialogs/sbu/ServiceBackupDlg.java index e5c4cdc731..a417cb2c2a 100644 --- a/cave/com.raytheon.viz.gfe/src/com/raytheon/viz/gfe/dialogs/sbu/ServiceBackupDlg.java +++ b/cave/com.raytheon.viz.gfe/src/com/raytheon/viz/gfe/dialogs/sbu/ServiceBackupDlg.java @@ -19,8 +19,11 @@ **/ package com.raytheon.viz.gfe.dialogs.sbu; +import java.io.FileNotFoundException; +import java.net.URL; import java.util.List; +import org.eclipse.core.runtime.FileLocator; import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.core.runtime.IStatus; import org.eclipse.core.runtime.Status; @@ -48,10 +51,10 @@ import org.eclipse.swt.widgets.Menu; import org.eclipse.swt.widgets.MenuItem; import org.eclipse.swt.widgets.MessageBox; import org.eclipse.swt.widgets.Shell; +import org.osgi.framework.Bundle; import com.raytheon.uf.common.dataplugin.gfe.request.GetKnownSitesRequest; import com.raytheon.uf.common.dataplugin.gfe.request.GetSbLockFilesRequest; -import com.raytheon.uf.common.dataplugin.gfe.request.GetServiceBackupServerRequest; import com.raytheon.uf.common.dataplugin.gfe.server.message.ServerResponse; import com.raytheon.uf.common.site.requests.GetActiveSitesRequest; import com.raytheon.uf.common.status.IUFStatusHandler; @@ -63,6 +66,7 @@ import com.raytheon.uf.viz.core.auth.UserController; import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.uf.viz.core.localization.LocalizationManager; import com.raytheon.uf.viz.core.requests.ThriftClient; +import com.raytheon.viz.gfe.Activator; import com.raytheon.viz.gfe.dialogs.sbu.jobs.ServiceBackupJobManager; import com.raytheon.viz.gfe.dialogs.sbu.jobs.SvcbuActivateSiteJob; import com.raytheon.viz.gfe.dialogs.sbu.jobs.SvcbuCleanupJob; @@ -94,6 +98,7 @@ import com.raytheon.viz.ui.dialogs.CaveJFACEDialog; * from A1 DR 21404, some code cleanup. * May 01, 2013 1762 dgilling Remove national center check. * Jul 22, 2013 1762 dgilling Fix running as primary check. + * Apr 14, 2014 2984 njensen Moved help files to viz.gfe plugin * * * @@ -342,12 +347,7 @@ public class ServiceBackupDlg extends CaveJFACEDialog { helpItem.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent e) { - final String url = "http://" - + getServiceBackupServer() - + ":8080/uEngineWeb/GfeServiceBackup/help/svcbu_help.html"; - if (!Program.launch(url)) { - statusHandler.error("Unable to open Help page: " + url); - } + openHelp("help/GfeServiceBackup/svcbu_help.html"); } }); @@ -356,13 +356,7 @@ public class ServiceBackupDlg extends CaveJFACEDialog { instructionsItem.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent e) { - final String url = "http://" - + getServiceBackupServer() - + ":8080/uEngineWeb/GfeServiceBackup/help/svcbu_instructions.html"; - if (!Program.launch(url)) { - statusHandler.error("Unable to open Instructions page: " - + url); - } + openHelp("help/GfeServiceBackup/svcbu_instructions.html"); } }); @@ -371,12 +365,7 @@ public class ServiceBackupDlg extends CaveJFACEDialog { faqItem.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent e) { - final String url = "http://" - + getServiceBackupServer() - + ":8080/uEngineWeb/GfeServiceBackup/help/svcbu_faq.html"; - if (!Program.launch(url)) { - statusHandler.error("Unable to open FAQ page: " + url); - } + openHelp("help/GfeServiceBackup/svcbu_faq.html"); } }); @@ -1207,19 +1196,22 @@ public class ServiceBackupDlg extends CaveJFACEDialog { this.getShell().pack(true); } - private String getServiceBackupServer() { - GetServiceBackupServerRequest request = new GetServiceBackupServerRequest(); - try { - String obj = (String) ThriftClient.sendRequest(request); - return obj; - } catch (VizException e) { - statusHandler.handle(Priority.PROBLEM, - "Error processing get service backup server request", e); - } - return "dx3"; - } - private void displayMessage(String msg) { MessageDialog.openWarning(getShell(), "Warning", msg); } + + private void openHelp(String helpPath) { + try { + Bundle bundle = Activator.getDefault().getBundle(); + URL url = bundle.getEntry(helpPath); + if (url == null) { + throw new FileNotFoundException(helpPath); + } + url = FileLocator.toFileURL(url); + Program.launch(url.toString()); + } catch (Exception e) { + statusHandler.handle(Priority.PROBLEM, "Error loading help " + + helpPath, e); + } + } } diff --git a/edexOsgi/build.edex/esb/conf/res/response-ngats.xml b/edexOsgi/build.edex/esb/conf/res/response-ngats.xml deleted file mode 100755 index 374b50058a..0000000000 --- a/edexOsgi/build.edex/esb/conf/res/response-ngats.xml +++ /dev/null @@ -1,28 +0,0 @@ - - - - - - - - RESP_NGATS - com.raytheon.edex.uengine.tasks.response.MakeResponseNGATS - diff --git a/edexOsgi/build.edex/esb/conf/wrapper.conf b/edexOsgi/build.edex/esb/conf/wrapper.conf index a42d5cf480..a66a88932d 100644 --- a/edexOsgi/build.edex/esb/conf/wrapper.conf +++ b/edexOsgi/build.edex/esb/conf/wrapper.conf @@ -135,10 +135,6 @@ wrapper.java.additional.log.4=-Dcom.mchange.v2.log.FallbackMLog.DEFAULT_CUTOFF_L # to get java.util.logging to go into slf4j....don't use java.util.logging, this is only for open src plugins using it wrapper.java.additional.log.5=-Djava.util.logging.config.file=${EDEX_HOME}/conf/logging.properties -# used by uengineWeb page -wrapper.java.additional.web.1=-Dweb.port=8080 -wrapper.java.additional.web.2=-Dconfidential.port=8443 - # the max size in MB of any stream sent to thrift, this prevents the OutOfMemory # errors reported by thrift sometimes when the stream is corrupt/incorrect wrapper.java.additional.thrift.maxStreamSize=-Dthrift.stream.maxsize=200 diff --git a/edexOsgi/build.edex/esb/webapps/admin/META-INF/LICENSE b/edexOsgi/build.edex/esb/webapps/admin/META-INF/LICENSE deleted file mode 100644 index 8731741981..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/META-INF/LICENSE +++ /dev/null @@ -1,1026 +0,0 @@ - - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - -========================================================================= -== For the MochiKit library == -========================================================================= - -MochiKit is dual-licensed software. It is available under the terms of the -MIT License, or the Academic Free License version 2.1. The full text of -each license is included below. - -MIT License -=========== - -Copyright (c) 2005 Bob Ippolito. All rights reserved. - -Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - - -Academic Free License v. 2.1 -============================ - -Copyright (c) 2005 Bob Ippolito. All rights reserved. - -This Academic Free License (the "License") applies to any original work of authorship (the "Original Work") whose owner (the "Licensor") has placed the following notice immediately following the copyright notice for the Original Work: - -Licensed under the Academic Free License version 2.1 - -1) Grant of Copyright License. Licensor hereby grants You a world-wide, royalty-free, non-exclusive, perpetual, sublicenseable license to do the following: - -a) to reproduce the Original Work in copies; - -b) to prepare derivative works ("Derivative Works") based upon the Original Work; - -c) to distribute copies of the Original Work and Derivative Works to the public; - -d) to perform the Original Work publicly; and - -e) to display the Original Work publicly. - -2) Grant of Patent License. Licensor hereby grants You a world-wide, royalty-free, non-exclusive, perpetual, sublicenseable license, under patent claims owned or controlled by the Licensor that are embodied in the Original Work as furnished by the Licensor, to make, use, sell and offer for sale the Original Work and Derivative Works. - -3) Grant of Source Code License. The term "Source Code" means the preferred form of the Original Work for making modifications to it and all available documentation describing how to modify the Original Work. Licensor hereby agrees to provide a machine-readable copy of the Source Code of the Original Work along with each copy of the Original Work that Licensor distributes. Licensor reserves the right to satisfy this obligation by placing a machine-readable copy of the Source Code in an information repository reasonably calculated to permit inexpensive and convenient access by You for as long as Licensor continues to distribute the Original Work, and by publishing the address of that information repository in a notice immediately following the copyright notice that applies to the Original Work. - -4) Exclusions From License Grant. Neither the names of Licensor, nor the names of any contributors to the Original Work, nor any of their trademarks or service marks, may be used to endorse or promote products derived from this Original Work without express prior written permission of the Licensor. Nothing in this License shall be deemed to grant any rights to trademarks, copyrights, patents, trade secrets or any other intellectual property of Licensor except as expressly stated herein. No patent license is granted to make, use, sell or offer to sell embodiments of any patent claims other than the licensed claims defined in Section 2. No right is granted to the trademarks of Licensor even if such marks are included in the Original Work. Nothing in this License shall be interpreted to prohibit Licensor from licensing under different terms from this License any Original Work that Licensor otherwise would have a right to license. - -5) This section intentionally omitted. - -6) Attribution Rights. You must retain, in the Source Code of any Derivative Works that You create, all copyright, patent or trademark notices from the Source Code of the Original Work, as well as any notices of licensing and any descriptive text identified therein as an "Attribution Notice." You must cause the Source Code for any Derivative Works that You create to carry a prominent Attribution Notice reasonably calculated to inform recipients that You have modified the Original Work. - -7) Warranty of Provenance and Disclaimer of Warranty. Licensor warrants that the copyright in and to the Original Work and the patent rights granted herein by Licensor are owned by the Licensor or are sublicensed to You under the terms of this License with the permission of the contributor(s) of those copyrights and patent rights. Except as expressly stated in the immediately proceeding sentence, the Original Work is provided under this License on an "AS IS" BASIS and WITHOUT WARRANTY, either express or implied, including, without limitation, the warranties of NON-INFRINGEMENT, MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY OF THE ORIGINAL WORK IS WITH YOU. This DISCLAIMER OF WARRANTY constitutes an essential part of this License. No license to Original Work is granted hereunder except under this disclaimer. - -8) Limitation of Liability. Under no circumstances and under no legal theory, whether in tort (including negligence), contract, or otherwise, shall the Licensor be liable to any person for any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or the use of the Original Work including, without limitation, damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses. This limitation of liability shall not apply to liability for death or personal injury resulting from Licensor's negligence to the extent applicable law prohibits such limitation. Some jurisdictions do not allow the exclusion or limitation of incidental or consequential damages, so this exclusion and limitation may not apply to You. - -9) Acceptance and Termination. If You distribute copies of the Original Work or a Derivative Work, You must make a reasonable effort under the circumstances to obtain the express assent of recipients to the terms of this License. Nothing else but this License (or another written agreement between Licensor and You) grants You permission to create Derivative Works based upon the Original Work or to exercise any of the rights granted in Section 1 herein, and any attempt to do so except under the terms of this License (or another written agreement between Licensor and You) is expressly prohibited by U.S. copyright law, the equivalent laws of other countries, and by international treaty. Therefore, by exercising any of the rights granted to You in Section 1 herein, You indicate Your acceptance of this License and all of its terms and conditions. - -10) Termination for Patent Action. This License shall terminate automatically and You may no longer exercise any of the rights granted to You by this License as of the date You commence an action, including a cross-claim or counterclaim, against Licensor or any licensee alleging that the Original Work infringes a patent. This termination provision shall not apply for an action alleging patent infringement by combinations of the Original Work with other software or hardware. - -11) Jurisdiction, Venue and Governing Law. Any action or suit relating to this License may be brought only in the courts of a jurisdiction wherein the Licensor resides or in which Licensor conducts its primary business, and under the laws of that jurisdiction excluding its conflict-of-law provisions. The application of the United Nations Convention on Contracts for the International Sale of Goods is expressly excluded. Any use of the Original Work outside the scope of this License or after its termination shall be subject to the requirements and penalties of the U.S. Copyright Act, 17 U.S.C. § 101 et seq., the equivalent laws of other countries, and international treaty. This section shall survive the termination of this License. - -12) Attorneys Fees. In any action to enforce the terms of this License or seeking damages relating thereto, the prevailing party shall be entitled to recover its costs and expenses, including, without limitation, reasonable attorneys' fees and costs incurred in connection with such action, including any appeal of such action. This section shall survive the termination of this License. - -13) Miscellaneous. This License represents the complete agreement concerning the subject matter hereof. If any provision of this License is held to be unenforceable, such provision shall be reformed only to the extent necessary to make it enforceable. - -14) Definition of "You" in This License. "You" throughout this License, whether in upper or lower case, means an individual or a legal entity exercising rights under, and complying with all of the terms of, this License. For legal entities, "You" includes any entity that controls, is controlled by, or is under common control with you. For purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. - -15) Right to Use. You may use the Original Work in all ways not otherwise restricted or conditioned by this License or by law, and Licensor promises not to interfere with or be responsible for such uses by You. - -This license is Copyright (C) 2003-2004 Lawrence E. Rosen. All rights reserved. Permission is hereby granted to copy and distribute this license without modification. This license may not be modified without the express written permission of its copyright owner. - -========================================================================= -== For the Plotkit library == -========================================================================= - -Copyright (c) 2006, Alastair Tse -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are -met: - - * Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above - copyright notice, this list of conditions and the following - disclaimer in the documentation and/or other materials provided - with the distribution. - * Neither the name of the Alastair Tse nor the names of its - contributors may be used to endorse or promote products derived - from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -========================================================================= -== For the behaviour.js library == -========================================================================= - -Copyright (c) 2005, Ben Nolan -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are -met: - - * Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above - copyright notice, this list of conditions and the following - disclaimer in the documentation and/or other materials provided - with the distribution. - * Neither the name of the Ben Nolan nor the names of its - contributors may be used to endorse or promote products derived - from this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -========================================================================= -== For the iecanvas.htc library == -========================================================================= - -|-----------------------------------------------------------------------------| -| Copyright (c) 2005 Emil A Eklund | -|- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -| -| This program is free software; you can redistribute it and/or modify it | -| under the terms of the MIT License. | -|- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -| -| Permission is hereby granted, free of charge, to any person obtaining a | -| copy of this software and associated documentation files (the "Software"), | -| to deal in the Software without restriction, including without limitation | -| the rights to use, copy, modify, merge, publish, distribute, sublicense, | -| and/or sell copies of the Software, and to permit persons to whom the | -| Software is furnished to do so, subject to the following conditions: | -| The above copyright notice and this permission notice shall be included in | -| all copies or substantial portions of the Software. | -|- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -| -| THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | -| IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | -| FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | -| AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | -| LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING | -| FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER | -| DEALINGS IN THE SOFTWARE. | -|- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -| - -========================================================================= -== For the scriptaculous.js library == -========================================================================= - -// Copyright (c) 2005 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us) -// -// Permission is hereby granted, free of charge, to any person obtaining -// a copy of this software and associated documentation files (the -// "Software"), to deal in the Software without restriction, including -// without limitation the rights to use, copy, modify, merge, publish, -// distribute, sublicense, and/or sell copies of the Software, and to -// permit persons to whom the Software is furnished to do so, subject to -// the following conditions: -// -// The above copyright notice and this permission notice shall be -// included in all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -========================================================================= -== For the standardista-table-sorting.js library == -== For the css.js library == -========================================================================= - -/** - * Copyright (c) 2006 Neil Crosby - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - **/ - -========================================================================= -== For the prototype.js library == -========================================================================= - -Copyright (c) 2005 Sam Stephenson - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. - -========================================================================= -== For the style.css library == -== For the common.js library == -========================================================================= - -

License

- -

THE WORK (AS DEFINED BELOW) IS PROVIDED UNDER THE TERMS OF THIS CREATIVE COMMONS PUBLIC LICENSE ("CCPL" OR "LICENSE"). THE WORK IS PROTECTED BY COPYRIGHT AND/OR OTHER APPLICABLE LAW. ANY USE OF THE WORK OTHER THAN AS AUTHORIZED UNDER THIS LICENSE OR COPYRIGHT LAW IS PROHIBITED.

- -

BY EXERCISING ANY RIGHTS TO THE WORK PROVIDED HERE, YOU ACCEPT AND AGREE TO BE BOUND BY THE TERMS OF THIS LICENSE. THE LICENSOR GRANTS YOU THE RIGHTS CONTAINED HERE IN CONSIDERATION OF YOUR ACCEPTANCE OF SUCH TERMS AND CONDITIONS.

- - -

1. Definitions

- -
    - -
  1. -"Collective Work" means a work, such as a periodical issue, anthology or encyclopedia, in which the Work in its entirety in unmodified form, along with a number of other contributions, constituting separate and independent works in themselves, are assembled into a collective whole. A work that constitutes a Collective Work will not be considered a Derivative Work (as defined below) for the purposes of this License. -
  2. - -
  3. -"Derivative Work" means a work based upon the Work or upon the Work and other pre-existing works, such as a translation, musical arrangement, dramatization, fictionalization, motion picture version, sound recording, art reproduction, abridgment, condensation, or any other form in which the Work may be recast, transformed, or adapted, except that a work that constitutes a Collective Work will not be considered a Derivative Work for the purpose of this License. For the avoidance of doubt, where the Work is a musical composition or sound recording, the synchronization of the Work in timed-relation with a moving image ("synching") will be considered a Derivative Work for the purpose of this License.
  4. - -
  5. -"Licensor" means the individual or entity that offers the Work under the terms of this License. -
  6. - -
  7. -"Original Author" means the individual or entity who created the Work. -
  8. - -
  9. -"Work" means the copyrightable work of authorship offered under the terms of this License. -
  10. - -
  11. -"You" means an individual or entity exercising rights under this License who has not previously violated the terms of this License with respect to the Work, or who has received express permission from the Licensor to exercise rights under this License despite a previous violation. - -
  12. -
- -

2. Fair Use Rights. Nothing in this license is intended to reduce, limit, or restrict any rights arising from fair use, first sale or other limitations on the exclusive rights of the copyright owner under copyright law or other applicable laws.

- - -

3. License Grant. Subject to the terms and conditions of this License, Licensor hereby grants You a worldwide, royalty-free, non-exclusive, perpetual (for the duration of the applicable copyright) license to exercise the rights in the Work as stated below:

- - -
    -
  1. - -to reproduce the Work, to incorporate the Work into one or more Collective Works, and to reproduce the Work as incorporated in the Collective Works; -
  2. - -
  3. -to create and reproduce Derivative Works; -
  4. - -
  5. -to distribute copies or phonorecords of, display publicly, perform publicly, and perform publicly by means of a digital audio transmission the Work including as incorporated in Collective Works; - -
  6. - -
  7. -to distribute copies or phonorecords of, display publicly, perform publicly, and perform publicly by means of a digital audio transmission Derivative Works. -
  8. - -
  9. For the avoidance of doubt, where the work is a musical composition:

    - -
      -
    1. Performance Royalties Under Blanket Licenses. Licensor waives the exclusive right to collect, whether individually or via a performance rights society (e.g. ASCAP, BMI, SESAC), royalties for the public performance or public digital performance (e.g. webcast) of the Work.
    2. - -
    3. Mechanical Rights and Statutory Royalties. Licensor waives the exclusive right to collect, whether individually or via a music rights agency or designated agent (e.g. Harry Fox Agency), royalties for any phonorecord You create from the Work ("cover version") and distribute, subject to the compulsory license created by 17 USC Section 115 of the US Copyright Act (or the equivalent in other jurisdictions).
  10. - -
  11. Webcasting Rights and Statutory Royalties. For the avoidance of doubt, where the Work is a sound recording, Licensor waives the exclusive right to collect, whether individually or via a performance-rights society (e.g. SoundExchange), royalties for the public digital performance (e.g. webcast) of the Work, subject to the compulsory license created by 17 USC Section 114 of the US Copyright Act (or the equivalent in other jurisdictions).
  12. - -
- - -

The above rights may be exercised in all media and formats whether now known or hereafter devised. The above rights include the right to make such modifications as are technically necessary to exercise the rights in other media and formats. All rights not expressly granted by Licensor are hereby reserved.

- -

4. Restrictions.The license granted in Section 3 above is expressly made subject to and limited by the following restrictions:

- - -
    -
  1. -You may distribute, publicly display, publicly perform, or publicly digitally perform the Work only under the terms of this License, and You must include a copy of, or the Uniform Resource Identifier for, this License with every copy or phonorecord of the Work You distribute, publicly display, publicly perform, or publicly digitally perform. You may not offer or impose any terms on the Work that alter or restrict the terms of this License or the recipients' exercise of the rights granted hereunder. You may not sublicense the Work. You must keep intact all notices that refer to this License and to the disclaimer of warranties. You may not distribute, publicly display, publicly perform, or publicly digitally perform the Work with any technological measures that control access or use of the Work in a manner inconsistent with the terms of this License Agreement. The above applies to the Work as incorporated in a Collective Work, but this does not require the Collective Work apart from the Work itself to be made subject to the terms of this License. If You create a Collective Work, upon notice from any Licensor You must, to the extent practicable, remove from the Collective Work any credit as required by clause 4(b), as requested. If You create a Derivative Work, upon notice from any Licensor You must, to the extent practicable, remove from the Derivative Work any credit as required by clause 4(b), as requested. -
  2. - - -
  3. -If you distribute, publicly display, publicly perform, or publicly digitally perform the Work or any Derivative Works or Collective Works, You must keep intact all copyright notices for the Work and provide, reasonable to the medium or means You are utilizing: (i) the name of the Original Author (or pseudonym, if applicable) if supplied, and/or (ii) if the Original Author and/or Licensor designate another party or parties (e.g. a sponsor institute, publishing entity, journal) for attribution in Licensor's copyright notice, terms of service or by other reasonable means, the name of such party or parties; the title of the Work if supplied; to the extent reasonably practicable, the Uniform Resource Identifier, if any, that Licensor specifies to be associated with the Work, unless such URI does not refer to the copyright notice or licensing information for the Work; and in the case of a Derivative Work, a credit identifying the use of the Work in the Derivative Work (e.g., "French translation of the Work by Original Author," or "Screenplay based on original Work by Original Author"). Such credit may be implemented in any reasonable manner; provided, however, that in the case of a Derivative Work or Collective Work, at a minimum such credit will appear where any other comparable authorship credit appears and in a manner at least as prominent as such other comparable authorship credit. -
  4. - -
- - - - - - -

5. Representations, Warranties and Disclaimer

- -

UNLESS OTHERWISE MUTUALLY AGREED TO BY THE PARTIES IN WRITING, LICENSOR OFFERS THE WORK AS-IS AND MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY KIND CONCERNING THE WORK, EXPRESS, IMPLIED, STATUTORY OR OTHERWISE, INCLUDING, WITHOUT LIMITATION, WARRANTIES OF TITLE, MERCHANTIBILITY, FITNESS FOR A PARTICULAR PURPOSE, NONINFRINGEMENT, OR THE ABSENCE OF LATENT OR OTHER DEFECTS, ACCURACY, OR THE PRESENCE OF ABSENCE OF ERRORS, WHETHER OR NOT DISCOVERABLE. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OF IMPLIED WARRANTIES, SO SUCH EXCLUSION MAY NOT APPLY TO YOU.

- - -

6. Limitation on Liability. EXCEPT TO THE EXTENT REQUIRED BY APPLICABLE LAW, IN NO EVENT WILL LICENSOR BE LIABLE TO YOU ON ANY LEGAL THEORY FOR ANY SPECIAL, INCIDENTAL, CONSEQUENTIAL, PUNITIVE OR EXEMPLARY DAMAGES ARISING OUT OF THIS LICENSE OR THE USE OF THE WORK, EVEN IF LICENSOR HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

- -

7. Termination

- -
    - -
  1. -This License and the rights granted hereunder will terminate automatically upon any breach by You of the terms of this License. Individuals or entities who have received Derivative Works or Collective Works from You under this License, however, will not have their licenses terminated provided such individuals or entities remain in full compliance with those licenses. Sections 1, 2, 5, 6, 7, and 8 will survive any termination of this License. -
  2. - -
  3. -Subject to the above terms and conditions, the license granted here is perpetual (for the duration of the applicable copyright in the Work). Notwithstanding the above, Licensor reserves the right to release the Work under different license terms or to stop distributing the Work at any time; provided, however that any such election will not serve to withdraw this License (or any other license that has been, or is required to be, granted under the terms of this License), and this License will continue in full force and effect unless terminated as stated above. -
  4. -
- -

8. Miscellaneous

- -
    - -
  1. -Each time You distribute or publicly digitally perform the Work or a Collective Work, the Licensor offers to the recipient a license to the Work on the same terms and conditions as the license granted to You under this License. -
  2. - -
  3. -Each time You distribute or publicly digitally perform a Derivative Work, Licensor offers to the recipient a license to the original Work on the same terms and conditions as the license granted to You under this License. -
  4. - -
  5. -If any provision of this License is invalid or unenforceable under applicable law, it shall not affect the validity or enforceability of the remainder of the terms of this License, and without further action by the parties to this agreement, such provision shall be reformed to the minimum extent necessary to make such provision valid and enforceable. -
  6. - -
  7. -No term or provision of this License shall be deemed waived and no breach consented to unless such waiver or consent shall be in writing and signed by the party to be charged with such waiver or consent. - -
  8. - -
  9. -This License constitutes the entire agreement between the parties with respect to the Work licensed here. There are no understandings, agreements or representations with respect to the Work not specified here. Licensor shall not be bound by any additional provisions that may appear in any communication from You. This License may not be modified without the mutual written agreement of the Licensor and You. -
  10. -
- -========================================================================= -== Jetty is under the Apache License v 2.0 == -========================================================================= - --- Licenses for included libraries - -========================================================================= -== For jaxb-api and jaxb-impl (CDDL) == -== Source code is at java.net == -========================================================================= - -COMMON DEVELOPMENT AND DISTRIBUTION LICENSE (CDDL) -Version 1.0 - - * - - 1. Definitions. - o - - 1.1. “Contributor†means each individual or entity that creates or contributes to the creation of Modifications. - o - - 1.2. “Contributor Version†means the combination of the Original Software, prior Modifications used by a Contributor (if any), and the Modifications made by that particular Contributor. - o - - 1.3. “Covered Software†means (a) the Original Software, or (b) Modifications, or (c) the combination of files containing Original Software with files containing Modifications, in each case including portions thereof. - o - - 1.4. “Executable†means the Covered Software in any form other than Source Code. - o - - 1.5. “Initial Developer†means the individual or entity that first makes Original Software available under this License. - o - - 1.6. “Larger Work†means a work which combines Covered Software or portions thereof with code not governed by the terms of this License. - o - - 1.7. “License†means this document. - o - - 1.8. “Licensable†means having the right to grant, to the maximum extent possible, whether at the time of the initial grant or subsequently acquired, any and all of the rights conveyed herein. - o - - 1.9. “Modifications†means the Source Code and Executable form of any of the following: - + - - A. Any file that results from an addition to, deletion from or modification of the contents of a file containing Original Software or previous Modifications; - + - - B. Any new file that contains any part of the Original Software or previous Modification; or - + - - C. Any new file that is contributed or otherwise made available under the terms of this License. - o - - 1.10. “Original Software†means the Source Code and Executable form of computer software code that is originally released under this License. - o - - 1.11. “Patent Claims†means any patent claim(s), now owned or hereafter acquired, including without limitation, method, process, and apparatus claims, in any patent Licensable by grantor. - o - - 1.12. “Source Code†means (a) the common form of computer software code in which modifications are made and (b) associated documentation included in or with such code. - o - - 1.13. “You†(or “Yourâ€) means an individual or a legal entity exercising rights under, and complying with all of the terms of, this License. For legal entities, “You†includes any entity which controls, is controlled by, or is under common control with You. For purposes of this definition, “control†means (a) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (b) ownership of more than fifty percent (50%) of the outstanding shares or beneficial ownership of such entity. - * - - 2. License Grants. - o - - 2.1. The Initial Developer Grant. - - Conditioned upon Your compliance with Section 3.1 below and subject to third party intellectual property claims, the Initial Developer hereby grants You a world-wide, royalty-free, non-exclusive license: - + - - (a) under intellectual property rights (other than patent or trademark) Licensable by Initial Developer, to use, reproduce, modify, display, perform, sublicense and distribute the Original Software (or portions thereof), with or without Modifications, and/or as part of a Larger Work; and - + - - (b) under Patent Claims infringed by the making, using or selling of Original Software, to make, have made, use, practice, sell, and offer for sale, and/or otherwise dispose of the Original Software (or portions thereof). - + - - (c) The licenses granted in Sections 2.1(a) and (b) are effective on the date Initial Developer first distributes or otherwise makes the Original Software available to a third party under the terms of this License. - + - - (d) Notwithstanding Section 2.1(b) above, no patent license is granted: (1) for code that You delete from the Original Software, or (2) for infringements caused by: (i) the modification of the Original Software, or (ii) the combination of the Original Software with other software or devices. - o - - 2.2. Contributor Grant. - - Conditioned upon Your compliance with Section 3.1 below and subject to third party intellectual property claims, each Contributor hereby grants You a world-wide, royalty-free, non-exclusive license: - + - - (a) under intellectual property rights (other than patent or trademark) Licensable by Contributor to use, reproduce, modify, display, perform, sublicense and distribute the Modifications created by such Contributor (or portions thereof), either on an unmodified basis, with other Modifications, as Covered Software and/or as part of a Larger Work; and - + - - (b) under Patent Claims infringed by the making, using, or selling of Modifications made by that Contributor either alone and/or in combination with its Contributor Version (or portions of such combination), to make, use, sell, offer for sale, have made, and/or otherwise dispose of: (1) Modifications made by that Contributor (or portions thereof); and (2) the combination of Modifications made by that Contributor with its Contributor Version (or portions of such combination). - + - - (c) The licenses granted in Sections 2.2(a) and 2.2(b) are effective on the date Contributor first distributes or otherwise makes the Modifications available to a third party. - + - - (d) Notwithstanding Section 2.2(b) above, no patent license is granted: (1) for any code that Contributor has deleted from the Contributor Version; (2) for infringements caused by: (i) third party modifications of Contributor Version, or (ii) the combination of Modifications made by that Contributor with other software (except as part of the Contributor Version) or other devices; or (3) under Patent Claims infringed by Covered Software in the absence of Modifications made by that Contributor. - * - - 3. Distribution Obligations. - o - - 3.1. Availability of Source Code. - - Any Covered Software that You distribute or otherwise make available in Executable form must also be made available in Source Code form and that Source Code form must be distributed only under the terms of this License. You must include a copy of this License with every copy of the Source Code form of the Covered Software You distribute or otherwise make available. You must inform recipients of any such Covered Software in Executable form as to how they can obtain such Covered Software in Source Code form in a reasonable manner on or through a medium customarily used for software exchange. - o - - 3.2. Modifications. - - The Modifications that You create or to which You contribute are governed by the terms of this License. You represent that You believe Your Modifications are Your original creation(s) and/or You have sufficient rights to grant the rights conveyed by this License. - o - - 3.3. Required Notices. - - You must include a notice in each of Your Modifications that identifies You as the Contributor of the Modification. You may not remove or alter any copyright, patent or trademark notices contained within the Covered Software, or any notices of licensing or any descriptive text giving attribution to any Contributor or the Initial Developer. - o - - 3.4. Application of Additional Terms. - - You may not offer or impose any terms on any Covered Software in Source Code form that alters or restricts the applicable version of this License or the recipients’ rights hereunder. You may choose to offer, and to charge a fee for, warranty, support, indemnity or liability obligations to one or more recipients of Covered Software. However, you may do so only on Your own behalf, and not on behalf of the Initial Developer or any Contributor. You must make it absolutely clear that any such warranty, support, indemnity or liability obligation is offered by You alone, and You hereby agree to indemnify the Initial Developer and every Contributor for any liability incurred by the Initial Developer or such Contributor as a result of warranty, support, indemnity or liability terms You offer. - o - - 3.5. Distribution of Executable Versions. - - You may distribute the Executable form of the Covered Software under the terms of this License or under the terms of a license of Your choice, which may contain terms different from this License, provided that You are in compliance with the terms of this License and that the license for the Executable form does not attempt to limit or alter the recipient’s rights in the Source Code form from the rights set forth in this License. If You distribute the Covered Software in Executable form under a different license, You must make it absolutely clear that any terms which differ from this License are offered by You alone, not by the Initial Developer or Contributor. You hereby agree to indemnify the Initial Developer and every Contributor for any liability incurred by the Initial Developer or such Contributor as a result of any such terms You offer. - o - - 3.6. Larger Works. - - You may create a Larger Work by combining Covered Software with other code not governed by the terms of this License and distribute the Larger Work as a single product. In such a case, You must make sure the requirements of this License are fulfilled for the Covered Software. - * - - 4. Versions of the License. - o - - 4.1. New Versions. - - Sun Microsystems, Inc. is the initial license steward and may publish revised and/or new versions of this License from time to time. Each version will be given a distinguishing version number. Except as provided in Section 4.3, no one other than the license steward has the right to modify this License. - o - - 4.2. Effect of New Versions. - - You may always continue to use, distribute or otherwise make the Covered Software available under the terms of the version of the License under which You originally received the Covered Software. If the Initial Developer includes a notice in the Original Software prohibiting it from being distributed or otherwise made available under any subsequent version of the License, You must distribute and make the Covered Software available under the terms of the version of the License under which You originally received the Covered Software. Otherwise, You may also choose to use, distribute or otherwise make the Covered Software available under the terms of any subsequent version of the License published by the license steward. - o - - 4.3. Modified Versions. - - When You are an Initial Developer and You want to create a new license for Your Original Software, You may create and use a modified version of this License if You: (a) rename the license and remove any references to the name of the license steward (except to note that the license differs from this License); and (b) otherwise make it clear that the license contains terms which differ from this License. - * - - 5. DISCLAIMER OF WARRANTY. - - COVERED SOFTWARE IS PROVIDED UNDER THIS LICENSE ON AN “AS IS†BASIS, WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, WITHOUT LIMITATION, WARRANTIES THAT THE COVERED SOFTWARE IS FREE OF DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE OR NON-INFRINGING. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE COVERED SOFTWARE IS WITH YOU. SHOULD ANY COVERED SOFTWARE PROVE DEFECTIVE IN ANY RESPECT, YOU (NOT THE INITIAL DEVELOPER OR ANY OTHER CONTRIBUTOR) ASSUME THE COST OF ANY NECESSARY SERVICING, REPAIR OR CORRECTION. THIS DISCLAIMER OF WARRANTY CONSTITUTES AN ESSENTIAL PART OF THIS LICENSE. NO USE OF ANY COVERED SOFTWARE IS AUTHORIZED HEREUNDER EXCEPT UNDER THIS DISCLAIMER. - * - - 6. TERMINATION. - o - - 6.1. This License and the rights granted hereunder will terminate automatically if You fail to comply with terms herein and fail to cure such breach within 30 days of becoming aware of the breach. Provisions which, by their nature, must remain in effect beyond the termination of this License shall survive. - o - - 6.2. If You assert a patent infringement claim (excluding declaratory judgment actions) against Initial Developer or a Contributor (the Initial Developer or Contributor against whom You assert such claim is referred to as “Participantâ€) alleging that the Participant Software (meaning the Contributor Version where the Participant is a Contributor or the Original Software where the Participant is the Initial Developer) directly or indirectly infringes any patent, then any and all rights granted directly or indirectly to You by such Participant, the Initial Developer (if the Initial Developer is not the Participant) and all Contributors under Sections 2.1 and/or 2.2 of this License shall, upon 60 days notice from Participant terminate prospectively and automatically at the expiration of such 60 day notice period, unless if within such 60 day period You withdraw Your claim with respect to the Participant Software against such Participant either unilaterally or pursuant to a written agreement with Participant. - o - - 6.3. In the event of termination under Sections 6.1 or 6.2 above, all end user licenses that have been validly granted by You or any distributor hereunder prior to termination (excluding licenses granted to You by any distributor) shall survive termination. - * - - 7. LIMITATION OF LIABILITY. - - UNDER NO CIRCUMSTANCES AND UNDER NO LEGAL THEORY, WHETHER TORT (INCLUDING NEGLIGENCE), CONTRACT, OR OTHERWISE, SHALL YOU, THE INITIAL DEVELOPER, ANY OTHER CONTRIBUTOR, OR ANY DISTRIBUTOR OF COVERED SOFTWARE, OR ANY SUPPLIER OF ANY OF SUCH PARTIES, BE LIABLE TO ANY PERSON FOR ANY INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES OF ANY CHARACTER INCLUDING, WITHOUT LIMITATION, DAMAGES FOR LOST PROFITS, LOSS OF GOODWILL, WORK STOPPAGE, COMPUTER FAILURE OR MALFUNCTION, OR ANY AND ALL OTHER COMMERCIAL DAMAGES OR LOSSES, EVEN IF SUCH PARTY SHALL HAVE BEEN INFORMED OF THE POSSIBILITY OF SUCH DAMAGES. THIS LIMITATION OF LIABILITY SHALL NOT APPLY TO LIABILITY FOR DEATH OR PERSONAL INJURY RESULTING FROM SUCH PARTY’S NEGLIGENCE TO THE EXTENT APPLICABLE LAW PROHIBITS SUCH LIMITATION. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OR LIMITATION OF INCIDENTAL OR CONSEQUENTIAL DAMAGES, SO THIS EXCLUSION AND LIMITATION MAY NOT APPLY TO YOU. - * - - 8. U.S. GOVERNMENT END USERS. - - The Covered Software is a “commercial item,†as that term is defined in 48 C.F.R. 2.101 (Oct. 1995), consisting of “commercial computer software†(as that term is defined at 48 C.F.R. § 252.227-7014(a)(1)) and “commercial computer software documentation†as such terms are used in 48 C.F.R. 12.212 (Sept. 1995). Consistent with 48 C.F.R. 12.212 and 48 C.F.R. 227.7202-1 through 227.7202-4 (June 1995), all U.S. Government End Users acquire Covered Software with only those rights set forth herein. This U.S. Government Rights clause is in lieu of, and supersedes, any other FAR, DFAR, or other clause or provision that addresses Government rights in computer software under this License. - * - - 9. MISCELLANEOUS. - - This License represents the complete agreement concerning subject matter hereof. If any provision of this License is held to be unenforceable, such provision shall be reformed only to the extent necessary to make it enforceable. This License shall be governed by the law of the jurisdiction specified in a notice contained within the Original Software (except to the extent applicable law, if any, provides otherwise), excluding such jurisdiction’s conflict-of-law provisions. Any litigation relating to this License shall be subject to the jurisdiction of the courts located in the jurisdiction and venue specified in a notice contained within the Original Software, with the losing party responsible for costs, including, without limitation, court costs and reasonable attorneys’ fees and expenses. The application of the United Nations Convention on Contracts for the International Sale of Goods is expressly excluded. Any law or regulation which provides that the language of a contract shall be construed against the drafter shall not apply to this License. You agree that You alone are responsible for compliance with the United States export administration regulations (and the export control laws and regulation of any other countries) when You use, distribute or otherwise make available any Covered Software. - * - - 10. RESPONSIBILITY FOR CLAIMS. - - As between Initial Developer and the Contributors, each party is responsible for claims and damages arising, directly or indirectly, out of its utilization of rights under this License and You agree to work with Initial Developer and Contributors to distribute such responsibility on an equitable basis. Nothing herein is intended or shall be deemed to constitute any admission of liability. - -========================================================================= -== jstl and taglibs standard are under either the Apache License v 2.0 or CDDL == -========================================================================= -========================================================================= -== For JDom == -========================================================================= -Copyright (C) 2000-2004 Jason Hunter & Brett McLaughlin. - All rights reserved. - - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions - are met: - - 1. Redistributions of source code must retain the above copyright - notice, this list of conditions, and the following disclaimer. - - 2. Redistributions in binary form must reproduce the above copyright - notice, this list of conditions, and the disclaimer that follows - these conditions in the documentation and/or other materials - provided with the distribution. - - 3. The name "JDOM" must not be used to endorse or promote products - derived from this software without prior written permission. For - written permission, please contact . - - 4. Products derived from this software may not be called "JDOM", nor - may "JDOM" appear in their name, without prior written permission - from the JDOM Project Management . - - In addition, we request (but do not require) that you include in the - end-user documentation provided with the redistribution and/or in the - software itself an acknowledgement equivalent to the following: - "This product includes software developed by the - JDOM Project (http://www.jdom.org/)." - Alternatively, the acknowledgment may be graphical using the logos - available at http://www.jdom.org/images/logos. - - THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - DISCLAIMED. IN NO EVENT SHALL THE JDOM AUTHORS OR THE PROJECT - CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - SUCH DAMAGE. - - This software consists of voluntary contributions made by many - individuals on behalf of the JDOM Project and was originally - created by Jason Hunter and - Brett McLaughlin . For more information - on the JDOM Project, please see . - -========================================================================= -== For the mx4j, mx4j-remote, and mx4j-tools library == -========================================================================= - - The MX4J License, Version 1.0 - - Copyright (c) 2001-2004 by the MX4J contributors. All rights reserved. - - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions - are met: - - 1. Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. - - 2. Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in - the documentation and/or other materials provided with the - distribution. - - 3. The end-user documentation included with the redistribution, - if any, must include the following acknowledgment: - "This product includes software developed by the - MX4J project (http://mx4j.sourceforge.net)." - Alternately, this acknowledgment may appear in the software itself, - if and wherever such third-party acknowledgments normally appear. - - 4. The name "MX4J" must not be used to endorse or promote - products derived from this software without prior written - permission. - For written permission, please contact - biorn_steedom [at] users [dot] sourceforge [dot] net - - 5. Products derived from this software may not be called "MX4J", - nor may "MX4J" appear in their name, without prior written - permission of Simone Bordet. - - THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - DISCLAIMED. IN NO EVENT SHALL THE MX4J CONTRIBUTORS - BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - SUCH DAMAGE. - ==================================================================== - - This software consists of voluntary contributions made by many - individuals on behalf of the MX4J project. For more information on - MX4J, please see - the MX4J website. - - -========================================================================= -== Rome is under the Apache License v 2.0 == -========================================================================= -========================================================================= -== For Sitemesh == -========================================================================= -/* ==================================================================== - * The OpenSymphony Software License, Version 1.1 - * - * (this license is derived and fully compatible with the Apache Software - * License - see http://www.apache.org/LICENSE.txt) - * - * Copyright (c) 2001-2004 The OpenSymphony Group. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * - * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: - * "This product includes software developed by the - * OpenSymphony Group (http://www.opensymphony.com/)." - * Alternately, this acknowledgment may appear in the software itself, - * if and wherever such third-party acknowledgments normally appear. - * - * 4. The names "OpenSymphony" and "The OpenSymphony Group" - * must not be used to endorse or promote products derived from this - * software without prior written permission. For written - * permission, please contact license@opensymphony.com . - * - * 5. Products derived from this software may not be called "OpenSymphony" - * or "SiteMesh", nor may "OpenSymphony" or "SiteMesh" appear in their - * name, without prior written permission of the OpenSymphony Group. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * ==================================================================== - */ - ========================================================================= -== For slf4j == -========================================================================= -Copyright (c) 2004-2007 QOS.ch All rights reserved. Permission is hereby -granted, free of charge, to any person obtaining a copy of this software -and associated documentation files (the "Software"), to deal in the -Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: The above -copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. -IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY -CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE -SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. -========================================================================= -== Smackx is under the Apache License v 2.0 == -========================================================================= -========================================================================= -== Spring is under the Apache License v 2.0 == -========================================================================= -========================================================================= -== Woodstox is under the Apache License v 2.0 == -========================================================================= -========================================================================= -== For the xmlpull library == -========================================================================= - -XMLPULL API IS FREE -------------------- - -All of the XMLPULL API source code, compiled code, and documentation -contained in this distribution *except* for tests (see separate LICENSE_TESTS.txt) -are in the Public Domain. - -XMLPULL API comes with NO WARRANTY or guarantee of fitness for any purpose. - -Initial authors: - - Stefan Haustein - Aleksander Slominski - -2001-12-12 - -========================================================================= -== For the xstream library == -========================================================================= - -(BSD Style License) - -Copyright (c) 2003-2004, Joe Walnes -All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are met: - -Redistributions of source code must retain the above copyright notice, this list of -conditions and the following disclaimer. Redistributions in binary form must reproduce -the above copyright notice, this list of conditions and the following disclaimer in -the documentation and/or other materials provided with the distribution. - -Neither the name of XStream nor the names of its contributors may be used to endorse -or promote products derived from this software without specific prior written -permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY -EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES -OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT -SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, -INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR -BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN -CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY -WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -DAMAGE. diff --git a/edexOsgi/build.edex/esb/webapps/admin/META-INF/NOTICE b/edexOsgi/build.edex/esb/webapps/admin/META-INF/NOTICE deleted file mode 100644 index b91150c8b3..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/META-INF/NOTICE +++ /dev/null @@ -1,107 +0,0 @@ -Apache ActiveMQ -Copyright 2005-2006 The Apache Software Foundation - -This product includes software developed by -The Apache Software Foundation (http://www.apache.org/). - -========================================================================= -== Derby Notice == -========================================================================= - -Portions of Derby were orginally developed by -International Business Machines Corporation and are -licensed to the Apache Software Foundation under the -"Software Grant and Corporate Contribution License Agreement", -informally known as the "Derby CLA". - -The portion of the functionTests under 'nist' was originally -developed by the National Institute of Standards and Technology (NIST), -an agency of the United States Department of Commerce, and adapted by -International Business Machines Corporation in accordance with the NIST -Software Acknowledgment and Redistribution document at -http://www.itl.nist.gov/div897/ctg/sql_form.htm - -============================================================== - Jetty Web Container - Copyright 1995-2006 Mort Bay Consulting Pty Ltd -============================================================== - -This product includes some software developed at The Apache Software -Foundation (http://www.apache.org/). - -The javax.servlet package used by Jetty is copyright -Sun Microsystems, Inc and Apache Software Foundation. It is -distributed under the Common Development and Distribution License. -You can obtain a copy of the license at -https://glassfish.dev.java.net/public/CDDLv1.0.html. - -The UnixCrypt.java code ~Implements the one way cryptography used by -Unix systems for simple password protection. Copyright 1996 Aki Yoshida, -modified April 2001 by Iris Van den Broeke, Daniel Deville. - -The default JSP implementation is provided by the Glassfish JSP engine -from project Glassfish http://glassfish.dev.java.net. Copyright 2005 -Sun Microsystems, Inc. and portions Copyright Apache Software Foundation. - -Some portions of the code are Copyright: - 2006 Tim Vernum - 1999 Jason Gilbert. - -The jboss integration module contains some LGPL code. - -========================================================================= -== Spring Notice == -========================================================================= - -This product includes software developed by -the Apache Software Foundation (http://www.apache.org). - -This product also includes software developed by -Clinton Begin (http://www.ibatis.com). - -The end-user documentation included with a redistribution, if any, -must include the following acknowledgement: - - "This product includes software developed by the Spring Framework - Project (http://www.springframework.org)." - -Alternately, this acknowledgement may appear in the software itself, -if and wherever such third-party acknowledgements normally appear. - -The names "Spring" and "Spring Framework" must not be used to -endorse or promote products derived from this software without -prior written permission. For written permission, please contact -rod.johnson@interface21.com or juergen.hoeller@interface21.com. - - -========================================================================= -== MX4J Notice == -========================================================================= - -This product includes software developed by the MX4J project -(http://sourceforge.net/projects/mx4j). -========================================================================= -== Sitemesh Notice == -========================================================================= - -This product includes software developed by the -OpenSymphony Group (http://www.opensymphony.com/). - -========================================================================= -== Smackx Notice (not from Jive Software) == -========================================================================= - -This product includes software developed by JiveSoftware -(http://www.igniterealtime.org/). - -========================================================================= -== Woodstox Notice (http://woodstox.codehaus.org) == -========================================================================= -This product currently only contains code developed by authors -of specific components, as identified by the source code files. - -Since product implements StAX API, it has dependencies to StAX API -classes. - -For additional credits (generally to people who reported problems) -see CREDITS file. diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/decorators.xml b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/decorators.xml deleted file mode 100644 index d37565c988..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/decorators.xml +++ /dev/null @@ -1,49 +0,0 @@ - - - - - - - /xml/* - - - - /* - - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/dispatcher-servlet.xml b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/dispatcher-servlet.xml deleted file mode 100644 index 04a4bdd79a..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/dispatcher-servlet.xml +++ /dev/null @@ -1,80 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/jspf/headertags.jspf b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/jspf/headertags.jspf deleted file mode 100644 index 4b698304c4..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/jspf/headertags.jspf +++ /dev/null @@ -1,21 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> -<%@ taglib prefix="decorator" uri="http://www.opensymphony.com/sitemesh/decorator" %> -<%@ taglib prefix="form" tagdir="/WEB-INF/tags/form" %> -<%@ taglib prefix="jms" tagdir="/WEB-INF/tags/jms" %> -<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> -<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%> diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/jspf/old.jspf b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/jspf/old.jspf deleted file mode 100644 index f952019551..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/jspf/old.jspf +++ /dev/null @@ -1,21 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> -<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> -<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> -<%@ taglib prefix="display" uri="http://displaytag.sf.net" %> - -<%@ taglib prefix="c" tagdir="/WEB-INF/tags/c" %> diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/checkbox.tag b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/checkbox.tag deleted file mode 100644 index 4a5dec5c58..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/checkbox.tag +++ /dev/null @@ -1,18 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> -<%@ attribute name="name" type="java.lang.String" required="true" %> - diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/forEachMapEntry.tag b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/forEachMapEntry.tag deleted file mode 100644 index 70baff98d2..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/forEachMapEntry.tag +++ /dev/null @@ -1,29 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> -<%@ attribute name="var" type="java.lang.String" required="true" %> -<%@ attribute name="items" type="java.util.Map" required="true" %> -<%@ tag import="java.util.Iterator" %> -<% - Iterator iter = items.entrySet().iterator(); - while (iter.hasNext()) { - request.setAttribute(var, iter.next()); -%> - -<% - } -%> - diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/option.tag b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/option.tag deleted file mode 100644 index 4227c41036..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/option.tag +++ /dev/null @@ -1,20 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> -<%@ attribute name="name" type="java.lang.String" required="true" %> -<%@ attribute name="value" type="java.lang.String" required="true" %> -<%@ attribute name="label" type="java.lang.String" required="true" %> - diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/short.tag b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/short.tag deleted file mode 100644 index 3302e44293..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/short.tag +++ /dev/null @@ -1,27 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> -<%@ attribute name="text" type="java.lang.String" required="true" %> -<%@ attribute name="length" type="java.lang.Integer" required="false" %> -<% - if (length == null) - length = 20; - if (text.length() <= 20) { - out.print(text); - } else { - out.println(text.substring(0, 10) + "..." + text.substring(text.length() - 5)); - } -%> \ No newline at end of file diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/text.tag b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/text.tag deleted file mode 100644 index a557a42bb2..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/text.tag +++ /dev/null @@ -1,28 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> -<%@ attribute name="name" type="java.lang.String" required="true" %> -<%@ attribute name="defaultValue" type="java.lang.String" required="false" %> -<% - String value = request.getParameter(name); - if (value == null || value.trim().length() == 0) { - value = defaultValue; - } - if (value == null) { - value = ""; - } -%> - diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/tooltip.tag b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/tooltip.tag deleted file mode 100644 index 0f2d495e2d..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/tooltip.tag +++ /dev/null @@ -1,29 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> -<%@ attribute name="text" type="java.lang.String" required="true" %> -<%@ attribute name="length" type="java.lang.Integer" required="false" %> -<% - text = text.replaceAll("<", "<"); - text = text.replaceAll(">", ">"); - if (length == null) - length = 23; - if (text.length() <= length) { - out.print(text); - } else { - out.println(" " + text.substring(0, length - 3) + "... " + text + ""); - } -%> \ No newline at end of file diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/uri.tag b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/uri.tag deleted file mode 100644 index a9abb167ba..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/form/uri.tag +++ /dev/null @@ -1,18 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> -<%@ attribute name="name" type="java.lang.String" required="true" %> - diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/jms/forEachMessage.tag b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/jms/forEachMessage.tag deleted file mode 100644 index 6dae9dbc65..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/jms/forEachMessage.tag +++ /dev/null @@ -1,34 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> -<%@ attribute name="var" type="java.lang.String" required="true" %> -<%@ attribute name="queueBrowser" type="javax.jms.QueueBrowser" required="true" %> -<%@ tag import="java.util.Enumeration" %> -<%@ tag import="javax.jms.Message" %> -<% - - Enumeration iter = queueBrowser.getEnumeration(); - while (iter.hasMoreElements()) { - Message message = (Message) iter.nextElement(); - if (message != null) { - request.setAttribute(var, message); -%> - -<% - } - } -%> - diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/jms/formatTimestamp.tag b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/jms/formatTimestamp.tag deleted file mode 100644 index 1a4a54bd8e..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/jms/formatTimestamp.tag +++ /dev/null @@ -1,29 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> -<%@ attribute name="timestamp" type="java.lang.String"%> -<%@ tag import="java.util.Date" %> -<%@ tag import="java.text.SimpleDateFormat" %> -<% - if (timestamp != null) { - long time = Long.parseLong(timestamp); - Date date = new Date(time); - - SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss:SSS z"); - - out.println(formatter.format(date)); - } -%> diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/jms/persistent.tag b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/jms/persistent.tag deleted file mode 100644 index f7f33a6277..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/tags/jms/persistent.tag +++ /dev/null @@ -1,27 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> -<%@ attribute name="message" type="javax.jms.Message" required="true" %> -<% - if (message != null) { - if (message.getJMSDeliveryMode() == javax.jms.DeliveryMode.PERSISTENT) { - out.println("Persistent"); - } - else { - out.println("Non Persistent"); - } - } -%> diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/web.xml b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/web.xml deleted file mode 100644 index 6237b907cd..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/web.xml +++ /dev/null @@ -1,181 +0,0 @@ - - - - - - - - Apache ActiveMQ Web Console - - ActiveMQ Console - - - - - - sitemesh - com.opensymphony.module.sitemesh.filter.PageFilter - - - - sitemesh - /* - - - - - - - spring - org.apache.activemq.web.filter.ApplicationContextFilter - - - - spring - /* - - - - - - - - - AjaxServlet - org.apache.activemq.web.AjaxServlet - 1 - - - AjaxServlet - /ajax/* - - - - SendServlet - org.apache.activemq.web.MessageServlet - 1 - - - SendServlet - /send/* - - - - - QueueBrowseServlet - org.apache.activemq.web.QueueBrowseServlet - - - QueueBrowseServlet - /queueBrowse/* - - - - - session - org.apache.activemq.web.SessionFilter - - - - spring-rq - org.springframework.web.filter.RequestContextFilter - - - - session - /* - - - spring-rq - /* - - - - - - - - org.apache.activemq.web.WebConsoleStarter - - - - - - - - dispatcher - org.springframework.web.servlet.DispatcherServlet - 2 - - - - dispatcher - *.action - - - - index.html - index.jsp - - - - - - - - - - - - *.jsp - /WEB-INF/jspf/headertags.jspf - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-default.xml b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-default.xml deleted file mode 100644 index 4fe67d1e22..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-default.xml +++ /dev/null @@ -1,45 +0,0 @@ - - - - - - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-embedded.xml b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-embedded.xml deleted file mode 100644 index d53e455e18..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-embedded.xml +++ /dev/null @@ -1,56 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-invm.xml b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-invm.xml deleted file mode 100644 index bf5199cf66..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-invm.xml +++ /dev/null @@ -1,62 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-jndi.xml b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-jndi.xml deleted file mode 100644 index b6e2feaeef..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-jndi.xml +++ /dev/null @@ -1,65 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-properties.xml b/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-properties.xml deleted file mode 100644 index a68bdaf283..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/WEB-INF/webconsole-properties.xml +++ /dev/null @@ -1,64 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/browse.jsp b/edexOsgi/build.edex/esb/webapps/admin/browse.jsp deleted file mode 100644 index 598434372d..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/browse.jsp +++ /dev/null @@ -1,68 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> - - -Browse <form:short text="${requestContext.queueBrowser.JMSDestination}"/> - - - -

Browse

- - - - - - - - - - - - - - - - -<%-- - ----%> - - - - - - - - - - - - - -<%-- - ---%> - -
Message IDCorrelation IDPersistencePriorityRedeliveredReply ToTimestampTypeOperations
${row.JMSMessageID}${row.JMSCorrelationID}${row.JMSPriority}${row.JMSRedelivered}${row.JMSReplyTo}${row.JMSType} - Delete -
- - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/decorators/main.jsp b/edexOsgi/build.edex/esb/webapps/admin/decorators/main.jsp deleted file mode 100644 index 017b2e866d..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/decorators/main.jsp +++ /dev/null @@ -1,149 +0,0 @@ - -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> - - - - - ${requestContext.brokerQuery.brokerAdmin.brokerName} : <decorator:title default="ActiveMQ Console" /> - - - - - - - - - - - - - -
-
-
-
-
-
-
-
-
-
- -
- - - - - -
- - -
- - - - - - - - -
-
- -
-
- - -
- - -
-
-
-
-
-
- -
-
- - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/decorators/panel.jsp b/edexOsgi/build.edex/esb/webapps/admin/decorators/panel.jsp deleted file mode 100644 index 4746808db5..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/decorators/panel.jsp +++ /dev/null @@ -1,31 +0,0 @@ -<%@ taglib uri="http://www.opensymphony.com/sitemesh/decorator" prefix="decorator" %> -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> -

- - - - - - - -
- -
- -
-

diff --git a/edexOsgi/build.edex/esb/webapps/admin/decorators/printable.jsp b/edexOsgi/build.edex/esb/webapps/admin/decorators/printable.jsp deleted file mode 100644 index 6b78947d27..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/decorators/printable.jsp +++ /dev/null @@ -1,31 +0,0 @@ -<%@ taglib uri="http://www.opensymphony.com/sitemesh/decorator" prefix="decorator" %> -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> - - - - <decorator:title default="Welcome!" /> - - - - - Printed on <%=new java.util.Date()%>.
-
-
- - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/graph.jsp b/edexOsgi/build.edex/esb/webapps/admin/graph.jsp deleted file mode 100644 index 21805f865b..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/graph.jsp +++ /dev/null @@ -1,67 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> - - -Browse ${requestContext.queueBrowser.JMSDestination} - - - -

Browse ${requestContext.queueBrowser.JMSDestination}

- - - - - - - - - - - - - - - - -<%-- - ----%> - - - - - - - - - - - - - -<%-- - ---%> - -
Message IDCorrelation IDPersistencePriorityRedeliveredReply ToTimestampTypeOperations
${row.JMSMessageID}${row.JMSCorrelationID}${row.JMSPriority}${row.JMSRedelivered}${row.JMSReplyTo}${row.JMSTimestamp}${row.JMSType} - Delete -
- - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/activemq-logo.png b/edexOsgi/build.edex/esb/webapps/admin/images/activemq-logo.png deleted file mode 100644 index d514448b55a5f5f97c9de1900144f3c1572d4e71..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 6819 zcmcgxXEYp8w;c?|XfueYF?u(8i|9n}UG&~X7ov<_qIbd|MDM+3ltd6E+8`JbC3-{; z^76g!=llQeT6gce?%n6Cv-Vx<{gwv^cdGhPh_{`+w9lWRdpqm z4cTRVsTG~+@AC8W%X5nAGm(v{CG~Lywb8lB$;lNl*)8Gu&0)Fuv8hE-X$>J+(b3WG zf>P>zvnqX)Lqb9-JrZ+YM!$89_V@SCcMMN;3C*$z$$k+WYweqE;_v9_n5pmk#^7bF zzDI(NM}~%%nVH#}=dNMu_Q^61adP&$y1I$d4snt;G2)i$>gvG~W?_P+2)JpWfPtKx zTnLA50GFd<4vzOf4|0uvuPf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N)9X1;- zF{fH?BG*jZ59-j#dgoo!mah+z?C?99&$Y?OC9UV9b9=UuYliE8=o^?Cg%N)l{?GUO bU;Ox+&sl}@E?WQk2LM$iEyV_TYsCKm5px!0 diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/asf-logo.png b/edexOsgi/build.edex/esb/webapps/admin/images/asf-logo.png deleted file mode 100644 index d824fab7680b23386c46a27ad3c3727811e129ef..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4735 zcmc&%_fwON(tRjO5CQ?Di9iBKFQJQoLLhYMz4u-NQj{i!D!ucHAckrIDG41hgd)92 zjr5KRf)r88<^8^y`!C#`*>iSwc4u~Wf7z3$ud5Eeaq9*E0ANiGRl_S@zH%gp>S13y{GcS z`}glRF)owE)m`O*ZJ3lF`A(&!rLCn-?SZ*7Y9l=1bG#~KH@y1F(RXmu-V z9mDMdEF~;0EoUXY79hc1HK;MhyuXXg*vDJ&xPYHPE|e zz{<)hN1?0@@IW9CNk9@x3cK1rD=8ZUpuIXsN2#O16-5OZ>KXz6e~JGU0wvy6SEEq+ zYghyV02TeePBK0pd3Kd#3PPF(si0gOf;{|up~fCQE&yCYOk7F~E?dSk55B5^{##+> z=Nc5^fN}vIIyj;Hd|aG89H43*D3=gFlvg11p?PbDAP)f0c513B8;2JDuuOEC=oyd7 zG^|Rv0a5;PGp9>`%(Qe;D z>`~{`h~{~oI*OQ8t`|j~ue)(w%GUkntJ?G+ZzcNVlkycTMpX2T$i5hI6tR2bGLX}( zgwOp$G{Z@Q_7kp@F zWR)p01TQ`qnqp06dc7RdTC#WNj>jW6H<#Aguim0=B(5E{BTRy^y^D)~b?)yEMzRFq z_48ER2oLMYvK6isN8D(cuMSGuj9-C?^)SHi2Mu8-yRq1ul$;dTfMyHfsrv4@uhwPR zRbMa9h$FhZ%1F&v-q4NFTGFkd@zQ%Bq!-k5!sNJlMcOIHt)2p$3-r?T9);h zEPwrIU>-X;84LbB>-&DXZa};Hakajnse~TKka6VS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m7Mb`mdNiBw23N`){!K b0Dnp9*ls}#VVo4Y(*1xYQdhMaVIT7!9XU$B diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/big-bullet.png b/edexOsgi/build.edex/esb/webapps/admin/images/big-bullet.png deleted file mode 100644 index bc66207eb5b47c8a8c02d20b6a5658bbe0ac6fd4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 325 zcmeAS@N?(olHy`uVBq!ia0vp^LLkh-3?!F4n4AKnn2Vh}LpV4%Za?&Y0OTqL_=LFr z2ZJ9!ems5p^xoaOXU?2CeE9I*y?d)Q0t*Bka|G;vKFw1BD&{T;@(X5ws0NX>Wwlp< z!kh&jk;On+pk3TTjF;}#{Q(M!mAFQfI2WZRmSpDVDTHL^rZN~9=^L8p8<;OuxyuVw zp#V}5oS#-wo>-L1;G39Sl%JcLl9{OBmRXcqo?nz*tl%55d!iP|<}gne$B>FS$pS5m zY>LSo0Vx80{>+U=&TJ2Z(ie1iT1=RF>Eg|chKG4ic)gp!m@>ODLP3#(TZJXDvBgSJ yXTlaqM_EmUg?i>4xoUcP3b!BVIqcwi7sT-FrZH2<6!mJL4Gf;HelF{r5}E)jJayXu diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/black-footer-bottom.png b/edexOsgi/build.edex/esb/webapps/admin/images/black-footer-bottom.png deleted file mode 100644 index 998fdc37a1c9d2a0f8038c0edc39bcee40f1045c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 265 zcmeAS@N?(olHy`uVBq!ia0vp^j6kf)!VDw}+2+jxQq09po*^6@9Je3(KLB#&0(?ST z|AWEDj~^dBdUWQ@nVma#&YU^3xw$zlEe)vT$=A~DK#Hp*$S;@yq7+Ehb&7-mML7#R zB8wRqxP?HN@zUM8KR`i+64!{5;QX|b^2DN42H(WwqWs*{l*~j0x6Go{^8BLgVg=ub z-4nG`fNI4+YMqNx6H7Al^Atidb5j`%jPwmn^bO3Hs@&xTs*v+^aSW-LlRV>qgIrF6 pMuJBIM?yh@K|(-+K!N}R!-pM0f`1~fu>n;wc)I$ztaD0e0swL8Tjl@& diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/black-footer-left.png b/edexOsgi/build.edex/esb/webapps/admin/images/black-footer-left.png deleted file mode 100644 index 01ed47da93f291ff54d74a79d219ecd2bdfcc0eb..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 433 zcmeAS@N?(olHy`uVBq!ia0vp^!a%Ib!3-p)uT}B`Qq09po*^6@9Je3(KLBz)0(?ST z|AWEz@893QfB)>+vj-0zT)ler%$YMsj~?B#XU~=`Th^{!yKLFAnKNhh^z^i}v{Y7B z78Vw!rKQ=~*%=!f^YZd?b8`a?yJ33jEs&BZ3GxeOfEbEFzP#gN22{gY;1OBOz`!j8 z!i<;h*8KqrDwMcJlmzFem6RtIr84*?CKu)Brlw>jD!649rIzOxWfv>>M(m!br2l$uzQnV+W+l9`*zU|^(gXrgamzEtHdFHl9Fr;B4q#hkMj&I%n;;9+^-#H%|^ zer3r0|Gsw}t{!@lqW|t=vazs{#!`I~+kVL#Jt>;jTnLBl9alS-Zbhb@SY+g_IfhqFrmqlwkwokdXRl=WH{CO>h;lAG4oA>JRtz2eu wERa=s_f@Tlh7~^~!VhxPt}Up{$mvhfKh>*hBf2o50q8OYPgg&ebxsLQ01B75DF6Tf diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/black-footer-right.png b/edexOsgi/build.edex/esb/webapps/admin/images/black-footer-right.png deleted file mode 100644 index 27204f183798d7f3e57fa9255bcec4798f9587fd..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 473 zcmeAS@N?(olHy`uVBq!ia0vp^!a%Ib!3-p)uT}B`Qq09po*^6@9Je3(KLB$50(?ST z|AWEz@893QfB)>+vpaY0T)ler%$YMsj~?B#XV2EHTi32#yL9Q&nKNhh^z^i}v{YAD z7Zw(#rKLqjM+XH3d3kwhX=y1cDspmi0*z!4=RE)rMq>1f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i+9KuZ&xke{!b#J`oV)|BZq|dnk<$sLR$&>F63SR#|Q7Df0$#U zsDgCF9cFzd7>p77P*&AQ%UPe85$7@9^=TRJ3a<>698Fv(xV8s{OsJ}y@k$OiK3|jy z$A6JHktGO4K{^Y8J5&xBP@=huD%xP=Vg!1G5eKaL;Tgh1Aa4dlCWkJHqZ>lU2CS$8 zv=EIKB`ydDOOz{tiZZ;%#Yq| zZD(&Ui~nQeE`RR>-#*JeY?NsQL6CMqPEo`9eWAR=Z|i<68JSy#zg808m>u}1EzX{H LK2>z$>Yx7w<$f~Q diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/content-left.png b/edexOsgi/build.edex/esb/webapps/admin/images/content-left.png deleted file mode 100644 index 78051fc051cc21c1168e89a9e411633d9f242644..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 231 zcmeAS@N?(olHy`uVBq!ia0vp^Y(UJ&!VDz&pC395q?n7HJVQ7*IBq}me*okP1^9%x z{s)7PA3r{N^yti)Gdp+g%+S1R3Y29l3GxeO0LxZYKKKU|;VkfoEM{Qf76M_$OLy!3 z00k9FTq8*TqQw%!3+?kK(ek=Bn&9Z zS>O>_%)r1c1j3A$?$-SQ3M!PiMwA5Srn#ux*wMo^&`e(fJE6nEQhcki7U&z!kG+XAmT$=sPcb7tn8?|f&@ zh?AQe^0|f?yE3WF4o3ijKEj#WhJC6+Kq??tN5cPOxpKbHRva2WB+l-<|ATy8euqCk z1}7olCLL~XsxBGf1}z!ljgu8Z1KLTn5G<_T zqgpOLE0N9O;_m}(;?gUNb;6fOHq1rs(x*sCKwjyF>g&F(^2Q70qW>S@Jk^T0Bx+pT z81|7cv@uF1XUs+R(QT1{E*Ihb+5vg01HvDjq`dSAMP-rGLImgwMoCQZ2>XD+w+ITv zo~rU$w1)TNRk0WCmiC;$r;ugEGVY5j=e&_*q#X!v6uQt4k;%cyPKSHf5+om32mEsx zC|-(`H;ZLOStqf-}W)qINoT@frk; zIn-CwS2{M_fS`!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K;c4sd9|6Bg`t8qL@8&2>3d6I?k}Y^Qq2nsOf(0?A8MTfL|2zX45z9Va^x7q>CeGxo3#$|S%sQy z`{6yX1uhw)=JH!VgxA&y;m?3i3?onT*^Zast?ESa=*Ja$M!Ez`c*V@|fSAB378I`) z;wnfLDvCBru=W*%eXm0h@=A%@`V71$cEca+Cj+K5(sMn)5(r5|{*l~#1;Z!c|9k+s zr+Of+jiPXH7dW-4rdI8d*&_!~`u#9OC}O?F1B&s&Di%5(v;k!`N&vm_cuTLBp=Gn< z5QBY?|D1!m!65Tz1|L;Z*;tavXHJdXJf-FNDiAiMfm z6b`?G;NmHSV?)TaJ&CGEy1@&7qxi=UnnJmC-SF<;0Ds^+$e0!n7RdXLV_Bfq(a;;sgM{~`Eik0X&oty;MtS?E+wHH%%{`;g4nx+Z0Ieq;`# zB3AtBHMnhCk=d{VW!+O`kbl^Zen<-72I{cJ&&NEF=o{3yrEn-$o3*(O!C<83FSz$FQsFE8}NS^wvqZ!1j|xJNY(BR^|A;ghWB7jnPvmaUIzM zF}HMO({>pa<02JZUZ<+S_LbE^CAhq5_XaPN1!TDO@0MF`yuis+!FLK>ZuhQE5HDBifUX6e$UGiT21>FFu5H@^hb z$X^oV7t8?B2_v8O&RYhQ;w{9SU*s-od=Vl1Xxj74u>~<#z&Qi&}N_USDixm>uop9P2Re@br)= z1q`V(|6F^>mdKI;Vst E027z5WB>pF diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/left-box-right.png b/edexOsgi/build.edex/esb/webapps/admin/images/left-box-right.png deleted file mode 100644 index f9222870463760fac262bb3086defb8510f07053..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 248 zcmeAS@N?(olHy`uVBq!ia0vp^+(694!VDy9dadsQDdu7)&kzm{j@u9Y9{{=10X`wF z|H0tv*RQW%zrK6-?wK=ZcI?=(aN)w9o*oXH-fuu}|Noma&AtK>Ebxdd z23jEm!i<;h*8Kqrij}xVlsFfqCYEI8=P86_=B6?j80j0D=o^?XRk_OxRG|P;5uBe^ zQl40p%HW%rT$G=inv$8Q;FejGTAp8&U98|6v3sJH3Q(<}r;B4q#hl~}|I#oKk%Wc- Y2Jy8_k2MNifN~5Bp00i_>zopr02pvqo&W#< diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/left-box-top.png b/edexOsgi/build.edex/esb/webapps/admin/images/left-box-top.png deleted file mode 100644 index cbfe24597feb5f74c58b410024ce95cb49b42bd9..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 376 zcmeAS@N?(olHy`uVBq!ia0vp^cYs)sg&9b?Fx|faq?n7HJVQ7*IBq}me*om_2Ka=y z{s)8a-@m_q|NhytXZP;iyLRo`nKNgO9zD8e&z`MYx2{^XYU$FYGiT21?d`qzdi_(N zM*fl@zhDN4P8j*Lciu9f6lZ})WHAE+w-5+3UbyW>IQ+eo=O@f^Wp` ziCQW^wUwSOjv*Cuk_DD%CrE7N6Bh_llG6}MmbGJ^((B3S)^%g;VFR(FVdQ&MBb@06spN A{{R30 diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/oval-arrow.png b/edexOsgi/build.edex/esb/webapps/admin/images/oval-arrow.png deleted file mode 100644 index 17d3404424f30b36f6add498a616e31fea540708..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3878 zcmV+>583dEP)4Tx0C=30mv>kc=N87_*#!iFg&=|jbWuPQP^4Nxx{4woAVtMx3oLG9c4>kX zMZppgJC>*r6#_S?K`C~E8Y_yTCb1DUL4qJ+ySBZ5%QXVI{?OUR6GrUaV!;w0x(XINn`*K55Slm&*A_? z1^_!UG{hSqN&zt9sJI3IBbJJP0>DUS$H@TV4nQ{&arh!YqaDz4=WwNLK-Ufcha+VR z0p0Zg@kuBYa{&GI0BqP2QU>VP0I-jUjABx^%pL={=>i(>d-jAwfrHP1VIO<;tP6ob zOrX-PXRkX11OURMQOa|21OO0vUV!F(xxCvN=(hp*SSXjjFP6(cmH_m-z-a+HiA+}L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|6v3sJH3Q(<}r;B4q#hhdTk&rUq{Dg)8 Z27$Lsj}L6K0ouvH;OXk;vd$@?2>>V?SH1uM diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/right-box-top.png b/edexOsgi/build.edex/esb/webapps/admin/images/right-box-top.png deleted file mode 100644 index 656f1249a03768a43e90e3f60ba7676103356591..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 415 zcmeAS@N?(olHy`uVBq!ia0vp^cYs)sg&9b?Fx|faq?n7HJVQ7*IBq}me*om_2Ka=y z{s)8a-@m_q|NhytXZP;iyLRo`nKNgO9zD8u@7}Fjx2{>UX6e$UGiT21>FFu5H@^hb z$X^oV7t8?B2_v8O&RYhQ;wnXm6PJL|Hw8cawkMm%*t(mo?!@Oec`8&B}*UaH$HnwtDAUj=o16!l< zuBBZZuYC^fE}NJUX({$TY3o^ztIZ0pW3U2;4q+D89ZJ6T-G@yGywqn9It%< diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/small-bullet-gray.png b/edexOsgi/build.edex/esb/webapps/admin/images/small-bullet-gray.png deleted file mode 100644 index 8af9e18166ae20c5140a1919a386cc56d5c660d9..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 215 zcmeAS@N?(olHy`uVBq!ia0vp^Y#_|Y3?y$c)p7$V=3*z$5DpHG+YkL8faC&vLR|m< z|DTqY*7q)F0Z@dgB*-tA;eYf*rL907XMsm#F#`j)5C}6~x?A@LC@5Cq8d2h0l$uzQ znV+W+l9`*zU|^(gXrgamzEtHdFHnU7NJVgdT1k0gQ7VIPVscS_ZfZ(qqJmpyQEGX9 xQFgI{Z^Z72S}H)bJf1F&Ar*6ye;j6LXHc$TeJK#}eH~Do!PC{xWt~$(69ADWJ_Y~) diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/small-bullet-red.png b/edexOsgi/build.edex/esb/webapps/admin/images/small-bullet-red.png deleted file mode 100644 index c17f695d4920887542260af771c7eacea325f7ba..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 215 zcmeAS@N?(olHy`uVBq!ia0vp^Y#_|Y3?y$c)p7$V=3*z$5DpHG+YkL8faC&vLR|m< z|6d^J7;N~`0w}^%666=m@IQK@(pDgkv%n*=n1O*?2!t6g-L3lr6cj6QjVN(0N=+=u z%+FH@$;?e`~%JhK1* diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/spacer.gif b/edexOsgi/build.edex/esb/webapps/admin/images/spacer.gif deleted file mode 100644 index fc2560981ee1caca400e225e48d282106f907f2d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 43 ucmZ?wbhEHbWMp7uXkcLY|NlP&1B2pE7Df>utpmhBaYhCPCMFj~25SJyItL8^ diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/top-red-bar.png b/edexOsgi/build.edex/esb/webapps/admin/images/top-red-bar.png deleted file mode 100644 index 23fde246a585db22d0fe04386ff884907ae8706f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 233 zcmeAS@N?(olHy`uVBq!ia0vp^tU%1o#0(@)aj$0sQq09po*^6@9Je3(KLBz$1AIbU z|NsAAAn2IJVEp6a=OU1rk|4iehX4Ov0cC>6SY); zYQ;cmor_WvOEUBG6hbm{QyC15^bJk)4a}FS+~ozTi1KuC45^rtEYQNp$fo0?%E}S! z;d$~#1LGkhv%*3K^d~_5XUm39!`e&RYLE=1r327U|{fc^>bP0l+XkK(v)-0 diff --git a/edexOsgi/build.edex/esb/webapps/admin/images/white-header-right.png b/edexOsgi/build.edex/esb/webapps/admin/images/white-header-right.png deleted file mode 100644 index e91de9715381b5f12b96fedf57418219526c0e11..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 362 zcmeAS@N?(olHy`uVBq!ia0vp^!ayvt!vk=UAlDX%$YOYs&ce|y7)?h z{DK)E+Mr~(*KHA?3}=ByWHAE+w-5+3Ub-L1;G39Sl%JcL zl9{OBmRXcqo?nz*tl%55d!m*KP^}n9t#eUoVo7Fxo2BR0prAsDYeY$Kep*R+Vo@rCZ(?#$er{??W}<>yW>IQ+eo=O@f^Wp`iCQW^wPGN( z&PAz-C7Jno3L%-fsSE~2`i3U@2Ifmu?(zavNP4 - - -ActiveMQ Console - - - -

Welcome!

- -

-Welcome to the ActiveMQ Console -

- -

-You can find more information about ActiveMQ on the Apache ActiveMQ Site -

- -

Broker

- - - - - - - - - - - - - - - - - - - - - - - -
Name${requestContext.brokerQuery.brokerAdmin.brokerName}
ID${requestContext.brokerQuery.brokerAdmin.brokerId}
Store percent used${requestContext.brokerQuery.brokerAdmin.storePercentUsage}
Memory percent used${requestContext.brokerQuery.brokerAdmin.memoryPercentUsage}
Temp percent used${requestContext.brokerQuery.brokerAdmin.tempPercentUsage}
- - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/js/common.js b/edexOsgi/build.edex/esb/webapps/admin/js/common.js deleted file mode 100644 index e20a34fb9c..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/js/common.js +++ /dev/null @@ -1,121 +0,0 @@ -/** - * This software is licensed under the Creative Commons Licence 2.5 - * http://creativecommons.org/licenses/by/2.5/ - * - * addEvent written by Dean Edwards, 2005 - * with input from Tino Zijdel - * - * http://dean.edwards.name/weblog/2005/10/add-event/ - **/ -function addEvent(element, type, handler) { - // assign each event handler a unique ID - if (!handler.$$guid) handler.$$guid = addEvent.guid++; - // create a hash table of event types for the element - if (!element.events) element.events = {}; - // create a hash table of event handlers for each element/event pair - var handlers = element.events[type]; - if (!handlers) { - handlers = element.events[type] = {}; - // store the existing event handler (if there is one) - if (element["on" + type]) { - handlers[0] = element["on" + type]; - } - } - // store the event handler in the hash table - handlers[handler.$$guid] = handler; - // assign a global event handler to do all the work - element["on" + type] = handleEvent; -}; -// a counter used to create unique IDs -addEvent.guid = 1; - -function removeEvent(element, type, handler) { - // delete the event handler from the hash table - if (element.events && element.events[type]) { - delete element.events[type][handler.$$guid]; - } -}; - -function handleEvent(event) { - var returnValue = true; - // grab the event object (IE uses a global event object) - event = event || fixEvent(window.event); - // get a reference to the hash table of event handlers - var handlers = this.events[event.type]; - // execute each event handler - for (var i in handlers) { - this.$$handleEvent = handlers[i]; - if (this.$$handleEvent(event) === false) { - returnValue = false; - } - } - return returnValue; -}; - -function fixEvent(event) { - // add W3C standard event methods - event.preventDefault = fixEvent.preventDefault; - event.stopPropagation = fixEvent.stopPropagation; - return event; -}; -fixEvent.preventDefault = function() { - this.returnValue = false; -}; -fixEvent.stopPropagation = function() { - this.cancelBubble = true; -}; - -// end from Dean Edwards - - -/** - * Creates an Element for insertion into the DOM tree. - * From http://simon.incutio.com/archive/2003/06/15/javascriptWithXML - * - * @param element the element type to be created. - * e.g. ul (no angle brackets) - **/ -function createElement(element) { - if (typeof document.createElementNS != 'undefined') { - return document.createElementNS('http://www.w3.org/1999/xhtml', element); - } - if (typeof document.createElement != 'undefined') { - return document.createElement(element); - } - return false; -} - -/** - * "targ" is the element which caused this function to be called - * from http://www.quirksmode.org/js/events_properties.html - **/ -function getEventTarget(e) { - var targ; - if (!e) { - e = window.event; - } - if (e.target) { - targ = e.target; - } else if (e.srcElement) { - targ = e.srcElement; - } - if (targ.nodeType == 3) { // defeat Safari bug - targ = targ.parentNode; - } - - return targ; -} - -function confirmAction(id, url) { - //TODO i18n messages - var select = document.getElementById(id); - var selectedIndex = select.selectedIndex; - if (select.selectedIndex == 0) { - alert("Please select a value"); - return; - } - var value = select.options[selectedIndex].value; - url = url.replace(/%target%/gi, value); - if (confirm("Are you sure?")) - location.href=url; -} \ No newline at end of file diff --git a/edexOsgi/build.edex/esb/webapps/admin/js/css.js b/edexOsgi/build.edex/esb/webapps/admin/js/css.js deleted file mode 100644 index ec8d27880c..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/js/css.js +++ /dev/null @@ -1,145 +0,0 @@ -/** - * Written by Neil Crosby. - * http://www.workingwith.me.uk/ - * - * Use this wherever you want, but please keep this comment at the top of this file. - * - * Copyright (c) 2006 Neil Crosby - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - **/ -var css = { - /** - * Returns an array containing references to all elements - * of a given tag type within a certain node which have a given class - * - * @param node the node to start from - * (e.g. document, - * getElementById('whateverStartpointYouWant') - * ) - * @param searchClass the class we're wanting - * (e.g. 'some_class') - * @param tag the tag that the found elements are allowed to be - * (e.g. '*', 'div', 'li') - **/ - getElementsByClass : function(node, searchClass, tag) { - var classElements = new Array(); - var els = node.getElementsByTagName(tag); - var elsLen = els.length; - var pattern = new RegExp("(^|\\s)"+searchClass+"(\\s|$)"); - - - for (var i = 0, j = 0; i < elsLen; i++) { - if (this.elementHasClass(els[i], searchClass) ) { - classElements[j] = els[i]; - j++; - } - } - return classElements; - }, - - - /** - * PRIVATE. Returns an array containing all the classes applied to this - * element. - * - * Used internally by elementHasClass(), addClassToElement() and - * removeClassFromElement(). - **/ - privateGetClassArray: function(el) { - return el.className.split(' '); - }, - - /** - * PRIVATE. Creates a string from an array of class names which can be used - * by the className function. - * - * Used internally by addClassToElement(). - **/ - privateCreateClassString: function(classArray) { - return classArray.join(' '); - }, - - /** - * Returns true if the given element has been assigned the given class. - **/ - elementHasClass: function(el, classString) { - if (!el) { - return false; - } - - var regex = new RegExp('\\b'+classString+'\\b'); - if (el.className.match(regex)) { - return true; - } - - return false; - }, - - /** - * Adds classString to the classes assigned to the element with id equal to - * idString. - **/ - addClassToId: function(idString, classString) { - this.addClassToElement(document.getElementById(idString), classString); - }, - - /** - * Adds classString to the classes assigned to the given element. - * If the element already has the class which was to be added, then - * it is not added again. - **/ - addClassToElement: function(el, classString) { - var classArray = this.privateGetClassArray(el); - - if (this.elementHasClass(el, classString)) { - return; // already has element so don't need to add it - } - - classArray.push(classString); - - el.className = this.privateCreateClassString(classArray); - }, - - /** - * Removes the given classString from the list of classes assigned to the - * element with id equal to idString - **/ - removeClassFromId: function(idString, classString) { - this.removeClassFromElement(document.getElementById(idString), classString); - }, - - /** - * Removes the given classString from the list of classes assigned to the - * given element. If the element has the same class assigned to it twice, - * then only the first instance of that class is removed. - **/ - removeClassFromElement: function(el, classString) { - var classArray = this.privateGetClassArray(el); - - for (x in classArray) { - if (classString == classArray[x]) { - classArray[x] = ''; - break; - } - } - - el.className = this.privateCreateClassString(classArray); - } -} \ No newline at end of file diff --git a/edexOsgi/build.edex/esb/webapps/admin/js/mochi/MochiKit.js b/edexOsgi/build.edex/esb/webapps/admin/js/mochi/MochiKit.js deleted file mode 100644 index 6189d565dc..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/js/mochi/MochiKit.js +++ /dev/null @@ -1,4804 +0,0 @@ -/*** - - MochiKit.MochiKit 1.3 : PACKED VERSION - - THIS FILE IS AUTOMATICALLY GENERATED. If creating patches, please - diff against the source tree, not this file. - - See for documentation, downloads, license, etc. - - (c) 2005 Bob Ippolito. All rights Reserved. - -***/ - -if(typeof (dojo)!="undefined"){ -dojo.provide("MochiKit.Base"); -} -if(typeof (MochiKit)=="undefined"){ -MochiKit={}; -} -if(typeof (MochiKit.Base)=="undefined"){ -MochiKit.Base={}; -} -MochiKit.Base.VERSION="1.3"; -MochiKit.Base.NAME="MochiKit.Base"; -MochiKit.Base.update=function(_1,_2){ -if(_1===null){ -_1={}; -} -for(var i=1;i=0;i--){ -_12.unshift(o[i]); -} -}else{ -res.push(o); -} -} -return res; -},extend:function(_13,obj,_15){ -if(!_15){ -_15=0; -} -if(obj){ -var l=obj.length; -if(typeof (l)!="number"){ -if(typeof (MochiKit.Iter)!="undefined"){ -obj=MochiKit.Iter.list(obj); -l=obj.length; -}else{ -throw new TypeError("Argument not an array-like and MochiKit.Iter not present"); -} -} -if(!_13){ -_13=[]; -} -for(var i=_15;i>b; -},zrshift:function(a,b){ -return a>>>b; -},eq:function(a,b){ -return a==b; -},ne:function(a,b){ -return a!=b; -},gt:function(a,b){ -return a>b; -},ge:function(a,b){ -return a>=b; -},lt:function(a,b){ -return al){ -_41=l; -} -} -_40=[]; -for(i=0;i<_41;i++){ -var _42=[]; -for(var j=1;j0){ -_57=m.concat(me.im_preargs,_57); -} -var _52=me.im_self; -if(!_52){ -_52=this; -} -return me.im_func.apply(_52,_57); -}; -_56.im_self=_55; -_56.im_func=_53; -_56.im_preargs=_54; -return _56; -},bindMethods:function(_58){ -var _59=MochiKit.Base.bind; -for(var k in _58){ -var _60=_58[k]; -if(typeof (_60)=="function"){ -_58[k]=_59(_60,_58); -} -} -},registerComparator:function(_61,_62,_63,_64){ -MochiKit.Base.comparatorRegistry.register(_61,_62,_63,_64); -},_primitives:{"bool":true,"string":true,"number":true},compare:function(a,b){ -if(a==b){ -return 0; -} -var _65=(typeof (a)=="undefined"||a===null); -var _66=(typeof (b)=="undefined"||b===null); -if(_65&&_66){ -return 0; -}else{ -if(_65){ -return -1; -}else{ -if(_66){ -return 1; -} -} -} -var m=MochiKit.Base; -var _67=m._primitives; -if(!(typeof (a) in _67&&typeof (b) in _67)){ -try{ -return m.comparatorRegistry.match(a,b); -} -catch(e){ -if(e!=m.NotFound){ -throw e; -} -} -} -if(ab){ -return 1; -} -} -var _68=m.repr; -throw new TypeError(_68(a)+" and "+_68(b)+" can not be compared"); -},compareDateLike:function(a,b){ -return MochiKit.Base.compare(a.getTime(),b.getTime()); -},compareArrayLike:function(a,b){ -var _69=MochiKit.Base.compare; -var _70=a.length; -var _71=0; -if(_70>b.length){ -_71=1; -_70=b.length; -}else{ -if(_700))){ -var kv=MochiKit.DOM.formContents(_113); -_113=kv[0]; -_114=kv[1]; -}else{ -if(arguments.length==1){ -var o=_113; -_113=[]; -_114=[]; -for(var k in o){ -var v=o[k]; -if(typeof (v)!="function"){ -_113.push(k); -_114.push(v); -} -} -} -} -var rval=[]; -var len=Math.min(_113.length,_114.length); -var _118=MochiKit.Base.urlEncode; -for(var i=0;i=stop){ -throw self.StopIteration; -} -_147+=step; -return rval; -}}; -},imap:function(fun,p,q){ -var m=MochiKit.Base; -var self=MochiKit.Iter; -var _151=m.map(self.iter,m.extend(null,arguments,1)); -var map=m.map; -var next=self.next; -return {repr:function(){ -return "imap(...)"; -},toString:m.forwardCall("repr"),next:function(){ -return fun.apply(this,map(next,_151)); -}}; -},applymap:function(fun,seq,self){ -seq=MochiKit.Iter.iter(seq); -var m=MochiKit.Base; -return {repr:function(){ -return "applymap(...)"; -},toString:m.forwardCall("repr"),next:function(){ -return fun.apply(self,seq.next()); -}}; -},chain:function(p,q){ -var self=MochiKit.Iter; -var m=MochiKit.Base; -if(arguments.length==1){ -return self.iter(arguments[0]); -} -var _153=m.map(self.iter,arguments); -return {repr:function(){ -return "chain(...)"; -},toString:m.forwardCall("repr"),next:function(){ -while(_153.length>1){ -try{ -return _153[0].next(); -} -catch(e){ -if(e!=self.StopIteration){ -throw e; -} -_153.shift(); -} -} -if(_153.length==1){ -var arg=_153.shift(); -this.next=m.bind("next",arg); -return this.next(); -} -throw self.StopIteration; -}}; -},takewhile:function(pred,seq){ -var self=MochiKit.Iter; -seq=self.iter(seq); -return {repr:function(){ -return "takewhile(...)"; -},toString:MochiKit.Base.forwardCall("repr"),next:function(){ -var rval=seq.next(); -if(!pred(rval)){ -this.next=function(){ -throw self.StopIteration; -}; -this.next(); -} -return rval; -}}; -},dropwhile:function(pred,seq){ -seq=MochiKit.Iter.iter(seq); -var m=MochiKit.Base; -var bind=m.bind; -return {"repr":function(){ -return "dropwhile(...)"; -},"toString":m.forwardCall("repr"),"next":function(){ -while(true){ -var rval=seq.next(); -if(!pred(rval)){ -break; -} -} -this.next=bind("next",seq); -return rval; -}}; -},_tee:function(_155,sync,_157){ -sync.pos[_155]=-1; -var m=MochiKit.Base; -var _158=m.listMin; -return {repr:function(){ -return "tee("+_155+", ...)"; -},toString:m.forwardCall("repr"),next:function(){ -var rval; -var i=sync.pos[_155]; -if(i==sync.max){ -rval=_157.next(); -sync.deque.push(rval); -sync.max+=1; -sync.pos[_155]+=1; -}else{ -rval=sync.deque[i-sync.min]; -sync.pos[_155]+=1; -if(i==sync.min&&_158(sync.pos)!=sync.min){ -sync.min+=1; -sync.deque.shift(); -} -} -return rval; -}}; -},tee:function(_159,n){ -var rval=[]; -var sync={"pos":[],"deque":[],"max":-1,"min":-1}; -if(arguments.length==1){ -n=2; -} -var self=MochiKit.Iter; -_159=self.iter(_159); -var _tee=self._tee; -for(var i=0;i0&&_165>=stop)||(step<0&&_165<=stop)){ -throw MochiKit.Iter.StopIteration; -} -var rval=_165; -_165+=step; -return rval; -},repr:function(){ -return "range("+[_165,stop,step].join(", ")+")"; -},toString:MochiKit.Base.forwardCall("repr")}; -},sum:function(_166,_167){ -var x=_167||0; -var self=MochiKit.Iter; -_166=self.iter(_166); -try{ -while(true){ -x+=_166.next(); -} -} -catch(e){ -if(e!=self.StopIteration){ -throw e; -} -} -return x; -},exhaust:function(_168){ -var self=MochiKit.Iter; -_168=self.iter(_168); -try{ -while(true){ -_168.next(); -} -} -catch(e){ -if(e!=self.StopIteration){ -throw e; -} -} -},forEach:function(_169,func,self){ -var m=MochiKit.Base; -if(arguments.length>2){ -func=m.bind(func,self); -} -if(m.isArrayLike(_169)){ -try{ -for(var i=0;i<_169.length;i++){ -func(_169[i]); -} -} -catch(e){ -if(e!=MochiKit.Iter.StopIteration){ -throw e; -} -} -}else{ -self=MochiKit.Iter; -self.exhaust(self.imap(func,_169)); -} -},every:function(_171,func){ -var self=MochiKit.Iter; -try{ -self.ifilterfalse(func,_171).next(); -return false; -} -catch(e){ -if(e!=self.StopIteration){ -throw e; -} -return true; -} -},sorted:function(_172,cmp){ -var rval=MochiKit.Iter.list(_172); -if(arguments.length==1){ -cmp=MochiKit.Base.compare; -} -rval.sort(cmp); -return rval; -},reversed:function(_173){ -var rval=MochiKit.Iter.list(_173); -rval.reverse(); -return rval; -},some:function(_174,func){ -var self=MochiKit.Iter; -try{ -self.ifilter(func,_174).next(); -return true; -} -catch(e){ -if(e!=self.StopIteration){ -throw e; -} -return false; -} -},iextend:function(lst,_175){ -if(MochiKit.Base.isArrayLike(_175)){ -for(var i=0;i<_175.length;i++){ -lst.push(_175[i]); -} -}else{ -var self=MochiKit.Iter; -_175=self.iter(_175); -try{ -while(true){ -lst.push(_175.next()); -} -} -catch(e){ -if(e!=self.StopIteration){ -throw e; -} -} -} -return lst; -},groupby:function(_176,_177){ -var m=MochiKit.Base; -var self=MochiKit.Iter; -if(arguments.length<2){ -_177=m.operator.identity; -} -_176=self.iter(_176); -var pk=undefined; -var k=undefined; -var v; -function fetch(){ -v=_176.next(); -k=_177(v); -} -function eat(){ -var ret=v; -v=undefined; -return ret; -} -var _180=true; -return {repr:function(){ -return "groupby(...)"; -},next:function(){ -while(k==pk){ -fetch(); -if(_180){ -_180=false; -break; -} -} -pk=k; -return [k,{next:function(){ -if(v==undefined){ -fetch(); -} -if(k!=pk){ -throw self.StopIteration; -} -return eat(); -}}]; -}}; -},groupby_as_array:function(_181,_182){ -var m=MochiKit.Base; -var self=MochiKit.Iter; -if(arguments.length<2){ -_182=m.operator.identity; -} -_181=self.iter(_181); -var _183=[]; -var _184=true; -var _185; -while(true){ -try{ -var _186=_181.next(); -var key=_182(_186); -} -catch(e){ -if(e==self.StopIteration){ -break; -} -throw e; -} -if(_184||key!=_185){ -var _187=[]; -_183.push([key,_187]); -} -_187.push(_186); -_184=false; -_185=key; -} -return _183; -},arrayLikeIter:function(_188){ -var i=0; -return {repr:function(){ -return "arrayLikeIter(...)"; -},toString:MochiKit.Base.forwardCall("repr"),next:function(){ -if(i>=_188.length){ -throw MochiKit.Iter.StopIteration; -} -return _188[i++]; -}}; -},hasIterateNext:function(_189){ -return (_189&&typeof (_189.iterateNext)=="function"); -},iterateNextIter:function(_190){ -return {repr:function(){ -return "iterateNextIter(...)"; -},toString:MochiKit.Base.forwardCall("repr"),next:function(){ -var rval=_190.iterateNext(); -if(rval===null||rval===undefined){ -throw MochiKit.Iter.StopIteration; -} -return rval; -}}; -}}); -MochiKit.Iter.EXPORT_OK=["iteratorRegistry","arrayLikeIter","hasIterateNext","iterateNextIter",]; -MochiKit.Iter.EXPORT=["StopIteration","registerIteratorFactory","iter","count","cycle","repeat","next","izip","ifilter","ifilterfalse","islice","imap","applymap","chain","takewhile","dropwhile","tee","list","reduce","range","sum","exhaust","forEach","every","sorted","reversed","some","iextend","groupby","groupby_as_array"]; -MochiKit.Iter.__new__=function(){ -var m=MochiKit.Base; -this.StopIteration=new m.NamedError("StopIteration"); -this.iteratorRegistry=new m.AdapterRegistry(); -this.registerIteratorFactory("arrayLike",m.isArrayLike,this.arrayLikeIter); -this.registerIteratorFactory("iterateNext",this.hasIterateNext,this.iterateNextIter); -this.EXPORT_TAGS={":common":this.EXPORT,":all":m.concat(this.EXPORT,this.EXPORT_OK)}; -m.nameFunctions(this); -}; -MochiKit.Iter.__new__(); -if(!MochiKit.__compat__){ -reduce=MochiKit.Iter.reduce; -} -MochiKit.Base._exportSymbols(this,MochiKit.Iter); -if(typeof (dojo)!="undefined"){ -dojo.provide("MochiKit.Logging"); -dojo.require("MochiKit.Base"); -} -if(typeof (JSAN)!="undefined"){ -JSAN.use("MochiKit.Base",[]); -} -try{ -if(typeof (MochiKit.Base)=="undefined"){ -throw ""; -} -} -catch(e){ -throw "MochiKit.Logging depends on MochiKit.Base!"; -} -if(typeof (MochiKit.Logging)=="undefined"){ -MochiKit.Logging={}; -} -MochiKit.Logging.NAME="MochiKit.Logging"; -MochiKit.Logging.VERSION="1.3"; -MochiKit.Logging.__repr__=function(){ -return "["+this.NAME+" "+this.VERSION+"]"; -}; -MochiKit.Logging.toString=function(){ -return this.__repr__(); -}; -MochiKit.Logging.EXPORT=["LogLevel","LogMessage","Logger","alertListener","logger","log","logError","logDebug","logFatal","logWarning"]; -MochiKit.Logging.EXPORT_OK=["logLevelAtLeast","isLogMessage","compareLogMessage"]; -MochiKit.Logging.LogMessage=function(num,_192,info){ -this.num=num; -this.level=_192; -this.info=info; -this.timestamp=new Date(); -}; -MochiKit.Logging.LogMessage.prototype={repr:function(){ -var m=MochiKit.Base; -return "LogMessage("+m.map(m.repr,[this.num,this.level,this.info]).join(", ")+")"; -},toString:MochiKit.Base.forwardCall("repr")}; -MochiKit.Base.update(MochiKit.Logging,{logLevelAtLeast:function(_194){ -var self=MochiKit.Logging; -if(typeof (_194)=="string"){ -_194=self.LogLevel[_194]; -} -return function(msg){ -var _196=msg.level; -if(typeof (_196)=="string"){ -_196=self.LogLevel[_196]; -} -return _196>=_194; -}; -},isLogMessage:function(){ -var _197=MochiKit.Logging.LogMessage; -for(var i=0;i=0&&this._messages.length>this.maxSize){ -this._messages.shift(); -} -},getMessages:function(_206){ -var _207=0; -if(!(typeof (_206)=="undefined"||_206===null)){ -_207=Math.max(0,this._messages.length-_206); -} -return this._messages.slice(_207); -},getMessageText:function(_208){ -if(typeof (_208)=="undefined"||_208===null){ -_208=30; -} -var _209=this.getMessages(_208); -if(_209.length){ -var lst=map(function(m){ -return "\n ["+m.num+"] "+m.level+": "+m.info.join(" "); -},_209); -lst.unshift("LAST "+_209.length+" MESSAGES:"); -return lst.join(""); -} -return ""; -},debuggingBookmarklet:function(_210){ -if(typeof (MochiKit.LoggingPane)=="undefined"){ -alert(this.getMessageText()); -}else{ -MochiKit.LoggingPane.createLoggingPane(_210||false); -} -}}; -MochiKit.Logging.__new__=function(){ -this.LogLevel={ERROR:40,FATAL:50,WARNING:30,INFO:20,DEBUG:10}; -var m=MochiKit.Base; -m.registerComparator("LogMessage",this.isLogMessage,this.compareLogMessage); -var _211=m.partial; -var _212=this.Logger; -var _213=_212.prototype.baseLog; -m.update(this.Logger.prototype,{debug:_211(_213,"DEBUG"),log:_211(_213,"INFO"),error:_211(_213,"ERROR"),fatal:_211(_213,"FATAL"),warning:_211(_213,"WARNING")}); -var self=this; -var _214=function(name){ -return function(){ -self.logger[name].apply(self.logger,arguments); -}; -}; -this.log=_214("log"); -this.logError=_214("error"); -this.logDebug=_214("debug"); -this.logFatal=_214("fatal"); -this.logWarning=_214("warning"); -this.logger=new _212(); -this.logger.useNativeConsole=true; -this.EXPORT_TAGS={":common":this.EXPORT,":all":m.concat(this.EXPORT,this.EXPORT_OK)}; -m.nameFunctions(this); -}; -if(typeof (printfire)=="undefined"&&typeof (document)!="undefined"&&document.createEvent&&typeof (dispatchEvent)!="undefined"){ -function printfire(){ -printfire.args=arguments; -var ev=document.createEvent("Events"); -ev.initEvent("printfire",false,true); -dispatchEvent(ev); -} -} -MochiKit.Logging.__new__(); -MochiKit.Base._exportSymbols(this,MochiKit.Logging); -if(typeof (dojo)!="undefined"){ -dojo.provide("MochiKit.DateTime"); -} -if(typeof (MochiKit)=="undefined"){ -MochiKit={}; -} -if(typeof (MochiKit.DateTime)=="undefined"){ -MochiKit.DateTime={}; -} -MochiKit.DateTime.NAME="MochiKit.DateTime"; -MochiKit.DateTime.VERSION="1.3"; -MochiKit.DateTime.__repr__=function(){ -return "["+this.NAME+" "+this.VERSION+"]"; -}; -MochiKit.DateTime.toString=function(){ -return this.__repr__(); -}; -MochiKit.DateTime.isoDate=function(str){ -str=str+""; -if(typeof (str)!="string"||str.length===0){ -return null; -} -var iso=str.split("-"); -if(iso.length===0){ -return null; -} -return new Date(iso[0],iso[1]-1,iso[2]); -}; -MochiKit.DateTime._isoRegexp=/(\d{4,})(?:-(\d{1,2})(?:-(\d{1,2})(?:[T ](\d{1,2}):(\d{1,2})(?::(\d{1,2})(?:\.(\d+))?)?(?:(Z)|([+-])(\d{1,2})(?::(\d{1,2}))?)?)?)?)?/; -MochiKit.DateTime.isoTimestamp=function(str){ -str=str+""; -if(typeof (str)!="string"||str.length===0){ -return null; -} -var res=str.match(MochiKit.DateTime._isoRegexp); -if(typeof (res)=="undefined"||res===null){ -return null; -} -var year,month,day,hour,min,sec,msec; -year=parseInt(res[1],10); -if(typeof (res[2])=="undefined"||res[2]===""){ -return new Date(year); -} -month=parseInt(res[2],10)-1; -day=parseInt(res[3],10); -if(typeof (res[4])=="undefined"||res[4]===""){ -return new Date(year,month,day); -} -hour=parseInt(res[4],10); -min=parseInt(res[5],10); -sec=(typeof (res[6])!="undefined"&&res[6]!=="")?parseInt(res[6],10):0; -if(typeof (res[7])!="undefined"&&res[7]!==""){ -msec=Math.round(1000*parseFloat("0."+res[7])); -}else{ -msec=0; -} -if((typeof (res[8])=="undefined"||res[8]==="")&&(typeof (res[9])=="undefined"||res[9]==="")){ -return new Date(year,month,day,hour,min,sec,msec); -} -var ofs; -if(typeof (res[9])!="undefined"&&res[9]!==""){ -ofs=parseInt(res[10],10)*3600000; -if(typeof (res[11])!="undefined"&&res[11]!==""){ -ofs+=parseInt(res[11],10)*60000; -} -if(res[9]=="-"){ -ofs=-ofs; -} -}else{ -ofs=0; -} -return new Date(Date.UTC(year,month,day,hour,min,sec,msec)-ofs); -}; -MochiKit.DateTime.toISOTime=function(date,_221){ -if(typeof (date)=="undefined"||date===null){ -return null; -} -var hh=date.getHours(); -var mm=date.getMinutes(); -var ss=date.getSeconds(); -var lst=[((_221&&(hh<10))?"0"+hh:hh),((mm<10)?"0"+mm:mm),((ss<10)?"0"+ss:ss)]; -return lst.join(":"); -}; -MochiKit.DateTime.toISOTimestamp=function(date,_225){ -if(typeof (date)=="undefined"||date===null){ -return null; -} -var sep=_225?"T":" "; -var foot=_225?"Z":""; -if(_225){ -date=new Date(date.getTime()+(date.getTimezoneOffset()*60000)); -} -return MochiKit.DateTime.toISODate(date)+sep+MochiKit.DateTime.toISOTime(date,_225)+foot; -}; -MochiKit.DateTime.toISODate=function(date){ -if(typeof (date)=="undefined"||date===null){ -return null; -} -var _228=MochiKit.DateTime._padTwo; -return [date.getFullYear(),_228(date.getMonth()+1),_228(date.getDate())].join("-"); -}; -MochiKit.DateTime.americanDate=function(d){ -d=d+""; -if(typeof (d)!="string"||d.length===0){ -return null; -} -var a=d.split("/"); -return new Date(a[2],a[0]-1,a[1]); -}; -MochiKit.DateTime._padTwo=function(n){ -return (n>9)?n:"0"+n; -}; -MochiKit.DateTime.toPaddedAmericanDate=function(d){ -if(typeof (d)=="undefined"||d===null){ -return null; -} -var _230=MochiKit.DateTime._padTwo; -return [_230(d.getMonth()+1),_230(d.getDate()),d.getFullYear()].join("/"); -}; -MochiKit.DateTime.toAmericanDate=function(d){ -if(typeof (d)=="undefined"||d===null){ -return null; -} -return [d.getMonth()+1,d.getDate(),d.getFullYear()].join("/"); -}; -MochiKit.DateTime.EXPORT=["isoDate","isoTimestamp","toISOTime","toISOTimestamp","toISODate","americanDate","toPaddedAmericanDate","toAmericanDate"]; -MochiKit.DateTime.EXPORT_OK=[]; -MochiKit.DateTime.EXPORT_TAGS={":common":MochiKit.DateTime.EXPORT,":all":MochiKit.DateTime.EXPORT}; -MochiKit.DateTime.__new__=function(){ -var base=this.NAME+"."; -for(var k in this){ -var o=this[k]; -if(typeof (o)=="function"&&typeof (o.NAME)=="undefined"){ -try{ -o.NAME=base+k; -} -catch(e){ -} -} -} -}; -MochiKit.DateTime.__new__(); -if(typeof (MochiKit.Base)!="undefined"){ -MochiKit.Base._exportSymbols(this,MochiKit.DateTime); -}else{ -(function(_231,_232){ -if((typeof (JSAN)=="undefined"&&typeof (dojo)=="undefined")||(typeof (MochiKit.__compat__)=="boolean"&&MochiKit.__compat__)){ -var all=_232.EXPORT_TAGS[":all"]; -for(var i=0;i_240){ -var i=_246.length-_240; -res=fmt.separator+_246.substring(i,_246.length)+res; -_246=_246.substring(0,i); -} -} -res=_246+res; -if(_238>0){ -while(frac.length<_241){ -frac=frac+"0"; -} -res=res+fmt.decimal+frac; -} -return _242+res+_243; -}; -}; -MochiKit.Format.numberFormatter=function(_248,_249,_250){ -if(typeof (_249)=="undefined"){ -_249=""; -} -var _251=_248.match(/((?:[0#]+,)?[0#]+)(?:\.([0#]+))?(%)?/); -if(!_251){ -throw TypeError("Invalid pattern"); -} -var _252=_248.substr(0,_251.index); -var _253=_248.substr(_251.index+_251[0].length); -if(_252.search(/-/)==-1){ -_252=_252+"-"; -} -var _254=_251[1]; -var frac=(typeof (_251[2])=="string"&&_251[2]!="")?_251[2]:""; -var _255=(typeof (_251[3])=="string"&&_251[3]!=""); -var tmp=_254.split(/,/); -var _257; -if(typeof (_250)=="undefined"){ -_250="default"; -} -if(tmp.length==1){ -_257=null; -}else{ -_257=tmp[1].length; -} -var _258=_254.length-_254.replace(/0/g,"").length; -var _259=frac.length-frac.replace(/0/g,"").length; -var _260=frac.length; -var rval=MochiKit.Format._numberFormatter(_249,_252,_253,_250,_255,_260,_258,_257,_259); -var m=MochiKit.Base; -if(m){ -var fn=arguments.callee; -var args=m.concat(arguments); -rval.repr=function(){ -return [self.NAME,"(",map(m.repr,args).join(", "),")"].join(""); -}; -} -return rval; -}; -MochiKit.Format.formatLocale=function(_262){ -if(typeof (_262)=="undefined"||_262===null){ -_262="default"; -} -if(typeof (_262)=="string"){ -var rval=MochiKit.Format.LOCALE[_262]; -if(typeof (rval)=="string"){ -rval=arguments.callee(rval); -MochiKit.Format.LOCALE[_262]=rval; -} -return rval; -}else{ -return _262; -} -}; -MochiKit.Format.twoDigitAverage=function(_263,_264){ -if(_264){ -var res=_263/_264; -if(!isNaN(res)){ -return MochiKit.Format.twoDigitFloat(_263/_264); -} -} -return "0"; -}; -MochiKit.Format.twoDigitFloat=function(_265){ -var sign=(_265<0?"-":""); -var s=Math.floor(Math.abs(_265)*100).toString(); -if(s=="0"){ -return s; -} -if(s.length<3){ -while(s.charAt(s.length-1)=="0"){ -s=s.substring(0,s.length-1); -} -return sign+"0."+s; -} -var head=sign+s.substring(0,s.length-2); -var tail=s.substring(s.length-2,s.length); -if(tail=="00"){ -return head; -}else{ -if(tail.charAt(1)=="0"){ -return head+"."+tail.charAt(0); -}else{ -return head+"."+tail; -} -} -}; -MochiKit.Format.lstrip=function(str,_270){ -str=str+""; -if(typeof (str)!="string"){ -return null; -} -if(!_270){ -return str.replace(/^\s+/,""); -}else{ -return str.replace(new RegExp("^["+_270+"]+"),""); -} -}; -MochiKit.Format.rstrip=function(str,_271){ -str=str+""; -if(typeof (str)!="string"){ -return null; -} -if(!_271){ -return str.replace(/\s+$/,""); -}else{ -return str.replace(new RegExp("["+_271+"]+$"),""); -} -}; -MochiKit.Format.strip=function(str,_272){ -var self=MochiKit.Format; -return self.rstrip(self.lstrip(str,_272),_272); -}; -MochiKit.Format.truncToFixed=function(_273,_274){ -_273=Math.floor(_273*Math.pow(10,_274)); -var res=(_273*Math.pow(10,-_274)).toFixed(_274); -if(res.charAt(0)=="."){ -res="0"+res; -} -return res; -}; -MochiKit.Format.roundToFixed=function(_275,_276){ -return MochiKit.Format.truncToFixed(_275+0.5*Math.pow(10,-_276),_276); -}; -MochiKit.Format.percentFormat=function(_277){ -return MochiKit.Format.twoDigitFloat(100*_277)+"%"; -}; -MochiKit.Format.EXPORT=["truncToFixed","roundToFixed","numberFormatter","formatLocale","twoDigitAverage","twoDigitFloat","percentFormat","lstrip","rstrip","strip"]; -MochiKit.Format.LOCALE={en_US:{separator:",",decimal:".",percent:"%"},de_DE:{separator:".",decimal:",",percent:"%"},fr_FR:{separator:" ",decimal:",",percent:"%"},"default":"en_US"}; -MochiKit.Format.EXPORT_OK=[]; -MochiKit.Format.EXPORT_TAGS={":all":MochiKit.Format.EXPORT,":common":MochiKit.Format.EXPORT}; -MochiKit.Format.__new__=function(){ -var base=this.NAME+"."; -var k,v,o; -for(k in this.LOCALE){ -o=this.LOCALE[k]; -if(typeof (o)=="object"){ -o.repr=function(){ -return this.NAME; -}; -o.NAME=base+"LOCALE."+k; -} -} -for(k in this){ -o=this[k]; -if(typeof (o)=="function"&&typeof (o.NAME)=="undefined"){ -try{ -o.NAME=base+k; -} -catch(e){ -} -} -} -}; -MochiKit.Format.__new__(); -if(typeof (MochiKit.Base)!="undefined"){ -MochiKit.Base._exportSymbols(this,MochiKit.Format); -}else{ -(function(_278,_279){ -if((typeof (JSAN)=="undefined"&&typeof (dojo)=="undefined")||(typeof (MochiKit.__compat__)=="boolean"&&MochiKit.__compat__)){ -var all=_279.EXPORT_TAGS[":all"]; -for(var i=0;i=0)){ -this._fire(); -} -},_continue:function(res){ -this._resback(res); -this._unpause(); -},_resback:function(res){ -this.fired=((res instanceof Error)?1:0); -this.results[this.fired]=res; -this._fire(); -},_check:function(){ -if(this.fired!=-1){ -if(!this.silentlyCancelled){ -throw new MochiKit.Async.AlreadyCalledError(this); -} -this.silentlyCancelled=false; -return; -} -},callback:function(res){ -this._check(); -if(res instanceof MochiKit.Async.Deferred){ -throw new Error("Deferred instances can only be chained if they are the result of a callback"); -} -this._resback(res); -},errback:function(res){ -this._check(); -var self=MochiKit.Async; -if(res instanceof self.Deferred){ -throw new Error("Deferred instances can only be chained if they are the result of a callback"); -} -if(!(res instanceof Error)){ -res=new self.GenericError(res); -} -this._resback(res); -},addBoth:function(fn){ -if(arguments.length>1){ -fn=MochiKit.Base.partial.apply(null,arguments); -} -return this.addCallbacks(fn,fn); -},addCallback:function(fn){ -if(arguments.length>1){ -fn=MochiKit.Base.partial.apply(null,arguments); -} -return this.addCallbacks(fn,null); -},addErrback:function(fn){ -if(arguments.length>1){ -fn=MochiKit.Base.partial.apply(null,arguments); -} -return this.addCallbacks(null,fn); -},addCallbacks:function(cb,eb){ -if(this.chained){ -throw new Error("Chained Deferreds can not be re-used"); -} -this.chain.push([cb,eb]); -if(this.fired>=0){ -this._fire(); -} -return this; -},_fire:function(){ -var _284=this.chain; -var _285=this.fired; -var res=this.results[_285]; -var self=this; -var cb=null; -while(_284.length>0&&this.paused===0){ -var pair=_284.shift(); -var f=pair[_285]; -if(f===null){ -continue; -} -try{ -res=f(res); -_285=((res instanceof Error)?1:0); -if(res instanceof MochiKit.Async.Deferred){ -cb=function(res){ -self._continue(res); -}; -this._pause(); -} -} -catch(err){ -_285=1; -if(!(err instanceof Error)){ -err=new MochiKit.Async.GenericError(err); -} -res=err; -} -} -this.fired=_285; -this.results[_285]=res; -if(cb&&this.paused){ -res.addBoth(cb); -res.chained=true; -} -}}; -MochiKit.Base.update(MochiKit.Async,{evalJSONRequest:function(){ -return eval("("+arguments[0].responseText+")"); -},succeed:function(_287){ -var d=new MochiKit.Async.Deferred(); -d.callback.apply(d,arguments); -return d; -},fail:function(_288){ -var d=new MochiKit.Async.Deferred(); -d.errback.apply(d,arguments); -return d; -},getXMLHttpRequest:function(){ -var self=arguments.callee; -if(!self.XMLHttpRequest){ -var _289=[function(){ -return new XMLHttpRequest(); -},function(){ -return new ActiveXObject("Msxml2.XMLHTTP"); -},function(){ -return new ActiveXObject("Microsoft.XMLHTTP"); -},function(){ -return new ActiveXObject("Msxml2.XMLHTTP.4.0"); -},function(){ -throw new MochiKit.Async.BrowserComplianceError("Browser does not support XMLHttpRequest"); -}]; -for(var i=0;i<_289.length;i++){ -var func=_289[i]; -try{ -self.XMLHttpRequest=func; -return func(); -} -catch(e){ -} -} -} -return self.XMLHttpRequest(); -},sendXMLHttpRequest:function(req,_291){ -if(_291===null){ -_291=""; -} -var _292=function(){ -try{ -req.onreadystatechange=null; -} -catch(e){ -try{ -req.onreadystatechange=function(){ -}; -} -catch(e){ -} -} -req.abort(); -}; -var self=MochiKit.Async; -var d=new self.Deferred(_292); -var _293=function(){ -if(req.readyState==4){ -try{ -req.onreadystatechange=null; -} -catch(e){ -try{ -req.onreadystatechange=function(){ -}; -} -catch(e){ -} -} -var _294=null; -try{ -_294=req.status; -if(!_294&&MochiKit.Base.isNotEmpty(req.responseText)){ -_294=304; -} -} -catch(e){ -} -if(_294==200||_294==304){ -d.callback(req); -}else{ -var err=new self.XMLHttpRequestError(req,"Request failed"); -if(err.number){ -d.errback(err); -}else{ -d.errback(err); -} -} -} -}; -try{ -req.onreadystatechange=_293; -req.send(_291); -} -catch(e){ -try{ -req.onreadystatechange=null; -} -catch(ignore){ -} -d.errback(e); -} -return d; -},doSimpleXMLHttpRequest:function(url){ -var self=MochiKit.Async; -var req=self.getXMLHttpRequest(); -if(arguments.length>1){ -var m=MochiKit.Base; -var qs=m.queryString.apply(null,m.extend(null,arguments,1)); -if(qs){ -url+="?"+qs; -} -} -req.open("GET",url,true); -return self.sendXMLHttpRequest(req); -},loadJSONDoc:function(url){ -var self=MochiKit.Async; -var d=self.doSimpleXMLHttpRequest.apply(self,arguments); -d=d.addCallback(self.evalJSONRequest); -return d; -},wait:function(_298,_299){ -var d=new MochiKit.Async.Deferred(); -var m=MochiKit.Base; -if(typeof (_299)!="undefined"){ -d.addCallback(function(){ -return _299; -}); -} -var _300=setTimeout(m.bind("callback",d),Math.floor(_298*1000)); -d.canceller=function(){ -try{ -clearTimeout(_300); -} -catch(e){ -} -}; -return d; -},callLater:function(_301,func){ -var m=MochiKit.Base; -var _302=m.partial.apply(m,m.extend(null,arguments,1)); -return MochiKit.Async.wait(_301).addCallback(function(res){ -return _302(); -}); -}}); -MochiKit.Async.DeferredLock=function(){ -this.waiting=[]; -this.locked=false; -this.id=this._nextId(); -}; -MochiKit.Async.DeferredLock.prototype={__class__:MochiKit.Async.DeferredLock,acquire:function(){ -d=new MochiKit.Async.Deferred(); -if(this.locked){ -this.waiting.push(d); -}else{ -this.locked=true; -d.callback(this); -} -return d; -},release:function(){ -if(!this.locked){ -throw TypeError("Tried to release an unlocked DeferredLock"); -} -this.locked=false; -if(this.waiting.length>0){ -this.locked=true; -this.waiting.shift().callback(this); -} -},_nextId:MochiKit.Base.counter(),repr:function(){ -var _303; -if(this.locked){ -_303="locked, "+this.waiting.length+" waiting"; -}else{ -_303="unlocked"; -} -return "DeferredLock("+this.id+", "+_303+")"; -},toString:MochiKit.Base.forwardCall("repr")}; -MochiKit.Async.DeferredList=function(list,_305,_306,_307,_308){ -this.list=list; -this.resultList=new Array(this.list.length); -this.chain=[]; -this.id=this._nextId(); -this.fired=-1; -this.paused=0; -this.results=[null,null]; -this.canceller=_308; -this.silentlyCancelled=false; -if(this.list.length===0&&!_305){ -this.callback(this.resultList); -} -this.finishedCount=0; -this.fireOnOneCallback=_305; -this.fireOnOneErrback=_306; -this.consumeErrors=_307; -var _309=0; -MochiKit.Base.map(MochiKit.Base.bind(function(d){ -d.addCallback(MochiKit.Base.bind(this._cbDeferred,this),_309,true); -d.addErrback(MochiKit.Base.bind(this._cbDeferred,this),_309,false); -_309+=1; -},this),this.list); -}; -MochiKit.Base.update(MochiKit.Async.DeferredList.prototype,MochiKit.Async.Deferred.prototype); -MochiKit.Base.update(MochiKit.Async.DeferredList.prototype,{_cbDeferred:function(_310,_311,_312){ -this.resultList[_310]=[_311,_312]; -this.finishedCount+=1; -if(this.fired!==0){ -if(_311&&this.fireOnOneCallback){ -this.callback([_310,_312]); -}else{ -if(!_311&&this.fireOnOneErrback){ -this.errback(_312); -}else{ -if(this.finishedCount==this.list.length){ -this.callback(this.resultList); -} -} -} -} -if(!_311&&this.consumeErrors){ -_312=null; -} -return _312; -}}); -MochiKit.Async.gatherResults=function(_313){ -var d=new MochiKit.Async.DeferredList(_313,false,true,false); -d.addCallback(function(_314){ -var ret=[]; -for(var i=0;i<_314.length;i++){ -ret.push(_314[i][1]); -} -return ret; -}); -return d; -}; -MochiKit.Async.maybeDeferred=function(func){ -var self=MochiKit.Async; -var _315; -try{ -var r=func.apply(null,MochiKit.Base.extend([],arguments,1)); -if(r instanceof self.Deferred){ -_315=r; -}else{ -if(r instanceof Error){ -_315=self.fail(r); -}else{ -_315=self.succeed(r); -} -} -} -catch(e){ -_315=self.fail(e); -} -return _315; -}; -MochiKit.Async.EXPORT=["AlreadyCalledError","CancelledError","BrowserComplianceError","GenericError","XMLHttpRequestError","Deferred","succeed","fail","getXMLHttpRequest","doSimpleXMLHttpRequest","loadJSONDoc","wait","callLater","sendXMLHttpRequest","DeferredLock","DeferredList","gatherResults","maybeDeferred"]; -MochiKit.Async.EXPORT_OK=["evalJSONRequest"]; -MochiKit.Async.__new__=function(){ -var m=MochiKit.Base; -var ne=m.partial(m._newNamedError,this); -ne("AlreadyCalledError",function(_318){ -this.deferred=_318; -}); -ne("CancelledError",function(_319){ -this.deferred=_319; -}); -ne("BrowserComplianceError",function(msg){ -this.message=msg; -}); -ne("GenericError",function(msg){ -this.message=msg; -}); -ne("XMLHttpRequestError",function(req,msg){ -this.req=req; -this.message=msg; -try{ -this.number=req.status; -} -catch(e){ -} -}); -this.EXPORT_TAGS={":common":this.EXPORT,":all":m.concat(this.EXPORT,this.EXPORT_OK)}; -m.nameFunctions(this); -}; -MochiKit.Async.__new__(); -MochiKit.Base._exportSymbols(this,MochiKit.Async); -if(typeof (dojo)!="undefined"){ -dojo.provide("MochiKit.DOM"); -dojo.require("MochiKit.Iter"); -} -if(typeof (JSAN)!="undefined"){ -JSAN.use("MochiKit.Iter",[]); -} -try{ -if(typeof (MochiKit.Iter)=="undefined"){ -throw ""; -} -} -catch(e){ -throw "MochiKit.DOM depends on MochiKit.Iter!"; -} -if(typeof (MochiKit.DOM)=="undefined"){ -MochiKit.DOM={}; -} -MochiKit.DOM.NAME="MochiKit.DOM"; -MochiKit.DOM.VERSION="1.3"; -MochiKit.DOM.__repr__=function(){ -return "["+this.NAME+" "+this.VERSION+"]"; -}; -MochiKit.DOM.toString=function(){ -return this.__repr__(); -}; -MochiKit.DOM.EXPORT=["formContents","currentWindow","currentDocument","withWindow","withDocument","registerDOMConverter","coerceToDOM","createDOM","createDOMFunc","getNodeAttribute","setNodeAttribute","updateNodeAttributes","appendChildNodes","replaceChildNodes","removeElement","swapDOM","BUTTON","TT","PRE","H1","H2","H3","BR","CANVAS","HR","LABEL","TEXTAREA","FORM","STRONG","SELECT","OPTION","OPTGROUP","LEGEND","FIELDSET","P","UL","OL","LI","TD","TR","THEAD","TBODY","TFOOT","TABLE","TH","INPUT","SPAN","A","DIV","IMG","getElement","$","computedStyle","getElementsByTagAndClassName","addToCallStack","addLoadEvent","focusOnLoad","setElementClass","toggleElementClass","addElementClass","removeElementClass","swapElementClass","hasElementClass","escapeHTML","toHTML","emitHTML","setDisplayForElement","hideElement","showElement","scrapeText","elementDimensions","elementPosition","setElementDimensions","setElementPosition","getViewportDimensions","setOpacity"]; -MochiKit.DOM.EXPORT_OK=["domConverters"]; -MochiKit.DOM.Dimensions=function(w,h){ -this.w=w; -this.h=h; -}; -MochiKit.DOM.Dimensions.prototype.repr=function(){ -var repr=MochiKit.Base.repr; -return "{w: "+repr(this.w)+", h: "+repr(this.h)+"}"; -}; -MochiKit.DOM.Coordinates=function(x,y){ -this.x=x; -this.y=y; -}; -MochiKit.DOM.Coordinates.prototype.repr=function(){ -var repr=MochiKit.Base.repr; -return "{x: "+repr(this.x)+", y: "+repr(this.y)+"}"; -}; -MochiKit.DOM.Coordinates.prototype.toString=function(){ -return this.repr(); -}; -MochiKit.Base.update(MochiKit.DOM,{setOpacity:function(elem,o){ -elem=MochiKit.DOM.getElement(elem); -MochiKit.DOM.updateNodeAttributes(elem,{"style":{"opacity":o,"-moz-opacity":o,"-khtml-opacity":o,"filter":" alpha(opacity="+(o*100)+")"}}); -},getViewportDimensions:function(){ -var d=new MochiKit.DOM.Dimensions(); -var w=MochiKit.DOM._window; -var b=MochiKit.DOM._document.body; -if(w.innerWidth){ -d.w=w.innerWidth; -d.h=w.innerHeight; -}else{ -if(b.parentElement.clientWidth){ -d.w=b.parentElement.clientWidth; -d.h=b.parentElement.clientHeight; -}else{ -if(b&&b.clientWidth){ -d.w=b.clientWidth; -d.h=b.clientHeight; -} -} -} -return d; -},elementDimensions:function(elem){ -var self=MochiKit.DOM; -if(typeof (elem.w)=="number"||typeof (elem.h)=="number"){ -return new self.Dimensions(elem.w||0,elem.h||0); -} -elem=self.getElement(elem); -if(!elem){ -return undefined; -} -if(self.computedStyle(elem,"display")!="none"){ -return new self.Dimensions(elem.offsetWidth||0,elem.offsetHeight||0); -} -var s=elem.style; -var _324=s.visibility; -var _325=s.position; -s.visibility="hidden"; -s.position="absolute"; -s.display=""; -var _326=elem.offsetWidth; -var _327=elem.offsetHeight; -s.display="none"; -s.position=_325; -s.visibility=_324; -return new self.Dimensions(_326,_327); -},elementPosition:function(elem,_328){ -var self=MochiKit.DOM; -elem=self.getElement(elem); -if(!elem){ -return undefined; -} -var c=new self.Coordinates(0,0); -if(elem.x&&elem.y){ -c.x+=elem.x||0; -c.y+=elem.y||0; -return c; -}else{ -if(elem.parentNode===null||self.computedStyle(elem,"display")=="none"){ -return undefined; -} -} -var box=null; -var _331=null; -var d=MochiKit.DOM._document; -var de=d.documentElement; -var b=d.body; -if(elem.getBoundingClientRect){ -box=elem.getBoundingClientRect(); -c.x+=box.left+(de.scrollLeft||b.scrollLeft)-(de.clientLeft||b.clientLeft); -c.y+=box.top+(de.scrollTop||b.scrollTop)-(de.clientTop||b.clientTop); -}else{ -if(d.getBoxObjectFor){ -box=d.getBoxObjectFor(elem); -c.x+=box.x; -c.y+=box.y; -}else{ -if(elem.offsetParent){ -c.x+=elem.offsetLeft; -c.y+=elem.offsetTop; -_331=elem.offsetParent; -if(_331!=elem){ -while(_331){ -c.x+=_331.offsetLeft; -c.y+=_331.offsetTop; -_331=_331.offsetParent; -} -} -var ua=navigator.userAgent.toLowerCase(); -if((typeof (opera)!="undefined"&&parseFloat(opera.version())<9)||(ua.indexOf("safari")!=-1&&self.computedStyle(elem,"position")=="absolute")){ -c.x-=b.offsetLeft; -c.y-=b.offsetTop; -} -} -} -} -if(typeof (_328)!="undefined"){ -_328=arguments.callee(_328); -if(_328){ -c.x-=(_328.x||0); -c.y-=(_328.y||0); -} -} -if(elem.parentNode){ -_331=elem.parentNode; -}else{ -_331=null; -} -while(_331&&_331.tagName!="BODY"&&_331.tagName!="HTML"){ -c.x-=_331.scrollLeft; -c.y-=_331.scrollTop; -if(_331.parentNode){ -_331=_331.parentNode; -}else{ -_331=null; -} -} -return c; -},setElementDimensions:function(elem,_334,_335){ -elem=MochiKit.DOM.getElement(elem); -if(typeof (_335)=="undefined"){ -_335="px"; -} -MochiKit.DOM.updateNodeAttributes(elem,{"style":{"width":_334.w+_335,"height":_334.h+_335}}); -},setElementPosition:function(elem,_336,_337){ -elem=MochiKit.DOM.getElement(elem); -if(typeof (_337)=="undefined"){ -_337="px"; -} -MochiKit.DOM.updateNodeAttributes(elem,{"style":{"left":_336.x+_337,"top":_336.y+_337}}); -},currentWindow:function(){ -return MochiKit.DOM._window; -},currentDocument:function(){ -return MochiKit.DOM._document; -},withWindow:function(win,func){ -var self=MochiKit.DOM; -var _339=self._document; -var _340=self._win; -var rval; -try{ -self._window=win; -self._document=win.document; -rval=func(); -} -catch(e){ -self._window=_340; -self._document=_339; -throw e; -} -self._window=_340; -self._document=_339; -return rval; -},formContents:function(elem){ -var _341=[]; -var _342=[]; -var m=MochiKit.Base; -var self=MochiKit.DOM; -if(typeof (elem)=="undefined"||elem===null){ -elem=self._document; -}else{ -elem=self.getElement(elem); -} -m.nodeWalk(elem,function(elem){ -var name=elem.name; -if(m.isNotEmpty(name)){ -var _343=elem.nodeName; -if(_343=="INPUT"&&(elem.type=="radio"||elem.type=="checkbox")&&!elem.checked){ -return null; -} -if(_343=="SELECT"){ -if(elem.selectedIndex>=0){ -var opt=elem.options[elem.selectedIndex]; -_341.push(name); -_342.push((opt.value)?opt.value:opt.text); -return null; -} -_341.push(name); -_342.push(""); -return null; -} -if(_343=="FORM"||_343=="P"||_343=="SPAN"||_343=="DIV"){ -return elem.childNodes; -} -_341.push(name); -_342.push(elem.value||""); -return null; -} -return elem.childNodes; -}); -return [_341,_342]; -},withDocument:function(doc,func){ -var self=MochiKit.DOM; -var _346=self._document; -var rval; -try{ -self._document=doc; -rval=func(); -} -catch(e){ -self._document=_346; -throw e; -} -self._document=_346; -return rval; -},registerDOMConverter:function(name,_347,wrap,_348){ -MochiKit.DOM.domConverters.register(name,_347,wrap,_348); -},coerceToDOM:function(node,ctx){ -var im=MochiKit.Iter; -var self=MochiKit.DOM; -var iter=im.iter; -var _352=im.repeat; -var imap=im.imap; -var _354=self.domConverters; -var _355=self.coerceToDOM; -var _356=MochiKit.Base.NotFound; -while(true){ -if(typeof (node)=="undefined"||node===null){ -return null; -} -if(typeof (node.nodeType)!="undefined"&&node.nodeType>0){ -return node; -} -if(typeof (node)=="number"||typeof (node)=="bool"){ -node=node.toString(); -} -if(typeof (node)=="string"){ -return self._document.createTextNode(node); -} -if(typeof (node.toDOM)=="function"){ -node=node.toDOM(ctx); -continue; -} -if(typeof (node)=="function"){ -node=node(ctx); -continue; -} -var _357=null; -try{ -_357=iter(node); -} -catch(e){ -} -if(_357){ -return imap(_355,_357,_352(ctx)); -} -try{ -node=_354.match(node,ctx); -continue; -} -catch(e){ -if(e!=_356){ -throw e; -} -} -return self._document.createTextNode(node.toString()); -} -return undefined; -},setNodeAttribute:function(node,attr,_359){ -var o={}; -o[attr]=_359; -try{ -return MochiKit.DOM.updateNodeAttributes(node,o); -} -catch(e){ -} -return null; -},getNodeAttribute:function(node,attr){ -var self=MochiKit.DOM; -var _360=self.attributeArray.renames[attr]; -node=self.getElement(node); -try{ -if(_360){ -return node[_360]; -} -return node.getAttribute(attr); -} -catch(e){ -} -return null; -},updateNodeAttributes:function(node,_361){ -var elem=node; -var self=MochiKit.DOM; -if(typeof (node)=="string"){ -elem=self.getElement(node); -} -if(_361){ -var _362=MochiKit.Base.updatetree; -if(self.attributeArray.compliant){ -for(var k in _361){ -var v=_361[k]; -if(typeof (v)=="object"&&typeof (elem[k])=="object"){ -_362(elem[k],v); -}else{ -if(k.substring(0,2)=="on"){ -if(typeof (v)=="string"){ -v=new Function(v); -} -elem[k]=v; -}else{ -elem.setAttribute(k,v); -} -} -} -}else{ -var _363=self.attributeArray.renames; -for(k in _361){ -v=_361[k]; -var _364=_363[k]; -if(k=="style"&&typeof (v)=="string"){ -elem.style.cssText=v; -}else{ -if(typeof (_364)=="string"){ -elem[_364]=v; -}else{ -if(typeof (elem[k])=="object"&&typeof (v)=="object"){ -_362(elem[k],v); -}else{ -if(k.substring(0,2)=="on"){ -if(typeof (v)=="string"){ -v=new Function(v); -} -elem[k]=v; -}else{ -elem.setAttribute(k,v); -} -} -} -} -} -} -} -return elem; -},appendChildNodes:function(node){ -var elem=node; -var self=MochiKit.DOM; -if(typeof (node)=="string"){ -elem=self.getElement(node); -} -var _365=[self.coerceToDOM(MochiKit.Base.extend(null,arguments,1),elem)]; -var _366=MochiKit.Base.concat; -while(_365.length){ -var n=_365.shift(); -if(typeof (n)=="undefined"||n===null){ -}else{ -if(typeof (n.nodeType)=="number"){ -elem.appendChild(n); -}else{ -_365=_366(n,_365); -} -} -} -return elem; -},replaceChildNodes:function(node){ -var elem=node; -var self=MochiKit.DOM; -if(typeof (node)=="string"){ -elem=self.getElement(node); -arguments[0]=elem; -} -var _367; -while((_367=elem.firstChild)){ -elem.removeChild(_367); -} -if(arguments.length<2){ -return elem; -}else{ -return self.appendChildNodes.apply(this,arguments); -} -},createDOM:function(name,_368){ -var elem; -var self=MochiKit.DOM; -var m=MochiKit.Base; -if(typeof (_368)=="string"||typeof (_368)=="number"){ -var args=m.extend([name,null],arguments,1); -return arguments.callee.apply(this,args); -} -if(typeof (name)=="string"){ -if(_368&&"name" in _368&&!self.attributeArray.compliant){ -name=("<"+name+" name=\""+self.escapeHTML(_368.name)+"\">"); -} -elem=self._document.createElement(name); -}else{ -elem=name; -} -if(_368){ -self.updateNodeAttributes(elem,_368); -} -if(arguments.length<=2){ -return elem; -}else{ -var args=m.extend([elem],arguments,2); -return self.appendChildNodes.apply(this,args); -} -},createDOMFunc:function(){ -var m=MochiKit.Base; -return m.partial.apply(this,m.extend([MochiKit.DOM.createDOM],arguments)); -},swapDOM:function(dest,src){ -var self=MochiKit.DOM; -dest=self.getElement(dest); -var _371=dest.parentNode; -if(src){ -src=self.getElement(src); -_371.replaceChild(src,dest); -}else{ -_371.removeChild(dest); -} -return src; -},getElement:function(id){ -var self=MochiKit.DOM; -if(arguments.length==1){ -return ((typeof (id)=="string")?self._document.getElementById(id):id); -}else{ -return MochiKit.Base.map(self.getElement,arguments); -} -},computedStyle:function(_373,_374,_375){ -if(arguments.length==2){ -_375=_374; -} -var self=MochiKit.DOM; -var el=self.getElement(_373); -var _377=self._document; -if(!el||el==_377){ -return undefined; -} -if(el.currentStyle){ -return el.currentStyle[_374]; -} -if(typeof (_377.defaultView)=="undefined"){ -return undefined; -} -if(_377.defaultView===null){ -return undefined; -} -var _378=_377.defaultView.getComputedStyle(el,null); -if(typeof (_378)=="undefined"||_378===null){ -return undefined; -} -return _378.getPropertyValue(_375); -},getElementsByTagAndClassName:function(_379,_380,_381){ -var self=MochiKit.DOM; -if(typeof (_379)=="undefined"||_379===null){ -_379="*"; -} -if(typeof (_381)=="undefined"||_381===null){ -_381=self._document; -} -_381=self.getElement(_381); -var _382=(_381.getElementsByTagName(_379)||self._document.all); -if(typeof (_380)=="undefined"||_380===null){ -return MochiKit.Base.extend(null,_382); -} -var _383=[]; -for(var i=0;i<_382.length;i++){ -var _384=_382[i]; -var _385=_384.className.split(" "); -for(var j=0;j<_385.length;j++){ -if(_385[j]==_380){ -_383.push(_384); -break; -} -} -} -return _383; -},_newCallStack:function(path,once){ -var rval=function(){ -var _388=arguments.callee.callStack; -for(var i=0;i<_388.length;i++){ -if(_388[i].apply(this,arguments)===false){ -break; -} -} -if(once){ -try{ -this[path]=null; -} -catch(e){ -} -} -}; -rval.callStack=[]; -return rval; -},addToCallStack:function(_389,path,func,once){ -var self=MochiKit.DOM; -var _390=_389[path]; -var _391=_390; -if(!(typeof (_390)=="function"&&typeof (_390.callStack)=="object"&&_390.callStack!==null)){ -_391=self._newCallStack(path,once); -if(typeof (_390)=="function"){ -_391.callStack.push(_390); -} -_389[path]=_391; -} -_391.callStack.push(func); -},addLoadEvent:function(func){ -var self=MochiKit.DOM; -self.addToCallStack(self._window,"onload",func,true); -},focusOnLoad:function(_392){ -var self=MochiKit.DOM; -self.addLoadEvent(function(){ -_392=self.getElement(_392); -if(_392){ -_392.focus(); -} -}); -},setElementClass:function(_393,_394){ -var self=MochiKit.DOM; -var obj=self.getElement(_393); -if(self.attributeArray.compliant){ -obj.setAttribute("class",_394); -}else{ -obj.setAttribute("className",_394); -} -},toggleElementClass:function(_395){ -var self=MochiKit.DOM; -for(var i=1;i/g,">"); -},toHTML:function(dom){ -return MochiKit.DOM.emitHTML(dom).join(""); -},emitHTML:function(dom,lst){ -if(typeof (lst)=="undefined"||lst===null){ -lst=[]; -} -var _411=[dom]; -var self=MochiKit.DOM; -var _412=self.escapeHTML; -var _413=self.attributeArray; -while(_411.length){ -dom=_411.pop(); -if(typeof (dom)=="string"){ -lst.push(dom); -}else{ -if(dom.nodeType==1){ -lst.push("<"+dom.nodeName.toLowerCase()); -var _414=[]; -var _415=_413(dom); -for(var i=0;i<_415.length;i++){ -var a=_415[i]; -_414.push([" ",a.name,"=\"",_412(a.value),"\""]); -} -_414.sort(); -for(i=0;i<_414.length;i++){ -var _416=_414[i]; -for(var j=0;j<_416.length;j++){ -lst.push(_416[j]); -} -} -if(dom.hasChildNodes()){ -lst.push(">"); -_411.push(""); -var _417=dom.childNodes; -for(i=_417.length-1;i>=0;i--){ -_411.push(_417[i]); -} -}else{ -lst.push("/>"); -} -}else{ -if(dom.nodeType==3){ -lst.push(_412(dom.nodeValue)); -} -} -} -} -return lst; -},setDisplayForElement:function(_418,_419){ -var m=MochiKit.Base; -var _420=m.extend(null,arguments,1); -MochiKit.Iter.forEach(m.filter(null,m.map(MochiKit.DOM.getElement,_420)),function(_419){ -_419.style.display=_418; -}); -},scrapeText:function(node,_421){ -var rval=[]; -(function(node){ -var cn=node.childNodes; -if(cn){ -for(var i=0;i0){ -var _426=m.filter; -_425=function(node){ -return _426(_425.ignoreAttrFilter,node.attributes); -}; -_425.ignoreAttr={}; -MochiKit.Iter.forEach(_424.attributes,function(a){ -_425.ignoreAttr[a.name]=a.value; -}); -_425.ignoreAttrFilter=function(a){ -return (_425.ignoreAttr[a.name]!=a.value); -}; -_425.compliant=false; -_425.renames={"class":"className","checked":"defaultChecked","usemap":"useMap","for":"htmlFor"}; -}else{ -_425=function(node){ -return node.attributes; -}; -_425.compliant=true; -_425.renames={}; -} -this.attributeArray=_425; -var _427=this.createDOMFunc; -this.UL=_427("ul"); -this.OL=_427("ol"); -this.LI=_427("li"); -this.TD=_427("td"); -this.TR=_427("tr"); -this.TBODY=_427("tbody"); -this.THEAD=_427("thead"); -this.TFOOT=_427("tfoot"); -this.TABLE=_427("table"); -this.TH=_427("th"); -this.INPUT=_427("input"); -this.SPAN=_427("span"); -this.A=_427("a"); -this.DIV=_427("div"); -this.IMG=_427("img"); -this.BUTTON=_427("button"); -this.TT=_427("tt"); -this.PRE=_427("pre"); -this.H1=_427("h1"); -this.H2=_427("h2"); -this.H3=_427("h3"); -this.BR=_427("br"); -this.HR=_427("hr"); -this.LABEL=_427("label"); -this.TEXTAREA=_427("textarea"); -this.FORM=_427("form"); -this.P=_427("p"); -this.SELECT=_427("select"); -this.OPTION=_427("option"); -this.OPTGROUP=_427("optgroup"); -this.LEGEND=_427("legend"); -this.FIELDSET=_427("fieldset"); -this.STRONG=_427("strong"); -this.CANVAS=_427("canvas"); -this.hideElement=m.partial(this.setDisplayForElement,"none"); -this.showElement=m.partial(this.setDisplayForElement,"block"); -this.removeElement=this.swapDOM; -this.$=this.getElement; -this.EXPORT_TAGS={":common":this.EXPORT,":all":m.concat(this.EXPORT,this.EXPORT_OK)}; -m.nameFunctions(this); -}}); -MochiKit.DOM.__new__(((typeof (window)=="undefined")?this:window)); -if(!MochiKit.__compat__){ -withWindow=MochiKit.DOM.withWindow; -withDocument=MochiKit.DOM.withDocument; -} -MochiKit.Base._exportSymbols(this,MochiKit.DOM); -if(typeof (dojo)!="undefined"){ -dojo.provide("MochiKit.LoggingPane"); -dojo.require("MochiKit.Logging"); -dojo.require("MochiKit.Base"); -} -if(typeof (JSAN)!="undefined"){ -JSAN.use("MochiKit.Logging",[]); -JSAN.use("MochiKit.Base",[]); -} -try{ -if(typeof (MochiKit.Base)=="undefined"||typeof (MochiKit.Logging)=="undefined"){ -throw ""; -} -} -catch(e){ -throw "MochiKit.LoggingPane depends on MochiKit.Base and MochiKit.Logging!"; -} -if(typeof (MochiKit.LoggingPane)=="undefined"){ -MochiKit.LoggingPane={}; -} -MochiKit.LoggingPane.NAME="MochiKit.LoggingPane"; -MochiKit.LoggingPane.VERSION="1.3"; -MochiKit.LoggingPane.__repr__=function(){ -return "["+this.NAME+" "+this.VERSION+"]"; -}; -MochiKit.LoggingPane.toString=function(){ -return this.__repr__(); -}; -MochiKit.LoggingPane.createLoggingPane=function(_428){ -var m=MochiKit.LoggingPane; -_428=!(!_428); -if(m._loggingPane&&m._loggingPane.inline!=_428){ -m._loggingPane.closePane(); -m._loggingPane=null; -} -if(!m._loggingPane||m._loggingPane.closed){ -m._loggingPane=new m.LoggingPane(_428,MochiKit.Logging.logger); -} -return m._loggingPane; -}; -MochiKit.LoggingPane.LoggingPane=function(_429,_430){ -if(typeof (_430)=="undefined"||_430===null){ -_430=MochiKit.Logging.logger; -} -this.logger=_430; -var _431=MochiKit.Base.update; -var _432=MochiKit.Base.updatetree; -var bind=MochiKit.Base.bind; -var _433=MochiKit.Base.clone; -var win=window; -var uid="_MochiKit_LoggingPane"; -if(typeof (MochiKit.DOM)!="undefined"){ -win=MochiKit.DOM.currentWindow(); -} -if(!_429){ -var url=win.location.href.split("?")[0].replace(/[:\/.><&]/g,"_"); -var name=uid+"_"+url; -var nwin=win.open("",name,"dependent,resizable,height=200"); -if(!nwin){ -alert("Not able to open debugging window due to pop-up blocking."); -return undefined; -} -nwin.document.write(""+"[MochiKit.LoggingPane]"+""); -nwin.document.close(); -nwin.document.title+=" "+win.document.title; -win=nwin; -} -var doc=win.document; -this.doc=doc; -var _436=doc.getElementById(uid); -var _437=!!_436; -if(_436&&typeof (_436.loggingPane)!="undefined"){ -_436.loggingPane.logger=this.logger; -_436.loggingPane.buildAndApplyFilter(); -return _436.loggingPane; -} -if(_437){ -var _438; -while((_438=_436.firstChild)){ -_436.removeChild(_438); -} -}else{ -_436=doc.createElement("div"); -_436.id=uid; -} -_436.loggingPane=this; -var _439=doc.createElement("input"); -var _440=doc.createElement("input"); -var _441=doc.createElement("button"); -var _442=doc.createElement("button"); -var _443=doc.createElement("button"); -var _444=doc.createElement("button"); -var _445=doc.createElement("div"); -var _446=doc.createElement("div"); -var _447=uid+"_Listener"; -this.colorTable=_433(this.colorTable); -var _448=[]; -var _449=null; -var _450=function(msg){ -var _451=msg.level; -if(typeof (_451)=="number"){ -_451=MochiKit.Logging.LogLevel[_451]; -} -return _451; -}; -var _452=function(msg){ -return msg.info.join(" "); -}; -var _453=bind(function(msg){ -var _454=_450(msg); -var text=_452(msg); -var c=this.colorTable[_454]; -var p=doc.createElement("span"); -p.className="MochiKit-LogMessage MochiKit-LogLevel-"+_454; -p.style.cssText="margin: 0px; white-space: -moz-pre-wrap; white-space: -o-pre-wrap; white-space: pre-wrap; white-space: pre-line; word-wrap: break-word; wrap-option: emergency; color: "+c; -p.appendChild(doc.createTextNode(_454+": "+text)); -_446.appendChild(p); -_446.appendChild(doc.createElement("br")); -if(_445.offsetHeight>_445.scrollHeight){ -_445.scrollTop=0; -}else{ -_445.scrollTop=_445.scrollHeight; -} -},this); -var _456=function(msg){ -_448[_448.length]=msg; -_453(msg); -}; -var _457=function(){ -var _458,infore; -try{ -_458=new RegExp(_439.value); -infore=new RegExp(_440.value); -} -catch(e){ -logDebug("Error in filter regex: "+e.message); -return null; -} -return function(msg){ -return (_458.test(_450(msg))&&infore.test(_452(msg))); -}; -}; -var _459=function(){ -while(_446.firstChild){ -_446.removeChild(_446.firstChild); -} -}; -var _460=function(){ -_448=[]; -_459(); -}; -var _461=bind(function(){ -if(this.closed){ -return; -} -this.closed=true; -if(MochiKit.LoggingPane._loggingPane==this){ -MochiKit.LoggingPane._loggingPane=null; -} -this.logger.removeListener(_447); -_436.loggingPane=null; -if(_429){ -_436.parentNode.removeChild(_436); -}else{ -this.win.close(); -} -},this); -var _462=function(){ -_459(); -for(var i=0;i<_448.length;i++){ -var msg=_448[i]; -if(_449===null||_449(msg)){ -_453(msg); -} -} -}; -this.buildAndApplyFilter=function(){ -_449=_457(); -_462(); -this.logger.removeListener(_447); -this.logger.addListener(_447,_449,_456); -}; -var _463=bind(function(){ -_448=this.logger.getMessages(); -_462(); -},this); -var _464=bind(function(_465){ -_465=_465||window.event; -key=_465.which||_465.keyCode; -if(key==13){ -this.buildAndApplyFilter(); -} -},this); -var _466="display: block; z-index: 1000; left: 0px; bottom: 0px; position: fixed; width: 100%; background-color: white; font: "+this.logFont; -if(_429){ -_466+="; height: 10em; border-top: 2px solid black"; -}else{ -_466+="; height: 100%;"; -} -_436.style.cssText=_466; -if(!_437){ -doc.body.appendChild(_436); -} -_466={"cssText":"width: 33%; display: inline; font: "+this.logFont}; -_432(_439,{"value":"FATAL|ERROR|WARNING|INFO|DEBUG","onkeypress":_464,"style":_466}); -_436.appendChild(_439); -_432(_440,{"value":".*","onkeypress":_464,"style":_466}); -_436.appendChild(_440); -_466="width: 8%; display:inline; font: "+this.logFont; -_441.appendChild(doc.createTextNode("Filter")); -_441.onclick=bind("buildAndApplyFilter",this); -_441.style.cssText=_466; -_436.appendChild(_441); -_442.appendChild(doc.createTextNode("Load")); -_442.onclick=_463; -_442.style.cssText=_466; -_436.appendChild(_442); -_443.appendChild(doc.createTextNode("Clear")); -_443.onclick=_460; -_443.style.cssText=_466; -_436.appendChild(_443); -_444.appendChild(doc.createTextNode("Close")); -_444.onclick=_461; -_444.style.cssText=_466; -_436.appendChild(_444); -_445.style.cssText="overflow: auto; width: 100%"; -_446.style.cssText="width: 100%; height: "+(_429?"8em":"100%"); -_445.appendChild(_446); -_436.appendChild(_445); -this.buildAndApplyFilter(); -_463(); -if(_429){ -this.win=undefined; -}else{ -this.win=win; -} -this.inline=_429; -this.closePane=_461; -this.closed=false; -return this; -}; -MochiKit.LoggingPane.LoggingPane.prototype={"logFont":"8pt Verdana,sans-serif","colorTable":{"ERROR":"red","FATAL":"darkred","WARNING":"blue","INFO":"black","DEBUG":"green"}}; -MochiKit.LoggingPane.EXPORT_OK=["LoggingPane"]; -MochiKit.LoggingPane.EXPORT=["createLoggingPane"]; -MochiKit.LoggingPane.__new__=function(){ -this.EXPORT_TAGS={":common":this.EXPORT,":all":MochiKit.Base.concat(this.EXPORT,this.EXPORT_OK)}; -MochiKit.Base.nameFunctions(this); -MochiKit.LoggingPane._loggingPane=null; -}; -MochiKit.LoggingPane.__new__(); -MochiKit.Base._exportSymbols(this,MochiKit.LoggingPane); -if(typeof (dojo)!="undefined"){ -dojo.provide("MochiKit.Color"); -dojo.require("MochiKit.Base"); -} -if(typeof (JSAN)!="undefined"){ -JSAN.use("MochiKit.Base",[]); -} -try{ -if(typeof (MochiKit.Base)=="undefined"){ -throw ""; -} -} -catch(e){ -throw "MochiKit.Color depends on MochiKit.Base"; -} -if(typeof (MochiKit.Color)=="undefined"){ -MochiKit.Color={}; -} -MochiKit.Color.NAME="MochiKit.Color"; -MochiKit.Color.VERSION="1.3"; -MochiKit.Color.__repr__=function(){ -return "["+this.NAME+" "+this.VERSION+"]"; -}; -MochiKit.Color.toString=function(){ -return this.__repr__(); -}; -MochiKit.Color.Color=function(red,_468,blue,_470){ -if(typeof (_470)=="undefined"||_470===null){ -_470=1; -} -this.rgb={r:red,g:_468,b:blue,a:_470}; -}; -MochiKit.Color.Color.prototype={__class__:MochiKit.Color.Color,colorWithAlpha:function(_471){ -var rgb=this.rgb; -var m=MochiKit.Color; -return m.Color.fromRGB(rgb.r,rgb.g,rgb.b,_471); -},colorWithHue:function(hue){ -var hsl=this.asHSL(); -hsl.h=hue; -var m=MochiKit.Color; -return m.Color.fromHSL(hsl); -},colorWithSaturation:function(_475){ -var hsl=this.asHSL(); -hsl.s=_475; -var m=MochiKit.Color; -return m.Color.fromHSL(hsl); -},colorWithLightness:function(_476){ -var hsl=this.asHSL(); -hsl.l=_476; -var m=MochiKit.Color; -return m.Color.fromHSL(hsl); -},darkerColorWithLevel:function(_477){ -var hsl=this.asHSL(); -hsl.l=Math.max(hsl.l-_477,0); -var m=MochiKit.Color; -return m.Color.fromHSL(hsl); -},lighterColorWithLevel:function(_478){ -var hsl=this.asHSL(); -hsl.l=Math.min(hsl.l+_478,1); -var m=MochiKit.Color; -return m.Color.fromHSL(hsl); -},blendedColor:function(_479,_480){ -if(typeof (_480)=="undefined"||_480===null){ -_480=0.5; -} -var sf=1-_480; -var s=this.rgb; -var d=_479.rgb; -var df=_480; -return MochiKit.Color.Color.fromRGB((s.r*sf)+(d.r*df),(s.g*sf)+(d.g*df),(s.b*sf)+(d.b*df),(s.a*sf)+(d.a*df)); -},compareRGB:function(_483){ -var a=this.asRGB(); -var b=_483.asRGB(); -return MochiKit.Base.compare([a.r,a.g,a.b,a.a],[b.r,b.g,b.b,b.a]); -},isLight:function(){ -return this.asHSL().b>0.5; -},isDark:function(){ -return (!this.isLight()); -},toHSLString:function(){ -var c=this.asHSL(); -var ccc=MochiKit.Color.clampColorComponent; -var rval=this._hslString; -if(!rval){ -var mid=(ccc(c.h,360).toFixed(0)+","+ccc(c.s,100).toPrecision(4)+"%"+","+ccc(c.l,100).toPrecision(4)+"%"); -var a=c.a; -if(a>=1){ -a=1; -rval="hsl("+mid+")"; -}else{ -if(a<=0){ -a=0; -} -rval="hsla("+mid+","+a+")"; -} -this._hslString=rval; -} -return rval; -},toRGBString:function(){ -var c=this.rgb; -var ccc=MochiKit.Color.clampColorComponent; -var rval=this._rgbString; -if(!rval){ -var mid=(ccc(c.r,255).toFixed(0)+","+ccc(c.g,255).toFixed(0)+","+ccc(c.b,255).toFixed(0)); -if(c.a!=1){ -rval="rgba("+mid+","+c.a+")"; -}else{ -rval="rgb("+mid+")"; -} -this._rgbString=rval; -} -return rval; -},asRGB:function(){ -return MochiKit.Base.clone(this.rgb); -},toHexString:function(){ -var m=MochiKit.Color; -var c=this.rgb; -var ccc=MochiKit.Color.clampColorComponent; -var rval=this._hexString; -if(!rval){ -rval=("#"+m.toColorPart(ccc(c.r,255))+m.toColorPart(ccc(c.g,255))+m.toColorPart(ccc(c.b,255))); -this._hexString=rval; -} -return rval; -},asHSV:function(){ -var hsv=this.hsv; -var c=this.rgb; -if(typeof (hsv)=="undefined"||hsv===null){ -hsv=MochiKit.Color.rgbToHSV(this.rgb); -this.hsv=hsv; -} -return MochiKit.Base.clone(hsv); -},asHSL:function(){ -var hsl=this.hsl; -var c=this.rgb; -if(typeof (hsl)=="undefined"||hsl===null){ -hsl=MochiKit.Color.rgbToHSL(this.rgb); -this.hsl=hsl; -} -return MochiKit.Base.clone(hsl); -},toString:function(){ -return this.toRGBString(); -},repr:function(){ -var c=this.rgb; -var col=[c.r,c.g,c.b,c.a]; -return this.__class__.NAME+"("+col.join(", ")+")"; -}}; -MochiKit.Base.update(MochiKit.Color.Color,{fromRGB:function(red,_488,blue,_489){ -var _490=MochiKit.Color.Color; -if(arguments.length==1){ -var rgb=red; -red=rgb.r; -_488=rgb.g; -blue=rgb.b; -if(typeof (rgb.a)=="undefined"){ -_489=undefined; -}else{ -_489=rgb.a; -} -} -return new _490(red,_488,blue,_489); -},fromHSL:function(hue,_491,_492,_493){ -var m=MochiKit.Color; -return m.Color.fromRGB(m.hslToRGB.apply(m,arguments)); -},fromHSV:function(hue,_494,_495,_496){ -var m=MochiKit.Color; -return m.Color.fromRGB(m.hsvToRGB.apply(m,arguments)); -},fromName:function(name){ -var _497=MochiKit.Color.Color; -if(name.charAt(0)=="\""){ -name=name.substr(1,name.length-2); -} -var _498=_497._namedColors[name.toLowerCase()]; -if(typeof (_498)=="string"){ -return _497.fromHexString(_498); -}else{ -if(name=="transparent"){ -return _497.transparentColor(); -} -} -return null; -},fromString:function(_499){ -var self=MochiKit.Color.Color; -var _500=_499.substr(0,3); -if(_500=="rgb"){ -return self.fromRGBString(_499); -}else{ -if(_500=="hsl"){ -return self.fromHSLString(_499); -}else{ -if(_499.charAt(0)=="#"){ -return self.fromHexString(_499); -} -} -} -return self.fromName(_499); -},fromHexString:function(_501){ -if(_501.charAt(0)=="#"){ -_501=_501.substring(1); -} -var _502=[]; -var i,hex; -if(_501.length==3){ -for(i=0;i<3;i++){ -hex=_501.substr(i,1); -_502.push(parseInt(hex+hex,16)/255); -} -}else{ -for(i=0;i<6;i+=2){ -hex=_501.substr(i,2); -_502.push(parseInt(hex,16)/255); -} -} -var _503=MochiKit.Color.Color; -return _503.fromRGB.apply(_503,_502); -},_fromColorString:function(pre,_505,_506,_507){ -if(_507.indexOf(pre)===0){ -_507=_507.substring(_507.indexOf("(",3)+1,_507.length-1); -} -var _508=_507.split(/\s*,\s*/); -var _509=[]; -for(var i=0;i<_508.length;i++){ -var c=_508[i]; -var val; -var _510=c.substring(c.length-3); -if(c.charAt(c.length-1)=="%"){ -val=0.01*parseFloat(c.substring(0,c.length-1)); -}else{ -if(_510=="deg"){ -val=parseFloat(c)/360; -}else{ -if(_510=="rad"){ -val=parseFloat(c)/(Math.PI*2); -}else{ -val=_506[i]*parseFloat(c); -} -} -} -_509.push(val); -} -return this[_505].apply(this,_509); -},fromComputedStyle:function(elem,_511,_512){ -var d=MochiKit.DOM; -var cls=MochiKit.Color.Color; -for(elem=d.getElement(elem);elem;elem=elem.parentNode){ -var _513=d.computedStyle.apply(d,arguments); -if(!_513){ -continue; -} -var _514=cls.fromString(_513); -if(!_514){ -break; -} -if(_514.asRGB().a>0){ -return _514; -} -} -return null; -},fromBackground:function(elem){ -var cls=MochiKit.Color.Color; -return cls.fromComputedStyle(elem,"backgroundColor","background-color")||cls.whiteColor(); -},fromText:function(elem){ -var cls=MochiKit.Color.Color; -return cls.fromComputedStyle(elem,"color","color")||cls.blackColor(); -},namedColors:function(){ -return MochiKit.Base.clone(MochiKit.Color.Color._namedColors); -}}); -MochiKit.Base.update(MochiKit.Color,{clampColorComponent:function(v,_515){ -v*=_515; -if(v<0){ -return 0; -}else{ -if(v>_515){ -return _515; -}else{ -return v; -} -} -},_hslValue:function(n1,n2,hue){ -if(hue>6){ -hue-=6; -}else{ -if(hue<0){ -hue+=6; -} -} -var val; -if(hue<1){ -val=n1+(n2-n1)*hue; -}else{ -if(hue<3){ -val=n2; -}else{ -if(hue<4){ -val=n1+(n2-n1)*(4-hue); -}else{ -val=n1; -} -} -} -return val; -},hsvToRGB:function(hue,_518,_519,_520){ -if(arguments.length==1){ -var hsv=hue; -hue=hsv.h; -_518=hsv.s; -_519=hsv.v; -_520=hsv.a; -} -var red; -var _521; -var blue; -if(_518===0){ -red=0; -_521=0; -blue=0; -}else{ -var i=Math.floor(hue*6); -var f=(hue*6)-i; -var p=_519*(1-_518); -var q=_519*(1-(_518*f)); -var t=_519*(1-(_518*(1-f))); -switch(i){ -case 1: -red=q; -_521=_519; -blue=p; -break; -case 2: -red=p; -_521=_519; -blue=t; -break; -case 3: -red=p; -_521=q; -blue=_519; -break; -case 4: -red=t; -_521=p; -blue=_519; -break; -case 5: -red=_519; -_521=p; -blue=q; -break; -case 6: -case 0: -red=_519; -_521=t; -blue=p; -break; -} -} -return {r:red,g:_521,b:blue,a:_520}; -},hslToRGB:function(hue,_523,_524,_525){ -if(arguments.length==1){ -var hsl=hue; -hue=hsl.h; -_523=hsl.s; -_524=hsl.l; -_525=hsl.a; -} -var red; -var _526; -var blue; -if(_523===0){ -red=_524; -_526=_524; -blue=_524; -}else{ -var m2; -if(_524<=0.5){ -m2=_524*(1+_523); -}else{ -m2=_524+_523-(_524*_523); -} -var m1=(2*_524)-m2; -var f=MochiKit.Color._hslValue; -var h6=hue*6; -red=f(m1,m2,h6+2); -_526=f(m1,m2,h6); -blue=f(m1,m2,h6-2); -} -return {r:red,g:_526,b:blue,a:_525}; -},rgbToHSV:function(red,_530,blue,_531){ -if(arguments.length==1){ -var rgb=red; -red=rgb.r; -_530=rgb.g; -blue=rgb.b; -_531=rgb.a; -} -var max=Math.max(Math.max(red,_530),blue); -var min=Math.min(Math.min(red,_530),blue); -var hue; -var _534; -var _535=max; -if(min==max){ -hue=0; -_534=0; -}else{ -var _536=(max-min); -_534=_536/max; -if(red==max){ -hue=(_530-blue)/_536; -}else{ -if(_530==max){ -hue=2+((blue-red)/_536); -}else{ -hue=4+((red-_530)/_536); -} -} -hue/=6; -if(hue<0){ -hue+=1; -} -if(hue>1){ -hue-=1; -} -} -return {h:hue,s:_534,v:_535,a:_531}; -},rgbToHSL:function(red,_537,blue,_538){ -if(arguments.length==1){ -var rgb=red; -red=rgb.r; -_537=rgb.g; -blue=rgb.b; -_538=rgb.a; -} -var max=Math.max(red,Math.max(_537,blue)); -var min=Math.min(red,Math.min(_537,blue)); -var hue; -var _539; -var _540=(max+min)/2; -var _541=max-min; -if(_541===0){ -hue=0; -_539=0; -}else{ -if(_540<=0.5){ -_539=_541/(max+min); -}else{ -_539=_541/(2-max-min); -} -if(red==max){ -hue=(_537-blue)/_541; -}else{ -if(_537==max){ -hue=2+((blue-red)/_541); -}else{ -hue=4+((red-_537)/_541); -} -} -hue/=6; -if(hue<0){ -hue+=1; -} -if(hue>1){ -hue-=1; -} -} -return {h:hue,s:_539,l:_540,a:_538}; -},toColorPart:function(num){ -num=Math.round(num); -var _542=num.toString(16); -if(num<16){ -return "0"+_542; -} -return _542; -},__new__:function(){ -var m=MochiKit.Base; -this.Color.fromRGBString=m.bind(this.Color._fromColorString,this.Color,"rgb","fromRGB",[1/255,1/255,1/255,1]); -this.Color.fromHSLString=m.bind(this.Color._fromColorString,this.Color,"hsl","fromHSL",[1/360,0.01,0.01,1]); -var _543=1/3; -var _544={black:[0,0,0],blue:[0,0,1],brown:[0.6,0.4,0.2],cyan:[0,1,1],darkGray:[_543,_543,_543],gray:[0.5,0.5,0.5],green:[0,1,0],lightGray:[2*_543,2*_543,2*_543],magenta:[1,0,1],orange:[1,0.5,0],purple:[0.5,0,0.5],red:[1,0,0],transparent:[0,0,0,0],white:[1,1,1],yellow:[1,1,0]}; -var _545=function(name,r,g,b,a){ -var rval=this.fromRGB(r,g,b,a); -this[name]=function(){ -return rval; -}; -return rval; -}; -for(var k in _544){ -var name=k+"Color"; -var _547=m.concat([_545,this.Color,name],_544[k]); -this.Color[name]=m.bind.apply(null,_547); -} -var _548=function(){ -for(var i=0;i1){ -var src=MochiKit.DOM.getElement(arguments[0]); -var sig=arguments[1]; -var obj=arguments[2]; -var func=arguments[3]; -for(var i=_564.length-1;i>=0;i--){ -var o=_564[i]; -if(o[0]===src&&o[1]===sig&&o[4]===obj&&o[5]===func){ -self._disconnect(o); -_564.splice(i,1); -return true; -} -} -}else{ -var idx=m.findIdentical(_564,_563); -if(idx>=0){ -self._disconnect(_563); -_564.splice(idx,1); -return true; -} -} -return false; -},disconnectAll:function(src,sig){ -src=MochiKit.DOM.getElement(src); -var m=MochiKit.Base; -var _565=m.flattenArguments(m.extend(null,arguments,1)); -var self=MochiKit.Signal; -var _566=self._disconnect; -var _567=self._observers; -if(_565.length===0){ -for(var i=_567.length-1;i>=0;i--){ -var _568=_567[i]; -if(_568[0]===src){ -_566(_568); -_567.splice(i,1); -} -} -}else{ -var sigs={}; -for(var i=0;i<_565.length;i++){ -sigs[_565[i]]=true; -} -for(var i=_567.length-1;i>=0;i--){ -var _568=_567[i]; -if(_568[0]===src&&_568[1] in sigs){ -_566(_568); -_567.splice(i,1); -} -} -} -},signal:function(src,sig){ -var _570=MochiKit.Signal._observers; -src=MochiKit.DOM.getElement(src); -var args=MochiKit.Base.extend(null,arguments,2); -var _571=[]; -for(var i=0;i<_570.length;i++){ -var _572=_570[i]; -if(_572[0]===src&&_572[1]===sig){ -try{ -_572[2].apply(src,args); -} -catch(e){ -_571.push(e); -} -} -} -if(_571.length==1){ -throw _571[0]; -}else{ -if(_571.length>1){ -var e=new Error("Multiple errors thrown in handling 'sig', see errors property"); -e.errors=_571; -throw e; -} -} -}}); -MochiKit.Signal.EXPORT_OK=[]; -MochiKit.Signal.EXPORT=["connect","disconnect","signal","disconnectAll"]; -MochiKit.Signal.__new__=function(win){ -var m=MochiKit.Base; -this._document=document; -this._window=win; -try{ -this.connect(window,"onunload",this._unloadCache); -} -catch(e){ -} -this.EXPORT_TAGS={":common":this.EXPORT,":all":m.concat(this.EXPORT,this.EXPORT_OK)}; -m.nameFunctions(this); -}; -MochiKit.Signal.__new__(this); -if(!MochiKit.__compat__){ -connect=MochiKit.Signal.connect; -disconnect=MochiKit.Signal.disconnect; -disconnectAll=MochiKit.Signal.disconnectAll; -signal=MochiKit.Signal.signal; -} -MochiKit.Base._exportSymbols(this,MochiKit.Signal); -if(typeof (dojo)!="undefined"){ -dojo.provide("MochiKit.Visual"); -dojo.require("MochiKit.Base"); -dojo.require("MochiKit.DOM"); -dojo.require("MochiKit.Color"); -} -if(typeof (JSAN)!="undefined"){ -JSAN.use("MochiKit.Base",[]); -JSAN.use("MochiKit.DOM",[]); -JSAN.use("MochiKit.Color",[]); -} -try{ -if(typeof (MochiKit.Base)=="undefined"||typeof (MochiKit.DOM)=="undefined"||typeof (MochiKit.Color)=="undefined"){ -throw ""; -} -} -catch(e){ -throw "MochiKit.Visual depends on MochiKit.Base, MochiKit.DOM and MochiKit.Color!"; -} -if(typeof (MochiKit.Visual)=="undefined"){ -MochiKit.Visual={}; -} -MochiKit.Visual.NAME="MochiKit.Visual"; -MochiKit.Visual.VERSION="1.3"; -MochiKit.Visual.__repr__=function(){ -return "["+this.NAME+" "+this.VERSION+"]"; -}; -MochiKit.Visual.toString=function(){ -return this.__repr__(); -}; -MochiKit.Visual._RoundCorners=function(e,_573){ -e=MochiKit.DOM.getElement(e); -this._setOptions(_573); -if(this.options.__unstable__wrapElement){ -e=this._doWrap(e); -} -var _574=this.options.color; -var C=MochiKit.Color.Color; -if(this.options.color=="fromElement"){ -_574=C.fromBackground(e); -}else{ -if(!(_574 instanceof C)){ -_574=C.fromString(_574); -} -} -this.isTransparent=(_574.asRGB().a<=0); -var _576=this.options.bgColor; -if(this.options.bgColor=="fromParent"){ -_576=C.fromBackground(e.offsetParent); -}else{ -if(!(_576 instanceof C)){ -_576=C.fromString(_576); -} -} -this._roundCornersImpl(e,_574,_576); -}; -MochiKit.Visual._RoundCorners.prototype={_doWrap:function(e){ -var _577=e.parentNode; -var doc=MochiKit.DOM.currentDocument(); -if(typeof (doc.defaultView)=="undefined"||doc.defaultView===null){ -return e; -} -var _578=doc.defaultView.getComputedStyle(e,null); -if(typeof (_578)=="undefined"||_578===null){ -return e; -} -var _579=MochiKit.DOM.DIV({"style":{display:"block",marginTop:_578.getPropertyValue("padding-top"),marginRight:_578.getPropertyValue("padding-right"),marginBottom:_578.getPropertyValue("padding-bottom"),marginLeft:_578.getPropertyValue("padding-left"),padding:"0px"}}); -_579.innerHTML=e.innerHTML; -e.innerHTML=""; -e.appendChild(_579); -return e; -},_roundCornersImpl:function(e,_580,_581){ -if(this.options.border){ -this._renderBorder(e,_581); -} -if(this._isTopRounded()){ -this._roundTopCorners(e,_580,_581); -} -if(this._isBottomRounded()){ -this._roundBottomCorners(e,_580,_581); -} -},_renderBorder:function(el,_582){ -var _583="1px solid "+this._borderColor(_582); -var _584="border-left: "+_583; -var _585="border-right: "+_583; -var _586="style='"+_584+";"+_585+"'"; -el.innerHTML="
"+el.innerHTML+"
"; -},_roundTopCorners:function(el,_587,_588){ -var _589=this._createCorner(_588); -for(var i=0;i=0;i--){ -_592.appendChild(this._createCornerSlice(_590,_591,i,"bottom")); -} -el.style.paddingBottom=0; -el.appendChild(_592); -},_createCorner:function(_593){ -var dom=MochiKit.DOM; -return dom.DIV({style:{backgroundColor:_593.toString()}}); -},_createCornerSlice:function(_594,_595,n,_596){ -var _597=MochiKit.DOM.SPAN(); -var _598=_597.style; -_598.backgroundColor=_594.toString(); -_598.display="block"; -_598.height="1px"; -_598.overflow="hidden"; -_598.fontSize="1px"; -var _599=this._borderColor(_594,_595); -if(this.options.border&&n===0){ -_598.borderTopStyle="solid"; -_598.borderTopWidth="1px"; -_598.borderLeftWidth="0px"; -_598.borderRightWidth="0px"; -_598.borderBottomWidth="0px"; -_598.height="0px"; -_598.borderColor=_599.toString(); -}else{ -if(_599){ -_598.borderColor=_599.toString(); -_598.borderStyle="solid"; -_598.borderWidth="0px 1px"; -} -} -if(!this.options.compact&&(n==(this.options.numSlices-1))){ -_598.height="2px"; -} -this._setMargin(_597,n,_596); -this._setBorder(_597,n,_596); -return _597; -},_setOptions:function(_600){ -this.options={corners:"all",color:"fromElement",bgColor:"fromParent",blend:true,border:false,compact:false,__unstable__wrapElement:false}; -MochiKit.Base.update(this.options,_600); -this.options.numSlices=(this.options.compact?2:4); -},_whichSideTop:function(){ -var _601=this.options.corners; -if(this._hasString(_601,"all","top")){ -return ""; -} -var _602=(_601.indexOf("tl")!=-1); -var _603=(_601.indexOf("tr")!=-1); -if(_602&&_603){ -return ""; -} -if(_602){ -return "left"; -} -if(_603){ -return "right"; -} -return ""; -},_whichSideBottom:function(){ -var _604=this.options.corners; -if(this._hasString(_604,"all","bottom")){ -return ""; -} -var _605=(_604.indexOf("bl")!=-1); -var _606=(_604.indexOf("br")!=-1); -if(_605&&_606){ -return ""; -} -if(_605){ -return "left"; -} -if(_606){ -return "right"; -} -return ""; -},_borderColor:function(_607,_608){ -if(_607=="transparent"){ -return _608; -}else{ -if(this.options.border){ -return this.options.border; -}else{ -if(this.options.blend){ -return _608.blendedColor(_607); -} -} -} -return ""; -},_setMargin:function(el,n,_609){ -var _610=this._marginSize(n)+"px"; -var _611=(_609=="top"?this._whichSideTop():this._whichSideBottom()); -var _612=el.style; -if(_611=="left"){ -_612.marginLeft=_610; -_612.marginRight="0px"; -}else{ -if(_611=="right"){ -_612.marginRight=_610; -_612.marginLeft="0px"; -}else{ -_612.marginLeft=_610; -_612.marginRight=_610; -} -} -},_setBorder:function(el,n,_613){ -var _614=this._borderSize(n)+"px"; -var _615=(_613=="top"?this._whichSideTop():this._whichSideBottom()); -var _616=el.style; -if(_615=="left"){ -_616.borderLeftWidth=_614; -_616.borderRightWidth="0px"; -}else{ -if(_615=="right"){ -_616.borderRightWidth=_614; -_616.borderLeftWidth="0px"; -}else{ -_616.borderLeftWidth=_614; -_616.borderRightWidth=_614; -} -} -},_marginSize:function(n){ -if(this.isTransparent){ -return 0; -} -var o=this.options; -if(o.compact&&o.blend){ -var _617=[1,0]; -return _617[n]; -}else{ -if(o.compact){ -var _618=[2,1]; -return _618[n]; -}else{ -if(o.blend){ -var _619=[3,2,1,0]; -return _619[n]; -}else{ -var _620=[5,3,2,1]; -return _620[n]; -} -} -} -},_borderSize:function(n){ -var o=this.options; -var _621; -if(o.compact&&(o.blend||this.isTransparent)){ -return 1; -}else{ -if(o.compact){ -_621=[1,0]; -}else{ -if(o.blend){ -_621=[2,1,1,1]; -}else{ -if(o.border){ -_621=[0,2,0,0]; -}else{ -if(this.isTransparent){ -_621=[5,3,2,1]; -}else{ -return 0; -} -} -} -} -} -return _621[n]; -},_hasString:function(str){ -for(var i=1;i"); -} -} -})(); -} - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/js/mochi/__package__.js b/edexOsgi/build.edex/esb/webapps/admin/js/mochi/__package__.js deleted file mode 100644 index b8e91582dd..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/js/mochi/__package__.js +++ /dev/null @@ -1,14 +0,0 @@ -/*** - - MochiKit.MochiKit 1.3 : PACKED VERSION - - THIS FILE IS AUTOMATICALLY GENERATED. If creating patches, please - diff against the source tree, not this file. - - See for documentation, downloads, license, etc. - - (c) 2005 Bob Ippolito. All rights Reserved. - -***/ -dojo.hostenv.conditionalLoadModule({"common": ["MochiKit.MochiKit"]}); -dojo.hostenv.moduleLoaded("MochiKit.*"); diff --git a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/Base.js b/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/Base.js deleted file mode 100644 index ae9ec0b5c9..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/Base.js +++ /dev/null @@ -1,332 +0,0 @@ -/* - PlotKit - ======= - PlotKit is a collection of Javascript classes that allows - you to quickly visualise data using different types of charts. - - For license/info/documentation: http://www.liquidx.net/plotkit/ - - Copyright - --------- - Copyright 2005,2006 (c) Alastair Tse - For use under the BSD license. -*/ - -// -------------------------------------------------------------------- -// Check required components -// -------------------------------------------------------------------- - -try { - if (typeof(MochiKit.Base) == 'undefined' || - typeof(MochiKit.DOM) == 'undefined' || - typeof(MochiKit.Color) == 'undefined' || - typeof(MochiKit.Format) == 'undefined') - { - throw ""; - } -} -catch (e) { - throw "PlotKit depends on MochiKit.{Base,Color,DOM,Format}" -} - -// ------------------------------------------------------------------- -// Inject Common Shortcuts we use into MochiKit.Color.Color -// ------------------------------------------------------------------- - -MochiKit.Base.update(MochiKit.Color.Color.prototype, { - asFillColor: function() { - return this.lighterColorWithLevel(0.3); - }, - - asStrokeColor: function() { - return this.darkerColorWithLevel(0.1); - }, - - asPointColor: function() { - return this.lighterColorWithLevel(0.1); - } -}); - - -// ------------------------------------------------------------------- -// Define our own PlotKit namespace -// ------------------------------------------------------------------- - -if (typeof(PlotKit) == 'undefined') { - PlotKit = {}; -} - -PlotKit.NAME = "PlotKit"; -PlotKit.VERSION = "0.8"; -PlotKit.__repr__ = function() { - return "[" + this.NAME + " " + this.VERSION + "]"; -}; - -PlotKit.toString = function() { - return this.__repr__(); -} - -// ------------------------------------------------------------------- -// Encapsulate all our utility function into it's own namespace. -// ------------------------------------------------------------------- - -if (typeof(PlotKit.Base) == 'undefined') { - PlotKit.Base = {}; -} - -PlotKit.Base.NAME = 'PlotKit.Base'; -PlotKit.Base.VERSION = PlotKit.VERSION; - -PlotKit.Base.__repr__ = function() { - return "[" + this.NAME + " " + this.VERSION + "]"; -}; - -PlotKit.Base.toString = function() { - return this.__repr__(); -} - -MochiKit.Base.update(PlotKit.Base, { - roundInterval: function(range, intervals, precision) { - // We want to make the interval look regular, - var trunc = MochiKit.Format.roundToFixed; - var sep = range/intervals; - return parseFloat(trunc(sep, precision)); - }, - - collapse: function(lst) { - var m = MochiKit.Base; - var biggerList = new Array(); - for (var i = 0; i < lst.length; i++) { - biggerList = m.concat(biggerList, lst[i]); - } - return biggerList; - }, - - uniq: function(sortedList) { - // get unique elements in list, exactly the same as unix shell's uniq. - var m = MochiKit.Base; - - if (!m.isArrayLike(sortedList) || (sortedList.length < 1)) - return new Array(); - - var uniq = new Array(); - var lastElem = sortedList[0]; - uniq.push(sortedList[0]); - for (var i = 1; i < sortedList.length; i++) { - if (m.compare(sortedList[i], lastElem) != 0) { - lastElem = sortedList[i]; - uniq.push(sortedList[i]); - } - } - return uniq; - }, - - colorScheme: function() { - var mb = MochiKit.Base; - var mc = MochiKit.Color - var scheme = ["red", "orange", "yellow", "green", "cyan", "blue", "purple", "magenta"]; - - var makeColor = function(name) { - return mc.Color[name + "Color"]() - }; - - return mb.map(makeColor, scheme); - }, - - baseDarkPrimaryColors: function () { - var hexColor = MochiKit.Color.Color.fromHexString; - return [hexColor("#ad3f40"), - hexColor("#ddac2c"), - hexColor("#dfdd0c"), - hexColor("#5276c4"), - hexColor("#739c5a")]; - }, - - basePrimaryColors: function () { - var hexColor = MochiKit.Color.Color.fromHexString; - return [hexColor("#d24c4d"), - hexColor("#f2b32f"), - hexColor("#ece90e"), - hexColor("#5d83da"), - hexColor("#78a15d")]; - }, - - baseBlueColors: function () { - var hexColor = MochiKit.Color.Color.fromHexString; - return [hexColor("#4b6b94"), hexColor("#5d81b4"), hexColor("#acbad2")]; - }, - - palette: function(baseColor, fromLevel, toLevel, increment) { - var isNil = MochiKit.Base.isUndefinedOrNull; - var fractions = new Array(); - if (isNil(increment)) - increment = 0.1; - if (isNil(toLevel)) - toLevel = 0.4; - if (isNil(fromLevel)) - fromLevel = -0.2; - - var level = fromLevel; - while (level <= toLevel) { - fractions.push(level); - level += increment; - } - - var makeColor = function(color, fraction) { - return color.lighterColorWithLevel(fraction); - }; - return MochiKit.Base.map(partial(makeColor, baseColor), fractions); - }, - - - - - // The follow functions are from quirksmode.org - // http://www.quirksmode.org/js/findpos.html - - findPosX: function(obj) { - var curleft = 0; - if (obj.offsetParent) - { - while (obj.offsetParent) - { - curleft += obj.offsetLeft - obj = obj.offsetParent; - } - } - else if (obj.x) - curleft += obj.x; - return curleft; - }, - - findPosY: function(obj) { - var curtop = 0; - if (obj.offsetParent) - { - while (obj.offsetParent) - { - curtop += obj.offsetTop - obj = obj.offsetParent; - } - } - else if (obj.y) - curtop += obj.y; - return curtop; - } -}); - -PlotKit.Base.baseColors = function () { - var hexColor = MochiKit.Color.Color.fromHexString; - return [hexColor("#476fb2"), - hexColor("#be2c2b"), - hexColor("#85b730"), - hexColor("#734a99"), - hexColor("#26a1c5"), - hexColor("#fb8707"), - hexColor("#000000")]; -}; - -PlotKit.Base.officeBaseStyle = { - "axisLineWidth": 2.0, - "axisLabelColor": Color.grayColor(), - "axisLineColor": Color.whiteColor(), - "padding": {top: 5, bottom: 10, left: 30, right: 30} -}; - -MochiKit.Base.update(PlotKit.Base,{ - officeBlue: function() { - var r = { - "colorScheme": PlotKit.Base.palette(PlotKit.Base.baseColors()[0]), - "backgroundColor": PlotKit.Base.baseColors()[0].lighterColorWithLevel(0.45) - }; - MochiKit.Base.update(r, PlotKit.Base.officeBaseStyle); - return r; - }, - officeRed: function() { - var r = { - "colorScheme": PlotKit.Base.palette(PlotKit.Base.baseColors()[1]), - "backgroundColor": PlotKit.Base.baseColors()[1].lighterColorWithLevel(0.5) - }; - MochiKit.Base.update(r, PlotKit.Base.officeBaseStyle); - return r; - }, - officeGreen: function() { - var r = { - "colorScheme": PlotKit.Base.palette(PlotKit.Base.baseColors()[2]), - "backgroundColor": PlotKit.Base.baseColors()[2].lighterColorWithLevel(0.5) - }; - MochiKit.Base.update(r, PlotKit.Base.officeBaseStyle); - return r; - }, - officePurple: function() { - var r = { - "colorScheme": PlotKit.Base.palette(PlotKit.Base.baseColors()[3]), - "backgroundColor": PlotKit.Base.baseColors()[3].lighterColorWithLevel(0.5) - }; - MochiKit.Base.update(r, PlotKit.Base.officeBaseStyle); - return r; - }, - - officeCyan: function() { - var r = { - "colorScheme": PlotKit.Base.palette(PlotKit.Base.baseColors()[4]), - "backgroundColor": PlotKit.Base.baseColors()[4].lighterColorWithLevel(0.5) - }; - MochiKit.Base.update(r, PlotKit.Base.officeBaseStyle); - return r; - }, - - officeOrange: function() { - var r = { - "colorScheme": PlotKit.Base.palette(PlotKit.Base.baseColors()[5]), - "backgroundColor": PlotKit.Base.baseColors()[5].lighterColorWithLevel(0.4) - }; - MochiKit.Base.update(r, PlotKit.Base.officeBaseStyle); - return r; - }, - - officeBlack: function() { - var r = { - "colorScheme": PlotKit.Base.palette(PlotKit.Base.baseColors()[6], 0.0, 0.6), - "backgroundColor": PlotKit.Base.baseColors()[6].lighterColorWithLevel(0.9) - }; - MochiKit.Base.update(r, PlotKit.Base.officeBaseStyle); - return r; - } -}); - - -PlotKit.Base.EXPORT = [ - "baseColors", - "collapse", - "colorScheme", - "findPosX", - "findPosY", - "officeBaseStyle", - "officeBlue", - "officeRed", - "officeGreen", - "officePurple", - "officeCyan", - "officeOrange", - "officeBlack", - "roundInterval", - "uniq", -]; - -PlotKit.Base.EXPORT_OK = []; - -PlotKit.Base.__new__ = function() { - var m = MochiKit.Base; - - m.nameFunctions(this); - - this.EXPORT_TAGS = { - ":common": this.EXPORT, - ":all": m.concat(this.EXPORT, this.EXPORT_OK) - }; -}; - -PlotKit.Base.__new__(); -MochiKit.Base._exportSymbols(this, PlotKit.Base); - diff --git a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/Canvas.js b/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/Canvas.js deleted file mode 100644 index b3ba168fe0..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/Canvas.js +++ /dev/null @@ -1,707 +0,0 @@ -/* - PlotKit Canvas - -------------- - - Provides HTML Canvas Renderer. This is supported under: - - - Safari 2.0 - - Mozilla Firefox 1.5 - - Opera 9.0 preview 2 - - IE 6 (via VML Emulation) - - It uses DIVs for labels. - - Notes About IE Support - ---------------------- - - This class relies on iecanvas.htc for Canvas Emulation under IE[1]. - iecanvas.htc is included in the distribution of PlotKit for convenience. In order to enable IE support, you must set the following option when initialising the renderer: - - var renderOptions = { - "IECanvasHTC": "contrib/iecanvas.htc" - }; - var engine = new CanvasRenderer(canvasElement, layout, renderOptions); - - Where "contrib/iecanvas.htc" is the path to the htc behavior relative - to where your HTML is. - - This is only needed for IE support. - - Copyright - --------- - Copyright 2005,2006 (c) Alastair Tse - For use under the BSD license. - -*/ -// -------------------------------------------------------------------- -// Check required components -// -------------------------------------------------------------------- - -try { - if (typeof(PlotKit.Layout) == 'undefined') - { - throw ""; - } -} -catch (e) { - throw "PlotKit.Layout depends on MochiKit.{Base,Color,DOM,Format} and PlotKit.Base and PlotKit.Layout" -} - - -// ------------------------------------------------------------------------ -// Defines the renderer class -// ------------------------------------------------------------------------ - -if (typeof(PlotKit.CanvasRenderer) == 'undefined') { - PlotKit.CanvasRenderer = {}; -} - -PlotKit.CanvasRenderer.NAME = "PlotKit.CanvasRenderer"; -PlotKit.CanvasRenderer.VERSION = PlotKit.VERSION; - -PlotKit.CanvasRenderer.__repr__ = function() { - return "[" + this.NAME + " " + this.VERSION + "]"; -}; - -PlotKit.CanvasRenderer.toString = function() { - return this.__repr__(); -} - -PlotKit.CanvasRenderer = function(element, layout, options) { - if (arguments.length > 0) - this.__init__(element, layout, options); -}; - -PlotKit.CanvasRenderer.prototype.__init__ = function(element, layout, options) { - var isNil = MochiKit.Base.isUndefinedOrNull; - var Color = MochiKit.Color.Color; - - // default options - this.options = { - "drawBackground": true, - "backgroundColor": Color.whiteColor(), - "padding": {left: 30, right: 30, top: 5, bottom: 10}, - "colorScheme": PlotKit.Base.palette(PlotKit.Base.baseColors()[0]), - "strokeColor": Color.whiteColor(), - "strokeColorTransform": "asStrokeColor", - "strokeWidth": 0.5, - "shouldFill": true, - "shouldStroke": true, - "drawXAxis": true, - "drawYAxis": true, - "axisLineColor": Color.blackColor(), - "axisLineWidth": 0.5, - "axisTickSize": 3, - "axisLabelColor": Color.blackColor(), - "axisLabelFont": "Arial", - "axisLabelFontSize": 9, - "axisLabelWidth": 50, - "pieRadius": 0.4, - "enableEvents": true, - "IECanvasHTC": "PlotKit/iecanvas.htc" - }; - MochiKit.Base.update(this.options, options ? options : {}); - - // we need to refetch the element because of this horrible Canvas on IE - // crap - this.element_id = element.id ? element.id : element; - - // Stuff relating to Canvas on IE support - var self = PlotKit.CanvasRenderer; - this.isIE = self.IECanvasEmulationIfNeeded(this.options.IECanvasHTC); - this.IEDelay = 0.5; - this.maxTries = 5; - this.renderDelay = null; - this.clearDelay = null; - - this.layout = layout; - this.style = layout.style; - this.element = MochiKit.DOM.getElement(this.element_id); - //this.element = element; - this.container = this.element.parentNode; - this.height = this.element.height; - this.width = this.element.width; - - // --- check whether everything is ok before we return - - if (isNil(this.element)) - throw "CanvasRenderer() - passed canvas is not found"; - - if (!this.isIE && !(PlotKit.CanvasRenderer.isSupported(this.element))) - throw "CanvasRenderer() - Canvas is not supported."; - - if (isNil(this.container) || (this.container.nodeName.toLowerCase() != "div")) - throw "CanvasRenderer() - needs to be enclosed in
"; - - // internal state - this.xlabels = new Array(); - this.ylabels = new Array(); - this.isFirstRender = true; - - this.area = { - x: this.options.padding.left, - y: this.options.padding.top, - w: this.width - this.options.padding.left - this.options.padding.right, - h: this.height - this.options.padding.top - this.options.padding.bottom - }; - - MochiKit.DOM.updateNodeAttributes(this.container, - {"style":{ "position": "relative", "width": this.width + "px"}}); - - // load event system if we have Signals - try { - this.event_isinside = null; - if (MochiKit.Signal && this.options.enableEvents) { - this._initialiseEvents(); - } - } - catch (e) { - // still experimental - } -}; - -PlotKit.CanvasRenderer.IECanvasEmulationIfNeeded = function(htc) { - var ie = navigator.appVersion.match(/MSIE (\d\.\d)/); - var opera = (navigator.userAgent.toLowerCase().indexOf("opera") != -1); - if ((!ie) || (ie[1] < 6) || (opera)) - return false; - - if (isUndefinedOrNull(MochiKit.DOM.getElement('VMLRender'))) { - // before we add VMLRender, we need to recreate all canvas tags - // programmatically otherwise IE will not recognise it - - var nodes = document.getElementsByTagName('canvas'); - for (var i = 0; i < nodes.length; i++) { - var node = nodes[i]; - if (node.getContext) { return; } // Other implementation, abort - var newNode = MochiKit.DOM.CANVAS( - {id: node.id, - width: "" + parseInt(node.width), - height: "" + parseInt(node.height)}, ""); - newNode.style.width = parseInt(node.width) + "px"; - newNode.style.height = parseInt(node.height) + "px"; - node.id = node.id + "_old"; - MochiKit.DOM.swapDOM(node, newNode); - } - - document.namespaces.add("v"); - var vmlopts = {'id':'VMLRender', - 'codebase':'vgx.dll', - 'classid':'CLSID:10072CEC-8CC1-11D1-986E-00A0C955B42E'}; - var vml = MochiKit.DOM.createDOM('object', vmlopts); - document.body.appendChild(vml); - var vmlStyle = document.createStyleSheet(); - vmlStyle.addRule("canvas", "behavior: url('" + htc + "');"); - vmlStyle.addRule("v\\:*", "behavior: url(#VMLRender);"); - } - return true; -}; - -PlotKit.CanvasRenderer.prototype.render = function() { - if (this.isIE) { - // VML takes a while to start up, so we just poll every this.IEDelay - try { - if (this.renderDelay) { - this.renderDelay.cancel(); - this.renderDelay = null; - } - var context = this.element.getContext("2d"); - } - catch (e) { - this.isFirstRender = false; - if (this.maxTries-- > 0) { - this.renderDelay = MochiKit.Async.wait(this.IEDelay); - this.renderDelay.addCallback(bind(this.render, this)); - } - return; - } - } - - if (this.options.drawBackground) - this._renderBackground(); - - if (this.style == "bar") { - this._renderBarChart(); - this._renderBarAxis(); - } - else if (this.style == "pie") { - this._renderPieChart(); - this._renderPieAxis(); - } - else if (this.style == "line") { - this._renderLineChart(); - this._renderLineAxis(); - } -}; - -PlotKit.CanvasRenderer.prototype._renderBarChartWrap = function(data, plotFunc) { - var context = this.element.getContext("2d"); - var colorCount = this.options.colorScheme.length; - var colorScheme = this.options.colorScheme; - var setNames = MochiKit.Base.keys(this.layout.datasets); - var setCount = setNames.length; - - for (var i = 0; i < setCount; i++) { - var setName = setNames[i]; - var color = colorScheme[i%colorCount]; - context.save(); - context.fillStyle = color.toRGBString(); - if (this.options.strokeColor) - context.strokeStyle = this.options.strokeColor.toRGBString(); - else if (this.options.strokeColorTransform) - context.strokeStyle = color[this.options.strokeColorTransform]().toRGBString(); - - context.lineWidth = this.options.strokeWidth; - var forEachFunc = function(obj) { - if (obj.name == setName) - plotFunc(context, obj); - }; - - MochiKit.Iter.forEach(data, bind(forEachFunc, this)); - context.restore(); - } -}; - -PlotKit.CanvasRenderer.prototype._renderBarChart = function() { - var bind = MochiKit.Base.bind; - - var drawRect = function(context, bar) { - var x = this.area.w * bar.x + this.area.x; - var y = this.area.h * bar.y + this.area.y; - var w = this.area.w * bar.w; - var h = this.area.h * bar.h; - if ((w < 1) || (h < 1)) - return; - if (this.options.shouldFill) - context.fillRect(x, y, w, h); - if (this.options.shouldStroke) - context.strokeRect(x, y, w, h); - }; - this._renderBarChartWrap(this.layout.bars, bind(drawRect, this)); -}; - -PlotKit.CanvasRenderer.prototype._renderLineChart = function() { - var context = this.element.getContext("2d"); - var colorCount = this.options.colorScheme.length; - var colorScheme = this.options.colorScheme; - var setNames = MochiKit.Base.keys(this.layout.datasets); - var setCount = setNames.length; - var bind = MochiKit.Base.bind; - var partial = MochiKit.Base.partial; - - for (var i = 0; i < setCount; i++) { - var setName = setNames[i]; - var color = colorScheme[i%colorCount]; - var strokeX = this.options.strokeColorTransform; - - // setup graphics context - context.save(); - context.fillStyle = color.toRGBString(); - if (this.options.strokeColor) - context.strokeStyle = this.options.strokeColor.toRGBString(); - else if (this.options.strokeColorTransform) - context.strokeStyle = color[strokeX]().toRGBString(); - - context.lineWidth = this.options.strokeWidth; - - // create paths - var makePath = function() { - context.beginPath(); - context.moveTo(this.area.x, this.area.y + this.area.h); - var addPoint = function(context, point) { - if (point.name == setName) - context.lineTo(this.area.w * point.x + this.area.x, - this.area.h * point.y + this.area.y); - }; - MochiKit.Iter.forEach(this.layout.points, partial(addPoint, context), this); - context.lineTo(this.area.w + this.area.x, - this.area.h + this.area.y); - context.lineTo(this.area.x, this.area.y + this.area.h); - context.closePath(); - }; - - if (this.options.shouldFill) { - bind(makePath, this)(); - context.fill(); - } - if (this.options.shouldStroke) { - bind(makePath, this)(); - context.stroke(); - } - - context.restore(); - } -}; - -PlotKit.CanvasRenderer.prototype._renderPieChart = function() { - var context = this.element.getContext("2d"); - var colorCount = this.options.colorScheme.length; - var slices = this.layout.slices; - - var centerx = this.area.x + this.area.w * 0.5; - var centery = this.area.y + this.area.h * 0.5; - var radius = Math.min(this.area.w * this.options.pieRadius, - this.area.h * this.options.pieRadius); - - if (this.isIE) { - centerx = parseInt(centerx); - centery = parseInt(centery); - radius = parseInt(radius); - } - - - // NOTE NOTE!! Canvas Tag draws the circle clockwise from the y = 0, x = 1 - // so we have to subtract 90 degrees to make it start at y = 1, x = 0 - - for (var i = 0; i < slices.length; i++) { - var color = this.options.colorScheme[i%colorCount]; - context.save(); - context.fillStyle = color.toRGBString(); - - var makePath = function() { - context.beginPath(); - context.moveTo(centerx, centery); - context.arc(centerx, centery, radius, - slices[i].startAngle - Math.PI/2, - slices[i].endAngle - Math.PI/2, - false); - context.lineTo(centerx, centery); - context.closePath(); - }; - - if (Math.abs(slices[i].startAngle - slices[i].endAngle) > 0.001) { - if (this.options.shouldFill) { - makePath(); - context.fill(); - } - - if (this.options.shouldStroke) { - makePath(); - context.lineWidth = this.options.strokeWidth; - if (this.options.strokeColor) - context.strokeStyle = this.options.strokeColor.toRGBString(); - else if (this.options.strokeColorTransform) - context.strokeStyle = color[this.options.strokeColorTransform]().toRGBString(); - context.stroke(); - } - } - context.restore(); - } -}; - -PlotKit.CanvasRenderer.prototype._renderBarAxis = function() { - this._renderAxis(); -} - -PlotKit.CanvasRenderer.prototype._renderLineAxis = function() { - this._renderAxis(); -}; - - -PlotKit.CanvasRenderer.prototype._renderAxis = function() { - if (!this.options.drawXAxis && !this.options.drawYAxis) - return; - - var context = this.element.getContext("2d"); - - var labelStyle = {"style": - {"position": "absolute", - "fontSize": this.options.axisLabelFontSize + "px", - "zIndex": 10, - "color": this.options.axisLabelColor.toRGBString(), - "width": this.options.axisLabelWidth + "px", - "overflow": "hidden" - } - }; - - // axis lines - context.save(); - context.strokeStyle = this.options.axisLineColor.toRGBString(); - context.lineWidth = this.options.axisLineWidth; - - - if (this.options.drawYAxis) { - if (this.layout.yticks) { - var drawTick = function(tick) { - var x = this.area.x; - var y = this.area.y + tick[0] * this.area.h; - context.beginPath(); - context.moveTo(x, y); - context.lineTo(x - this.options.axisTickSize, y); - context.closePath(); - context.stroke(); - - var label = DIV(labelStyle, tick[1]); - label.style.top = (y - this.options.axisLabelFontSize) + "px"; - label.style.left = (x - this.options.padding.left - this.options.axisTickSize) + "px"; - label.style.textAlign = "right"; - label.style.width = (this.options.padding.left - this.options.axisTickSize * 2) + "px"; - MochiKit.DOM.appendChildNodes(this.container, label); - this.ylabels.push(label); - }; - - MochiKit.Iter.forEach(this.layout.yticks, bind(drawTick, this)); - } - - context.beginPath(); - context.moveTo(this.area.x, this.area.y); - context.lineTo(this.area.x, this.area.y + this.area.h); - context.closePath(); - context.stroke(); - } - - if (this.options.drawXAxis) { - if (this.layout.xticks) { - var drawTick = function(tick) { - var x = this.area.x + tick[0] * this.area.w; - var y = this.area.y + this.area.h; - context.beginPath(); - context.moveTo(x, y); - context.lineTo(x, y + this.options.axisTickSize); - context.closePath(); - context.stroke(); - - var label = DIV(labelStyle, tick[1]); - label.style.top = (y + this.options.axisTickSize) + "px"; - label.style.left = (x - this.options.axisLabelWidth/2) + "px"; - label.style.textAlign = "center"; - label.style.width = this.options.axisLabelWidth + "px"; - MochiKit.DOM.appendChildNodes(this.container, label); - this.xlabels.push(label); - }; - - MochiKit.Iter.forEach(this.layout.xticks, bind(drawTick, this)); - } - - context.beginPath(); - context.moveTo(this.area.x, this.area.y + this.area.h); - context.lineTo(this.area.x + this.area.w, this.area.y + this.area.h); - context.closePath(); - context.stroke(); - } - - context.restore(); - -}; - -PlotKit.CanvasRenderer.prototype._renderPieAxis = function() { - if (!this.options.drawXAxis) - return; - - if (this.layout.xticks) { - // make a lookup dict for x->slice values - var lookup = new Array(); - for (var i = 0; i < this.layout.slices.length; i++) { - lookup[this.layout.slices[i].xval] = this.layout.slices[i]; - } - - var centerx = this.area.x + this.area.w * 0.5; - var centery = this.area.y + this.area.h * 0.5; - var radius = Math.min(this.area.w * this.options.pieRadius, - this.area.h * this.options.pieRadius); - var labelWidth = this.options.axisLabelWidth; - - for (var i = 0; i < this.layout.xticks.length; i++) { - var slice = lookup[this.layout.xticks[i][0]]; - if (MochiKit.Base.isUndefinedOrNull(slice)) - continue; - - - var angle = (slice.startAngle + slice.endAngle)/2; - // normalize the angle - var normalisedAngle = angle; - if (normalisedAngle > Math.PI * 2) - normalisedAngle = normalisedAngle - Math.PI * 2; - else if (normalisedAngle < 0) - normalisedAngle = normalisedAngle + Math.PI * 2; - - var labelx = centerx + Math.sin(normalisedAngle) * (radius + 10); - var labely = centery - Math.cos(normalisedAngle) * (radius + 10); - - var attrib = {"position": "absolute", - "zIndex": 11, - "width": labelWidth + "px", - "fontSize": this.options.axisLabelFontSize + "px", - "overflow": "hidden", - "color": this.options.axisLabelColor.toHexString() - }; - - if (normalisedAngle <= Math.PI * 0.5) { - // text on top and align left - attrib["textAlign"] = "left"; - attrib["verticalAlign"] = "top"; - attrib["left"] = labelx + "px"; - attrib["top"] = (labely - this.options.axisLabelFontSize) + "px"; - } - else if ((normalisedAngle > Math.PI * 0.5) && (normalisedAngle <= Math.PI)) { - // text on bottom and align left - attrib["textAlign"] = "left"; - attrib["verticalAlign"] = "bottom"; - attrib["left"] = labelx + "px"; - attrib["top"] = labely + "px"; - - } - else if ((normalisedAngle > Math.PI) && (normalisedAngle <= Math.PI*1.5)) { - // text on bottom and align right - attrib["textAlign"] = "right"; - attrib["verticalAlign"] = "bottom"; - attrib["left"] = (labelx - labelWidth) + "px"; - attrib["top"] = labely + "px"; - } - else { - // text on top and align right - attrib["textAlign"] = "right"; - attrib["verticalAlign"] = "bottom"; - attrib["left"] = (labelx - labelWidth) + "px"; - attrib["top"] = (labely - this.options.axisLabelFontSize) + "px"; - } - - var label = DIV({'style': attrib}, this.layout.xticks[i][1]); - this.xlabels.push(label); - MochiKit.DOM.appendChildNodes(this.container, label); - } - - } -}; - -PlotKit.CanvasRenderer.prototype._renderBackground = function() { - var context = this.element.getContext("2d"); - context.save(); - context.fillStyle = this.options.backgroundColor.toRGBString(); - context.fillRect(0, 0, this.width, this.height); - context.restore(); -}; - -PlotKit.CanvasRenderer.prototype.clear = function() { - if (this.isIE) { - // VML takes a while to start up, so we just poll every this.IEDelay - try { - if (this.clearDelay) { - this.clearDelay.cancel(); - this.clearDelay = null; - } - var context = this.element.getContext("2d"); - } - catch (e) { - this.isFirstRender = false; - this.clearDelay = MochiKit.Async.wait(this.IEDelay); - this.clearDelay.addCallback(bind(this.clear, this)); - return; - } - } - - var context = this.element.getContext("2d"); - context.clearRect(0, 0, this.width, this.height); - - - for (var i = 0; i < this.xlabels.length; i++) { - MochiKit.DOM.removeElement(this.xlabels[i]); - } - for (var i = 0; i < this.ylabels.length; i++) { - MochiKit.DOM.removeElement(this.ylabels[i]); - } - this.xlabels = new Array(); - this.ylabels = new Array(); - -}; - -PlotKit.CanvasRenderer.prototype._initialiseEvents = function() { - var connect = MochiKit.Signal.connect; - var bind = MochiKit.Base.bind; - MochiKit.Signal.registerSignals(this, ['onmouseover', 'onclick', 'onmouseout', 'onmousemove']); - //connect(this.element, 'onmouseover', bind(this.onmouseover, this)); - //connect(this.element, 'onmouseout', bind(this.onmouseout, this)); - //connect(this.element, 'onmousemove', bind(this.onmousemove, this)); - connect(this.element, 'onclick', bind(this.onclick, this)); -}; - -PlotKit.CanvasRenderer.prototype._resolveObject = function(e) { - // does not work in firefox - //var x = (e.event().offsetX - this.area.x) / this.area.w; - //var y = (e.event().offsetY - this.area.y) / this.area.h; - - var x = (e.mouse().page.x - PlotKit.Base.findPosX(this.element) - this.area.x) / this.area.w; - var y = (e.mouse().page.y - PlotKit.Base.findPosY(this.element) - this.area.y) / this.area.h; - - //log(x, y); - - var isHit = this.layout.hitTest(x, y); - if (isHit) - return isHit; - return null; -}; - -PlotKit.CanvasRenderer.prototype._createEventObject = function(layoutObj, e) { - if (layoutObj == null) { - return null; - } - - e.chart = layoutObj - return e; -}; - - -PlotKit.CanvasRenderer.prototype.onclick = function(e) { - var layoutObject = this._resolveObject(e); - var eventObject = this._createEventObject(layoutObject, e); - if (eventObject != null) - MochiKit.Signal.signal(this, "onclick", eventObject); -}; - -PlotKit.CanvasRenderer.prototype.onmouseover = function(e) { - var layoutObject = this._resolveObject(e); - var eventObject = this._createEventObject(layoutObject, e); - if (eventObject != null) - signal(this, "onmouseover", eventObject); -}; - -PlotKit.CanvasRenderer.prototype.onmouseout = function(e) { - var layoutObject = this._resolveObject(e); - var eventObject = this._createEventObject(layoutObject, e); - if (eventObject == null) - signal(this, "onmouseout", e); - else - signal(this, "onmouseout", eventObject); - -}; - -PlotKit.CanvasRenderer.prototype.onmousemove = function(e) { - var layoutObject = this._resolveObject(e); - var eventObject = this._createEventObject(layoutObject, e); - - if ((layoutObject == null) && (this.event_isinside == null)) { - // TODO: should we emit an event anyway? - return; - } - - if ((layoutObject != null) && (this.event_isinside == null)) - signal(this, "onmouseover", eventObject); - - if ((layoutObject == null) && (this.event_isinside != null)) - signal(this, "onmouseout", eventObject); - - if ((layoutObject != null) && (this.event_isinside != null)) - signal(this, "onmousemove", eventObject); - - this.event_isinside = layoutObject; - //log("move", x, y); -}; - -PlotKit.CanvasRenderer.isSupported = function(canvasName) { - var canvas = null; - try { - if (MochiKit.Base.isUndefinedOrNull(canvasName)) - canvas = MochiKit.DOM.CANVAS({}); - else - canvas = MochiKit.DOM.getElement(canvasName); - var context = canvas.getContext("2d"); - } - catch (e) { - var ie = navigator.appVersion.match(/MSIE (\d\.\d)/); - var opera = (navigator.userAgent.toLowerCase().indexOf("opera") != -1); - if ((!ie) || (ie[1] < 6) || (opera)) - return false; - return true; - } - return true; -}; diff --git a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/Layout.js b/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/Layout.js deleted file mode 100644 index f57951a370..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/Layout.js +++ /dev/null @@ -1,588 +0,0 @@ -/* - PlotKit Layout - -------------- - - Handles laying out data on to a virtual canvas square canvas between 0.0 - and 1.0. If you want to add new chart/plot types such as point plots, - you need to add them here. - - Copyright - --------- - Copyright 2005,2006 (c) Alastair Tse - For use under the BSD license. - -*/ - -try { - if (typeof(PlotKit.Base) == 'undefined') - { - throw "" - } -} -catch (e) { - throw "PlotKit.Layout depends on MochiKit.{Base,Color,DOM,Format} and PlotKit.Base" -} - -// -------------------------------------------------------------------- -// Start of Layout definition -// -------------------------------------------------------------------- - -if (typeof(PlotKit.Layout) == 'undefined') { - PlotKit.Layout = {}; -} - -PlotKit.Layout.NAME = "PlotKit.Layout"; -PlotKit.Layout.VERSION = PlotKit.VERSION; - -PlotKit.Layout.__repr__ = function() { - return "[" + this.NAME + " " + this.VERSION + "]"; -}; - -PlotKit.Layout.toString = function() { - return this.__repr__(); -} - -PlotKit.Layout.valid_styles = ["bar", "line", "pie", "point"]; - -// -------------------------------------------------------------------- -// Start of Layout definition -// -------------------------------------------------------------------- - -PlotKit.Layout = function(style, options) { - - this.options = { - "barWidthFillFraction": 0.75, - "xOriginIsZero": true, - "yOriginIsZero": true, - "xAxis": null, // [xmin, xmax] - "yAxis": null, // [ymin, ymax] - "xTicks": null, // [{label: "somelabel", v: value}, ..] (label opt.) - "yTicks": null, // [{label: "somelabel", v: value}, ..] (label opt.) - "xNumberOfTicks": 10, - "yNumberOfTicks": 5, - "xTickPrecision": 1, - "yTickPrecision": 3, - "pieRadius": 0.4 - }; - - // valid external options : TODO: input verification - this.style = style; - MochiKit.Base.update(this.options, options ? options : {}); - - // externally visible states - // overriden if xAxis and yAxis are set in options - if (!MochiKit.Base.isUndefinedOrNull(this.options.xAxis)) { - this.minxval = this.options.xAxis[0]; - this.maxxval = this.options.xAxis[1]; - this.xscale = this.maxxval - this.minxval; - } - else { - this.minxval = 0; - this.maxxval = null; - this.xscale = null; // val -> pos factor (eg, xval * xscale = xpos) - } - - if (!MochiKit.Base.isUndefinedOrNull(this.options.yAxis)) { - this.minyval = this.options.yAxis[0]; - this.maxyval = this.options.yAxis[1]; - this.yscale = this.maxyval - this.maxymin; - } - else { - this.minyval = 0; - this.maxyval = null; - this.yscale = null; - } - - this.bars = new Array(); // array of bars to plot for bar charts - this.points = new Array(); // array of points to plot for line plots - this.slices = new Array(); // array of slices to draw for pie charts - - this.xticks = new Array(); - this.yticks = new Array(); - - // internal states - this.datasets = new Array(); - this.minxdelta = 0; - this.xrange = 1; - this.yrange = 1; - - this.hitTestCache = {x2maxy: null}; - -}; - -// -------------------------------------------------------------------- -// Dataset Manipulation -// -------------------------------------------------------------------- - - -PlotKit.Layout.prototype.addDataset = function(setname, set_xy) { - this.datasets[setname] = set_xy; -}; - -PlotKit.Layout.prototype.removeDataset = function(setname, set_xy) { - this.datasets[setname] = null; -}; - -PlotKit.Layout.prototype.addDatasetFromTable = function(name, tableElement, xcol, ycol) { - var isNil = MochiKit.Base.isUndefinedOrNull; - var scrapeText = MochiKit.DOM.scrapeText; - var strip = MochiKit.Format.strip; - - if (isNil(xcol)) - xcol = 0; - if (isNil(ycol)) - ycol = 1; - - var rows = tableElement.tBodies[0].rows; - var data = new Array(); - if (!isNil(rows)) { - for (var i = 0; i < rows.length; i++) { - data.push([parseFloat(strip(scrapeText(rows[i].cells[xcol]))), - parseFloat(strip(scrapeText(rows[i].cells[ycol])))]); - } - this.addDataset(name, data); - return true; - } - return false; -}; - -// -------------------------------------------------------------------- -// Evaluates the layout for the current data and style. -// -------------------------------------------------------------------- - -PlotKit.Layout.prototype.evaluate = function() { - this._evaluateLimits(); - this._evaluateScales(); - if (this.style == "bar") { - this._evaluateBarCharts(); - this._evaluateBarTicks(); - } - else if (this.style == "line") { - this._evaluateLineCharts(); - this._evaluateLineTicks(); - } - else if (this.style == "pie") { - this._evaluatePieCharts(); - this._evaluatePieTicks(); - } -}; - - - -// Given the fractional x, y positions, report the corresponding -// x, y values. -PlotKit.Layout.prototype.hitTest = function(x, y) { - // TODO: make this more efficient with better datastructures - // for this.bars, this.points and this.slices - - var f = MochiKit.Format.twoDigitFloat; - - if ((this.style == "bar") && this.bars && (this.bars.length > 0)) { - for (var i = 0; i < this.bars.length; i++) { - var bar = this.bars[i]; - if ((x >= bar.x) && (x <= bar.x + bar.w) - && (y >= bar.y) && (y - bar.y <= bar.h)) - return bar; - } - } - - else if (this.style == "line") { - if (this.hitTestCache.x2maxy == null) { - this._regenerateHitTestCache(); - } - - // 1. find the xvalues that equal or closest to the give x - var xval = x / this.xscale; - var xvalues = this.hitTestCache.xvalues; - var xbefore = null; - var xafter = null; - - for (var i = 1; i < xvalues.length; i++) { - if (xvalues[i] > xval) { - xbefore = xvalues[i-1]; - xafter = xvalues[i]; - break; - } - } - - if ((xbefore != null)) { - var ybefore = this.hitTestCache.x2maxy[xbefore]; - var yafter = this.hitTestCache.x2maxy[xafter]; - var yval = (1.0 - y)/this.yscale; - - // interpolate whether we will fall inside or outside - var gradient = (yafter - ybefore) / (xafter - xbefore); - var projmaxy = ybefore + gradient * (xval - xbefore); - if (projmaxy >= yval) { - // inside the highest curve (roughly) - var obj = {xval: xval, yval: yval, - xafter: xafter, yafter: yafter, - xbefore: xbefore, ybefore: ybefore, - yprojected: projmaxy - }; - return obj; - } - } - } - - else if (this.style == "pie") { - var dist = Math.sqrt((y-0.5)*(y-0.5) + (x-0.5)*(x-0.5)); - if (dist > this.options.pieRadius) - return null; - - // TODO: actually doesn't work if we don't know how the Canvas - // lays it out, need to fix! - var angle = Math.atan2(y - 0.5, x - 0.5) - Math.PI/2; - for (var i = 0; i < this.slices.length; i++) { - var slice = this.slices[i]; - if (slice.startAngle < angle && slice.endAngle >= angle) - return slice; - } - } - - return null; -}; - -// Reports valid position rectangle for X value (only valid for bar charts) -PlotKit.Layout.prototype.rectForX = function(x) { - return null; -}; - -// Reports valid angles through which X value encloses (only valid for pie charts) -PlotKit.Layout.prototype.angleRangeForX = function(x) { - return null; -}; - -// -------------------------------------------------------------------- -// START Internal Functions -// -------------------------------------------------------------------- - -PlotKit.Layout.prototype._evaluateLimits = function() { - // take all values from all datasets and find max and min - var map = MochiKit.Base.map; - var items = MochiKit.Base.items; - var itemgetter = MochiKit.Base.itemgetter; - var collapse = PlotKit.Base.collapse; - var listMin = MochiKit.Base.listMin; - var listMax = MochiKit.Base.listMax; - var isNil = MochiKit.Base.isUndefinedOrNull; - - var all = collapse(map(itemgetter(1), items(this.datasets))); - - if (isNil(this.options.xAxis)) { - if (this.options.xOriginIsZero) - this.minxval = 0; - else - this.minxval = listMin(map(parseFloat, map(itemgetter(0), all))); - } - - if (isNil(this.options.yAxis)) { - if (this.options.yOriginIsZero) - this.minyval = 0; - else - this.minyval = listMin(map(parseFloat, map(itemgetter(1), all))); - } - - this.maxxval = listMax(map(parseFloat, map(itemgetter(0), all))); - this.maxyval = listMax(map(parseFloat, map(itemgetter(1), all))); -}; - -PlotKit.Layout.prototype._evaluateScales = function() { - var isNil = MochiKit.Base.isUndefinedOrNull; - - this.xrange = this.maxxval - this.minxval; - if (this.xrange == 0) - this.xscale = 1.0; - else - this.xscale = 1/this.xrange; - - this.yrange = this.maxyval - this.minyval; - if (this.yrange == 0) - this.yscale = 1.0; - else - this.yscale = 1/this.yrange; -}; - -PlotKit.Layout.prototype._uniqueXValues = function() { - var collapse = PlotKit.Base.collapse; - var map = MochiKit.Base.map; - var uniq = PlotKit.Base.uniq; - var getter = MochiKit.Base.itemgetter; - - var xvalues = map(parseFloat, map(getter(0), collapse(map(getter(1), items(this.datasets))))); - xvalues.sort(MochiKit.Base.compare); - return uniq(xvalues); -}; - -// Create the bars -PlotKit.Layout.prototype._evaluateBarCharts = function() { - var keys = MochiKit.Base.keys; - var items = MochiKit.Base.items; - - var setCount = keys(this.datasets).length; - - // work out how far separated values are - var xdelta = 10000000; - var xvalues = this._uniqueXValues(); - for (var i = 1; i < xvalues.length; i++) { - xdelta = Math.min(Math.abs(xvalues[i] - xvalues[i-1]), xdelta); - } - - var barWidth = 0; - var barWidthForSet = 0; - var barMargin = 0; - if (xvalues.length == 1) { - // note we have to do something smarter if we only plot one value - xdelta = 1.0; - this.xscale = 1.0; - this.minxval = xvalues[0]; - barWidth = 1.0 * this.options.barWidthFillFraction; - barWidthForSet = barWidth/setCount; - barMargin = (1.0 - this.options.barWidthFillFraction)/2; - } - else { - // readjust xscale to fix with bar charts - this.xscale = (1.0 - xdelta/this.xrange)/this.xrange; - barWidth = xdelta * this.xscale * this.options.barWidthFillFraction; - barWidthForSet = barWidth / setCount; - barMargin = xdelta * this.xscale * (1.0 - this.options.barWidthFillFraction)/2; - } - - this.minxdelta = xdelta; // need this for tick positions - - // add all the rects - this.bars = new Array(); - var i = 0; - for (var setName in this.datasets) { - var dataset = this.datasets[setName]; - for (var j = 0; j < dataset.length; j++) { - var item = dataset[j]; - var rect = { - x: ((parseFloat(item[0]) - this.minxval) * this.xscale) + (i * barWidthForSet) + barMargin, - y: 1.0 - ((parseFloat(item[1]) - this.minyval) * this.yscale), - w: barWidthForSet, - h: ((parseFloat(item[1]) - this.minyval) * this.yscale), - xval: parseFloat(item[0]), - yval: parseFloat(item[1]), - name: setName - }; - this.bars.push(rect); - } - i++; - } -}; - - -// Create the line charts -PlotKit.Layout.prototype._evaluateLineCharts = function() { - var keys = MochiKit.Base.keys; - var items = MochiKit.Base.items; - - var setCount = keys(this.datasets).length; - - // add all the rects - this.points = new Array(); - var i = 0; - for (var setName in this.datasets) { - var dataset = this.datasets[setName]; - dataset.sort(function(a, b) { return compare(parseFloat(a[0]), parseFloat(b[0])); }); - for (var j = 0; j < dataset.length; j++) { - var item = dataset[j]; - var point = { - x: ((parseFloat(item[0]) - this.minxval) * this.xscale), - y: 1.0 - ((parseFloat(item[1]) - this.minyval) * this.yscale), - xval: parseFloat(item[0]), - yval: parseFloat(item[1]), - name: setName - }; - this.points.push(point); - } - i++; - } -}; - -// Create the pie charts -PlotKit.Layout.prototype._evaluatePieCharts = function() { - var items = MochiKit.Base.items; - var sum = MochiKit.Iter.sum; - var getter = MochiKit.Base.itemgetter; - - var setCount = keys(this.datasets).length; - - // we plot the y values of the first dataset - var dataset = items(this.datasets)[0][1]; - var total = sum(map(getter(1), dataset)); - - this.slices = new Array(); - var currentAngle = 0.0; - for (var i = 0; i < dataset.length; i++) { - var fraction = dataset[i][1] / total; - var startAngle = currentAngle * Math.PI * 2; - var endAngle = (currentAngle + fraction) * Math.PI * 2; - - var slice = {fraction: fraction, - xval: dataset[i][0], - yval: dataset[i][1], - startAngle: startAngle, - endAngle: endAngle - }; - this.slices.push(slice); - currentAngle += fraction; - } -}; - -PlotKit.Layout.prototype._evaluateLineTicksForXAxis = function() { - var isNil = MochiKit.Base.isUndefinedOrNull; - - if (this.options.xTicks) { - // we use use specified ticks with optional labels - - this.xticks = new Array(); - var makeTicks = function(tick) { - var label = tick.label; - if (isNil(label)) - label = tick.v.toString(); - var pos = this.xscale * (tick.v - this.minxval); - this.xticks.push([pos, label]); - }; - MochiKit.Iter.forEach(this.options.xTicks, bind(makeTicks, this)); - } - else if (this.options.xNumberOfTicks) { - // we use defined number of ticks as hint to auto generate - var xvalues = this._uniqueXValues(); - var roughSeparation = this.xrange / this.options.xNumberOfTicks; - var tickCount = 0; - - this.xticks = new Array(); - for (var i = 0; i <= xvalues.length; i++) { - if (xvalues[i] >= (tickCount) * roughSeparation) { - var pos = this.xscale * (xvalues[i] - this.minxval); - if ((pos > 1.0) || (pos < 0.0)) - return; - this.xticks.push([pos, xvalues[i]]); - tickCount++; - } - if (tickCount > this.options.xNumberOfTicks) - break; - } - } -}; - -PlotKit.Layout.prototype._evaluateLineTicksForYAxis = function() { - var isNil = MochiKit.Base.isUndefinedOrNull; - - - if (this.options.yTicks) { - this.yticks = new Array(); - var makeTicks = function(tick) { - var label = tick.label; - if (isNil(label)) - label = tick.v.toString(); - var pos = 1.0 - (this.yscale * (tick.v + this.minxval)); - if ((pos < 0.0) || (pos > 1.0)) - return; - this.yticks.push([pos, label]); - }; - MochiKit.Iter.forEach(this.options.yTicks, bind(makeTicks, this)); - } - else if (this.options.yNumberOfTicks) { - // We use the optionally defined number of ticks as a guide - this.yticks = new Array(); - - // if we get this separation right, we'll have good looking graphs - var roundInt = PlotKit.Base.roundInterval; - var prec = this.options.yTickPrecision; - var roughSeparation = roundInt(this.yrange, - this.options.yNumberOfTicks, - this.options.yTickPrecision); - - for (var i = 0; i <= this.options.yNumberOfTicks; i++) { - var yval = this.minyval + (i * roughSeparation); - var pos = 1.0 - ((yval - this.minyval) * this.yscale); - this.yticks.push([pos, MochiKit.Format.roundToFixed(yval, 1)]); - } - } -}; - -PlotKit.Layout.prototype._evaluateLineTicks = function() { - this._evaluateLineTicksForXAxis(); - this._evaluateLineTicksForYAxis(); -}; - -PlotKit.Layout.prototype._evaluateBarTicks = function() { - this._evaluateLineTicks(); - var centerInBar = function(tick) { - return [tick[0] + (this.minxdelta * this.xscale)/2, tick[1]]; - }; - this.xticks = MochiKit.Base.map(bind(centerInBar, this), this.xticks); -}; - -PlotKit.Layout.prototype._evaluatePieTicks = function() { - var isNil = MochiKit.Base.isUndefinedOrNull; - var formatter = MochiKit.Format.numberFormatter("#%"); - - this.xticks = new Array(); - if (this.options.xTicks) { - // make a lookup dict for x->slice values - var lookup = new Array(); - for (var i = 0; i < this.slices.length; i++) { - lookup[this.slices[i].xval] = this.slices[i]; - } - - for (var i =0; i < this.options.xTicks.length; i++) { - var tick = this.options.xTicks[i]; - var slice = lookup[tick.v]; - var label = tick.label; - if (slice) { - if (isNil(label)) - label = tick.v.toString(); - label += " (" + formatter(slice.fraction) + ")"; - this.xticks.push([tick.v, label]); - } - } - } - else { - // we make our own labels from all the slices - for (var i =0; i < this.slices.length; i++) { - var slice = this.slices[i]; - var label = slice.xval + " (" + formatter(slice.fraction) + ")"; - this.xticks.push([slice.xval, label]); - } - } -}; - -PlotKit.Layout.prototype._regenerateHitTestCache = function() { - this.hitTestCache.xvalues = this._uniqueXValues(); - this.hitTestCache.xlookup = new Array(); - this.hitTestCache.x2maxy = new Array(); - - var listMax = MochiKit.Base.listMax; - var itemgetter = MochiKit.Base.itemgetter; - var map = MochiKit.Base.map; - - // generate a lookup table for x values to y values - var setNames = keys(this.datasets); - for (var i = 0; i < setNames.length; i++) { - var dataset = this.datasets[setNames[i]]; - for (var j = 0; j < dataset.length; j++) { - var xval = dataset[j][0]; - var yval = dataset[j][1]; - if (this.hitTestCache.xlookup[xval]) - this.hitTestCache.xlookup[xval].push([yval, setNames[i]]); - else - this.hitTestCache.xlookup[xval] = [[yval, setNames[i]]]; - } - } - - for (var x in this.hitTestCache.xlookup) { - var yvals = this.hitTestCache.xlookup[x]; - this.hitTestCache.x2maxy[x] = listMax(map(itemgetter(0), yvals)); - } - - -}; - -// -------------------------------------------------------------------- -// END Internal Functions -// -------------------------------------------------------------------- - diff --git a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/SVG.js b/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/SVG.js deleted file mode 100644 index ce2427cc4c..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/SVG.js +++ /dev/null @@ -1,677 +0,0 @@ -/* - PlotKit SVG - =========== - SVG Renderer for PlotKit - - Copyright - --------- - Copyright 2005,2006 (c) Alastair Tse - For use under the BSD license. -*/ - -// ------------------------------------------------------------------------- -// NOTES: - If you use XHTML1.1 strict, then you must include each MochiKit -// file individuall. -// - For IE support, you must include the AdobeSVG object hack. -// See tests/svg.html for details. -// ------------------------------------------------------------------------- -// ------------------------------------------------------------------------- -// Check required components -// ------------------------------------------------------------------------- - -try { - if (typeof(PlotKit.Layout) == 'undefined') - { - throw ""; - } -} -catch (e) { - throw "PlotKit depends on MochiKit.{Base,Color,DOM,Format} and PlotKit.Layout" -} - - -// --------------------------------------------------------------------------- -// SVG Renderer -// --------------------------------------------------------------------------- - -PlotKit.SVGRenderer = function(element, layout, options) { - if (arguments.length > 0) - this.__init__(element, layout, options); -}; - -PlotKit.SVGRenderer.NAME = "PlotKit.SVGRenderer"; -PlotKit.SVGRenderer.VERSION = PlotKit.VERSION; - -PlotKit.SVGRenderer.__repr__ = function() { - return "[" + this.NAME + " " + this.VERSION + "]"; -}; - -PlotKit.SVGRenderer.toString = function() { - return this.__repr__(); -} - -PlotKit.SVGRenderer.isSupported = function() { - // TODO - return true; -}; - -PlotKit.SVGRenderer.prototype.__init__ = function(element, layout, options) { - var isNil = MochiKit.Base.isUndefinedOrNull; - - // default options - this.options = { - "drawBackground": true, - "backgroundColor": Color.whiteColor(), - "padding": {left: 30, right: 30, top: 5, bottom: 10}, - "colorScheme": PlotKit.Base.palette(PlotKit.Base.baseColors()[1]), - "strokeColor": Color.whiteColor(), - "strokeColorTransform": "asStrokeColor", - "strokeWidth": 0.5, - "shouldFill": true, - "shouldStroke": true, - "drawXAxis": true, - "drawYAxis": true, - "axisLineColor": Color.blackColor(), - "axisLineWidth": 0.5, - "axisTickSize": 3, - "axisLabelColor": Color.blackColor(), - "axisLabelFont": "Arial", - "axisLabelFontSize": 9, - "axisLabelWidth": 50, - "axisLabelUseDiv": true, - "pieRadius": 0.4, - "enableEvents": true - }; - - MochiKit.Base.update(this.options, options ? options : {}); - this.layout = layout; - this.style = layout.style; - this.element = MochiKit.DOM.getElement(element); - this.container = this.element.parentNode; - this.height = parseInt(this.element.getAttribute("height")); - this.width = parseInt(this.element.getAttribute("width")); - this.document = document; - this.root = this.element; - - // Adobe SVG Support: - // - if an exception is thrown, then no Adobe SVG Plugin support. - try { - this.document = this.element.getSVGDocument(); - this.root = isNil(this.document.documentElement) ? this.element : this.document.documentElement; - } - catch (e) { - } - - this.element.style.zIndex = 1; - - if (isNil(this.element)) - throw "SVGRenderer() - passed SVG object is not found"; - - if (isNil(this.container) || this.container.nodeName.toLowerCase() != "div") - throw "SVGRenderer() - No DIV's around the SVG."; - - // internal state - this.xlabels = new Array(); - this.ylabels = new Array(); - - // initialise some meta structures in SVG - this.defs = this.createSVGElement("defs"); - - this.area = { - x: this.options.padding.left, - y: this.options.padding.top, - w: this.width - this.options.padding.left - this.options.padding.right, - h: this.height - this.options.padding.top - this.options.padding.bottom - }; - - MochiKit.DOM.updateNodeAttributes(this.container, - {"style":{ "position": "relative", "width": this.width + "px"}}); - - -}; - - -PlotKit.SVGRenderer.prototype.render = function() { - if (this.options.drawBackground) - this._renderBackground(); - - if (this.style == "bar") { - this._renderBarChart(); - this._renderBarAxis(); - } - else if (this.style == "pie") { - this._renderPieChart(); - this._renderPieAxis(); - } - else if (this.style == "line") { - this._renderLineChart(); - this._renderLineAxis(); - } -}; - -PlotKit.SVGRenderer.prototype._renderBarOrLine = function(data, plotFunc, startFunc, endFunc) { - - var colorCount = this.options.colorScheme.length; - var colorScheme = this.options.colorScheme; - var setNames = MochiKit.Base.keys(this.layout.datasets); - var setCount = setNames.length; - - for (var i = 0; i < setCount; i++) { - var setName = setNames[i]; - var attrs = new Array(); - var color = colorScheme[i%colorCount]; - - if (this.options.shouldFill) - attrs["fill"] = color.toRGBString(); - else - attrs["fill"] = "none"; - - if (this.options.shouldStroke && - (this.options.strokeColor || this.options.strokeColorTransform)) { - if (this.options.strokeColor) - attrs["stroke"] = this.options.strokeColor.toRGBString(); - else if (this.options.strokeColorTransform) - attrs["stroke"] = color[this.options.strokeColorTransform]().toRGBString(); - attrs["strokeWidth"] = this.options.strokeWidth; - } - - if (startFunc) - startFunc(attrs); - - var forEachFunc = function(obj) { - if (obj.name == setName) - plotFunc(attrs, obj); - }; - - MochiKit.Iter.forEach(data, bind(forEachFunc, this)); - if (endFunc) - endFunc(attrs); - } -}; - -PlotKit.SVGRenderer.prototype._renderBarChart = function() { - var bind = MochiKit.Base.bind; - - var drawRect = function(attrs, bar) { - var x = this.area.w * bar.x + this.area.x; - var y = this.area.h * bar.y + this.area.y; - var w = this.area.w * bar.w; - var h = this.area.h * bar.h; - this._drawRect(x, y, w, h, attrs); - }; - this._renderBarOrLine(this.layout.bars, bind(drawRect, this)); -}; - -PlotKit.SVGRenderer.prototype._renderLineChart = function() { - var bind = MochiKit.Base.bind; - - var addPoint = function(attrs, point) { - this._tempPointsBuffer += (this.area.w * point.x + this.area.x) + "," + - (this.area.h * point.y + this.area.y) + " "; - }; - - var startLine = function(attrs) { - this._tempPointsBuffer = ""; - this._tempPointsBuffer += (this.area.x) + "," + (this.area.y+this.area.h) + " "; - }; - - var endLine = function(attrs) { - this._tempPointsBuffer += (this.area.w + this.area.x) + "," +(this.area.h + this.area.y); - attrs["points"] = this._tempPointsBuffer; - var elem = this.createSVGElement("polygon", attrs); - this.root.appendChild(elem); - }; - - this._renderBarOrLine(this.layout.points, - bind(addPoint, this), - bind(startLine, this), - bind(endLine, this)); -}; - - -PlotKit.SVGRenderer.prototype._renderPieChart = function() { - var colorCount = this.options.colorScheme.length; - var slices = this.layout.slices; - - var centerx = this.area.x + this.area.w * 0.5; - var centery = this.area.y + this.area.h * 0.5; - var radius = Math.min(this.area.w * this.options.pieRadius, - this.area.h * this.options.pieRadius); - - // NOTE NOTE!! Canvas Tag draws the circle clockwise from the y = 0, x = 1 - // so we have to subtract 90 degrees to make it start at y = 1, x = 0 - - // workaround if we only have 1 slice of 100% - if (slices.length == 1 && (Math.abs(slices[0].startAngle) - Math.abs(slices[0].endAngle) < 0.1)) { - var attrs = {"cx": centerx , "cy": centery , "r": radius }; - var color = this.options.colorScheme[0]; - if (this.options.shouldFill) - attrs["fill"] = color.toRGBString(); - else - attrs["fill"] = "none"; - - if (this.options.shouldStroke && - (this.options.strokeColor || this.options.strokeColorTransform)) { - if (this.options.strokeColor) - attrs["stroke"] = this.options.strokeColor.toRGBString(); - else if (this.options.strokeColorTransform) - attrs["stroke"] = color[this.options.strokeColorTransform]().toRGBString(); - attrs["style"] = "stroke-width: " + this.options.strokeWidth; - } - - this.root.appendChild(this.createSVGElement("circle", attrs)); - return; - } - - for (var i = 0; i < slices.length; i++) { - var attrs = new Array(); - var color = this.options.colorScheme[i%colorCount]; - if (this.options.shouldFill) - attrs["fill"] = color.toRGBString(); - else - attrs["fill"] = "none"; - - if (this.options.shouldStroke && - (this.options.strokeColor || this.options.strokeColorTransform)) { - if (this.options.strokeColor) - attrs["stroke"] = this.options.strokeColor.toRGBString(); - else if (this.options.strokeColorTransform) - attrs["stroke"] = color[this.options.strokeColorTransform]().toRGBString(); - attrs["style"] = "stroke-width:" + this.options.strokeWidth; - } - - var largearc = 0; - if (Math.abs(slices[i].endAngle - slices[i].startAngle) > Math.PI) - largearc = 1; - var x1 = Math.cos(slices[i].startAngle - Math.PI/2) * radius; - var y1 = Math.sin(slices[i].startAngle - Math.PI/2) * radius; - var x2 = Math.cos(slices[i].endAngle - Math.PI/2) * radius; - var y2 = Math.sin(slices[i].endAngle - Math.PI/2) * radius; - var rx = x2 - x1; - var ry = y2 - y1; - - var pathString = "M" + centerx + "," + centery + " "; - pathString += "l" + x1 + "," + y1 + " "; - pathString += "a" + radius + "," + radius + " 0 " + largearc + ",1 " + rx + "," + ry + " z"; - - attrs["d"] = pathString; - - var elem = this.createSVGElement("path", attrs); - this.root.appendChild(elem); - } -}; - -PlotKit.SVGRenderer.prototype._renderBarAxis = function() { - this._renderAxis(); -} - -PlotKit.SVGRenderer.prototype._renderLineAxis = function() { - this._renderAxis(); -}; - - -PlotKit.SVGRenderer.prototype._renderAxis = function() { - - if (!this.options.drawXAxis && !this.options.drawYAxis) - return; - - var labelStyle = {"style": - {"position": "absolute", - "textAlign": "center", - "fontSize": this.options.axisLabelFontSize + "px", - "zIndex": 10, - "color": this.options.axisLabelColor.toRGBString(), - "width": this.options.axisLabelWidth + "px", - "overflow": "hidden" - } - }; - - // axis lines - var lineAttrs = { - "stroke": this.options.axisLineColor.toRGBString(), - "strokeWidth": this.options.axisLineWidth - }; - - - if (this.options.drawYAxis) { - if (this.layout.yticks) { - var drawTick = function(tick) { - var x = this.area.x; - var y = this.area.y + tick[0] * this.area.h; - this._drawLine(x, y, x - 3, y, lineAttrs); - - if (this.options.axisLabelUseDiv) { - var label = DIV(labelStyle, tick[1]); - label.style.top = (y - this.options.axisLabelFontSize) + "px"; - label.style.left = (x - this.options.padding.left + this.options.axisTickSize) + "px"; - label.style.textAlign = "left"; - label.style.width = (this.options.padding.left - 3) + "px"; - MochiKit.DOM.appendChildNodes(this.container, label); - this.ylabels.push(label); - } - else { - var attrs = { - y: y + 3, - x: (x - this.options.padding.left + 3), - width: (this.options.padding.left - this.options.axisTickSize) + "px", - height: (this.options.axisLabelFontSize + 3) + "px", - fontFamily: "Arial", - fontSize: this.options.axisLabelFontSize + "px", - fill: this.options.axisLabelColor.toRGBString() - }; - - /* we can do clipping just like DIVs - http://www.xml.com/pub/a/2004/06/02/svgtype.html */ - /* - var mask = this.createSVGElement("mask", {id: "mask" + tick[0]}); - var maskShape = this.createSVGElement("rect", - {y: y + 3, - x: (x - this.options.padding.left + 3), - width: (this.options.padding.left - this.options.axisTickSize) + "px", - height: (this.options.axisLabelFontSize + 3) + "px", - style: {"fill": "#ffffff", "stroke": "#000000"}}); - mask.appendChild(maskShape); - this.defs.appendChild(mask); - - attrs["filter"] = "url(#mask" + tick[0] + ")"; - */ - - var label = this.createSVGElement("text", attrs); - label.appendChild(this.document.createTextNode(tick[1])); - this.root.appendChild(label); - } - }; - - MochiKit.Iter.forEach(this.layout.yticks, bind(drawTick, this)); - } - - this._drawLine(this.area.x, this.area.y, this.area.x, this.area.y + this.area.h, lineAttrs); - } - - if (this.options.drawXAxis) { - if (this.layout.xticks) { - var drawTick = function(tick) { - var x = this.area.x + tick[0] * this.area.w; - var y = this.area.y + this.area.h; - this._drawLine(x, y, x, y + this.options.axisTickSize, lineAttrs); - - if (this.options.axisLabelUseDiv) { - var label = DIV(labelStyle, tick[1]); - label.style.top = (y + this.options.axisTickSize) + "px"; - label.style.left = (x - this.options.axisLabelWidth/2) + "px"; - label.style.textAlign = "center"; - label.style.width = this.options.axisLabelWidth + "px"; - MochiKit.DOM.appendChildNodes(this.container, label); - this.xlabels.push(label); - } - else { - var attrs = { - y: (y + this.options.axisTickSize + this.options.axisLabelFontSize), - x: x - 3, - width: this.options.axisLabelWidth + "px", - height: (this.options.axisLabelFontSize + 3) + "px", - fontFamily: "Arial", - fontSize: this.options.axisLabelFontSize + "px", - fill: this.options.axisLabelColor.toRGBString(), - textAnchor: "middle" - }; - var label = this.createSVGElement("text", attrs); - label.appendChild(this.document.createTextNode(tick[1])); - this.root.appendChild(label); - } - }; - - MochiKit.Iter.forEach(this.layout.xticks, bind(drawTick, this)); - } - - this._drawLine(this.area.x, this.area.y + this.area.h, this.area.x + this.area.w, this.area.y + this.area.h, lineAttrs) - } -}; - -PlotKit.SVGRenderer.prototype._renderPieAxis = function() { - - if (this.layout.xticks) { - // make a lookup dict for x->slice values - var lookup = new Array(); - for (var i = 0; i < this.layout.slices.length; i++) { - lookup[this.layout.slices[i].xval] = this.layout.slices[i]; - } - - var centerx = this.area.x + this.area.w * 0.5; - var centery = this.area.y + this.area.h * 0.5; - var radius = Math.min(this.area.w * this.options.pieRadius + 10, - this.area.h * this.options.pieRadius + 10); - var labelWidth = this.options.axisLabelWidth; - - for (var i = 0; i < this.layout.xticks.length; i++) { - var slice = lookup[this.layout.xticks[i][0]]; - if (MochiKit.Base.isUndefinedOrNull(slice)) - continue; - - - var angle = (slice.startAngle + slice.endAngle)/2; - // normalize the angle - var normalisedAngle = angle; - if (normalisedAngle > Math.PI * 2) - normalisedAngle = normalisedAngle - Math.PI * 2; - else if (normalisedAngle < 0) - normalisedAngle = normalisedAngle + Math.PI * 2; - - var labelx = centerx + Math.sin(normalisedAngle) * (radius + 10); - var labely = centery - Math.cos(normalisedAngle) * (radius + 10); - - var attrib = { - "position": "absolute", - "zIndex": 11, - "width": labelWidth + "px", - "fontSize": this.options.axisLabelFontSize + "px", - "overflow": "hidden", - "color": this.options.axisLabelColor.toHexString() - }; - - var svgattrib = { - "width": labelWidth + "px", - "fontSize": this.options.axisLabelFontSize + "px", - "height": (this.options.axisLabelFontSize + 3) + "px", - "fill": this.options.axisLabelColor.toRGBString() - }; - - if (normalisedAngle <= Math.PI * 0.5) { - // text on top and align left - MochiKit.Base.update(attrib, { - 'textAlign': 'left', 'verticalAlign': 'top', - 'left': labelx + 'px', - 'top': (labely - this.options.axisLabelFontSize) + "px" - }); - MochiKit.Base.update(svgattrib, { - "x": labelx, - "y" :(labely - this.options.axisLabelFontSize), - "textAnchor": "left" - }); - } - else if ((normalisedAngle > Math.PI * 0.5) && (normalisedAngle <= Math.PI)) { - // text on bottom and align left - MochiKit.Base.update(attrib, { - 'textAlign': 'left', 'verticalAlign': 'bottom', - 'left': labelx + 'px', - 'top': labely + "px" - }); - MochiKit.Base.update(svgattrib, { - 'textAnchor': 'left', - 'x': labelx, - 'y': labely - }); - } - else if ((normalisedAngle > Math.PI) && (normalisedAngle <= Math.PI*1.5)) { - // text on bottom and align right - MochiKit.Base.update(attrib, { - 'textAlign': 'right', 'verticalAlign': 'bottom', - 'left': labelx + 'px', - 'top': labely + "px" - }); - MochiKit.Base.update(svgattrib, { - 'textAnchor': 'right', - 'x': labelx - labelWidth, - 'y': labely - }); - } - else { - // text on top and align right - MochiKit.Base.update(attrib, { - 'textAlign': 'left', 'verticalAlign': 'bottom', - 'left': labelx + 'px', - 'top': labely + "px" - }); - MochiKit.Base.update(svgattrib, { - 'textAnchor': 'left', - 'x': labelx - labelWidth, - 'y': labely - this.options.axisLabelFontSize - }); - } - - if (this.options.axisLabelUseDiv) { - var label = DIV({'style': attrib}, this.layout.xticks[i][1]); - this.xlabels.push(label); - MochiKit.DOM.appendChildNodes(this.container, label); - } - else { - var label = this.createSVGElement("text", svgattrib); - label.appendChild(this.document.createTextNode(this.layout.xticks[i][1])) - this.root.appendChild(label); - } - } - - } -}; - -PlotKit.SVGRenderer.prototype._renderBackground = function() { - var opts = {"stroke": "none", - "fill": this.options.backgroundColor.toRGBString() - }; - this._drawRect(0, 0, this.width, this.height, opts); -}; - -PlotKit.SVGRenderer.prototype._drawRect = function(x, y, w, h, moreattrs) { - var attrs = {x: x + "px", y: y + "px", width: w + "px", height: h + "px"}; - if (moreattrs) - MochiKit.Base.update(attrs, moreattrs); - - var elem = this.createSVGElement("rect", attrs); - this.root.appendChild(elem); -}; - -PlotKit.SVGRenderer.prototype._drawLine = function(x1, y1, x2, y2, moreattrs) { - var attrs = {x1: x1 + "px", y1: y1 + "px", x2: x2 + "px", y2: y2 + "px"}; - if (moreattrs) - MochiKit.Base.update(attrs, moreattrs); - - var elem = this.createSVGElement("line", attrs); - this.root.appendChild(elem); -} - -PlotKit.SVGRenderer.prototype.clear = function() { - while(this.element.firstChild) { - this.element.removeChild(this.element.firstChild); - } - - if (this.options.axisLabelUseDiv) { - for (var i = 0; i < this.xlabels.length; i++) { - MochiKit.DOM.removeElement(this.xlabels[i]); - } - for (var i = 0; i < this.ylabels.length; i++) { - MochiKit.DOM.removeElement(this.ylabels[i]); - } - } - this.xlabels = new Array(); - this.ylabels = new Array(); -}; - -PlotKit.SVGRenderer.prototype.createSVGElement = function(name, attrs) { - var isNil = MochiKit.Base.isUndefinedOrNull; - var elem; - var doc = isNil(this.document) ? document : this.document; - - try { - elem = doc.createElementNS("http://www.w3.org/2000/svg", name); - } - catch (e) { - elem = doc.createElement(name); - elem.setAttribute("xmlns", "http://www.w3.org/2000/svg"); - } - - if (attrs) - MochiKit.DOM.updateNodeAttributes(elem, attrs); - - // TODO: we don't completely emulate the MochiKit.DOM.createElement - // as we don't care about nodes contained. We really should though. - - return elem; - -}; - -PlotKit.SVGRenderer.SVGNS = 'http://www.w3.org/2000/svg'; - -PlotKit.SVGRenderer.SVG = function(attrs) { - // we have to do things differently for IE+AdobeSVG. - // My guess this works (via trial and error) is that we need to - // have an SVG object in order to use SVGDocument.createElementNS - // but IE doesn't allow us to that. - - var ie = navigator.appVersion.match(/MSIE (\d\.\d)/); - var opera = (navigator.userAgent.toLowerCase().indexOf("opera") != -1); - if (ie && (ie[1] >= 6) && (!opera)) { - var width = attrs["width"] ? attrs["width"] : "100"; - var height = attrs["height"] ? attrs["height"] : "100"; - var eid = attrs["id"] ? attrs["id"] : "notunique"; - - var html = ''; - - var canvas = document.createElement(html); - - // create embedded SVG inside SVG. - var group = canvas.getSVGDocument().createElementNS(PlotKit.SVGRenderer.SVGNS, "svg"); - group.setAttribute("width", width); - group.setAttribute("height", height); - canvas.getSVGDocument().appendChild(group); - - return canvas; - } - else { - return PlotKit.SVGRenderer.prototype.createSVGElement("svg", attrs); - } -}; - -PlotKit.SVGRenderer.isSupported = function() { - var isOpera = (navigator.userAgent.toLowerCase().indexOf("opera") != -1); - var ieVersion = navigator.appVersion.match(/MSIE (\d\.\d)/); - var safariVersion = navigator.userAgent.match(/AppleWebKit\/(\d+)/); - var operaVersion = navigator.userAgent.match(/Opera\/(\d*\.\d*)/); - var mozillaVersion = navigator.userAgent.match(/rv:(\d*\.\d*).*Gecko/); - - - if (ieVersion && (ieVersion[1] >= 6) && !isOpera) { - var dummysvg = document.createElement(''); - try { - dummysvg.getSVGDocument(); - dummysvg = null; - return true; - } - catch (e) { - return false; - } - } - - /* support not really there yet. no text and paths are buggy - if (safariVersion && (safariVersion[1] > 419)) - return true; - */ - - if (operaVersion && (operaVersion[1] > 8.9)) - return true - - if (mozillaVersion && (mozillaVersion > 1.7)) - return true; - - return false; -}; diff --git a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/SweetCanvas.js b/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/SweetCanvas.js deleted file mode 100644 index 07492ae847..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/SweetCanvas.js +++ /dev/null @@ -1,281 +0,0 @@ -/* - PlotKit Sweet Canvas Renderer - ============================= - Canvas Renderer for PlotKit which looks pretty! - - Copyright - --------- - Copyright 2005,2006 (c) Alastair Tse - For use under the BSD license. -*/ - -// ------------------------------------------------------------------------- -// Check required components -// ------------------------------------------------------------------------- - -try { - if (typeof(PlotKit.CanvasRenderer) == 'undefined') - { - throw ""; - } -} -catch (e) { - throw "SweetCanvas depends on MochiKit.{Base,Color,DOM,Format} and PlotKit.{Layout, Canvas}" -} - - -if (typeof(PlotKit.SweetCanvasRenderer) == 'undefined') { - PlotKit.SweetCanvasRenderer = {}; -} - -PlotKit.SweetCanvasRenderer = function(element, layout, options) { - if (arguments.length > 0) { - this.__init__(element, layout, options); - } -}; - -PlotKit.SweetCanvasRenderer.NAME = "PlotKit.SweetCanvasRenderer"; -PlotKit.SweetCanvasRenderer.VERSION = PlotKit.VERSION; - -PlotKit.SweetCanvasRenderer.__repr__ = function() { - return "[" + this.NAME + " " + this.VERSION + "]"; -}; - -PlotKit.SweetCanvasRenderer.toString = function() { - return this.__repr__(); -}; - -// --------------------------------------------------------------------- -// Subclassing Magic -// --------------------------------------------------------------------- - -PlotKit.SweetCanvasRenderer.prototype = new PlotKit.CanvasRenderer(); -PlotKit.SweetCanvasRenderer.prototype.constructor = PlotKit.SweetCanvasRenderer; -PlotKit.SweetCanvasRenderer.__super__ = PlotKit.CanvasRenderer.prototype; - -// --------------------------------------------------------------------- -// Constructor -// --------------------------------------------------------------------- - -PlotKit.SweetCanvasRenderer.prototype.__init__ = function(el, layout, opts) { - var moreOpts = PlotKit.Base.officeBlue(); - MochiKit.Base.update(moreOpts, opts); - PlotKit.SweetCanvasRenderer.__super__.__init__.call(this, el, layout, moreOpts); -}; - -// --------------------------------------------------------------------- -// Extended Plotting Functions -// --------------------------------------------------------------------- - -PlotKit.SweetCanvasRenderer.prototype._renderBarChart = function() { - var bind = MochiKit.Base.bind; - var shadowColor = Color.blackColor().colorWithAlpha(0.1).toRGBString(); - - var prepareFakeShadow = function(context, x, y, w, h) { - context.fillStyle = shadowColor; - context.fillRect(x-2, y-2, w+4, h+2); - context.fillStyle = shadowColor; - context.fillRect(x-1, y-1, w+2, h+1); - }; - - var colorCount = this.options.colorScheme.length; - var colorScheme = this.options.colorScheme; - var setNames = MochiKit.Base.keys(this.layout.datasets); - var setCount = setNames.length; - - var chooseColor = function(name) { - for (var i = 0; i < setCount; i++) { - if (name == setNames[i]) - return colorScheme[i%colorCount]; - } - return colorScheme[0]; - }; - - var drawRect = function(context, bar) { - var x = this.area.w * bar.x + this.area.x; - var y = this.area.h * bar.y + this.area.y; - var w = this.area.w * bar.w; - var h = this.area.h * bar.h; - - if ((w < 1) || (h < 1)) - return; - - context.save(); - - context.shadowBlur = 5.0; - context.shadowColor = Color.fromHexString("#888888").toRGBString(); - - if (this.isIE) { - context.save(); - context.fillStyle = "#cccccc"; - context.fillRect(x-2, y-2, w+4, h+2); - context.restore(); - } - else { - prepareFakeShadow(context, x, y, w, h); - } - - context.fillStyle = chooseColor(bar.name).toRGBString(); - context.fillRect(x, y, w, h); - - context.shadowBlur = 0; - context.strokeStyle = Color.whiteColor().toRGBString(); - context.lineWidth = 2.0; - - context.strokeRect(x, y, w, h); - - context.restore(); - - }; - this._renderBarChartWrap(this.layout.bars, bind(drawRect, this)); -}; - -PlotKit.CanvasRenderer.prototype._renderLineChart = function() { - var context = this.element.getContext("2d"); - var colorCount = this.options.colorScheme.length; - var colorScheme = this.options.colorScheme; - var setNames = MochiKit.Base.keys(this.layout.datasets); - var setCount = setNames.length; - var bind = MochiKit.Base.bind; - - - for (var i = 0; i < setCount; i++) { - var setName = setNames[i]; - var color = colorScheme[i%colorCount]; - var strokeX = this.options.strokeColorTransform; - - // setup graphics context - context.save(); - - // create paths - var makePath = function() { - context.beginPath(); - context.moveTo(this.area.x, this.area.y + this.area.h); - var addPoint = function(context, point) { - if (point.name == setName) - context.lineTo(this.area.w * point.x + this.area.x, - this.area.h * point.y + this.area.y); - }; - MochiKit.Iter.forEach(this.layout.points, partial(addPoint, context), this); - context.lineTo(this.area.w + this.area.x, - this.area.h + this.area.y); - context.lineTo(this.area.x, this.area.y + this.area.h); - context.closePath(); - }; - - // faux shadow for firefox - context.save(); - if (this.isIE) { - context.fillStyle = "#cccccc"; - } - else { - context.fillStyle = Color.blackColor().colorWithAlpha(0.2).toRGBString(); - } - - context.translate(-1, -2); - bind(makePath, this)(); - context.fill(); - context.restore(); - - context.shadowBlur = 5.0; - context.shadowColor = Color.fromHexString("#888888").toRGBString(); - context.fillStyle = color.toRGBString(); - context.lineWidth = 2.0; - context.strokeStyle = Color.whiteColor().toRGBString(); - - bind(makePath, this)(); - context.fill(); - bind(makePath, this)(); - context.stroke(); - - context.restore(); - } -}; - -PlotKit.CanvasRenderer.prototype._renderPieChart = function() { - var context = this.element.getContext("2d"); - - var colorCount = this.options.colorScheme.length; - var slices = this.layout.slices; - - var centerx = this.area.x + this.area.w * 0.5; - var centery = this.area.y + this.area.h * 0.5; - var radius = Math.min(this.area.w * this.options.pieRadius, - this.area.h * this.options.pieRadius); - - if (this.isIE) { - centerx = parseInt(centerx); - centery = parseInt(centery); - radius = parseInt(radius); - } - - // NOTE NOTE!! Canvas Tag draws the circle clockwise from the y = 0, x = 1 - // so we have to subtract 90 degrees to make it start at y = 1, x = 0 - - if (!this.isIE) { - context.save(); - var shadowColor = Color.blackColor().colorWithAlpha(0.2); - context.fillStyle = shadowColor.toRGBString(); - context.shadowBlur = 5.0; - context.shadowColor = Color.fromHexString("#888888").toRGBString(); - context.translate(1, 1); - context.beginPath(); - context.moveTo(centerx, centery); - context.arc(centerx, centery, radius + 2, 0, Math.PI*2, false); - context.closePath(); - context.fill(); - context.restore(); - } - - context.save(); - context.strokeStyle = Color.whiteColor().toRGBString(); - context.lineWidth = 2.0; - for (var i = 0; i < slices.length; i++) { - var color = this.options.colorScheme[i%colorCount]; - context.fillStyle = color.toRGBString(); - - var makePath = function() { - context.beginPath(); - context.moveTo(centerx, centery); - context.arc(centerx, centery, radius, - slices[i].startAngle - Math.PI/2, - slices[i].endAngle - Math.PI/2, - false); - context.lineTo(centerx, centery); - context.closePath(); - }; - - if (Math.abs(slices[i].startAngle - slices[i].endAngle) > 0.0001) { - makePath(); - context.fill(); - makePath(); - context.stroke(); - } - } - context.restore(); -}; - -PlotKit.SweetCanvasRenderer.prototype._renderBackground = function() { - var context = this.element.getContext("2d"); - - if (this.layout.style == "bar" || this.layout.style == "line") { - context.save(); - context.fillStyle = this.options.backgroundColor.toRGBString(); - context.fillRect(this.area.x, this.area.y, this.area.w, this.area.h); - context.strokeStyle = Color.whiteColor().toRGBString(); - context.lineWidth = 1.0; - for (var i = 0; i < this.layout.yticks.length; i++) { - var y = this.layout.yticks[i][0] * this.area.h + this.area.y; - var x = this.area.x; - context.beginPath(); - context.moveTo(x, y); - context.lineTo(x + this.area.w, y); - context.closePath(); - context.stroke(); - } - context.restore(); - } - else { - PlotKit.SweetCanvasRenderer.__super__._renderBackground.call(this); - } -}; diff --git a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/SweetSVG.js b/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/SweetSVG.js deleted file mode 100644 index 6fd6d479c9..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/SweetSVG.js +++ /dev/null @@ -1,196 +0,0 @@ -/* - PlotKit Sweet SVG Renderer - ========================== - SVG Renderer for PlotKit which looks pretty! - - Copyright - --------- - Copyright 2005,2006 (c) Alastair Tse - For use under the BSD license. -*/ - - -// ------------------------------------------------------------------------- -// Check required components -// ------------------------------------------------------------------------- - -try { - if (typeof(PlotKit.SVGRenderer) == 'undefined') - { - throw ""; - } -} -catch (e) { - throw "SweetSVG depends on MochiKit.{Base,Color,DOM,Format} and PlotKit.{Layout, SVG}" -} - - -if (typeof(PlotKit.SweetSVGRenderer) == 'undefined') { - PlotKit.SweetSVGRenderer = {}; -} - -PlotKit.SweetSVGRenderer = function(element, layout, options) { - if (arguments.length > 0) { - this.__init__(element, layout, options); - } -}; - -PlotKit.SweetSVGRenderer.NAME = "PlotKit.SweetSVGRenderer"; -PlotKit.SweetSVGRenderer.VERSION = PlotKit.VERSION; - -PlotKit.SweetSVGRenderer.__repr__ = function() { - return "[" + this.NAME + " " + this.VERSION + "]"; -}; - -PlotKit.SweetSVGRenderer.toString = function() { - return this.__repr__(); -}; - -// --------------------------------------------------------------------- -// Subclassing Magic -// --------------------------------------------------------------------- - -PlotKit.SweetSVGRenderer.prototype = new PlotKit.SVGRenderer(); -PlotKit.SweetSVGRenderer.prototype.constructor = PlotKit.SweetSVGRenderer; -PlotKit.SweetSVGRenderer.__super__ = PlotKit.SVGRenderer.prototype; - -// --------------------------------------------------------------------- -// Constructor -// --------------------------------------------------------------------- - -PlotKit.SweetSVGRenderer.prototype.__init__ = function(element, layout, options) { - var moreOpts = PlotKit.Base.officeBlue(); - MochiKit.Base.update(moreOpts, options); - PlotKit.SweetSVGRenderer.__super__.__init__.call(this, element, layout, moreOpts); - //this._addDropShadowFilter(); -}; - -PlotKit.SweetSVGRenderer.prototype._addDropShadowFilter = function() { - var filter = this.createSVGElement("filter", {x: 0, y: 0, "id":"dropShadow"}); - var goffset = this.createSVGElement("feOffset", - {"in": "SourceGraphic", "dx": 0, "dy": 0, "result": "topCopy"}); - var blur = this.createSVGElement("feGaussianBlur", - {"in": "SourceAlpha", "StdDeviation": 2, "result": "shadow"}); - var soffset = this.createSVGElement("feOffset", - {"in": "shadow", "dx": -1, "dy": -2, "result":"movedShadow"}); - var merge = this.createSVGElement("feMerge"); - var gmerge = this.createSVGElement("feMergeNode", {"in":"topCopy"}); - var smerge = this.createSVGElement("feMergeNode", {"in":"movedShadow"}); - - merge.appendChild(gmerge); - merge.appendChild(smerge); - filter.appendChild(goffset); - filter.appendChild(blur); - filter.appendChild(soffset); - filter.appendChild(merge); - this.defs.appendChild(filter); -}; - -// --------------------------------------------------------------------- -// Extended Plotting Functions -// --------------------------------------------------------------------- - -PlotKit.SweetSVGRenderer.prototype._renderBarChart = function() { - var bind = MochiKit.Base.bind; - var shadowColor = Color.blackColor().toRGBString(); - var shadowStyle = "fill:" + shadowColor + ";fill-opacity:0.15"; - var strokeStyle = "stroke-width: 2.0; stroke:" + Color.whiteColor().toRGBString(); - - var drawRect = function(attrs, bar) { - var x = this.area.w * bar.x + this.area.x; - var y = this.area.h * bar.y + this.area.y; - var w = this.area.w * bar.w; - var h = this.area.h * bar.h; - - if ((w < 1) || (h < 1)) - return; - - //attrs["filter"] = "url(#dropShadow)"; - attrs["style"] = strokeStyle; - this._drawRect(x - 2, y - 1, w+4, h+2, {"style":shadowStyle}); - this._drawRect(x, y, w, h, attrs); - }; - this._renderBarOrLine(this.layout.bars, bind(drawRect, this)); - -}; - -PlotKit.SweetSVGRenderer.prototype._renderLineChart = function() { - var bind = MochiKit.Base.bind; - var shadowColor = Color.blackColor().toRGBString(); - var shadowStyle = "fill:" + shadowColor + ";fill-opacity:0.15"; - var strokeStyle = "stroke-width: 2.0; stroke:" + Color.whiteColor().toRGBString(); - - var addPoint = function(attrs, point) { - this._tempPointsBuffer += (this.area.w * point.x + this.area.x) + "," + - (this.area.h * point.y + this.area.y) + " "; - }; - - var startLine = function(attrs) { - this._tempPointsBuffer = ""; - this._tempPointsBuffer += (this.area.x) + "," + (this.area.y+this.area.h) + " "; - }; - - var endLine = function(attrs) { - this._tempPointsBuffer += (this.area.w + this.area.x) + "," +(this.area.h + this.area.y); - attrs["points"] = this._tempPointsBuffer; - - attrs["stroke"] = "none"; - attrs["transform"] = "translate(-2, -1)"; - attrs["style"] = shadowStyle; - var shadow = this.createSVGElement("polygon", attrs); - this.root.appendChild(shadow); - - attrs["transform"] = ""; - attrs["style"] = strokeStyle; - var elem = this.createSVGElement("polygon", attrs); - this.root.appendChild(elem); - - - }; - - this._renderBarOrLine(this.layout.points, - bind(addPoint, this), - bind(startLine, this), - bind(endLine, this)); -}; - -PlotKit.SweetSVGRenderer.prototype._renderPieChart = function() { - var centerx = this.area.x + this.area.w * 0.5; - var centery = this.area.y + this.area.h * 0.5; - var shadowColor = Color.blackColor().toRGBString(); - var radius = Math.min(this.area.w * this.options.pieRadius, - this.area.h * this.options.pieRadius); - var shadowStyle = "fill:" + shadowColor + ";fill-opacity:0.15"; - - var shadow = this.createSVGElement("circle", - {"style": shadowStyle, "cx": centerx + 1, "cy": centery + 1, "r": radius + 1}); - this.root.appendChild(shadow); - - PlotKit.SweetSVGRenderer.__super__._renderPieChart.call(this); -}; - - -PlotKit.SweetSVGRenderer.prototype._renderBackground = function() { - var attrs = { - "fill": this.options.backgroundColor.toRGBString(), - "stroke": "none" - }; - - - if (this.layout.style == "bar" || this.layout.style == "line") { - this._drawRect(this.area.x, this.area.y, - this.area.w, this.area.h, attrs); - for (var i = 0; i < this.layout.yticks.length; i++) { - this._drawRect(this.area.x, - this.layout.yticks[i][0] * this.area.h + this.area.y, - this.area.w, - 1, - {"fill": Color.whiteColor().toRGBString()}); - } - } - else { - PlotKit.SweetSVGRenderer.__super__._renderBackground.call(this); - - } - -}; diff --git a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/dummy.svg b/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/dummy.svg deleted file mode 100644 index 722ec755be..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/dummy.svg +++ /dev/null @@ -1,15 +0,0 @@ - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/iecanvas.htc b/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/iecanvas.htc deleted file mode 100644 index c89e4375a2..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/js/plotkit/iecanvas.htc +++ /dev/null @@ -1,389 +0,0 @@ -/*----------------------------------------------------------------------------\ -| IE Canvas 1.0 | -|-----------------------------------------------------------------------------| -| Created by Emil A Eklund | -| (http://eae.net/contact/emil) | -|-----------------------------------------------------------------------------| -| Implementation of the canvas API for Internet Explorer. Uses VML. | -|-----------------------------------------------------------------------------| -| Copyright (c) 2005 Emil A Eklund | -|- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -| -| This program is free software; you can redistribute it and/or modify it | -| under the terms of the MIT License. | -|- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -| -| Permission is hereby granted, free of charge, to any person obtaining a | -| copy of this software and associated documentation files (the "Software"), | -| to deal in the Software without restriction, including without limitation | -| the rights to use, copy, modify, merge, publish, distribute, sublicense, | -| and/or sell copies of the Software, and to permit persons to whom the | -| Software is furnished to do so, subject to the following conditions: | -| The above copyright notice and this permission notice shall be included in | -| all copies or substantial portions of the Software. | -|- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -| -| THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | -| IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | -| FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | -| AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | -| LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING | -| FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER | -| DEALINGS IN THE SOFTWARE. | -|- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -| -| http://eae.net/license/mit | -|-----------------------------------------------------------------------------| -| Dependencies: canvas.js - For initialization of canvas elements | -|-----------------------------------------------------------------------------| -| 2005-12-27 | Work started. | -| 2005-12-29 | First version posted. | -| 2006-01-03 | Fixed bug in moveTo and lineTo, arguments where not converted | -| | to int which could cause IE to enter an endless loop. Disabled | -| | antalias for fillRect to better comply with the Mozilla, Opera | -| | and possibly Safari implementations where using fillRect is | -| | about the only way to raw non antialiased lines. | -|-----------------------------------------------------------------------------| -| Created 2005-12-27 | All changes are in the log above. | Updated 2006-01-03 | -\----------------------------------------------------------------------------*/ - - - - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/js/standardista-table-sorting.js b/edexOsgi/build.edex/esb/webapps/admin/js/standardista-table-sorting.js deleted file mode 100644 index ee9b79f182..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/js/standardista-table-sorting.js +++ /dev/null @@ -1,428 +0,0 @@ -/** - * Written by Neil Crosby. - * http://www.workingwith.me.uk/articles/scripting/standardista_table_sorting - * - * This module is based on Stuart Langridge's "sorttable" code. Specifically, - * the determineSortFunction, sortCaseInsensitive, sortDate, sortNumeric, and - * sortCurrency functions are heavily based on his code. This module would not - * have been possible without Stuart's earlier outstanding work. - * - * Use this wherever you want, but please keep this comment at the top of this file. - * - * Copyright (c) 2006 Neil Crosby - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to deal - * in the Software without restriction, including without limitation the rights - * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell - * copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in - * all copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - **/ -var standardistaTableSorting = { - - that: false, - isOdd: false, - - sortColumnIndex : -1, - lastAssignedId : 0, - newRows: -1, - lastSortedTable: -1, - - /** - * Initialises the Standardista Table Sorting module - **/ - init : function() { - // first, check whether this web browser is capable of running this script - if (!document.getElementsByTagName) { - return; - } - - this.that = this; - - this.run(); - - }, - - /** - * Runs over each table in the document, making it sortable if it has a class - * assigned named "sortable" and an id assigned. - **/ - run : function() { - var tables = document.getElementsByTagName("table"); - - for (var i=0; i < tables.length; i++) { - var thisTable = tables[i]; - - if (css.elementHasClass(thisTable, 'sortable')) { - this.makeSortable(thisTable); - } - } - }, - - /** - * Makes the given table sortable. - **/ - makeSortable : function(table) { - - // first, check if the table has an id. if it doesn't, give it one - if (!table.id) { - table.id = 'sortableTable'+this.lastAssignedId++; - } - - // if this table does not have a thead, we don't want to know about it - if (!table.tHead || !table.tHead.rows || 0 == table.tHead.rows.length) { - return; - } - - // we'll assume that the last row of headings in the thead is the row that - // wants to become clickable - var row = table.tHead.rows[table.tHead.rows.length - 1]; - - for (var i=0; i < row.cells.length; i++) { - - // create a link with an onClick event which will - // control the sorting of the table - var linkEl = createElement('a'); - linkEl.href = '#'; - linkEl.onclick = this.headingClicked; - linkEl.setAttribute('columnId', i); - linkEl.title = 'Click to sort'; - - // move the current contents of the cell that we're - // hyperlinking into the hyperlink - var innerEls = row.cells[i].childNodes; - for (var j = 0; j < innerEls.length; j++) { - linkEl.appendChild(innerEls[j]); - } - - // and finally add the new link back into the cell - row.cells[i].appendChild(linkEl); - - var spanEl = createElement('span'); - spanEl.className = 'tableSortArrow'; - spanEl.appendChild(document.createTextNode('\u00A0\u00A0')); - row.cells[i].appendChild(spanEl); - - } - - if (css.elementHasClass(table, 'autostripe')) { - this.isOdd = false; - var rows = table.tBodies[0].rows; - - // We appendChild rows that already exist to the tbody, so it moves them rather than creating new ones - for (var i=0;i 0) { - previousSortOrder = arrows[0].getAttribute('sortOrder'); - } - - // work out how we want to sort this column using the data in the first cell - // but just getting the first cell is no good if it contains no data - // so if the first cell just contains white space then we need to track - // down until we find a cell which does contain some actual data - var itm = '' - var rowNum = 0; - while ('' == itm && rowNum < table.tBodies[0].rows.length) { - itm = that.getInnerText(table.tBodies[0].rows[rowNum].cells[column]); - rowNum++; - } - var sortfn = that.determineSortFunction(itm); - - // if the last column that was sorted was this one, then all we need to - // do is reverse the sorting on this column - if (table.id == that.lastSortedTable && column == that.sortColumnIndex) { - newRows = that.newRows; - newRows.reverse(); - // otherwise, we have to do the full sort - } else { - that.sortColumnIndex = column; - var newRows = new Array(); - - for (var j = 0; j < table.tBodies[0].rows.length; j++) { - newRows[j] = table.tBodies[0].rows[j]; - } - - newRows.sort(sortfn); - } - - that.moveRows(table, newRows); - that.newRows = newRows; - that.lastSortedTable = table.id; - - // now, give the user some feedback about which way the column is sorted - - // first, get rid of any arrows in any heading cells - var arrows = css.getElementsByClass(tr, 'tableSortArrow', 'span'); - for (var j = 0; j < arrows.length; j++) { - var arrowParent = arrows[j].parentNode; - arrowParent.removeChild(arrows[j]); - - if (arrowParent != td) { - spanEl = createElement('span'); - spanEl.className = 'tableSortArrow'; - spanEl.appendChild(document.createTextNode('\u00A0\u00A0')); - arrowParent.appendChild(spanEl); - } - } - - // now, add back in some feedback - var spanEl = createElement('span'); - spanEl.className = 'tableSortArrow'; - if (null == previousSortOrder || '' == previousSortOrder || 'DESC' == previousSortOrder) { - spanEl.appendChild(document.createTextNode(' \u2191')); - spanEl.setAttribute('sortOrder', 'ASC'); - } else { - spanEl.appendChild(document.createTextNode(' \u2193')); - spanEl.setAttribute('sortOrder', 'DESC'); - } - - td.appendChild(spanEl); - - return false; - }, - - getInnerText : function(el) { - - if ('string' == typeof el || 'undefined' == typeof el) { - return el; - } - - if (el.innerText) { - return el.innerText; // Not needed but it is faster - } - - var str = el.getAttribute('standardistaTableSortingInnerText'); - if (null != str && '' != str) { - return str; - } - str = ''; - - var cs = el.childNodes; - var l = cs.length; - for (var i = 0; i < l; i++) { - // 'if' is considerably quicker than a 'switch' statement, - // in Internet Explorer which translates up to a good time - // reduction since this is a very often called recursive function - if (1 == cs[i].nodeType) { // ELEMENT NODE - str += this.getInnerText(cs[i]); - break; - } else if (3 == cs[i].nodeType) { //TEXT_NODE - str += cs[i].nodeValue; - break; - } - } - - // set the innertext for this element directly on the element - // so that it can be retrieved early next time the innertext - // is requested - el.setAttribute('standardistaTableSortingInnerText', str); - - return str; - }, - - determineSortFunction : function(itm) { - - var sortfn = this.sortCaseInsensitive; - - if (itm.match(/^\d\d[\/-]\d\d[\/-]\d\d\d\d$/)) { - sortfn = this.sortDate; - } - if (itm.match(/^\d\d[\/-]\d\d[\/-]\d\d$/)) { - sortfn = this.sortDate; - } - if (itm.match(/^[£$]/)) { - sortfn = this.sortCurrency; - } - if (itm.match(/^\d?\.?\d+$/)) { - sortfn = this.sortNumeric; - } - if (itm.match(/^[+-]?\d*\.?\d+([eE]-?\d+)?$/)) { - sortfn = this.sortNumeric; - } - if (itm.match(/^([01]?\d\d?|2[0-4]\d|25[0-5])\.([01]?\d\d?|2[0-4]\d|25[0-5])\.([01]?\d\d?|2[0-4]\d|25[0-5])\.([01]?\d\d?|2[0-4]\d|25[0-5])$/)) { - sortfn = this.sortIP; - } - - return sortfn; - }, - - sortCaseInsensitive : function(a, b) { - var that = standardistaTableSorting.that; - - var aa = that.getInnerText(a.cells[that.sortColumnIndex]).toLowerCase(); - var bb = that.getInnerText(b.cells[that.sortColumnIndex]).toLowerCase(); - if (aa==bb) { - return 0; - } else if (aa val.length) { - val = '0'+val; - } - vals[x] = val; - } - - val = vals.join('.'); - - return val; - }, - - sortIP : function(a,b) { - var that = standardistaTableSorting.that; - - var aa = that.makeStandardIPAddress(that.getInnerText(a.cells[that.sortColumnIndex]).toLowerCase()); - var bb = that.makeStandardIPAddress(that.getInnerText(b.cells[that.sortColumnIndex]).toLowerCase()); - if (aa==bb) { - return 0; - } else if (aa - - - -Message ${requestContext.messageQuery.id} - - - - - - - -
-No message could be found for ID ${requestContext.messageQuery.JMSMessageID} -
- -
- - - - - - - - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- Properties -
${prop.key}${prop.value}
-
- - - - - - - - - - - -
- Message Details -
-
- - - - - - - - - - - - - - - - - - - -
- Message Actions -
Delete
Copy - -
Move
-
- - -
-
- - - - - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/queueGraph.jsp b/edexOsgi/build.edex/esb/webapps/admin/queueGraph.jsp deleted file mode 100644 index 3e26c1de49..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/queueGraph.jsp +++ /dev/null @@ -1,68 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> - - -Queues - - - - - - - - - - - - - -
- -<%--- -Other values we can graph... - -${row.consumerCount} -${row.enqueueCount} -${row.dequeueCount} ---%> - - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/queues.jsp b/edexOsgi/build.edex/esb/webapps/admin/queues.jsp deleted file mode 100644 index 0e6d1f74ae..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/queues.jsp +++ /dev/null @@ -1,78 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> - - -Queues - - - -
-
- - - - - - -
-
- - -

Queues

- - - - - - - - - - - - - - - - - - - - - - - - - - -
NameNumber Of Pending MessagesNumber Of ConsumersMessages SentMessages ReceivedViewsOperations
${row.queueSize}${row.consumerCount}${row.enqueueCount}${row.dequeueCount} - Browse -<%-- - Graph ---%> - - - - Send To - Purge - Delete -
- - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/send.jsp b/edexOsgi/build.edex/esb/webapps/admin/send.jsp deleted file mode 100644 index ddcfcbe34c..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/send.jsp +++ /dev/null @@ -1,144 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> - - -Send Messages - - - -

Send a JMS Message

- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Message Header
- - - - - - - -
- - - - - - - -
- - - - - - - -
- - - - - - - -
- - - - - - - -
- - - - - - - -
- - -
- -
- -
- -
- - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/styles/site.css b/edexOsgi/build.edex/esb/webapps/admin/styles/site.css deleted file mode 100644 index 13cfc545fd..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/styles/site.css +++ /dev/null @@ -1,206 +0,0 @@ -/** - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -body { - padding: 20px; -} - -/* ====================================================== */ -/* Rounded Box Styles */ -/* ====================================================== */ -div.white_box div.header {background: transparent url("../images/white-header-top.png") repeat-x 0pt;} -div.white_box div.header_l {background: transparent url("../images/white-header-left.png") no-repeat 0pt;} -div.white_box div.header_r {background: transparent url("../images/white-header-right.png") no-repeat 100% 0pt;} -div.white_box div.header_r {height: 18px;} - -div.white_box div.content {background: #ffffff; } -div.white_box div.content_l {background: transparent url("../images/content-left.png") repeat-y 0pt;} -div.white_box div.content_r {background: transparent url("../images/content-right.png") repeat-y 100% 0pt;} -div.white_box div.content_r {padding-left: 6px; padding-right: 9px;} - -div.white_box div.footer {background: transparent url("../images/white-footer-bottom.png") repeat-x 0pt;} -div.white_box div.footer_l {background: transparent url("../images/white-footer-left.png") no-repeat 0pt;} -div.white_box div.footer_r {background: transparent url("../images/white-footer-right.png") no-repeat 100% 0pt;} -div.white_box div.footer_r {color: #ffffff; height:37px; padding:0px;} -div.white_box div.footer_r {padding-left: 6px;padding-right: 9px;} - -div.black_box div.footer {background: transparent url("../images/black-footer-bottom.png") repeat-x 0pt;} -div.black_box div.footer_l {background: transparent url("../images/black-footer-left.png") no-repeat 0pt;} -div.black_box div.footer_r {background: transparent url("../images/black-footer-right.png") no-repeat right bottom;} -div.black_box div.footer_r {color: #ffffff; height:37; padding:0px;} -div.black_box div.footer_r {padding-left: 6px;padding-right: 9px;} - -/* ====================================================== */ -/* Logo Positioning */ -/* ====================================================== */ -div#activemq_logo{background: transparent url("../images/activemq-logo.png") no-repeat left top; height: 100px; } -div#activemq_logo{margin-left: 20px; overflow: hidden;} -div#asf_logo {background: transparent url("../images/asf-logo.png") no-repeat right center; height: 100px; } - -/* ====================================================== */ -/* Top and Bottom Bar Styling */ -/* ====================================================== */ -div.top_red_bar { - background: transparent url("../images/top-red-bar.png") repeat 0pt; - overflow: hidden; -} -div.bottom_red_bar { - background: transparent url("../images/bottom-red-bar.png") repeat 0pt; height: 11px; - overflow: hidden; -} - -div#site-breadcrumbs { - margin: 0px; - padding: 0px; - float:left; - padding: 2px; - padding-left: 20px; -} -div#site-quicklinks { - margin: 0px; - padding: 2px; - padding-right: 20px; -} -div#site-quicklinks p { - text-align: right; - padding: 0px; - margin: 0px; -} - -div#site-quicklinks, div#site-breadcrumbs, div#site-quicklinks p, div#site-breadcrumbs p, -div#site-quicklinks a:link, div#site-quicklinks a:visited, -div#site-breadcrumbs a:link, div#site-breadcrumbs a:visited { - font-family: Verdana, arial, sans-serif; - font-size: 11px; - font-weight: bold; - line-height: 16px; - color: #ffffff; - text-decoration: none; -} -div#site-quicklinks a:active, div#site-quicklinks a:hover, -div#site-breadcrumbs a:active, div#site-breadcrumbs a:hover { - font-family: Verdana, arial, sans-serif; - font-size: 11px; - font-weight: bold; - line-height: 13px; - color: #c0c0c0; - text-decoration: underline; -} -div#site-quicklinks sup img { - height: 0px; - width: 0px; -} - -/* ====================================================== */ -/* Navigation Styling */ -/* ====================================================== */ -div.navigation {background: #ffffff url("../images/right-box-left.png") repeat-y left 0pt; width:200px;} -div.navigation_top {background: transparent url("../images/right-box-top.png") no-repeat left top;} -div.navigation_bottom {background: transparent url("../images/right-box-bottom.png") no-repeat left bottom;} -div.navigation_bottom {padding-left: 5px;padding-right:11px; padding-top:17px; padding-bottom:17px;} - -/* div.navigation {float:right;} */ -div.navigation_bottom ol, -div.navigation_bottom ul, -div.navigation_bottom { - font-family: Verdana, arial, sans-serif; - font-size: 11px; - font-weight: bold; - line-height: 13px; - text-align: left; - padding-left: 11px; -} - -div.navigation { - text-align: left; - clear: left; -} - - -div.navigation h3, -div.navigation h3 a:link, div.navigation h3 a:visited, div.navigation h3 a:active, div.navigation h3 a:hover { - font-family: Verdana, arial, sans-serif; - font-size: 11px; - font-weight: bold; - line-height: 120%; - - border: none; - font-size: 15px; - text-decoration: none; - color: #660033; - margin:5px; -} - -div.navigation h3 { - background: url("../images/big-bullet.png") no-repeat 0pt; - background-position:left center; - margin-left:15px; - padding-left: 20px; -} - -div.navigation a:link, div.navigation a:visited, div.navigation a:active, div.navigation a:hover { - text-decoration: none; - color: #000000; -} -div.navigation a:active, div.navigation a:hover { - text-decoration: underline; - color: #880055; -} - -div.navigation ul { - padding-left: 25px; - list-style: none; - padding-bottom: 10px; - border-bottom:1px solid #CACACA; - margin: 0px; - margin-left: 10px; - margin-bottom: 10px; -} - -div.navigation_bottom div { - margin-left:10px; - padding-left:25px; - padding-bottom: 10px; - margin-bottom: 10px; - border-bottom:1px solid #CACACA; -} - -div.navigation img { - margin-left:15px; - padding-left: 20px; -} - -div.navigation sup img { height: 0px; width: 0px; } - -/* ====================================================== */ -/* Footer Styling */ -/* ====================================================== */ -div.black_box div.footer_r div { - font-family: Verdana, arial, sans-serif; - font-size: 10px; - font-weight: normal; - line-height: normal; - padding:5px; - padding-left:20px; -} - -div.design_attribution, div.design_attribution a { - font-family: Verdana, arial, sans-serif; - font-size: 10px; - text-align:center; - color: #a0a0a0; -} diff --git a/edexOsgi/build.edex/esb/webapps/admin/styles/sorttable.css b/edexOsgi/build.edex/esb/webapps/admin/styles/sorttable.css deleted file mode 100644 index 98cd35a15e..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/styles/sorttable.css +++ /dev/null @@ -1,70 +0,0 @@ -/** - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -table.sortable { - margin: 0px; - padding: 0px; - margin-bottom: 1em; - - margin: 1em auto; -} - -th { - padding: 2px; - padding-left: 10px; - text-align: left; - background-color: #ccc; -} - -tfoot { - /* border-top: 1px solid black; */ -} - -td { - padding: 0.5em; - /* border: 1px solid black; */ - /** border-top: 1px solid black; */ -} - -tr { - background-color: #ffffff; -} - -tr.odd { - background-color: #f3f3f3; -} - -td.numeric, - th.numeric { - text-align: right; -} - -/** forms using table layout */ -td.label { - background-color: #f3f3f3; -} -/* -table.layout { - border-bottom: solid white; - border-right: solid white; -} - -td.layout { - border-top: 1px solid black; - border: solid white; -} -*/ diff --git a/edexOsgi/build.edex/esb/webapps/admin/styles/type-settings.css b/edexOsgi/build.edex/esb/webapps/admin/styles/type-settings.css deleted file mode 100644 index 8cb79415bc..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/styles/type-settings.css +++ /dev/null @@ -1,171 +0,0 @@ -/** - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -body, p, ul, ol { - font-family: verdana,arial,helvetica,sans-serif; - font-size: 14px; - font-size-adjust: none; - font-style: normal; - font-font-variant: normal; - font-weight: normal; - line-height: 140%; - color: #000000; -} - -div.body-content { - padding-left: 25px; -} - -td, table, tr { - font-family: verdana,arial,helvetica,sans-serif; - font-size: 10px; - font-size-adjust: none; - font-style: normal; - font-font-variant: normal; - font-weight: normal; - line-height: normal; - color: #000000; -} - -a:link, a:visited, a:active, a:hover { - color: #880055; - text-decoration: none; -} - -a:active, a:hover { - text-decoration: underline; - color: #202020; -} - -ul, ol { - margin-left: 15px; - margin-top: 5px; - margin-bottom: 5px; - padding: 0px; - font-size: 12px; -} - -ul li { - list-style-image: url("../images/small-bullet-red.png"); -} -ul li ul li{ - list-style-image: url("../images/small-bullet-gray.png"); -} - -pre { - padding: 0px; - margin-top: 5px; - margin-left: 15px; - margin-bottom: 5px; - margin-right: 5px; - text-align: left; -} - -hr { - color: #3c78b5; - height: 1; -} - -input { - font-family: verdana, geneva, arial, sans-serif; - font-size: 11px; - color: #000000; -} - -textarea { - font-family: verdana, geneva, arial, sans-serif; - font-size: 11px; - color: #333333; -} - -h1, h2, h3, h4, h5, h6 { - font-family: Georgia,'Times New Roman',serif; - line-height: normal; - font-weight: bold; -} - -h1 { - border-bottom: 1px solid #808080; - padding: 2px; - margin: 36px 0px 4px -25px; - font-size: 20px; -} -h1 a:link, h1 a:visited, h1 a:active { - text-decoration: none; -} - -h1 a:hover { - border-bottom: 1px dotted #660033; -} - -h2 { - border-bottom: 1px solid #a0a0a0; - padding: 2px; - margin: 27px 0px 4px -20px; - font-size: 18px; -} - -h3 { - border-bottom: 1px solid #c0c0c0; - padding: 2px; - margin: 21px 0px 4px -15px; - font-size: 16px; -} - -h4 { - border-bottom: 1px solid #c0c0c0; - padding: 2px; - margin: 18px 0px 4px -10px; - font-size: 15px; -} - -h5 { - padding: 2px; - margin: 14px 0px 4px -5px; - font-size: 14px; -} - -h6 { - padding: 2px; - margin: 14px 0px 4px -5px; - font-size: 13px; -} - -blockquote { - padding-left: 10px; - padding-right: 10px; - margin-left: 5px; - margin-right: 0px; - border-left: 1px solid #3c78b5; -} - -.tooltip { position: relative; - text-decoration: none; -} - -.tooltip span { - display: none; -} - -.tooltip:hover span { - position: absolute; - top: 10px; - left: 25px; - display: block; - background: #ccc; - color: #880055; - border: 1px solid #880055; -} \ No newline at end of file diff --git a/edexOsgi/build.edex/esb/webapps/admin/subscribers.jsp b/edexOsgi/build.edex/esb/webapps/admin/subscribers.jsp deleted file mode 100644 index 0dd16097c9..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/subscribers.jsp +++ /dev/null @@ -1,115 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> - - -Durable Topic Subscribers - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - -
Create Durable Topic Subscribers
- - - - - - - -
- - - - - - - -
- -
-
- - -

Durable Topic Subscribers

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Client IDSubscription NameConnection IDDestinationSelectorPending Queue SizeDispatched Queue SizeDispatched CounterEnqueue CounterDequeue CounterOperations
${row.selector}${row.pendingQueueSize}${row.dispatchedQueueSize}${row.dispachedCounter}${row.enqueueCounter}${row.dequeueCounter} - Delete -
- - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/test/dummy.jsp b/edexOsgi/build.edex/esb/webapps/admin/test/dummy.jsp deleted file mode 100644 index cdb062be19..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/test/dummy.jsp +++ /dev/null @@ -1,52 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> - - -Test Pages - - - -

Test Pages

- -These pages are used to test out the environment and web framework. - - - - - - - - - - - - - - - - - - - - - -
Values
Broker type${requestContext.brokerQuery.broker.class}
Managed broker${requestContext.brokerQuery.brokerAdmin.broker.class}
Destinations${requestContext.brokerQuery.managedBroker.queueRegion.destinationMap}
- - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/test/index.jsp b/edexOsgi/build.edex/esb/webapps/admin/test/index.jsp deleted file mode 100644 index 65719d442c..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/test/index.jsp +++ /dev/null @@ -1,84 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> - - -Test Pages - - - -

Test Pages

- -These pages are used to test out the environment and web framework. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Headers
request.contextPath${request.contextPath}
request.requestURI${request.requestURI}
request.remoteAddr${request.remoteAddr}
request.remoteHost${request.remoteHost}
request.queryString${request.queryString}
request.scheme${request.scheme}
request.serverName${request.serverName}
request.serverPort${request.serverPort}
Spring applicationContext${applicationContext}
Spring requestContext${requestContext}
System properties<%= System.getProperties() %>
- - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/test/systemProperties.jsp b/edexOsgi/build.edex/esb/webapps/admin/test/systemProperties.jsp deleted file mode 100644 index a4b2bc6002..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/test/systemProperties.jsp +++ /dev/null @@ -1,53 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> - - -Test Pages - - - -

Test Pages

- -These pages are used to test out the environment and web framework. - - - - - - - - - - -<% - for (java.util.Iterator iter = System.getProperties().entrySet().iterator(); iter.hasNext(); ) { - request.setAttribute("entry", iter.next()); -%> - - - - -<% -} -%> - -
System PropertyValue
${entry.key}${entry.value}
- - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/topics.jsp b/edexOsgi/build.edex/esb/webapps/admin/topics.jsp deleted file mode 100644 index fc9c3c3943..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/topics.jsp +++ /dev/null @@ -1,65 +0,0 @@ -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> - - -Topics - - - -
-
- - - - - - -
-
- -

Topics

- - - - - - - - - - - - - - - - - - - - - - -
NameNumber Of ConsumersMessages SentMessages ReceivedOperations
${row.consumerCount}${row.enqueueCount}${row.dequeueCount} - Send To - Delete -
- - - - - diff --git a/edexOsgi/build.edex/esb/webapps/admin/xml/queues.jsp b/edexOsgi/build.edex/esb/webapps/admin/xml/queues.jsp deleted file mode 100644 index 6a09e227fc..0000000000 --- a/edexOsgi/build.edex/esb/webapps/admin/xml/queues.jsp +++ /dev/null @@ -1,34 +0,0 @@ -<%@ page contentType="text/xml;charset=ISO-8859-1"%> -<%-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. ---%> - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.edex.common/res/NGATS_binding.xsd b/edexOsgi/com.raytheon.edex.common/res/NGATS_binding.xsd deleted file mode 100644 index f07964e419..0000000000 --- a/edexOsgi/com.raytheon.edex.common/res/NGATS_binding.xsd +++ /dev/null @@ -1,232 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.productsrv/res/spring/uengine-request.xml b/edexOsgi/com.raytheon.edex.productsrv/res/spring/uengine-request.xml index 3d145edeea..b28f6e7c5e 100644 --- a/edexOsgi/com.raytheon.edex.productsrv/res/spring/uengine-request.xml +++ b/edexOsgi/com.raytheon.edex.productsrv/res/spring/uengine-request.xml @@ -10,56 +10,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/scripts/ObAndTaf.js b/edexOsgi/com.raytheon.edex.uengine/scripts/ObAndTaf.js deleted file mode 100644 index 2941a1bc41..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/scripts/ObAndTaf.js +++ /dev/null @@ -1,53 +0,0 @@ -include("ObsRequest.js"); -include("TafRequest.js"); - -var oQuery = new ObsRequest(); -var tQuery = new TafRequest(); - -function ObAndTaf(count,icaos) { - var icao = "KOFF"; - oQuery.setCount(count); - oQuery.setSortValue("timeobs"); - oQuery.addParameter("reporttype","METAR"); - if (icaos != null) { - oQuery.addList("stationid",icaos); - } else { - oQuery.addParameter("stationid",icao); - } - tQuery.setCount(count); - if (icaos != null) { - tQuery.addList("stationid",icaos); - } else { - tQuery.addParameter("stationid",icao); - } - tQuery.setSortValue("issue_time"); - return combineResponses(oQuery.execute(),tQuery.execute()); -} -function combineResponses(respA,respB) { - var retVal = new Array(); - var ptr = 0; - if (respA != null && respA.length > 0) { - for (i = 0; i < respA.length; i++) { - retVal[ptr] = respA[i]; - ptr++; - } - } else { - retVal[ptr] = respA; - ptr++; - } - if (respB != null && respB.length > 0) { - for (i = 0; i < respB.length; i++) { - retVal[ptr] = respB[i]; - ptr++; - } - } else { - retVal[ptr] = respB; - ptr++ - } - return retVal; -} -function makeError(message,query) { - var response = new MakeResponseNull(message,query); - return response.execute(); -} -ObAndTaf(3,"KSDF,KGAG,KIAH,KLBE,KLUK"); \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/scripts/SpatialQueryDemo.js b/edexOsgi/com.raytheon.edex.uengine/scripts/SpatialQueryDemo.js deleted file mode 100644 index d3e00167ca..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/scripts/SpatialQueryDemo.js +++ /dev/null @@ -1,106 +0,0 @@ -/* the class constructor */ -function SpatialDataQuery(plugin) { - /* named constants */ - this.icao = "icao"; - this.stationid = "stationid"; - /* the query objects */ - this.asciiResponse = false; - this.plugin = (plugin!=null)?plugin:"obs"; - this.spatial = new SpatialQuery(); - this.query = new TermQuery(this.plugin); -} - -/* the execute function */ -function _execute() { - var response = this.spatial.execute(); - if (response.size() == 0 || response.get(this.icao).size() == 0) { - return this.makeNullResponse(null); - } - var icaos = this.listToString(response.get(this.icao),","); - this.query.addParameter(this.stationid,icaos,"in"); - this.query.setCount(0); - var result = this.query.execute(); - if (result.size() == 0) { - return this.makeNullResponse(this.query); - } else if (this.asciiResponse) { - return this.makeAsciiResponse(result); - } else { - return this.makeXmlResponse(result); - } -} - -/* converts a List to a string */ -function _listToString(list,sep){ - var string = new Array(); - for (i=0;i 0) { - for (i = 0; i < respA.length; i++) { - retVal[ptr] = respA[i]; - ptr++; - } - } - if (respB != null && respB.length > 0) { - for (i = 0; i < respB.length; i++) { - retVal[ptr] = respB[i]; - ptr++; - } - } - return retVal; -} - -ASCIIandImage(); \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/scripts/makeBarnesAnalysisWinds.js b/edexOsgi/com.raytheon.edex.uengine/scripts/makeBarnesAnalysisWinds.js deleted file mode 100644 index f90190b150..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/scripts/makeBarnesAnalysisWinds.js +++ /dev/null @@ -1,386 +0,0 @@ -/* define a class to find winds and generate wind speed grid */ -function GribWinds(plugin,speed) { - this.plugin = plugin; - this.speed = speed; - this.params = new Object(); - this.count = 1; - this.sortby = "basetime"; - this.query = new TermQuery(this.plugin); - this.geom = null; - this.crs = null; - this.dataURI = null; -} -function _executeGWS() { - var response; - /* get the U wind grib */ - var query = new TermQuery(this.plugin); - for (name in this.params) { - query.addParameter(name,this.params[name]); - } - query.addParameter("paramid","U%wind","like"); - query.setCount(this.count); - query.setSortBy(this.sortby); - var uResult = query.execute(); - if (uResult.size() == 0) { - return this.makeError("Query for Wind-U returned 0 results.",this.query); - } - /* get the V wind grib */ - var query = new TermQuery(this.plugin); - for (name in this.params) { - query.addParameter(name,this.params[name]); - } - query.addParameter("paramid","V%wind","like"); - query.setCount(this.count); - query.setSortBy(this.sortby); - var vResult = query.execute(); - if (vResult.size() == 0) { - return this.makeError("Query for Wind-V returned 0 results.",this.query); - } - /* read the data from the data store */ - this.geom = uResult.get(0).getGrid().getGridGeom(); - this.crs = uResult.get(0).getGrid().getCrs(); - this.dataURI = uResult.get(0).getDataURI(); - var uFile = new FileIn(this.plugin,uResult.get(0)); - var vFile = new FileIn(this.plugin,vResult.get(0)); - var uData = uFile.execute(); - var vData = vFile.execute(); - /* combine the data into wind speed data */ - var windSpeed = new ConvertWindsData(uData,vData,this.speed); - return windSpeed.execute(); - - -} -/* GWS accessors */ -function _setGWSSortValue(sortValue) { - this.sortby = sortValue; -} -function _setGWSCount(count) { - this.count = count; -} -function _addGWSParameter(name,value) { - this.params[name] = value; -} -function _getGWSGeom() { - return this.geom; -} -function _getGWSCRS () { - return this.crs; -} -function _getGWSDataURI() { - return this.dataURI; -} - -/* mapping functions to the GWS object */ -GribWinds.prototype.execute = _executeGWS; -GribWinds.prototype.addParameter = _addGWSParameter; -GribWinds.prototype.getGeom = _getGWSGeom; -GribWinds.prototype.getCRS = _getGWSCRS; -GribWinds.prototype.getDataURI = _getGWSDataURI; -GribWinds.prototype.setCount = _setGWSCount; -GribWinds.prototype.setSortby = _setGWSSortValue; -GribWinds.prototype.makeError = _makeError; - -/* define a query to get the temperature data */ -function ObsSpatialQuery(plugin,obParam) { - this.icao = "icao"; - this.geometry = "geometry"; - this.plugin = plugin; - this.obParam = obParam; - this.oQuery = new TermQuery(this.plugin); - this.sQuery = new SpatialQuery(); -} -function _executeOSQ() { - /* get the spatial results */ - var sResult = this.sQuery.execute(); - if(sResult == null || sResult.size() == 0) { - return this.makeError("Spatial query returned no results.",this.spatial); - } - /* get and geolocate the wind speed observations */ - this.addList("stationid",MEUtils.changeArrayListToString(sResult.get(this.icao))); - var oResult = this.oQuery.execute(); - if(oResult == null || oResult.size() == 0) { - return this.makeError("Ob query returned no results.",oQuery); - } - var oMap = new MapAsciiData(this.obParam, - oResult, - sResult.get(this.icao), - sResult.get(this.geometry)); - - return oMap.execute(); -} -/* OSQ accessors */ -function _setOSQSortValue(sortValue) { - this.oQuery.setSortBy(sortValue); -} -function _setOSQCount(count) { - this.oQuery.setCount(count); -} -function _addOSQParameter(name,value) { - this.oQuery.addParameter(name,value); -} -function _addOSQList(name,value) { - this.oQuery.addParameter(name,value,"in"); -} -/* setter for the spatial bounds */ -function _setOSQSpatialBounds(ulLat, ulLon, lrLat, lrLon, icao, geom) { - this.icao = icao; - this.geometry = geom; - this.sQuery.setUpperLeftLat(ulLat); - this.sQuery.setUpperLeftLon(ulLon); - this.sQuery.setLowerRightLat(lrLat); - this.sQuery.setLowerRightLon(lrLon); - /* preload fields of the query */ - this.sQuery.addField(this.icao); - this.sQuery.addField(this.geometry); -} - -/* mapping functions to the OSQ object */ -ObsSpatialQuery.prototype.execute = _executeOSQ; -ObsSpatialQuery.prototype.addParameter = _addOSQParameter; -ObsSpatialQuery.prototype.setCount = _setOSQCount; -ObsSpatialQuery.prototype.setSortby = _setOSQSortValue; -ObsSpatialQuery.prototype.makeError = _makeError; -ObsSpatialQuery.prototype.setSpatialBounds = _setOSQSpatialBounds; -ObsSpatialQuery.prototype.addList = _addOSQList; - -/* define a class to generate a image from a GRIB */ -function GribImage(plugin) { - /* names of things */ - this.plugin = plugin; - /* grid attributes */ - this.grid = null; - this.geom = null; - this.crs = null; - /* image attributes */ - this.colormap = "GribRGB"; - this.format = "png"; - this.scaleFactor = 3; - this.reproject = false; -} -function _executeGI() { - var gribMap = new GribMap(this.grib, this.colormap, this.grid, this.geom); - gribMap.setScaleFactor(this.scaleFactor); - var imageData = gribMap.execute(); - this.geom = gribMap.getGridGeometry(); - var colorMap = new ColorMapImage(this.colormap, imageData, this.geom); - var imageOut = null; - if(this.reproject){ - var reproject = new ReprojectImage(colorMap.execute(), this.geom, this.crs); - var reprojectedImage = reproject.execute(); - imageOut = new ImageOut(reprojectedImage, this.format, reproject.getGridGeometry()); - } - else - { - imageOut = new ImageOut(colorMap.execute(), this.format,this.geom); - } - return imageOut.execute(); -} -/* setters */ -function _setGIGrid(grid) { - this.grid = grid; -} -function _setGIGeom(geom) { - this.geom = geom; -} -function _setGICrs(crs) { - this.crs = crs; -} -function _setGIColormap(colormap) { - this.colormap = colormap; -} -function _setGIFormat(format) { - this.format = format; -} -function _setGIScaleFactor(scale) { - this.scaleFactor = scale; -} -function _setGIReproject(reproject) { - this.reproject = reproject; -} -/* getters */ -function _getGIGeom() { - return this.geom; -} -function _getGIFormat() { - return this.format; -} - -/* map the functions to the class prototype */ -GribImage.prototype.execute = _executeGI; -GribImage.prototype.setGrid = _setGIGrid; -GribImage.prototype.setGeom = _setGIGeom; -GribImage.prototype.getGeom = _getGIGeom; -GribImage.prototype.setCrs = _setGICrs; -GribImage.prototype.setColormap = _setGIColormap; -GribImage.prototype.setFormat = _setGIFormat; -GribImage.prototype.getFormat = _getGIFormat; -GribImage.prototype.setScaleFactor = _setGIScaleFactor; -GribImage.prototype.setReproject = _setGIReproject; - -/* Define the class to perform the analysis */ -function BarnesAnalysisWinds() { - /* names of things */ - this.grib = "grib"; - this.obs = "obs"; - this.icao = "icao"; - this.geometry = "geometry"; - this.obParam = "windSpeed"; - /* settings for Barnes Analysis */ - this.radius = "50000.0"; - this.weight = "0.50"; - this.stations = "1"; - this.passes = "1"; - /* query objects */ - this.gQuery = new GribWinds(this.grib,true); - this.oQuery = new ObsSpatialQuery(this.obs,this.obParam); - /* the image creator */ - this.iMaker = new GribImage(this.grib); - /* the logger */ - this.logger = new SystemLog(); -} - -function _execute() { - var response; - /* get the wind speed as a grib */ - var wResult = this.gQuery.execute(); - if (wResult.getClass().getSimpleName() != "FloatDataRecord") { - this.logger.log("warn","GRIB Winds creation failed."); - return wResult; - } - this.logger.log("info","GRIB Winds creation successful."); - var geom = this.gQuery.getGeom(); - var crs = this.gQuery.getCRS(); - - /* get and geolocate the wind speed observations */ - var oResult = this.oQuery.execute(); - - if(oResult.getClass().getSimpleName() != "ArrayList") { - this.logger.log("warn","Spatial ob query for " + this.obParam + " failed."); - return oResult; - } - this.logger.log("info","Spatial ob query for " + this.obParam + " successful."); - - /* setup the analyzer and perform the analysis */ - var analyzer = new ObjectiveAnalysis(wResult, - geom, - crs, - oResult); - analyzer.addParameter("searchRadius",this.radius); - analyzer.addParameter("weight",this.weight); - analyzer.addParameter("minNoStns",this.stations); - analyzer.addParameter("numPasses",this.passes); - analyzer.addParameter("extrapolate","true"); - var analyzed = analyzer.execute(); - - /* create the derived image */ - this.iMaker.setGrid(analyzed); - this.iMaker.setCrs(crs); - this.iMaker.setGeom(geom); - var imageOut = this.iMaker.execute(); - geom = this.iMaker.getGeom(); - var format = this.iMaker.getFormat(); - - /* write the image to the file and return the response */ - var fileOut = new FileOut(imageOut, format); - var writeFile = fileOut.execute(); - var makeResponse = new MakeResponseUri(writeFile, - null, - this.gQuery.getDataURI(), - this.format); - return makeResponse.execute(); -} - -/* helper methods */ -function _makeError(message,query) { - var response = new MakeResponseNull(message,query); - return response.execute(); -} - -/* setters for query objects */ -function _addParameter(grid,name,value) { - var query = (grid)?this.gQuery:this.oQuery; - query.addParameter(name,value); -} -function _addList(grid,name,value) { - var query = (grid)?this.gQuery:this.oQuery; - query.addParameter(name,value,"in"); -} -function _setSortValue(grid,sortValue) { - var query = (grid)?this.gQuery:this.oQuery; - query.setSortby(sortValue); -} -function _setCount(grid,count) { - var query = (grid)?this.gQuery:this.oQuery; - query.setCount(count); -} -/* setters for image creation parameters */ -function _setScaleFactor(scale) { - this.iMaker.setScaleFactor(scale); -} - -function _reprojectImage(reproject) { - this.iMaker.setReproject(reproject); -} - -function _setColorMap(colormap){ - this.iMaker.setColormap(colormap); -} - -function _setFormat(format){ - this.iMaker.setFormat(format); -} - -/* setters for the spatial query */ -function _setSpatialBounds(ulLat, ulLon, lrLat, lrLon) { - this.oQuery.setSpatialBounds(ulLat, - ulLon, - lrLat, - lrLon, - this.icao, - this.geometry); -} - -/* setters for Barnes Analysis */ -function _setBarnesParameters(radius,weight,stations,passes) { - this.radius = radius; - this.weight = weight; - this.stations = stations; - this.passes = passes; -} - -/* mapping functions to the object */ -BarnesAnalysisWinds.prototype.execute = _execute; -BarnesAnalysisWinds.prototype.addParameter = _addParameter; -BarnesAnalysisWinds.prototype.addList = _addList; -BarnesAnalysisWinds.prototype.setSortValue = _setSortValue; -BarnesAnalysisWinds.prototype.setCount = _setCount; -BarnesAnalysisWinds.prototype.setScaleFactor = _setScaleFactor; -BarnesAnalysisWinds.prototype.reprojectImage = _reprojectImage; -BarnesAnalysisWinds.prototype.setColorMap = _setColorMap; -BarnesAnalysisWinds.prototype.setFormat = _setFormat; -BarnesAnalysisWinds.prototype.setSpatialBounds = _setSpatialBounds; -BarnesAnalysisWinds.prototype.setBarnesParameters = _setBarnesParameters; -BarnesAnalysisWinds.prototype.makeError = _makeError; - -var runner = new BarnesAnalysisWinds(); -/* setup the basic grib queries */ -runner.addParameter(true,"levelinfo","10.0_m"); -runner.addParameter(true,"forecasttime","0"); -runner.addParameter(true,"gridid",212); -runner.setSortValue(true,"basetime"); -runner.setCount(true,1); -/* setup the basic obs query */ -runner.addParameter(false,"refhour","20070601190000"); -runner.setSortValue(false,"timeobs"); -runner.setCount(false,0); -/* setup the spatial search parameters */ -runner.setSpatialBounds(43.00, -98.00, 37.00, -92.00); -/* setup the Barnes analysis paramters */ -runner.setBarnesParameters("50000.0","0.50","1","1"); -/* set image properties */ -runner.setColorMap("GribRGB"); -runner.setFormat("png"); -runner.setScaleFactor(3.0); -/* execute the script */ -runner.execute(); - diff --git a/edexOsgi/com.raytheon.edex.uengine/scripts/makeBarnesTemperatureAnalysis.js b/edexOsgi/com.raytheon.edex.uengine/scripts/makeBarnesTemperatureAnalysis.js deleted file mode 100644 index c95fcca6ad..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/scripts/makeBarnesTemperatureAnalysis.js +++ /dev/null @@ -1,184 +0,0 @@ -/* constructor */ -function BarnesTemperatureAnalysis() { - /* names of constants */ - this.grib = "grib"; - this.icao = "icao"; - this.geometry = "geometry"; - /* settings for Barnes Analysis */ - this.radius = 50000.0; - this.weight = 0.50; - this.stations = 1; - this.passes = 1; - /* settings for image creation */ - this.reproject = false; - this.colormap = "StopLight"; - this.format = "png"; - this.scaleFactor = 3.0; - /* the queries */ - this.gridquery = new TermQuery(this.grib); - this.obsquery = new TermQuery("obs"); - this.spatial = new SpatialQuery(); -} - -/* the execute function */ -function _execute() { - var response; - /* get the grib record */ - var gridResults = this.gridquery.execute(); - if(gridResults == null || gridResults.size() == 0) - { - response = new MakeResponseNull("Query for GRIB returned no results.",this.gridquery); - return response.execute(); - } - var grid = gridResults.get(0); - /* get the spatial information */ - this.spatial.addField(this.icao); - this.spatial.addField(this.geometry); - var spatialResults = this.spatial.execute(); - if (spatialResults == null || spatialResults.size() == 0) { - response = new MakeResponseNull("Spatial query returned no results.",this.spatial); - return response.execute(); - } - /* get the and geolocate the temperature observations */ - this.addList(false,"stationid",MEUtils.changeArrayListToString(spatialResults.get(this.icao))); - var obsResults = this.obsquery.execute(); - if (obsResults == null || obsResults.size() == 0) { - response = new MakeResponseNull("Ob query returned no results.",this.obsquery); - return response.execute(); - } - var mapObs = new MapAsciiData("temperature", - obsResults, - spatialResults.get(this.icao), - spatialResults.get(this.geometry)); - /* get the GRIB record and perform the analysis */ - var fileIn = new FileIn(this.grib, grid); - var geom = grid.getGrid().getGridGeom(); - var crs = grid.getGrid().getCrs(); - var gribRecord = fileIn.execute(); - var analyzer = new ObjectiveAnalysis(gribRecord, - geom, - crs, - mapObs.execute()); - analyzer.addParameter("searchRadius","50000.0"); - analyzer.addParameter("weight","0.50"); - analyzer.addParameter("minNoStns","1"); - analyzer.addParameter("extrapolate","true"); - analyzer.addParameter("numPasses","1"); - var analyzed = analyzer.execute(); - - /* create the derived image */ - var gribMap = new GribMap(this.grib, this.colormap, analyzed, geom); - gribMap.setScaleFactor(this.scaleFactor); - var imageData = gribMap.execute(); - geom = gribMap.getGridGeometry(); - var colorMap = new ColorMapImage(this.colormap, imageData, geom); - var imageOut = null; - if(this.reproject){ - var reproject = new ReprojectImage(colorMap.execute(), geom, crs); - var reprojectedImage = reproject.execute(); - imageOut = new ImageOut(reprojectedImage, this.format, reproject.getGridGeometry()); - } - else - { - imageOut = new ImageOut(colorMap.execute(), this.format,geom); - } - var fileOut = new FileOut(imageOut.execute(), this.format); - var writeFile = fileOut.execute(); - var makeResponse = new MakeResponseUri(writeFile, - null, - grid.getDataURI(), - this.format); - return makeResponse.execute(); - -} -/* query related setter functions */ -function _addParameter(grib, name, value) { - var query = (grib)?this.gridquery:this.obsquery; - query.addParameter(name, value); -} - -function _addList(grib, name, value) { - var query = (grib)?this.gridquery:this.obsquery; - query.addParameter(name, value, "in"); -} - -function _setCount(grib, count){ - var query = (grib)?this.gridquery:this.obsquery; - query.setCount(count); -} - -function _setSortValue(grib, sortValue){ - var query = (grib)?this.gridquery:this.obsquery; - query.setSortBy(sortValue); -} - -/* image related setter functions */ -function _setScaleFactor(scale){ - this.scaleFactor = scale; -} - -function _reprojectImage(reproject){ - this.reproject = reproject; -} - -function _setColormap(colormap){ - this.colormap = colormap; -} - -function _setFormat(format){ - this.format = format; -} - -/* setters for the spatial query */ -function _setSpatialBounds(ulLat, ulLon, lrLat, lrLon) { - this.spatial.setUpperLeftLat(ulLat); - this.spatial.setUpperLeftLon(ulLon); - this.spatial.setLowerRightLat(lrLat); - this.spatial.setLowerRightLon(lrLon); -} - -/* setters for Barnes Analysis */ -function _setBarnesParameters(radius,weight,stations,passes) { - this.radius = radius; - this.weight = weight; - this.stations = stations; - this.passes = passes; -} - -/* mapping functions to the object */ -BarnesTemperatureAnalysis.prototype.execute = _execute; -BarnesTemperatureAnalysis.prototype.addParameter = _addParameter; -BarnesTemperatureAnalysis.prototype.addList = _addList; -BarnesTemperatureAnalysis.prototype.setSpatialBounds = _setSpatialBounds; -BarnesTemperatureAnalysis.prototype.setScaleFactor = _setScaleFactor; -BarnesTemperatureAnalysis.prototype.setCount = _setCount; -BarnesTemperatureAnalysis.prototype.reprojectImage = _reprojectImage; -BarnesTemperatureAnalysis.prototype.setColorMap = _setColormap; -BarnesTemperatureAnalysis.prototype.setFormat = _setFormat; -BarnesTemperatureAnalysis.prototype.setSortValue = _setSortValue; -BarnesTemperatureAnalysis.prototype.setBarnesParameters = _setBarnesParameters; - -/* the compact action script */ -var barnes = new BarnesTemperatureAnalysis(); -/* set the grib search parameters */ -barnes.addParameter(true,"paramid","Temperature"); -barnes.addParameter(true,"levelinfo","2.0_m"); -barnes.addParameter(true,"forecasttime","0"); -barnes.addParameter(true,"gridid",212); -barnes.setCount(true,1); -barnes.setSortValue(true,"basetime"); -/* set the lat/lon bounds*/ -barnes.setSpatialBounds(43.00, -98.00, 37.00, -92.00); -/* set the metar search parameters */ -barnes.addParameter(false,"refhour","20070601190000"); -barnes.setCount(false,0); -barnes.setSortValue(false,"timeobs"); -/* set analysis parameters */ -barnes.setBarnesParameters(50000.0,0.50,1,1); -/* set image properties */ -barnes.setColorMap("GribTempRGB"); -barnes.setFormat("png"); -barnes.setScaleFactor(3.0); -/* execute the query */ -barnes.execute(); - diff --git a/edexOsgi/com.raytheon.edex.uengine/scripts/makeFilteredImage.js b/edexOsgi/com.raytheon.edex.uengine/scripts/makeFilteredImage.js deleted file mode 100644 index 1e39f2cecc..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/scripts/makeFilteredImage.js +++ /dev/null @@ -1,133 +0,0 @@ -function FilteredImage() { - this.format = "png"; - this.colormap = "BW"; - this.reproject = false; - this.plugin = "satellite"; - this.low = 0; - this.high = 255; - this.remap = false; - this.subscribe = false; - this.subscription = null; - this.queryResults = null; - this.createImage = false; - this.sortValue = ""; - this.query = new TermQuery(this.plugin, subscriptionDataFieldId, subscriptionDataQueryId); -} - -function _addParameter(name, value){ - this.query.addParameter(name, value); -} - -function _addList(name, value){ - this.query.addParameter(name, value, "in"); -} - -function _setCount(count){ - this.query.setCount(count); -} - -function _enableSubscription(){ - this.subscribe = true; -} - -function _reprojectImage(reproject){ - this.reproject = reproject; -} - -function _setColormap(colormap){ - this.colormap = colormap; -} - -function _setFormat(format){ - this.format = format; -} - -function _setSortValue(sortValue){ - this.query.setSortBy(sortValue); -} - -function _requestImage(image){ - this.createImage = image; -} -function _execute() -{ - if(this.subscribe){ - this.subscription = new Subscription(); - this.subscription.setup(this.query); - } - - var queryResults = this.query.execute(); - if(queryResults == null || queryResults.size() == 0) - { - response = new MakeResponseNull("Query returned 0 results.",this.query); - return response.execute(); - } - else - { - return this.makeImageResponse(queryResults); - } -} - -function _makeImageResponse(queryResults){ - var response = new Array(); - for(i=0; i < queryResults.size(); i++) - { - var currentQuery = queryResults.get(i); - var geom = currentQuery.getCoverage().getMapGeom(); - var crs = currentQuery.getCoverage().getCrs(); - var fileIn = new FileIn(this.plugin, currentQuery); - var record = fileIn.execute(); - var colorMap = null;; - if (this.remap) { - colorMap = new ColorMapImage(this.colormap, MEUtils.byteHighLowFilterImage(record.getDataObject(),this.low,this.high), geom); - } else { - colorMap = new ColorMapImage(this.colormap, record.getDataObject(), geom); - } - var imageOut = null; - if(this.reproject){ - var reproject = new ReprojectImage(colorMap.execute(), geom, crs); - var reprojectedImage = reproject.execute(); - imageOut = new ImageOut(reprojectedImage, this.format, reproject.getGridGeometry()); - } - else - { - imageOut = new ImageOut(colorMap.execute(), this.format); - } - var fileOut = new FileOut(imageOut.execute(), this.format); - var writeFile = fileOut.execute(); - var makeResponse = new MakeResponseUri(writeFile, null, currentQuery.getDataURI(), this.format); - response[i] = makeResponse.execute(); - } - return response; -} -function _remapImage(low,high) { - this.low = low; - this.high = high; - this.remap = true; -} - -// add the methods to the SatelliteRequest Object. -FilteredImage.prototype.remapImage = _remapImage; -FilteredImage.prototype.execute = _execute; -FilteredImage.prototype.makeImageResponse = _makeImageResponse; -FilteredImage.prototype.addParameter = _addParameter; -FilteredImage.prototype.addList = _addList; -FilteredImage.prototype.setCount = _setCount; -FilteredImage.prototype.enableSubscription = _enableSubscription; -FilteredImage.prototype.reprojectImage = _reprojectImage; -FilteredImage.prototype.setColormap = _setColormap; -FilteredImage.prototype.setFormat = _setFormat; -FilteredImage.prototype.setSortValue = _setSortValue; -FilteredImage.prototype.requestImage = _requestImage; - - -// Code the user writes: -var dataRequest = new FilteredImage(); -dataRequest.addParameter("satellite","GOES"); -dataRequest.addParameter("area_subtype","East CONUS"); -dataRequest.addParameter("parameter","Imager 11 micron IR"); -dataRequest.setCount(1); -dataRequest.setColormap("IREnhanced"); -dataRequest.remapImage(64,192); -dataRequest.setSortValue("valid_time"); -dataRequest.execute(); \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/scripts/makeStopLightImage.js b/edexOsgi/com.raytheon.edex.uengine/scripts/makeStopLightImage.js deleted file mode 100644 index bf5b811407..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/scripts/makeStopLightImage.js +++ /dev/null @@ -1,124 +0,0 @@ -function StopLightMaker(){ - this.plugin = "grib"; - this.subscribe = false; - this.subscription = null; - this.queryResults = null; - this.reproject = false; - this.colormap = "StopLight"; - this.format = "png"; - this.scaleFactor = 3.0; - this.query = new TermQuery(this.plugin, subscriptionDataFieldId, subscriptionDataQueryId); -} - -function _addParameter(name, value){ - this.query.addParameter(name, value); -} - -function _addList(name, value){ - this.query.addParameter(name, value, "in"); -} - -function _setCount(count){ - this.query.setCount(count); -} - -function _setScaleFactor(scale){ - this.scaleFactor = scale; -} - -function _enableSubscription(){ - this.subscribe = true; -} - -function _reprojectImage(reproject){ - this.reproject = reproject; -} - -function _setColormap(colormap){ - this.colormap = colormap; -} - -function _setFormat(format){ - this.format = format; -} - -function _setSortValue(sortValue){ - this.query.setSortBy(sortValue); -} - -function _requestImage(image){ - this.createImage = image; -} - -function _execute() -{ - if(this.subscribe){ - this.subscription = new Subscription(); - this.subscription.setup(this.query); - } - this.queryResults = this.query.execute(); - if(this.queryResults == null || this.queryResults.size() == 0) - { - var response = new MakeResponseNull("Query returned 0 results.",this.query); - return response.execute(); - } - else - { - return this.makeImageResponse(); - } -} - -function _makeImageResponse(){ - var response = new Array(); - for(i=0; i < this.queryResults.size(); i++) - { - var currentQuery = this.queryResults.get(i); - var geom = currentQuery.getGrid().getGridGeom(); - var crs = currentQuery.getGrid().getCrs(); - var fileIn = new FileIn(this.plugin, currentQuery); - var stopLight = new StopLightImage(fileIn.execute()); - var gribMap = new GribMap(this.plugin, this.colormap, stopLight.execute(), geom); - gribMap.setScaleFactor(this.scaleFactor); - var imageData = gribMap.execute(); - geom = gribMap.getGridGeometry(); - var colorMap = new ColorMapImage(this.colormap, imageData, geom); - var imageOut = null; - if(this.reproject){ - var reproject = new ReprojectImage(colorMap.execute(), geom, crs); - var reprojectedImage = reproject.execute(); - imageOut = new ImageOut(reprojectedImage, this.format, reproject.getGridGeometry()); - } - else - { - imageOut = new ImageOut(colorMap.execute(), this.format); - } - var fileOut = new FileOut(imageOut.execute(), this.format); - var writeFile = fileOut.execute(); - var makeResponse = new MakeResponseUri(writeFile, null, currentQuery.getDataURI(), this.format); - response[i] = makeResponse.execute(); - } - return response; -} - -StopLightMaker.prototype.execute = _execute; -StopLightMaker.prototype.makeImageResponse = _makeImageResponse; -StopLightMaker.prototype.addParameter = _addParameter; -StopLightMaker.prototype.addList = _addList; -StopLightMaker.prototype.setCount = _setCount; -StopLightMaker.prototype.setScaleFactor = _setScaleFactor; -StopLightMaker.prototype.enableSubscription = _enableSubscription; -StopLightMaker.prototype.reprojectImage = _reprojectImage; -StopLightMaker.prototype.setColormap = _setColormap; -StopLightMaker.prototype.setFormat = _setFormat; -StopLightMaker.prototype.setSortValue = _setSortValue; -StopLightMaker.prototype.requestImage = _requestImage; - -var dataRequest = new StopLightMaker(); -dataRequest.addParameter("paramid","Temperature"); -dataRequest.addParameter("levelinfo","2.0_m"); -dataRequest.addParameter("forecasttime","0"); -dataRequest.addParameter("gridid",212); -dataRequest.setCount(1); -dataRequest.setColormap("StopLight"); -dataRequest.setSortValue("basetime"); -dataRequest.execute(); \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/scripts/makeWindSpeedImage.js b/edexOsgi/com.raytheon.edex.uengine/scripts/makeWindSpeedImage.js deleted file mode 100644 index c4ac572d9d..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/scripts/makeWindSpeedImage.js +++ /dev/null @@ -1,261 +0,0 @@ -/* define a class to find winds and generate wind speed grid */ -function GribWinds(plugin,speed) { - this.plugin = plugin; - this.speed = speed; - this.params = new Object(); - this.count = 1; - this.sortby = "basetime"; - this.query = new TermQuery(this.plugin); - this.geom = null; - this.crs = null; - this.dataURI = null; -} -function _executeGWS() { - var response; - /* get the U wind grib */ - var query = new TermQuery(this.plugin); - for (name in this.params) { - query.addParameter(name,this.params[name]); - } - query.addParameter("paramid","U%wind","like"); - query.setCount(this.count); - query.setSortBy(this.sortby); - var uResult = query.execute(); - if (uResult.size() == 0) { - return this.makeError("Query for Wind-U returned 0 results.",this.query); - } - /* get the V wind grib */ - var query = new TermQuery(this.plugin); - for (name in this.params) { - query.addParameter(name,this.params[name]); - } - query.addParameter("paramid","V%wind","like"); - query.setCount(this.count); - query.setSortBy(this.sortby); - var vResult = query.execute(); - if (vResult.size() == 0) { - return this.makeError("Query for Wind-V returned 0 results.",this.query); - } - /* read the data from the data store */ - this.geom = uResult.get(0).getGrid().getGridGeom(); - this.crs = uResult.get(0).getGrid().getCrs(); - this.dataURI = uResult.get(0).getDataURI(); - var uFile = new FileIn(this.plugin,uResult.get(0)); - var vFile = new FileIn(this.plugin,vResult.get(0)); - var uData = uFile.execute(); - var vData = vFile.execute(); - /* combine the data into wind speed data */ - var windSpeed = new ConvertWindsData(uData,vData,this.speed); - return windSpeed.execute(); - - -} -/* GWS accessors */ -function _setGWSSortValue(sortValue) { - this.sortby = sortValue; -} -function _setGWSCount(count) { - this.count = count; -} -function _addGWSParameter(name,value) { - this.params[name] = value; -} -function _getGWSGeom() { - return this.geom; -} -function _getGWSCRS () { - return this.crs; -} -function _getGWSDataURI() { - return this.dataURI; -} - -/* mapping functions to the GWS object */ -GribWinds.prototype.execute = _executeGWS; -GribWinds.prototype.addParameter = _addGWSParameter; -GribWinds.prototype.getGeom = _getGWSGeom; -GribWinds.prototype.getCRS = _getGWSCRS; -GribWinds.prototype.getDataURI = _getGWSDataURI; -GribWinds.prototype.setCount = _setGWSCount; -GribWinds.prototype.setSortby = _setGWSSortValue; -GribWinds.prototype.makeError = _makeError; - -/* define a class to generate a image from a GRIB */ -function GribImage(plugin) { - /* names of things */ - this.plugin = plugin; - /* grid attributes */ - this.grid = null; - this.geom = null; - this.crs = null; - /* image attributes */ - this.colormap = "GribRGB"; - this.format = "png"; - this.scaleFactor = 3; - this.reproject = false; -} -function _executeGI() { - var gribMap = new GribMap(this.grib, this.colormap, this.grid, this.geom); - gribMap.setScaleFactor(this.scaleFactor); - var imageData = gribMap.execute(); - this.geom = gribMap.getGridGeometry(); - var colorMap = new ColorMapImage(this.colormap, imageData, this.geom); - var imageOut = null; - if(this.reproject){ - var reproject = new ReprojectImage(colorMap.execute(), this.geom, this.crs); - var reprojectedImage = reproject.execute(); - imageOut = new ImageOut(reprojectedImage, this.format, reproject.getGridGeometry()); - } - else - { - imageOut = new ImageOut(colorMap.execute(), this.format,this.geom); - } - return imageOut.execute(); -} -/* setters */ -function _setGIGrid(grid) { - this.grid = grid; -} -function _setGIGeom(geom) { - this.geom = geom; -} -function _setGICrs(crs) { - this.crs = crs; -} -function _setGIColormap(colormap) { - this.colormap = colormap; -} -function _setGIFormat(format) { - this.format = format; -} -function _setGIScaleFactor(scale) { - this.scaleFactor = scale; -} -function _setGIReproject(reproject) { - this.reproject = reproject; -} -/* getters */ -function _getGIGeom() { - return this.geom; -} -function _getGIFormat() { - return this.format; -} - -/* map the functions to the class prototype */ -GribImage.prototype.execute = _executeGI; -GribImage.prototype.setGrid = _setGIGrid; -GribImage.prototype.setGeom = _setGIGeom; -GribImage.prototype.getGeom = _getGIGeom; -GribImage.prototype.setCrs = _setGICrs; -GribImage.prototype.setColormap = _setGIColormap; -GribImage.prototype.setFormat = _setGIFormat; -GribImage.prototype.getFormat = _getGIFormat; -GribImage.prototype.setScaleFactor = _setGIScaleFactor; -GribImage.prototype.setReproject = _setGIReproject; - -/* Define the class to perform the analysis */ -function WindSpeedImage() { - /* names of things */ - this.grib = "grib"; - this.obs = "obs"; - /* query objects */ - this.gQuery = new GribWinds(this.grib,true); - /* the image creator */ - this.iMaker = new GribImage(this.grib); - /* the logger */ - this.logger = new SystemLog(); -} - -function _execute() { - var response; - /* get the wind speed as a grib */ - var wResult = this.gQuery.execute(); - if (wResult.getClass().getSimpleName() != "FloatDataRecord") { - this.logger.log("warn","GRIB Winds creation failed."); - return wResult; - } - this.logger.log("info","GRIB Winds creation successful."); - var geom = this.gQuery.getGeom(); - var crs = this.gQuery.getCRS(); - - /* create the derived image */ - this.iMaker.setGrid(wResult); - this.iMaker.setCrs(crs); - this.iMaker.setGeom(geom); - var imageOut = this.iMaker.execute(); - geom = this.iMaker.getGeom(); - var format = this.iMaker.getFormat(); - - /* write the image to the file and return the response */ - var fileOut = new FileOut(imageOut, format); - var writeFile = fileOut.execute(); - var makeResponse = new MakeResponseUri(writeFile, - null, - this.gQuery.getDataURI(), - this.format); - return makeResponse.execute(); -} - -/* helper methods */ -function _makeError(message,query) { - var response = new MakeResponseNull(message,query); - return response.execute(); -} - -/* setters for query objects */ -function _addParameter(name,value) { - this.gQuery.addParameter(name,value); -} -function _addList(name,value) { - this.gQuery.addParameter(name,value,"in"); -} -function _setSortValue(sortValue) { - this.gQuery.setSortby(sortValue); -} -function _setCount(count) { - this.gQuery.setCount(count); -} -/* setters for image creation parameters */ -function _setScaleFactor(scale) { - this.iMaker.setScaleFactor(scale); -} - -function _reprojectImage(reproject) { - this.iMaker.setReproject(reproject); -} - -function _setColorMap(colormap){ - this.iMaker.setColormap(colormap); -} - -function _setFormat(format){ - this.iMaker.setFormat(format); -} - -/* mapping functions to the object */ -WindSpeedImage.prototype.execute = _execute; -WindSpeedImage.prototype.addParameter = _addParameter; -WindSpeedImage.prototype.addList = _addList; -WindSpeedImage.prototype.setSortValue = _setSortValue; -WindSpeedImage.prototype.setCount = _setCount; -WindSpeedImage.prototype.setScaleFactor = _setScaleFactor; -WindSpeedImage.prototype.reprojectImage = _reprojectImage; -WindSpeedImage.prototype.setColorMap = _setColorMap; -WindSpeedImage.prototype.setFormat = _setFormat; -WindSpeedImage.prototype.makeError = _makeError; - -var runner = new WindSpeedImage(); -/* setup the basic grib queries */ -runner.addParameter("levelinfo","10.0_m"); -runner.addParameter("forecasttime","0"); -runner.addParameter("gridid",212); -runner.setSortValue("basetime"); -runner.setCount(1); -/* set image properties */ -runner.setColorMap("GribRGB"); -runner.setFormat("png"); -runner.setScaleFactor(3.0); -/* execute the script */ -runner.execute(); - diff --git a/edexOsgi/com.raytheon.edex.uengine/scripts/makeWindStopLight.js b/edexOsgi/com.raytheon.edex.uengine/scripts/makeWindStopLight.js deleted file mode 100644 index c45fe8ccc1..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/scripts/makeWindStopLight.js +++ /dev/null @@ -1,155 +0,0 @@ -// the constructor -function WindStopLight() { - this.plugin = "grib"; - this.format = "png"; - this.colormap = "StopLight"; - this.scaleFactor = 3.0; - this.count = 1; - this.levelInfo = "10.0_m"; - this.fcstHour = "0"; - this.gridId = "212"; - this.reproject = false; - this.sortValue = "basetime"; - this.green = 0.0; - this.yellow = 1.0; - this.red = 2.0; - this.windSpeed = true; -} - -// the main action method -function _execute() { - var uQuery = new TermQuery(this.plugin); - uQuery.addParameter("paramid","U%wind","like"); - uQuery.addParameter("levelinfo",this.levelInfo); - uQuery.addParameter("forecasttime",this.fcstHour); - uQuery.addParameter("gridid",this.gridId); - uQuery.setSortBy(this.sortValue); - uQuery.setCount(this.count); - var uQueryResults = uQuery.execute(); - if(uQueryResults == null || uQueryResults.size() == 0) - { - response = new MakeResponseNull("Query for Wind-U returned 0 results.",uQuery); - return response.execute(); - } - - var vQuery = new TermQuery(this.plugin); - vQuery.addParameter("paramid","V%wind","like"); - vQuery.addParameter("levelinfo",this.levelInfo); - vQuery.addParameter("forecasttime",this.fcstHour); - vQuery.addParameter("gridid",this.gridId); - vQuery.setSortBy(this.sortValue); - vQuery.setCount(this.count); - var vQueryResults = vQuery.execute(); - if(vQueryResults == null || vQueryResults.size() == 0) - { - response = new MakeResponseNull("Query for Wind-V returned 0 results.",uQuery); - return response.execute(); - } - - // read the data from the data store - var geom = uQueryResults.get(0).getGrid().getGridGeom(); - var crs = uQueryResults.get(0).getGrid().getCrs(); - var uFile = new FileIn(this.plugin,uQueryResults.get(0)); - var vFile = new FileIn(this.plugin,vQueryResults.get(0)); - var uData = uFile.execute(); - var vData = vFile.execute(); - - // combine the data into wind speed data - var windSpeed = new ConvertWindsData(uData,vData,this.windSpeed); - // create the stoplight chart - var stopLight = new StopLightImage(windSpeed.execute()); - var gribMap = new GribMap(this.plugin, this.colormap, stopLight.execute(), geom); - gribMap.setScaleFactor(this.scaleFactor); - var imageData = gribMap.execute(); - geom = gribMap.getGridGeometry(); - // create the output image - var colorMap = new ColorMapImage(this.colormap, imageData, geom); - var imageOut = null; - if(this.reproject){ - var reproject = new ReprojectImage(colorMap.execute(), geom, crs); - var reprojectedImage = reproject.execute(); - imageOut = new ImageOut(reprojectedImage, this.format, reproject.getGridGeometry()); - } - else - { - imageOut = new ImageOut(colorMap.execute(), this.format); - } - // write the image to disk and return the response info to the client - var fileOut = new FileOut(imageOut.execute(), this.format); - var writeFile = fileOut.execute(); - var makeResponse = new MakeResponseUri(writeFile, null, null, this.format); - return makeResponse.execute(); -} - -// setter methods -function _setScaleFactor(factor) { - this.scaleFactor = factor; -} -function _setCount(count){ - this.count = count; -} -function _reprojectImage(reproject){ - this.reproject = reproject; -} - -function _setColormap(colormap){ - this.colormap = colormap; -} - -function _setFormat(format){ - this.format = format; -} - -function _setLevelInfo(levelInfo) { - this.levelInfo = levelInfo; -} - -function _setFcstHour(fcstHour) { - this.fcstHour = fcstHour; -} -function _setGridId(gridId) { - this.gridId = gridId; -} - -function _setSortValue(sortValue) { - this.sortValue = sortValue; -} - -function _setWindMode(speed) { - this.windSpeed = speed; -} - -function _setColors(green,yellow,red) { - this.green = green; - this.yellow = yellow; - this.red = red; -} - -// add the methods to the SatelliteRequest Object. -WindStopLight.prototype.execute = _execute; -WindStopLight.prototype.setScaleFactor = _setScaleFactor; -WindStopLight.prototype.setCount = _setCount; -WindStopLight.prototype.reprojectImage = _reprojectImage; -WindStopLight.prototype.setColormap = _setColormap; -WindStopLight.prototype.setFormat = _setFormat; -WindStopLight.prototype.setLevelInfo = _setLevelInfo; -WindStopLight.prototype.setFcstHour = _setFcstHour; -WindStopLight.prototype.setGridId = _setGridId; -WindStopLight.prototype.setSortValue = _setSortValue; -WindStopLight.prototype.setColors = _setColors; -WindStopLight.prototype.setWindMode = _setWindMode; - -// Code the user writes: -var dataRequest = new WindStopLight(); -dataRequest.setLevelInfo("10.0_m"); -dataRequest.setScaleFactor(3.0); -dataRequest.setFcstHour("0"); -dataRequest.setGridId(212); -dataRequest.setCount(1); -dataRequest.setColormap("StopLight"); -dataRequest.setColors(0.0,1.0,2.0); -dataRequest.setSortValue("basetime"); -dataRequest.setFormat("png"); -dataRequest.reprojectImage(false); -dataRequest.setWindMode(true); -dataRequest.execute(); \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/scripts/sampleVtecEventUpdate.js b/edexOsgi/com.raytheon.edex.uengine/scripts/sampleVtecEventUpdate.js deleted file mode 100644 index 7ea380e889..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/scripts/sampleVtecEventUpdate.js +++ /dev/null @@ -1,12 +0,0 @@ -/** - * Performs an update of a single VTN. - * - * Change the values in the "setFields" method - * to control the actual VTN being updated. - */ -include("VtecEventUpdate.js"); -var runner = new VtecUpdater(); -runner.setTimeOut(10); -runner.setClientID("VTEC Update"); -runner.setFields("KOAX","BZ","W",1); -runner.execute(); \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/scripts/sampleVtecObjectRetrieval.js b/edexOsgi/com.raytheon.edex.uengine/scripts/sampleVtecObjectRetrieval.js deleted file mode 100644 index 8ad4c80640..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/scripts/sampleVtecObjectRetrieval.js +++ /dev/null @@ -1,13 +0,0 @@ -/** - * Performs a simple VTEC Request and returns the result to the requestor. - * - * Request the P-VTEC Event Group "Action" tokens. - */ -include("VtecObjectRetrieval.js"); -var runner = new VtecRetrieval("action"); -runner.setTimeOut(10); -runner.initialize("named","VTEC Action"); -runner.addProperty("count","0"); -runner.addField("name","NEW"); -runner.setClientID("VTEC REQUEST"); -runner.execute(); diff --git a/edexOsgi/com.raytheon.edex.uengine/scripts/sampleVtecRetrieval.js b/edexOsgi/com.raytheon.edex.uengine/scripts/sampleVtecRetrieval.js deleted file mode 100644 index 4adb966d6e..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/scripts/sampleVtecRetrieval.js +++ /dev/null @@ -1,12 +0,0 @@ -/** - * Performs a simple VTEC Request and returns the result to the requestor. - * - * Request the P-VTEC Event Group "Action" tokens. - */ -include("VtecRetrieval.js"); -var runner = new VtecRetrieval(); -runner.setTimeOut(10); -runner.initialize("named","action"); -runner.addProperty("count","0"); -runner.setClientID("VTEC REQUEST"); -runner.execute(); diff --git a/edexOsgi/com.raytheon.edex.uengine/scripts/scriptExecute.js b/edexOsgi/com.raytheon.edex.uengine/scripts/scriptExecute.js deleted file mode 100644 index a1d3ef7686..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/scripts/scriptExecute.js +++ /dev/null @@ -1,31 +0,0 @@ -/* class constructor */ -function ExecuteApplication() { - this.timeout = 10; - this.command = ""; -} - -/* main action method */ -function _execute() { - var executer = new ExecuteCommand(this.command,this.timeout); - var result = executer.execute(); - return result; -} - -/* class setters */ -function _setTimeOut(time) { - this.timeout = time * 1000; -} -function _setCommandLine(commandLine) { - this.command = commandLine; -} - -/* add methods to class */ -ExecuteApplication.prototype.execute = _execute; -ExecuteApplication.prototype.setTimeOut = _setTimeOut; -ExecuteApplication.prototype.setCommandLine = _setCommandLine; - -/* short form of the script */ -var runner = new ExecuteApplication(); -runner.setTimeOut(10000); -runner.setCommandLine("D:/bin/TestScript.bat This is a test"); -runner.execute(); \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/scripts/testMessageFormat.js b/edexOsgi/com.raytheon.edex.uengine/scripts/testMessageFormat.js deleted file mode 100644 index c56fc168c5..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/scripts/testMessageFormat.js +++ /dev/null @@ -1,83 +0,0 @@ -function SatelliteRequest(count, sat, image) { - this.satellite = sat; - this.area = "East CONUS"; - this.count = count; - this.makeImage = image; - this.format = "png"; - this.colormap = "IREnhanced"; - this.reproject = false; - this.plugin = "satellite"; -} - -function _execute() -{ - var query = new TermQuery("satellite"); - query.addParameter("satellite", this.satellite); - query.addParameter("area_subtype", this.area); - query.setCount(this.count); - var queryResults = query.execute(); - if(queryResults == null || queryResults.size() == 0) - { - response = new MakeResponseNull("Query returned 0 results.",query); - return response.execute(); - } - else - { - if (!this.makeImage) - { - return this.makeXmlResponse(queryResults); - } else { - return this.makeImageResponse(queryResults); - } - } -} - -function _makeXmlResponse(queryResults) -{ - var count = queryResults.size(); - var response = new Array(count); - for(i=0; i < count; i++) - { - var dataToXml = new DataToXml(queryResults.get(i)); - var makeResponse = new MakeResponseXml(dataToXml.execute()); - response[i] = makeResponse.execute(); - } - - return response; -} - -function _makeImageResponse(queryResults){ - var response = new Array(); - for(i=0; i < queryResults.size(); i++) - { - var currentQuery = queryResults.get(i); - var geom = currentQuery.getCoverage().getMapGeom(); - var crs = currentQuery.getCoverage().getCrs(); - var fileIn = new FileIn(this.plugin, currentQuery); - var record = fileIn.execute(); - var colorMap = new ColorMapImage(this.colormap, record.getDataObject(), geom); - var imageOut = null; - if(this.reproject){ - var reproject = new ReprojectImage(colorMap.execute(), geom, crs); - var reprojectedImage = reproject.execute(); - imageOut = new ImageOut(reprojectedImage, this.format, reproject.getGridGeometry()); - } - else - { - imageOut = new ImageOut(colorMap.execute(), this.format); - } - var fileOut = new FileOut(imageOut.execute(), this.format); - var writeFile = fileOut.execute(); - var makeResponse = new MakeResponseUri(writeFile, null, currentQuery.getDataURI(), this.format); - response[i] = makeResponse.execute(); - } - return response; -} - -SatelliteRequest.prototype.execute = _execute; -SatelliteRequest.prototype.makeXmlResponse = _makeXmlResponse; -SatelliteRequest.prototype.makeImageResponse = _makeImageResponse; - -// Code the user writes: -var dataRequest = new SatelliteRequest(4, "GOES",true); -dataRequest.execute(); \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/Activator.java b/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/Activator.java deleted file mode 100644 index 1f2de5d7b5..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/Activator.java +++ /dev/null @@ -1,41 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ -package com.raytheon.edex.uengine; - - -/** - * Activator for uEngine component - * - *
- * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Oct 8, 2008            njensen     Initial creation
- * 
- * - * @author njensen - * @version 1.0 - */ - -public class Activator { - - public static final String PLUGIN_ID = "com.raytheon.edex.uengine"; - -} diff --git a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/TaskParam.java b/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/TaskParam.java deleted file mode 100644 index b675026c7f..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/TaskParam.java +++ /dev/null @@ -1,84 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ - -package com.raytheon.edex.uengine; - -/** - * Convenience class. This class is a container that simplifies setting - * {@link org.apache.commons.digester.Digester} rules for handling nested - * "property like" tags, which are similar to Apache ANT's {@literal } - * tags. A property tag as foot print {@literal } - * and is used to specify "key/value" pairs into an underlying property structure. - * This class captures a key/value pair into a single object for processing by - * the tag object. That is, a single instance of this class represents a single - * key.value property. - * - *
- *
- * SOFTWARE HISTORY
- *
- * Date       	Ticket#		Engineer	Description
- * ------------	----------	-----------	--------------------------
- * 23Oct2006    TO4         MW Fegan    Initial creation.
- * 
- * 
- * - * @author mfegan - * @version 1 - */ -public class TaskParam { - /* - * the property name (key). - */ - private String name = null; - /** - * the property value. - */ - private Object value = null; - - /** - * Constructor. Creates an empty {@code TaskParam} object. - */ - public TaskParam() {} - /** - * @return the property name - */ - public String getName() { - return name; - } - /** - * @param name the property name to set - */ - public void setName(String name) { - this.name = name; - } - /** - * @return the property value - */ - public Object getValue() { - return value; - } - /** - * @param value the property value to set - */ - public void setValue(Object value) { - this.value = value; - } -} diff --git a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/chain/ChainAttributes.java b/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/chain/ChainAttributes.java deleted file mode 100644 index abf92730f1..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/chain/ChainAttributes.java +++ /dev/null @@ -1,138 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ - -package com.raytheon.edex.uengine.chain; - - -/** - * Defined attribute names for use with ChainDatatype during Task and Action process. - * - * @author pheaberl - */ -public final class ChainAttributes { - - /** - * Final output passed back by the Action, Object. - */ - public static final String CHAIN_OUTPUT = "chainOutput"; - - /** - * Original script used to create μEngine chain. Used with - * script validation to allow the original script to be returned - * with the validation results. - */ - public static final String CHAIN_INPUT = "chainInput"; - /** - * - */ - public static final String VALID_TIME = "valid_time"; - - public static final String ICAO_FILE_PREFIX = "icao_name"; - - public static final String SHAPEFILE_ATTRIBUTES = "shapefile_attributes"; - - /** - * - */ - public static final String DATA_URI = "dataURI"; - /** - * Contains the log of validation results. Used with script validation - * to allow the validation log to be returned with the results. - */ - public static final String VALIDATION_LOG = "validationLog"; - - /** - * File name returned following Lucene search. - */ - public static final String SEARCH_RESULT_KEY = "key"; - - /** - * Contents for a ASCII type retrieval. - */ - public static final String PLAIN_TEXT_ASCII = "plainText"; - /** - * Contains ASCII contents after conversion to XML. - */ - public static final String XML_FORMATTED_ASCII = "xml"; - /** - * Used by Tasks to pass image to be processed, byte[]. - */ - public static final String IMAGE_BYTES = "imageBytes"; - - /** - * Processed image ready for output, BufferedImage. - */ - public static final String IMAGE_BUFFERED = "imageBuffered"; - - /** - * Desired output format for processed image, String. - */ - public static final String IMAGE_FORMAT = "imageFormat"; - - /** - * Location where image was output, java.net.URI. - */ - public static final String IMAGE_OUT_URI = "imageOutURI"; - - /** - * Data read in from GRIB file, float[]. - */ - public static final String GRIB_FLOAT_DATA = "gribFloatData"; - - /** - * WorldFile info passed along, com.raytheon.edex.util.WorldFile. - */ - public static final String WORLD_FILE_OBJ = "worldFileObj"; - - /** - * Product attribute to describe a grib record - */ - public static final String GRIB_PRODUCT_DEFINITION = "grib_product_definition"; - - /** - * The coordinate reference system (projection) - */ - public static final String COORDINATE_REFERENCE_SYSTEM = "coordinate_reference_system"; - - /** - * The grid geometry: contains an envelope of the extent and the dimensions - */ - public static final String GRID_GEOMETRY = "grid_geometry"; - - /** - * The bounding box contains the 4 points for a radar coverage - */ - public static final String BOUNDING_BOX = "bounding_box"; - - /** - * Geometries used to create a shapefile - */ - public static final String GEOMETRIES = "geometries"; - - /** - * Location of the generated shapefiles - */ - public static final String SHAPEFILE_OUT_URI = "shapefileOutURI"; - - /** - * Image color array - */ - public static final String COLORS = "colors"; -} diff --git a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/chain/SpatialChaindataAdapter.java b/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/chain/SpatialChaindataAdapter.java deleted file mode 100644 index ff29b32524..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/chain/SpatialChaindataAdapter.java +++ /dev/null @@ -1,529 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ - -package com.raytheon.edex.uengine.chain; - -import org.geotools.coverage.grid.GeneralGridEnvelope; -import org.geotools.coverage.grid.GridGeometry2D; -import org.geotools.geometry.DirectPosition2D; -import org.geotools.geometry.GeneralEnvelope; -import org.opengis.geometry.DirectPosition; -import org.opengis.referencing.FactoryException; -import org.opengis.referencing.crs.CoordinateReferenceSystem; -import org.opengis.referencing.operation.MathTransform; -import org.opengis.referencing.operation.TransformException; - -import com.raytheon.uf.common.geospatial.CRSCache; -import com.raytheon.uf.common.geospatial.MapUtil; -import com.vividsolutions.jts.geom.Coordinate; -import com.vividsolutions.jts.geom.Geometry; -import com.vividsolutions.jts.io.WKTReader; - -/** - * Adapter class for converting meta-data attributes into geometries. - * - *
- * 
- *   SOFTWARE HISTORY
- *  
- *   Date           Ticket#     Engineer    Description
- *   ------------   ----------  ----------- --------------------------
- *   24Aug2006                  C Hammack   Initial Creation
- *   23Feb2007      TO5         MW Fegan    Modified to support new meta-data storage.
- * 
- * 
- */ -public class SpatialChaindataAdapter { - - private static final double FILL_VALUE = -999.99; - - /** - * Geolocation Attribute for use by WorldFile, etc, String. - */ - public static final String MAP_PROJECTION = "ProjType"; - - /** - * Geolocation Attribute for use by WorldFile, etc, String. - */ - public static final String MAP_FIRST_LAT = "Lat1"; - - /** - * Geolocation Attribute for use by WorldFile, etc, String. - */ - public static final String MAP_FIRST_LON = "Lon1"; - - /** - * Geolocation Attribute for use by WorldFile, etc, String. - */ - public static final String MAP_Y_POINTS = "Ny"; - - /** - * Geolocation Attribute for use by WorldFile, etc, String. - */ - public static final String MAP_X_POINTS = "Nx"; - - /** - * Geolocation Attribute for use by WorldFile, etc, String. - */ - public static final String MAP_X_INCREMENT = "Dx"; - - /** - * Geolocation Attribute for use by WorldFile, etc, String. - */ - public static final String MAP_Y_INCREMENT = "Dy"; - - /** - * Geolocation Attribute for use by WorldFile, etc, String. - */ - public static final String MAP_TANGENT_LAT1 = "Latin1"; - - /** - * Geolocation Attribute for use by WorldFile, etc, String. - */ - public static final String MAP_TANGENT_LAT2 = "Latin2"; - - /** - * Geolocation Attribute for use by WorldFile, etc, String. - */ - public static final String MAP_LAST_LAT = "Lat2"; - - /** - * Geolocation Attribute for use by WorldFile, etc, String. - */ - public static final String MAP_LAST_LON = "Lon2"; - - /** - * Geolocation Attribute for use by WorldFile, etc, String. - */ - public static final String LAT_OF_ORIGIN = "Lad"; - - /** - * Geolocation Attribute for use by WorldFile, etc, String. - */ - public static final String MAJOR_AXIS = "MajorAxis"; - - /** - * Geolocation Attribute for use by WorldFile, etc, String. - */ - public static final String MINOR_AXIS = "MinorAxis"; - - /** - * Lov value - */ - public static final String BASE_LONGITUDE = "Lov"; - - /** - * Scan mode - */ - public static final String SCAN_MODE = "ScanMode"; - - /** - * Radar latitude - */ - public static final String RADAR_RADIAL_LAT = "radial_latitude"; - - /** - * Radar longitude - */ - public static final String RADAR_RADIAL_LON = "radial_longitude"; - - /** - * Station ICAO - */ - public static final String ICAO = "icao"; - - public static final String SPATIAL_INFO = "spatial_info"; - - public static final String GRIB_CRS_WKT = "crswkt"; - - public static final String GRIB_COVERAGE_WKT = "coveragewkt"; - - // private RadarStationDao radarStationDao; - - /** - * A list of all spatial attributes - */ - private static String[] SPATIAL_ATTRIBUTES = { MAP_PROJECTION, - MAP_FIRST_LAT, MAP_FIRST_LON, MAP_Y_POINTS, MAP_X_POINTS, - MAP_X_INCREMENT, MAP_Y_INCREMENT, MAP_TANGENT_LAT1, - MAP_TANGENT_LAT2, MAP_LAST_LAT, MAP_LAST_LON, BASE_LONGITUDE, - LAT_OF_ORIGIN, MAJOR_AXIS, MINOR_AXIS, SCAN_MODE, RADAR_RADIAL_LAT, - RADAR_RADIAL_LON, ICAO, GRIB_CRS_WKT, GRIB_COVERAGE_WKT, - SPATIAL_INFO }; - - public static enum PROJECTION { - LAMBERT_CONFORMAL, MERCATOR, POLAR_STEREOGRAPHIC, LAT_LON - }; - - public static enum POINT_LOCATION { - UPPER_LEFT, UPPER_RIGHT, LOWER_LEFT, LOWER_RIGHT, ENVELOPE - }; - - private PROJECTION projection; - - private double firstLat = FILL_VALUE; - - private double firstLon = FILL_VALUE; - - private double lastLat = FILL_VALUE; - - private double lastLon = FILL_VALUE; - - private double baseLon = FILL_VALUE; - - private double tangentLat1 = FILL_VALUE; - - private double tangentLat2 = FILL_VALUE; - - private double xIncrement = FILL_VALUE; - - private double yIncrement = FILL_VALUE; - - // private double latOfOrigin = FILL_VALUE; - - private double majorAxis = FILL_VALUE; - - private double minorAxis = FILL_VALUE; - - // private double radialLat = FILL_VALUE; - - // private double radialLon = FILL_VALUE; - - private String icao = ICAO; - - private POINT_LOCATION pointLocation = POINT_LOCATION.ENVELOPE; - - private int xPoints = 0; - - private int yPoints = 0; - - private String crswkt = null; - - private String coveragewkt = null; - - private CoordinateReferenceSystem crs; - - /** - * Determine whether an attribute is a spatial attribute - * - * @param attribute - * the attribute to check - * @return true if an attribute is spatial - */ - public static boolean isSpatialAttribute(String attribute) { - for (int i = 0; i < SPATIAL_ATTRIBUTES.length; i++) { - if (SPATIAL_ATTRIBUTES[i].equalsIgnoreCase(attribute)) { - return true; - } - } - return false; - } - - public SpatialChaindataAdapter() { - - } - - /** - * Convenience method. The value of the spatial attribute is passed in as a - * String. The WKT attributes are assigned to the appropriate fields. Other - * attributes values are converted to Double and passed to {@line - * #addSpatialAttribute(String, Number) addSpatialAttribute(String,Number)}. - * - * @param attribute - * the name of the attribute to set - * @param value - * the value for the attribute - */ - public void addSpatialAttribute(String attribute, String value) { - if (attribute.equalsIgnoreCase(GRIB_CRS_WKT)) { - crswkt = value; - } else if (attribute.equalsIgnoreCase(GRIB_COVERAGE_WKT)) { - coveragewkt = value; - setCoverageWkt(); - } else if (attribute.equalsIgnoreCase(ICAO)) { - icao = value; - } else { - Double d = Double.parseDouble(value); - addSpatialAttribute(attribute, d); - } - } - - public void addSpatialAttribute(String attribute, Number value) { - - if (attribute.equalsIgnoreCase(MAP_FIRST_LAT)) { - firstLat = value.doubleValue(); - } else if (attribute.equalsIgnoreCase(MAP_FIRST_LON)) { - firstLon = value.doubleValue(); - } else if (attribute.equalsIgnoreCase(MAP_LAST_LAT)) { - if (value.doubleValue() != 0.0) { - lastLat = value.doubleValue(); - } - } else if (attribute.equalsIgnoreCase(MAP_LAST_LON)) { - if (value.doubleValue() != 0.0) { - lastLon = value.doubleValue(); - } - } else if (attribute.equalsIgnoreCase(MAP_X_INCREMENT)) { - xIncrement = value.doubleValue(); - } else if (attribute.equalsIgnoreCase(MAP_Y_INCREMENT)) { - yIncrement = value.doubleValue(); - } else if (attribute.equalsIgnoreCase(MAP_X_POINTS)) { - xPoints = value.intValue(); - } else if (attribute.equalsIgnoreCase(MAP_Y_POINTS)) { - yPoints = value.intValue(); - } else if (attribute.equalsIgnoreCase(SCAN_MODE)) { - int iValue = value.intValue(); - switch (iValue) { - case 0: - pointLocation = POINT_LOCATION.UPPER_LEFT; - break; - case 64: - pointLocation = POINT_LOCATION.LOWER_LEFT; - break; - case 128: - pointLocation = POINT_LOCATION.UPPER_RIGHT; - break; - case 192: - pointLocation = POINT_LOCATION.LOWER_RIGHT; - break; - } - } else if (attribute.equalsIgnoreCase(MAP_PROJECTION)) { - int iValue = value.intValue(); - - if (30 == iValue || 3 == iValue) { - projection = PROJECTION.LAMBERT_CONFORMAL; - } else if (10 == iValue || 1 == iValue) { - projection = PROJECTION.MERCATOR; - } else if (20 == iValue || 5 == iValue) { - projection = PROJECTION.POLAR_STEREOGRAPHIC; - } else if (0 == iValue) { - projection = PROJECTION.LAT_LON; - } else { - projection = null; - } - - } else if (attribute.equalsIgnoreCase(BASE_LONGITUDE)) { - baseLon = value.doubleValue(); - } else if (attribute.equalsIgnoreCase(MAP_TANGENT_LAT1)) { - tangentLat1 = value.doubleValue(); - } else if (attribute.equalsIgnoreCase(MAP_TANGENT_LAT2)) { - tangentLat2 = value.doubleValue(); - // } else if (attribute.equalsIgnoreCase(LAT_OF_ORIGIN)) { - // latOfOrigin = value.doubleValue(); - } else if (attribute.equalsIgnoreCase(MAJOR_AXIS)) { - majorAxis = value.doubleValue(); - } else if (attribute.equalsIgnoreCase(MINOR_AXIS)) { - minorAxis = value.doubleValue(); - // } else if (attribute.equalsIgnoreCase(RADAR_RADIAL_LAT)) { - // radialLat = value.doubleValue(); - // } else if (attribute.equalsIgnoreCase(RADAR_RADIAL_LON)) { - // radialLon = value.doubleValue(); - } - } - - public CoordinateReferenceSystem getCRS() { - - if (projection == PROJECTION.LAMBERT_CONFORMAL) { - crs = MapUtil.constructLambertConformal(this.majorAxis, - this.minorAxis, this.tangentLat1, this.tangentLat2, - this.baseLon); - return crs; - } else if (projection == PROJECTION.LAT_LON) { - crs = MapUtil.LATLON_PROJECTION; - return crs; - } - - return null; - - } - - public GridGeometry2D getGridGeometry(CoordinateReferenceSystem inputCRS) - throws TransformException, FactoryException { - crs = inputCRS; - return getGridGeometry(); - } - - public GridGeometry2D getGridGeometry() throws TransformException, - FactoryException { - - if (crs == null) { - getCRS(); - } - - if (xPoints > 0 && yPoints > 0) { - MathTransform mt = MapUtil.getTransformFromLatLon(crs); - MathTransform revTransform = MapUtil.getTransformToLatLon(crs); - - // Construct an envelope - double pt1x, pt1y, pt2x, pt2y; - // If we have first and last lat, use them - - // Adjust pt1 by one grid cell - DirectPosition nativeP1 = mt.transform(new DirectPosition2D( - firstLon, firstLat), new DirectPosition2D()); - double nativeP1x = nativeP1.getOrdinate(0); - double nativeP1y = nativeP1.getOrdinate(1); - - // If scanning mode is on right, grid must be shifted in x - if (pointLocation == POINT_LOCATION.UPPER_RIGHT - || pointLocation == POINT_LOCATION.LOWER_RIGHT) { - nativeP1x -= (xIncrement * 1); - } - - // If scanning mode is on bottom, grid must be shifted in y - if (pointLocation == POINT_LOCATION.LOWER_LEFT - || pointLocation == POINT_LOCATION.LOWER_RIGHT) { - nativeP1y -= (yIncrement * 1); - } - - DirectPosition p1Adjusted = revTransform.transform( - new DirectPosition2D(nativeP1x, nativeP1y), - new DirectPosition2D()); - - pt1x = p1Adjusted.getOrdinate(0); - pt1y = p1Adjusted.getOrdinate(1); - - pt2x = lastLon; - pt2y = lastLat; - - if ((pt2x == FILL_VALUE || pt2y == FILL_VALUE) && xPoints > 0 - && yPoints > 0 && xIncrement != FILL_VALUE - && yIncrement != FILL_VALUE) { - // try to derive the second point - double nativeP2x = nativeP1x + (xPoints * xIncrement); - - double nativeP2y = nativeP1y + (yPoints * yIncrement); - - // If scanning mode is in on right, grid must be shifted in y - if (pointLocation == POINT_LOCATION.UPPER_RIGHT - || pointLocation == POINT_LOCATION.UPPER_LEFT) { - nativeP2y -= (yIncrement * 1); - } - - // If scanning mode is on left, grid must be shifted in x - if (pointLocation == POINT_LOCATION.LOWER_LEFT - || pointLocation == POINT_LOCATION.UPPER_LEFT) { - nativeP2x -= (xIncrement * 1); - } - - DirectPosition p2LatLon = revTransform.transform( - new DirectPosition2D(nativeP2x, nativeP2y), - new DirectPosition2D()); - pt2x = p2LatLon.getOrdinate(0); - pt2y = p2LatLon.getOrdinate(1); - - } - - if (pt1x == FILL_VALUE || pt1y == FILL_VALUE || pt2x == FILL_VALUE - || pt2y == FILL_VALUE) { - return null; - } - - GeneralEnvelope env = new GeneralEnvelope(2); - DirectPosition pt1 = mt.transform(new DirectPosition2D(pt1x, pt1y), - new DirectPosition2D()); - DirectPosition pt2 = mt.transform(new DirectPosition2D(pt2x, pt2y), - new DirectPosition2D()); - env.setRange(0, Math.min(pt1.getOrdinate(0), pt2.getOrdinate(0)), - Math.max(pt1.getOrdinate(0), pt2.getOrdinate(0))); - env.setRange(1, Math.min(pt1.getOrdinate(1), pt2.getOrdinate(1)), - Math.max(pt1.getOrdinate(1), pt2.getOrdinate(1))); - env.setCoordinateReferenceSystem(crs); - - return new GridGeometry2D(new GeneralGridEnvelope( - new int[] { 0, 0 }, new int[] { xPoints, yPoints }, false), - env); - - } - return null; - } - - // private boolean withinTol(double v1, double v2) { - // - // long roundedV1 = Math.round(v1 * 100); - // long roundedV2 = Math.round(v2 * 100); - // if (roundedV1 == roundedV2) - // return true; - // - // return false; - // } - - private void setCoverageWkt() { - try { - WKTReader reader = new WKTReader(); - Geometry geometry = reader.read(this.coveragewkt); - Coordinate[] coordinates = geometry.getCoordinates(); - firstLat = coordinates[0].y; - firstLon = coordinates[0].x; - lastLat = coordinates[2].y; - lastLon = coordinates[2].x; - } catch (Exception e) { - e.printStackTrace(); - } - } - - /** - * Returns the CRS as derived from the GRIB meta-data's CRS WKT. - * - * @return the GRIB CRS - */ - public CoordinateReferenceSystem getGribCRS() { - try { - return CRSCache.getInstance().getCoordinateReferenceSystem(crswkt); - } catch (Exception e) { - return null; - } - } - - /** - * Creates the Radar CRS for this adapter. - * - * @return the Radar CRS - returns null if an error occurs. - */ - public CoordinateReferenceSystem getRadarCRS() { - // ArrayList fields = new ArrayList(); - // fields.add("lat"); - // fields.add("lon"); - // - // RadarStation station = null; - // try { - // radarStationDao = (RadarStationDao) DaoPool.getInstance() - // .borrowObject(RadarStationDao.class); - // station = radarStationDao.queryByRdaId(this.icao); - // DaoPool.getInstance().returnObject(radarStationDao); - // - // } catch (Exception e) { - // e.printStackTrace(); - // return null; - // } - // - // if (station != null) { - // - // double lat = station.getLat(); - // double lon = station.getLon(); - // return MapUtil.constructStereographic(MapUtil.AWIPS_EARTH_RADIUS, - // MapUtil.AWIPS_EARTH_RADIUS, lat, lon); - // } else { - // return null; - // } - return null; - - } - -} diff --git a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/chain/package-info.java b/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/chain/package-info.java deleted file mode 100644 index 0f95cb3268..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/chain/package-info.java +++ /dev/null @@ -1,26 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ -/** - * Provides the classes implementing the Chain Data objects for - * the μEngine tasks. - * - * @see "com.raytheon.edex.uengine" - */ -package com.raytheon.edex.uengine.chain; \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/subscription/Subscription.java b/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/subscription/Subscription.java deleted file mode 100644 index ead85a2902..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/subscription/Subscription.java +++ /dev/null @@ -1,106 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ - -package com.raytheon.edex.uengine.subscription; - -import java.io.Serializable; -import com.raytheon.edex.uengine.tasks.query.TermQuery; - -/** - * Basic subscription that contains the script ID, the data URI, and whether - * or not the subscription is active. The data URI is typically a regular expression - * of a data URI so it can be matched to multiple products. - * - * JavaScript scripts need to call the setup method on their subscription for the - * subscription to work correctly. - * - *
- * SOFTWARE HISTORY
- *
- * Date             PR#             Engineer            Description
- * -----------      ----------      ------------        --------------------------
- * Apr 5, 2007                      njensen             Initial Creation
- *
- * 
- * - */ -public class Subscription implements Serializable -{ - private static final long serialVersionUID = 1L; - - private boolean subscriptionActive = false; - - private String dataUri = ""; - - private String scriptId = null; - - /** - * Prepares the subscription based on the query. - * @param aQuery - */ - public void setup(TermQuery aQuery) - { - setup(null, aQuery); - } - - /** - * Prepares the subscription based on the values passed in. - * @param aScriptId - * @param aQuery - */ - public void setup(String aScriptId, TermQuery aQuery) - { - dataUri = aQuery.getMatchURI(); - scriptId = aScriptId; - subscriptionActive = true; - } - - public String getDataUri() - { - return dataUri; - } - - public void setDataUri(String aDataUri) - { - dataUri = aDataUri; - } - - public String getScriptId() - { - return scriptId; - } - - public void setScriptId(String aScriptId) - { - scriptId = aScriptId; - } - - public boolean isSubscriptionActive() - { - return subscriptionActive; - } - - public void setSubscriptionActive(boolean aSubscriptionActive) - { - subscriptionActive = aSubscriptionActive; - } - - -} diff --git a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/tasks/process/ExecuteCommand.java b/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/tasks/process/ExecuteCommand.java deleted file mode 100644 index 8d1cf5925a..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/tasks/process/ExecuteCommand.java +++ /dev/null @@ -1,108 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ - -package com.raytheon.edex.uengine.tasks.process; - -import javax.jms.TextMessage; - -import com.raytheon.edex.msg.Command; -import com.raytheon.edex.uengine.exception.MicroEngineException; -import com.raytheon.edex.uengine.tasks.ScriptTask; -import com.raytheon.edex.uengine.util.MEUtils; -import com.raytheon.uf.common.serialization.SerializationUtil; -import com.raytheon.uf.edex.core.props.EnvProperties; -import com.raytheon.uf.edex.core.props.PropertiesFactory; - -/** - * ExecuteCommand task derived from old uEngine ExecuteCommand task. Executes - * the command line command contained in the body. The command is executed by - * forwarding the command to the {@link com.raytheon.edex.adapterSrv.AdapterSrv - * AdapterSrv} service for processing. - * - *
- * SOFTWARE HISTORY
- * Date             PR#             Engineer            Description
- * -----------      ----------      ------------        --------------------------
- * Apr 12, 2007                     njensen             Initial Creation
- * 02Oct2007        345             MW Fegan            execute() returns ProgramOutput object.
- * 
- * - */ -public class ExecuteCommand extends ScriptTask { - - private String body = ""; - - private long timeOut = 60 * 1000; - - private static EnvProperties environment = PropertiesFactory.getInstance() - .getEnvProperties(); - - public ExecuteCommand(String aBody) { - body = aBody; - } - - public ExecuteCommand(String aBody, long aTimeOut) { - body = aBody; - timeOut = aTimeOut; - } - - /* - * (non-Javadoc) - * - * @see com.raytheon.edex.uengine.js.tasks.ScriptTask#execute() - */ - @Override - public Object execute() { - String responseStr = null; - - try { - - String queue = environment.getEnvValue("ADAPTERSRVQUE"); - - String corrID = java.util.UUID.randomUUID().toString(); - Command cmd = Command.initialize(body); - String command = SerializationUtil.marshalToXml(cmd); - TextMessage prodResponse = (TextMessage) MEUtils.handleTextMessage( - command, queue, queue + "Rsp", timeOut, corrID, - "uEngineWeb", "tcp://localhost:5672"); - responseStr = prodResponse.getText(); - return SerializationUtil.unmarshalFromXml(responseStr); - } catch (Exception e) { - throw new MicroEngineException("unable to execute ", e); - } - } - - public String getBody() { - return body; - } - - public void setBody(String aBody) { - body = aBody; - } - - public long getTimeOut() { - return timeOut; - } - - public void setTimeOut(long aTimeOut) { - timeOut = aTimeOut; - } - -} diff --git a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/RequestTestDriver.java b/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/RequestTestDriver.java deleted file mode 100644 index dc3bbbe464..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/RequestTestDriver.java +++ /dev/null @@ -1,507 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ - -package com.raytheon.edex.uengine.web; - -import java.io.ByteArrayOutputStream; -import java.io.IOException; -import java.io.InputStream; -import java.io.StringReader; -import java.io.StringWriter; -import java.net.URI; -import java.util.HashMap; -import java.util.Set; - -import javax.servlet.ServletException; -import javax.xml.bind.JAXBContext; -import javax.xml.bind.JAXBException; -import javax.xml.bind.Marshaller; -import javax.xml.bind.Unmarshaller; - -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; -import org.apache.http.HttpResponse; -import org.apache.http.client.HttpClient; -import org.apache.http.client.methods.HttpPost; -import org.apache.http.entity.StringEntity; -import org.apache.http.impl.conn.tsccm.ThreadSafeClientConnManager; -import org.apache.http.util.EntityUtils; -import org.w3c.dom.Document; - -import com.raytheon.edex.msg.ResponseMessageURI; -import com.raytheon.edex.util.Util; -import com.raytheon.edex.util.XMLUtils; -import com.raytheon.uf.common.message.Body; -import com.raytheon.uf.common.message.Header; -import com.raytheon.uf.common.message.Message; -import com.raytheon.uf.common.message.response.AbstractResponseMessage; -import com.raytheon.uf.common.message.response.ResponseMessageCatalog; -import com.raytheon.uf.common.message.response.ResponseMessageError; -import com.raytheon.uf.common.message.response.ResponseMessageGeneric; -import com.raytheon.uf.edex.core.EdexException; - -/** - * Interfaces with the ESB to get catalog and data information. - * - *
- * 
- *    SOFTWARE HISTORY
- *   
- *    Date          Ticket#     Engineer    Description
- *    ------------  ----------  ----------- --------------------------
- *    10/30/06                  brockwoo    Initial Creation.
- *    07/26/07                  njensen     Added requestColormaps().
- *    8/20/08                   njensen     Converted to JAXB
- * 
- * 
- * - * @author brockwoo - * @version 1 - */ -public class RequestTestDriver { - - private static final Log theLogger = LogFactory - .getLog(RequestTestDriver.class); - - private static final String ERROR = "ERROR"; - - private static final String REQUEST = "Request"; - - private static final String RESPONSE = "Response"; - - private static final String PARSEERROR = "Service response could not be parsed, no output."; - - private static HttpClient client; - - private HashMap responseStr; - - public RequestTestDriver() { - responseStr = new HashMap(); - } - - public HashMap requestProduct(String actionXML, - long timeout, boolean javascript) { - - if (actionXML != null) { - responseStr.put(REQUEST, actionXML); - // run action, return output - - String response = sendAndReceive(actionXML); - - if (responseStr.containsKey(ERROR)) { - return responseStr; - } - responseStr.put(RESPONSE, response); - } - if (responseStr.get(RESPONSE).indexOf("responseMessageURI") != -1) { - handleServiceResponse(); - } else if (responseStr.get(RESPONSE).indexOf("responseError") != -1) { - responseStr.put("TYPE", "ERROR"); - } else if (responseStr.get(RESPONSE).indexOf("responseMessageGeneric") != -1) { - handleAsciiResponse(); - } - - return responseStr; - } - - public String[] requestCatalog(String parameter, - HashMap filter, long timeout) { - String actionXML = assembleCatalogQuery(parameter, filter); - String response = null; - ResponseMessageCatalog servMsg = null; - if (actionXML != null) { - try { - response = requestHTTP(actionXML); - } catch (EdexException e) { - e.printStackTrace(); - } - } - if (response == null) - return null; - Message msg = null; - try { - JAXBContext jaxbContext = JAXBContext.newInstance(Message.class, - ResponseMessageCatalog.class); - Unmarshaller msh = jaxbContext.createUnmarshaller(); - StringReader reader = new StringReader(response); - msg = (Message) msh.unmarshal(reader); - } catch (Exception e) { - theLogger.error("Error extracting catalog from message: ", e); - } - if (msg == null) { - return null; - } - try { - servMsg = (ResponseMessageCatalog) msg.getBody().getResponses()[0]; - } catch (Throwable e) { - theLogger.error("Error extracting catalog from message: ", e); - } - return servMsg.getValues(); - } - - public String[] requestHibStats() { - StringBuffer actionXML = new StringBuffer(); - actionXML.append("include(\"RetrieveHibStats.js\");\n"); - actionXML.append("var query = new HibernateStats();\n"); - actionXML.append("query.execute();"); - - String response = null; - ResponseMessageCatalog servMsg = null; - if (actionXML != null) { - response = sendAndReceive(actionXML.toString()); - } - try { - response = extractResponseFromMessage(response, "responseCatalog"); - } catch (Exception e) { - theLogger.info("Error extracting catalog from message: " - + e.getMessage()); - } - if (response == null) { - return null; - } - // try { - // IBindingFactory bfact = BindingDirectory - // .getFactory(ResponseMessageCatalog.class); - // IUnmarshallingContext uctx = bfact.createUnmarshallingContext(); - // servMsg = (ResponseMessageCatalog) uctx - // .unmarshalDocument(new StringReader(response)); - // } catch (JiBXException e) { - // e.printStackTrace(); - // } catch (Throwable e) { - // e.printStackTrace(); - // } - return servMsg.getValues(); - - } - - public String[] requestColormaps(long timeout) { - StringBuffer buf = new StringBuffer(); - buf.append("from com.raytheon.edex.uengine.tasks.query import ColormapQuery\n"); - buf.append("colormapQuery = ColormapQuery()\n"); - buf.append("return colormapQuery.execute()\n"); - String response = null; - String action = buf.toString(); - ResponseMessageCatalog servMsg = null; - if (action != null) { - response = sendAndReceive(action); - } - Message msg = null; - try { - JAXBContext jaxbContext = JAXBContext.newInstance(Message.class, - ResponseMessageCatalog.class); - Unmarshaller msh = jaxbContext.createUnmarshaller(); - StringReader reader = new StringReader(response); - msg = (Message) msh.unmarshal(reader); - } catch (Exception e) { - theLogger.info("Error extracting catalog from message: " - + e.getMessage()); - e.printStackTrace(); - } - if (msg == null) { - return null; - } - try { - servMsg = (ResponseMessageCatalog) msg.getBody().getResponses()[0]; - } catch (Throwable e) { - e.printStackTrace(); - } - return servMsg.getValues(); - } - - public boolean purgeDataStore() { - throw new UnsupportedOperationException("Not yet implemented"); - // try { - // Connection connection = jms.createConnection(); - // Session session = jms.createSession(connection); - // MessageProducer producer = jms.createProducer(session); - // ObjectMessage purgeMessage = session - // .createObjectMessage(PurgeSrv.DELETE_ALL_DATA); - // producer.send(purgeMessage); - // } catch (JMSException e) { - // responseStr.put(ERROR, e.getMessage()); - // return false; - // } catch (Exception e) { - // responseStr.put(ERROR, e.getMessage()); - // return false; - // } - - // return true; - } - - public static String requestHTTP(String message) throws EdexException { - if (client == null) - client = new org.apache.http.impl.client.DefaultHttpClient( - new ThreadSafeClientConnManager()); - - try { - HttpPost put = new HttpPost( - "http://localhost:9581/services/pyproductjaxb"); - put.setEntity(new StringEntity(message, "text/xml", "ISO-8859-1")); - - HttpResponse resp = client.execute(put); - int code = resp.getStatusLine().getStatusCode(); - - if (code != 200) { - throw new EdexException( - "Error reading server response. Got error message: " - + EntityUtils.toString(resp.getEntity())); - } - - ByteArrayOutputStream baos = null; - InputStream is = null; - try { - is = resp.getEntity().getContent(); - baos = new ByteArrayOutputStream(); - int read = 0; - do { - byte[] tmp = new byte[1024]; - read = is.read(tmp); - - if (read > 0) - baos.write(tmp, 0, read); - } while (read > 0); - - return new String(baos.toByteArray()); - } finally { - // It seems we do not need to do this with 4.1 closing the - // input stream from the entity ( 'is' at the time of - // writing ) should allow the connection te be released - - // if (put != null) { - // put.releaseConnection(); - // } - - try { - if (resp != null && resp.getEntity() != null) { - EntityUtils.consume(resp.getEntity()); - } - } catch (IOException e) { - // if there was an error reading the input stream, - // notify but continue - theLogger.info( - "Error reading InputStream, assuming closed.", e); - } - - try { - if (baos != null) - baos.close(); - } catch (IOException e1) { - // ignore - } - try { - if (is != null) - is.close(); - } catch (IOException e) { - // ignore - } - } - } catch (Exception e) { - throw new EdexException("Unable to connect to server", e); - } - - } - - private String sendAndReceive(String actionScript) { - try { - return requestHTTP(actionScript); - } catch (Exception e) { - responseStr.put(ERROR, e.getMessage()); - } - - return null; - } - - /** - * Handles a URI product response. - * - * @param response - * the servlet response object - * @param responseStr - * the EDEX response from JMS - * - * @throws ServletException - * if a error occurs extracting information from the EDEX - * response - * @throws IOException - * if an IO error occurs - */ - private void handleServiceResponse() { - responseStr.put("TYPE", "URI"); - String fullResponse = responseStr.get(RESPONSE); - AbstractResponseMessage[] responses = null; - ResponseMessageURI servMsg = null; - try { - responses = this.extractAllResponses(fullResponse, "responseURI"); - } catch (Exception e) { - theLogger.error("Error extracting responses", e); - e.printStackTrace(); - } - - int counter = 0; - for (AbstractResponseMessage response : responses) { - servMsg = (ResponseMessageURI) response; - if (servMsg != null) { - theLogger.info("processing URI response " - + servMsg.getDataURI() + ":" + servMsg.getValidTime() - + ":" + servMsg.getProductURI().length); - URI[] uriArray = servMsg.getProductURI(); - responseStr.put("URI" + counter, - Util.getFileNameFromPath(uriArray[0].getPath())); - responseStr.put("TYPE" + counter, servMsg.getFileType()); - responseStr.put("DATE" + counter, servMsg.getValidTime() - .toString()); - } else { - responseStr.put(ERROR, PARSEERROR); - } - counter++; - } - responseStr.put("URICOUNT", Integer.toString(counter)); - - } - - /** - * Handles a ASCII product response. - * - * @param response - * the servlet response object - * @param responseStr - * the EDEX response from JMS - * - * @throws ServletException - * if a error occurs extracting information from the EDEX - * response - * @throws IOException - * if an IO error occurs - */ - private void handleAsciiResponse() { - responseStr.put("TYPE", "XML"); - String fullResponse = responseStr.get(RESPONSE); - AbstractResponseMessage[] responses = null; - try { - responses = this.extractAllResponses(fullResponse, "contents"); - } catch (Exception e) { - theLogger.error("Error extracting responses", e); - } - - int counter = 0; - JAXBContext jaxbContext; - try { - jaxbContext = JAXBContext.newInstance(Message.class, - ResponseMessageGeneric.class, ResponseMessageError.class); - for (AbstractResponseMessage response : responses) { - Marshaller msh = jaxbContext.createMarshaller(); - StringWriter writer = new StringWriter(); - msh.marshal(response, writer); - String msg = writer.toString(); - responseStr.put("MESSAGE" + counter, msg); - counter++; - } - } catch (JAXBException e) { - theLogger.error("Error separating responses", e); - } - responseStr.put("XMLCOUNT", Integer.toString(counter)); - } - - private String assembleCatalogQuery(String fieldName, - HashMap queryTerms) { - String pluginName = queryTerms.remove("plugin"); - StringBuffer query = new StringBuffer(); - // query.append("include(\"CatalogQuery.js\");\n"); - // query.append("var query = new CatalogQuery(\"" + pluginName + - // "\");\n"); - // query.append("query.setDistinctField(\"" + fieldName + "\");\n"); - // Set names = queryTerms.keySet(); - // for (String name : names) { - // query.append("query.addConstraint(\"" + name + "\",\"" - // + queryTerms.get(name) + "\");\n"); - // } - // query.append("query.execute();"); - query.append("import CatalogQuery\n"); - query.append("query = CatalogQuery.CatalogQuery(\"" + pluginName - + "\")\n"); - query.append("query.setDistinctField(\"" + fieldName + "\")\n"); - Set names = queryTerms.keySet(); - for (String name : names) { - query.append("query.addConstraint(\"" + name + "\",\"" - + queryTerms.get(name) + "\")\n"); - } - query.append("return query.execute()"); - return query.toString(); - } - - /** - * Extracts the response from the body of the message. The message is in - * canonical message format. - * - * @param message - * the canonical message - * @param responseName - * the name of the response to extract - * - * @return the requested response - * - * @throws Exception - * if an error occurs - */ - private String extractResponseFromMessage(String message, - String responseName) { - Document document; - Document responseMsg; - String parsedResponse = null; - try { - document = XMLUtils.scanXMLtoDOM(message); - if (document == null) { - return null; - } - responseMsg = XMLUtils.getSubDocument(document, responseName); - parsedResponse = XMLUtils.transformXMLDocument(responseMsg); - } catch (Exception e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } - return parsedResponse; - } - - /** - * Extracts all response messages from the body of the message. The message - * is in canonical message format. - * - * @param message - * the canonical message - * @param responseName - * the response to extract - * - * @return array of responses as strings - * - * @throws Exception - * if an error occurs. - */ - private AbstractResponseMessage[] extractAllResponses(String message, - String responseName) throws Exception { - JAXBContext jaxbContext = JAXBContext.newInstance(Message.class, - Body.class, Header.class, ResponseMessageCatalog.class, - ResponseMessageURI.class, ResponseMessageGeneric.class, - ResponseMessageError.class); - Unmarshaller msh = jaxbContext.createUnmarshaller(); - StringReader reader = new StringReader(message); - Message msg = (Message) msh.unmarshal(reader); - return msg.getBody().getResponses(); - } -} diff --git a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/RunAction.java b/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/RunAction.java deleted file mode 100644 index 489e759d9e..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/RunAction.java +++ /dev/null @@ -1,1609 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ - -package com.raytheon.edex.uengine.web; - -import java.io.ByteArrayInputStream; -import java.io.File; -import java.io.IOException; -import java.io.OutputStream; -import java.io.PrintWriter; -import java.net.URI; -import java.util.ArrayList; -import java.util.Calendar; -import java.util.List; -import java.util.zip.ZipEntry; -import java.util.zip.ZipInputStream; - -import javax.servlet.ServletException; -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpServletResponse; - -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; -import org.w3c.dom.Document; - -import com.raytheon.edex.msg.ResponseMessageASCII; -import com.raytheon.edex.msg.ResponseMessageInline; -import com.raytheon.edex.msg.ResponseMessageNull; -import com.raytheon.edex.msg.ResponseMessageSubscription; -import com.raytheon.edex.msg.ResponseMessageURI; -import com.raytheon.edex.msg.ResponseMessageValidate; -import com.raytheon.edex.msg.ResponseMessageXML; -import com.raytheon.edex.util.Util; -import com.raytheon.edex.util.XMLUtils; -import com.raytheon.uf.common.message.response.ResponseMessageError; -import com.raytheon.uf.common.util.FileUtil; -import com.raytheon.uf.common.util.StringUtil; -import com.raytheon.uf.edex.core.EdexException; - -/** - * Servlet implementation class for Servlet: RunAction - * - * @web.servlet name="RunAction" display-name="RunAction" description="takes an - * Action script, runs it, and displays the result" - * - * @web.servlet-mapping url-pattern="/runAction.jas" - */ -public class RunAction extends javax.servlet.http.HttpServlet implements - javax.servlet.Servlet { - /** - * - */ - private static final long serialVersionUID = 1L; - - private static final Log theLogger = LogFactory.getLog(RunAction.class); - - /* - * (non-Java-doc) - * - * @see javax.servlet.http.HttpServlet#HttpServlet() - */ - public RunAction() { - super(); - } - - /* - * (non-Java-doc) - * - * @see javax.servlet.http.HttpServlet#doGet(HttpServletRequest request, - * HttpServletResponse response) - */ - @Override - protected void doPost(HttpServletRequest request, - HttpServletResponse response) throws ServletException, IOException { - String requestType = request.getParameter("requesttype"); - String actionXML = request.getParameter("actionXML"); - String receiveTime = request.getParameter("receiveTime"); - long receive = 5000; - boolean jsEngine = false; - theLogger.info("request type is " + StringUtil.printString(requestType)); - if (requestType != null) { - if (requestType.equals("ascii")) { - actionXML = createActionASCII(request); - } else if (requestType.equalsIgnoreCase("image")) { - actionXML = createActionImage(request); - } else if (requestType.equalsIgnoreCase("grid")) { - actionXML = createActionGrib(request); - } else if (requestType.equalsIgnoreCase("radar")) { - actionXML = createActionRadar(request); - } else if (requestType.equalsIgnoreCase("unsubscribe")) { - actionXML = createActionUnsubscribe(request); - } else if (requestType.equalsIgnoreCase("javascript")) { - jsEngine = true; - actionXML = createActionJavaScript(request, actionXML); - } else if (requestType.equalsIgnoreCase("jsunsubscribe")) { - jsEngine = true; - actionXML = createActionJSUnsubscribe(request); - } - } - - if (actionXML != null) { - // run action, return output - String responseStr = ""; - if (receiveTime != null) { - try { - receive = Long.parseLong(receiveTime); - } catch (NumberFormatException nfe) { - theLogger.info("receiveTime(" + receiveTime - + ") not a number, defaulting to " + receive); - } - } - - try { - responseStr = RequestTestDriver.requestHTTP(actionXML); - System.out.println(responseStr); - } catch (EdexException e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } - - if (responseStr.indexOf("") != -1) { - handleAsciiResponse(response, responseStr); - } else if (responseStr.indexOf("") != -1) { - handleNullResponse(response, responseStr); - } else if (responseStr.indexOf("") != -1) { - handleProductResponse(response, responseStr); - } else if (responseStr.indexOf("") != -1) { - handleServiceResponse(response, responseStr); - } else if (responseStr.indexOf("") != -1) { - handleErrorResponse(response, responseStr); - } else if (responseStr.indexOf("") != -1) { - handleValidateResponse(response, responseStr); - } else if (responseStr.indexOf("") != -1) { - handleSubscriptionResponse(response, responseStr); - } else if (responseStr.indexOf("") != -1) { - handleNGATSResponse(response, responseStr); - } else if (responseStr.indexOf("responseXML") != -1) { - handleXMLResponse(response, responseStr); - } else if (responseStr.indexOf("ProgramOutput") != -1) { - handleProgramOutput(response, responseStr); - } else { - htmlOutput(response, "Cannot process response."); - } - } else { - htmlOutput(response, "Action NULL, no output."); - } - } - - private void handleNGATSResponse(HttpServletResponse response, - String responseStr) { - PrintWriter out = null; - try { - out = response.getWriter(); - } catch (IOException e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } - out.println(responseStr); - } - - /** - * Creates an unbscribe action script. The script is wrapped in a canonical - * message. The exact contents of the script is determined by the parameters - * in the request object. - * - * @param request - * the request object - * - * @return the unsubscribe script - */ - private String createActionUnsubscribe(HttpServletRequest request) { - Calendar cal = Calendar.getInstance(); - String now = String.format("%1$tY%1$tm%1$td%1$tH%1$tM%1$tS", cal); - StringBuffer action = new StringBuffer(); - String name = request.getParameter("scriptname"); - if (name == null || name.equals("")) { - name = "Image Request"; - } - String function = request.getParameter("function"); - String type = request.getParameter("datatype"); - String dataURI = ""; - try { - if (type.equalsIgnoreCase("images")) { - dataURI = makeImageDataURI(request); - } else if (type.equalsIgnoreCase("ascii")) { - dataURI = makeAsciiDataURI(request); - } else if (type.equalsIgnoreCase("grid")) { - dataURI = makeGribDataURI(request); - } else if (type.equalsIgnoreCase("radar")) { - dataURI = makeRadarDataURI(request); - } else { - theLogger - .warn("unable to create subscription key for data type " - + type); - dataURI = ""; - } - } catch (Exception e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } - /* - * create the XML message - use brute force to simplify the war - */ - String eol = System.getProperty("line.separator"); - action.append("\n
" + eol); - action.append("" - + eol); - action.append("" + eol); - action.append("" + eol); - action.append("" + eol); - action.append("
" + eol); - action.append("" + eol); - action.append("
" + eol); - - return action.toString(); - } - - private String createActionRadar(HttpServletRequest request) { - StringBuffer action = new StringBuffer(); - Calendar cal = Calendar.getInstance(); - String now = String.format("%1$tY%1$tm%1$td%1$tH%1$tM%1$tS", cal); - String name = request.getParameter("scriptname"); - if (StringUtil.isEmptyString(name)) { - name = ""; - } - String function = request.getParameter("function"); - // String plugin = request.getParameter("plugin"); - String location = request.getParameter("station"); - String productCode = request.getParameter("productcode"); - String elevation = request.getParameter("elevation"); - // String colorMap = request.getParameter("colormap"); - String imageFormat = request.getParameter("imageformat"); - String reproject = request.getParameter("reproject"); - String count = request.getParameter("count"); - if (StringUtil.isEmptyString(count)) { - count = "1"; - } - boolean subscription = function.equalsIgnoreCase("subscribe"); - String eol = System.getProperty("line.separator"); - // create the action script message - action.append("\n
" + eol); - action.append("" + eol); - action.append("" + eol); - action.append("" + eol); - action.append("
" + eol); - action.append("" + eol); - action.append("
" + eol); - - return action.toString(); - } - - /** - * Creates an image retrieval action script. The script is wrapped in a - * canonical message. The exact contents of the script is determined by the - * parameters in the request object. - * - * @param request - * the request object - * - * @return the action script. - */ - private String createActionImage(HttpServletRequest request) { - Calendar cal = Calendar.getInstance(); - String now = String.format("%1$tY%1$tm%1$td%1$tH%1$tM%1$tS", cal); - StringBuffer action = new StringBuffer(); - String name = request.getParameter("scriptname"); - if (StringUtil.isEmptyString(name)) { - name = ""; - } - String function = request.getParameter("function"); - String plugin = request.getParameter("plugin"); - String dataType = request.getParameter("datatype"); - String location = request.getParameter("location"); - String parameter = request.getParameter("parameter"); - String colorMap = request.getParameter("colormap"); - String imageFormat = request.getParameter("imageformat"); - String reproject = request.getParameter("reproject"); - String count = request.getParameter("count"); - - if (StringUtil.isEmptyString(count)) { - count = "1"; - } - boolean subscription = function.equalsIgnoreCase("subscribe"); - String eol = System.getProperty("line.separator"); - // create the action script message - action.append("\n
" + eol); - action.append("" + eol); - action.append("" + eol); - action.append("" + eol); - action.append("
" + eol); - action.append("" + eol); - action.append("
" + eol); - return action.toString(); - } - - /** - * Creates a GRIB product retrieval action script. The script is wrapped in - * a canonical message. The exact contents of the script is determined by - * the parameters in the request object. - * - * @param request - * the request object - * - * @return the action script. - */ - private String createActionGrib(HttpServletRequest request) { - Calendar cal = Calendar.getInstance(); - String now = String.format("%1$tY%1$tm%1$td%1$tH%1$tM%1$tS", cal); - StringBuffer action = new StringBuffer(); - String name = request.getParameter("scriptname"); - if (StringUtil.isEmptyString(name)) { - name = "GRIB Request"; - } - - String function = request.getParameter("function"); - String parameter = request.getParameter("parameter"); - String forecast = request.getParameter("forecast"); - String level1 = request.getParameter("level1"); - String level2 = request.getParameter("level2"); - String units = request.getParameter("unit"); - String colorMap = request.getParameter("colormap"); - String imageFormat = request.getParameter("imageformat"); - String reproject = request.getParameter("reproject"); - String count = request.getParameter("count"); - String scalefactor = request.getParameter("scalefactor"); - - /* create the value for the levelinfo query. */ - StringBuffer levelInfo = new StringBuffer(); - if (!StringUtil.isEmptyString(level2)) { - levelInfo.append(level2); - } - if (!StringUtil.isEmptyString(level1)) { - if (!StringUtil.isEmptyString(level2)) { - levelInfo.append("-"); - } - levelInfo.append(level1); - } - if (!StringUtil.isEmptyString(units)) { - if (levelInfo.length() != 0) { - levelInfo.append("_").append(units); - } - } - - if (StringUtil.isEmptyString(count)) { - count = "1"; - } - // boolean subscription = function.equalsIgnoreCase("subscribe"); - String eol = System.getProperty("line.separator"); - // create the action script message - action.append("\n
" + eol); - action.append("" + eol); - action.append("" + eol); - action.append("" + eol); - action.append("
" + eol); - action.append("" + eol); - action.append("
" + eol); - return action.toString(); - } - - /** - * Creates an ASCII products retrieval action script. The script is wrapped - * in a canonical message. The exact contents of the script is determined by - * the parameters in the request object. - * - * @param request - * the request object - * - * @return the action script. - */ - private String createActionASCII(HttpServletRequest request) { - Calendar cal = Calendar.getInstance(); - String now = String.format("%1$tY%1$tm%1$td%1$tH%1$tM%1$tS", cal); - StringBuffer action = new StringBuffer(); - String name = request.getParameter("name"); - if (name == null) { - name = ""; - } - String function = request.getParameter("function"); - String type = request.getParameter("type"); - - String eol = System.getProperty("line.separator"); - // create the action script message - action.append("\n
" + eol); - action.append("" + eol); - action.append("" + eol); - action.append("" + eol); - action.append("
" + eol); - action.append("" + eol); - action.append("
" + eol); - return action.toString(); - } - - /** - * Creates the JS uEngine script for ob requests. - * - * @param request - * the request object - * @param function - * script function - * @param type - * report type - * - * @return the JS Script - */ - private String createObScript(HttpServletRequest request, String function, - String type) { - StringBuffer script = new StringBuffer(); - String validTime = request.getParameter("time"); - String station = request.getParameter("station"); - String timeType = request.getParameter("refTime"); - String count = request.getParameter("count"); - - if (StringUtil.isEmptyString(count)) { - count = "1"; - } - boolean subscription = function.equalsIgnoreCase("subscribe"); - - script.append("include(\"ObsRequest.js\");"); - script.append("var dataRequest = new ObsRequest();"); - script.append("dataRequest.setCount(" + count + ");"); - script.append("dataRequest.addParameter(\"reporttype\",\"" + type - + "\");"); - if (station != null && (!station.equals(""))) { - script.append("dataRequest.addList(\"stationid\",\"" + station - + "\");"); - } - if (validTime != null && (!validTime.equals(""))) { - try { - if (validTime.length() == 6) { - validTime = String.format("%1$tY%\n
" + eol); - action.append("" + eol); - action.append("" + eol); - action.append("" + eol); - action.append("
" + eol); - action.append("" + eol); - action.append("" + eol); - return action.toString(); - } - - /** - * Creates the canonical message for a JScript unsubscribe. - * - * @param request - * the request object - * - * @return the action message. - */ - private String createActionJSUnsubscribe(HttpServletRequest request) { - Calendar cal = Calendar.getInstance(); - String now = String.format("%1$tY%1$tm%1$td%1$tH%1$tM%1$tS", cal); - StringBuffer action = new StringBuffer(); - String name = request.getParameter("scriptname"); - if (name == null || name.equals("")) { - name = "JScript Test Case"; - } - String function = request.getParameter("function"); - String dataURI = request.getParameter("scripturi"); - String eol = System.getProperty("line.separator"); - action.append("\n
" + eol); - action.append("" - + eol); - action.append("" + eol); - action.append("" + eol); - action.append("" + eol); - action.append("
" + eol); - action.append("" + eol); - action.append("
" + eol); - - return action.toString(); - } - - /** - * Extracts the response from the body of the message. The message is in - * canonical message format. - * - * @param message - * the canonical message - * @param responseName - * the name of the response to extract - * - * @return the requested response - * - * @throws Exception - * if an error occurs - */ - private String extractResponseFromMessage(String message, - String responseName) throws Exception { - Document document = XMLUtils.scanXMLtoDOM(message); - Document responseMsg = XMLUtils.getSubDocument(document, responseName); - - return XMLUtils.transformXMLDocument(responseMsg); - } - - /** - * Extracts all response messages from the body of the message. The message - * is in canonical message format. - * - * @param message - * the canonical message - * @param responseName - * the response to extract - * - * @return array of responses as strings - * - * @throws Exception - * if an error occurs. - */ - private String[] extractAllResponses(String message, String responseName) - throws Exception { - Document document = XMLUtils.scanXMLtoDOM(message); - List responses = XMLUtils.getAllSubDocumentsByTag(document, - responseName); - List xml = new ArrayList(); - for (Document doc : responses) { - xml.add(XMLUtils.transformXMLDocument(doc)); - } - return xml.toArray(new String[0]); - } - - /** - * Extracts a header property from a message. The message is in canonical - * message format. - * - * @param message - * the canonical message - * @param property - * the property - * - * @return the property value - * - * @throws Exception - * in an error occurs - */ - private String extractPropertyFromResponse(String message, String property) - throws Exception { - Document document = XMLUtils.scanXMLtoDOM(message); - return XMLUtils.getPropertyFromXML(document, property); - } - - private void handleProgramOutput(HttpServletResponse response, - String responseStr) throws ServletException, IOException { - String[] responses; - StringBuffer htmlStr = new StringBuffer(); - try { - responses = extractAllResponses(responseStr, "ProgramOutput"); - } catch (Exception e) { - throw new ServletException(e); - } - setContentType(response, "ascii"); - htmlStr.append("\n"); - htmlStr.append("RunAction Response\n"); - htmlStr.append("\n"); - htmlStr.append("
\n"); - htmlStr.append("\n"); - htmlStr.append("\n"); - htmlStr.append("
\n"); - htmlStr.append("

μEngine Response – External Application Execution

\n"); - for (String xmlDoc : responses) { - htmlStr.append("
\n"); - htmlStr.append("
\n")
-                    .append(xmlDoc.replaceAll("<", "<").replaceAll(">",
-                            ">")).append("\n
\n"); - - } - htmlStr.append("
\n"); - htmlStr.append("\n"); - htmlStr.append("\n"); - PrintWriter out = response.getWriter(); - out.println(htmlStr.toString()); - } - - /** - * - * @param response - * @param responseStr - * @throws ServletException - * @throws IOException - */ - private void handleXMLResponse(HttpServletResponse response, - String responseStr) throws ServletException, IOException { - String[] responses; - StringBuffer htmlStr = new StringBuffer(); - try { - responses = extractAllResponses(responseStr, "responseXML"); - } catch (Exception e) { - throw new ServletException(e); - } - setContentType(response, "ascii"); - htmlStr.append("\n"); - htmlStr.append("RunAction Response\n"); - htmlStr.append("\n"); - htmlStr.append("
\n"); - htmlStr.append("\n"); - htmlStr.append("\n"); - htmlStr.append("
\n"); - htmlStr.append("

μEngine Response – XML Product Retrieval

\n"); - for (String xmlDoc : responses) { - ResponseMessageXML servMsg = null; - try { - // IBindingFactory bfact = BindingDirectory - // .getFactory(ResponseMessageXML.class); - // IUnmarshallingContext uctx = - // bfact.createUnmarshallingContext(); - // servMsg = (ResponseMessageXML) uctx - // .unmarshalDocument(new StringReader(xmlDoc)); - } catch (Throwable e) { - throw new ServletException(e); - } - if (servMsg != null) { - // theLogger.info("Processing XML Message (" - // + servMsg.getContents() + ") to output."); - setContentType(response, servMsg.getFileType()); - String time = servMsg.getValidTime().toString(); - htmlStr.append("
\n"); - htmlStr.append("\n"); - htmlStr.append("\n"); - // try { - // htmlStr - // .append("\n"); - // } catch (JAXBException e) { - // // TODO Auto-generated catch block - // e.printStackTrace(); - // } - htmlStr.append("
Time:" + time - + "
Response:" - // + "
"
-                // + SerializationUtil.marshalToXml(
-                // servMsg.getContents()).replaceAll(
-                // "<", "<")
-                // .replaceAll(">", ">")
-                // + "
\n"); - } - } - htmlStr.append("
\n"); - htmlStr.append("\n"); - htmlStr.append("\n"); - PrintWriter out = response.getWriter(); - out.println(htmlStr.toString()); - } - - /** - * Extracts the subscription result from the response string. - * - * @param responseStr - * the response string - * - * @return the subscription message - * - * @throws Exception - * in the event on an error - */ - private String getSubscriptionMsg(String responseStr) throws Exception { - StringBuffer retVal = new StringBuffer(); - String id = null; - String dataURI = null; - String message = null; - String[] subscripts; - ResponseMessageSubscription respMsg = null; - - subscripts = extractAllResponses(responseStr, "responseSubscription"); - id = extractPropertyFromResponse(responseStr, "id"); - dataURI = extractPropertyFromResponse(responseStr, "uri"); - theLogger.info("Processing Subscription Message (" + dataURI + ":" + id - + ") to output."); - for (String response : subscripts) { - // IBindingFactory bfact = BindingDirectory - // .getFactory(ResponseMessageSubscription.class); - // IUnmarshallingContext uctx = bfact.createUnmarshallingContext(); - // respMsg = (ResponseMessageSubscription) uctx - // .unmarshalDocument(new StringReader(response)); - // message = respMsg.getStatusMessage(); - // retVal.append("Data URI:").append(dataURI) - // .append(""); - // retVal.append("Subscription ID:") - // .append(id).append(""); - // retVal.append("Result:").append(message) - // .append(""); - } - return retVal.toString(); - } - - /** - * Handles a subscription response. - * - * @param response - * the servlet response object - * @param responseStr - * the EDEX response from JMS - * - * @throws ServletException - * if a error occurs extracting information from the EDEX - * response - * @throws IOException - * if an IO error occurs - */ - private void handleSubscriptionResponse(HttpServletResponse response, - String responseStr) throws ServletException, IOException { - String message = ""; - try { - message = getSubscriptionMsg(responseStr); - } catch (Exception e) { - throw new ServletException(e); - } - response.setContentType("text/html"); - PrintWriter out = response.getWriter(); - out.println(""); - out.println("RunAction Response"); - out.println(""); - out.println(""); - out.println(""); - out.println("
"); - out.println(""); - out.println("

μEngine Response

"); - out.println("

Product Subscription Result

"); - out.println("
"); - out.println("
"); - out.println("
"); - out.println(""); - out.println(message); - out.println("
"); - out.println(""); - out.println(""); - } - - /** - * Handles the NULL Data Response. - * - * @param response - * the servlet response object - * @param responseStr - * the EDEX response from JMS - * - * @throws ServletException - * if a error occurs extracting information from the EDEX - * response - * @throws IOException - * if an IO error occurs - */ - private void handleNullResponse(HttpServletResponse response, - String responseStr) throws ServletException, IOException { - System.out.println(responseStr); - try { - responseStr = extractResponseFromMessage(responseStr, - "responseNULL"); - } catch (Exception e) { - throw new ServletException(e); - } - ResponseMessageNull servMsg = null; - // try { - // IBindingFactory bfact = BindingDirectory - // .getFactory(ResponseMessageNull.class); - // IUnmarshallingContext uctx = bfact.createUnmarshallingContext(); - // servMsg = (ResponseMessageNull) uctx - // .unmarshalDocument(new StringReader(responseStr)); - // } catch (JiBXException e) { - // e.printStackTrace(); - // throw new ServletException(e); - // } catch (Throwable e) { - // e.printStackTrace(); - // } - if (servMsg != null) { - theLogger.info("Writing error message(" + servMsg.getMessage() - + ") to output."); - - setContentType(response, servMsg.getFileType()); - PrintWriter out = response.getWriter(); - out.println(""); - out.println("RunAction NULL Data"); - out.println(""); - out.println("

No Data Available


"); - try { - String subresp = getSubscriptionMsg(responseStr); - if (!StringUtil.isEmptyString(subresp)) { - out.println("\n"); - out.println("\n"); - out.println(subresp); - out.println("
Subscription results:
\n"); - } - } catch (Exception e) { - - } - out.println("Data URI: " + servMsg.getDataURI() + "

"); - out.println("Time: " + servMsg.getTime() + "

"); - out.println("Message: " + servMsg.getMessage() + "

"); - out.println("


"); - out.println("See system log for more information."); - out.println(""); - - } else { - htmlOutput(response, - "NULL response could not be parsed, no output."); - } - } - - /** - * Handles an ASCII product response. - * - * @param response - * the servlet response object - * @param responseStr - * the EDEX response from JMS - * - * @throws ServletException - * if a error occurs extracting information from the EDEX - * response - * @throws IOException - * if an IO error occurs - */ - private void handleAsciiResponse(HttpServletResponse response, - String responseStr) throws ServletException, IOException { - String[] responses; - StringBuffer htmlStr = new StringBuffer(); - try { - responses = extractAllResponses(responseStr, "responseASCII"); - } catch (Exception e) { - throw new ServletException(e); - } - setContentType(response, "ascii"); - htmlStr.append("\n"); - htmlStr.append("RunAction Response\n"); - htmlStr.append("\n"); - htmlStr.append("
\n"); - htmlStr.append("\n"); - htmlStr.append("\n"); - htmlStr.append("
\n"); - htmlStr.append("

μEngine Response – ASCII Product Retrieval

\n"); - try { - String subresp = getSubscriptionMsg(responseStr); - if (!StringUtil.isEmptyString(subresp)) { - htmlStr.append("\n"); - htmlStr.append("\n"); - htmlStr.append(subresp); - htmlStr.append("
Subscription results:
\n"); - } - } catch (Exception e) { - - } - - for (String xmlDoc : responses) { - ResponseMessageASCII servMsg = null; - // try { - // IBindingFactory bfact = BindingDirectory - // .getFactory(ResponseMessageASCII.class); - // IUnmarshallingContext uctx = bfact.createUnmarshallingContext(); - // servMsg = (ResponseMessageASCII) uctx - // .unmarshalDocument(new StringReader(xmlDoc)); - // } catch (JiBXException e) { - // e.printStackTrace(); - // throw new ServletException(e); - // } catch (Throwable e) { - // e.printStackTrace(); - // } - if (servMsg != null) { - theLogger.info("Processing ASCII message(" - + servMsg.getContents() + ") to output."); - setContentType(response, servMsg.getFileType()); - String month = ""; - String day = ""; - String hour = ""; - String minute = ""; - String station = "N/A"; - if (!servMsg.getStation().equals("") - && !servMsg.getStation().equalsIgnoreCase("null")) { - station = servMsg.getStation(); - } - String time = "N/A"; - String strTime = servMsg.getTime(); - theLogger.debug(strTime); - if (strTime.length() == 6) { - day = strTime.substring(0, 2); - hour = strTime.substring(2, 4); - minute = strTime.substring(4, 6); - time = String.format("%1$s %2$s:%3$s", day, hour, minute); - } else if (strTime.length() == 7) { - month = strTime.substring(0, 2); - day = strTime.substring(2, 4); - hour = strTime.substring(4, 7); - time = String.format("%1$s %2$s:%3$s", month, day, hour); - } else if (strTime.length() == 17) { - month = strTime.substring(6, 8); - day = strTime.substring(8, 10); - hour = strTime.substring(10, 12); - time = String.format("%1$s %2$s:%3$s", month, day, hour); - } else if (strTime.length() == 21) { - day = strTime.substring(8, 10); - hour = strTime.substring(11, 13); - minute = strTime.substring(14, 16); - time = String.format("%1$s %2$s:%3$s", day, hour, minute); - } - htmlStr.append("
\n"); - htmlStr.append("\n"); - htmlStr.append("\n"); - htmlStr.append("\n" - + ""); - htmlStr.append("
Station: " + station - + "\n"); - htmlStr.append("Report Type: " + servMsg.getType() - + "\n"); - htmlStr.append("Report Time: " + time + "
Message:" - + "
"
-                        + servMsg.getContents().replaceAll("<", "<")
-                                .replaceAll(">", ">") + "
\n"); - } - } - htmlStr.append("
\n"); - htmlStr.append("\n"); - htmlStr.append("\n"); - PrintWriter out = response.getWriter(); - out.println(htmlStr.toString()); - } - - /** - * Handles a script validation response. - * - * @param response - * the servlet response object - * @param responseStr - * the EDEX response from JMS - * - * @throws ServletException - * if a error occurs extracting information from the EDEX - * response - * @throws IOException - * if an IO error occurs - */ - private void handleValidateResponse(HttpServletResponse response, - String responseStr) throws ServletException, IOException { - ResponseMessageValidate servMsg = null; - try { - responseStr = extractResponseFromMessage(responseStr, - "responseValidate"); - } catch (Exception e) { - throw new ServletException(e); - } - // try { - // IBindingFactory bfact = BindingDirectory - // .getFactory(ResponseMessageError.class); - // IUnmarshallingContext uctx = bfact.createUnmarshallingContext(); - // servMsg = (ResponseMessageValidate) uctx - // .unmarshalDocument(new StringReader(responseStr)); - // } catch (JiBXException e) { - // e.printStackTrace(); - // throw new ServletException(e); - // } catch (Throwable e) { - // e.printStackTrace(); - // } - if (servMsg != null) { - theLogger.info("Writing validate message(" + servMsg.getMessage() - + ") to output."); - - setContentType(response, servMsg.getFileType()); - PrintWriter out = response.getWriter(); - out.println(""); - out.println("RunAction Validation"); - out.println(""); - out.println("

" + servMsg.getErrorSource() - + " Results


"); - out.println("
Script:"); - out.println(""); - out.println("
"); - out.println("
Result: " + servMsg.getMessage() - + "

"); - if (!servMsg.getResult()) { - out.println("Exception: "); - if (!servMsg.getErrorCause().equals("")) { - out.println(servMsg.getErrorCause().toString()); - } else { - out.println("No exception available"); - } - out.println("

"); - String[] chain = servMsg.getErrorChain(); - out.println("Causes:"); - if (chain != null && chain.length > 0 && !chain[0].equals("")) { - out.println("

    "); - for (String msg : chain) { - out.println("
  1. " + msg); - } - out.println("
"); - } else { - out.println("No additional causes available."); - } - } - out.println("
"); - out.println("See system log for more information."); - - } - - } - - /** - * Hangles the Error Response (ResponseMessageError) from the - * micro engine. - * - * @param response - * response object - * @param responseStr - * message from the micro engine - * - * @throws ServletException - * - for problems unmarshaling message - * @throws IOException - * - for problems geting print writer - */ - private void handleErrorResponse(HttpServletResponse response, - String responseStr) throws ServletException, IOException { - try { - responseStr = extractResponseFromMessage(responseStr, - "responseError"); - } catch (Exception e) { - throw new ServletException(e); - } - ResponseMessageError servMsg = null; - // try { - // IBindingFactory bfact = BindingDirectory - // .getFactory(ResponseMessageError.class); - // IUnmarshallingContext uctx = bfact.createUnmarshallingContext(); - // servMsg = (ResponseMessageError) uctx - // .unmarshalDocument(new StringReader(responseStr)); - // } catch (JiBXException e) { - // e.printStackTrace(); - // throw new ServletException(e); - // } catch (Throwable e) { - // e.printStackTrace(); - // } - if (servMsg != null) { - theLogger.info("Writing error message(" + servMsg.getErrorMsg() - + ") to output."); - - setContentType(response, servMsg.getFileType()); - PrintWriter out = response.getWriter(); - - out.println(""); - out.println("RunAction Error"); - out.println(""); - out.println("

" + servMsg.getErrorSource() - + " 404 Error


"); - out.println("ERROR: " + servMsg.getErrorMsg() + "

"); - out.println("Exception: "); - if (!servMsg.getErrorCause().equals("")) { - out.println(servMsg.getErrorCause().toString()); - } else { - out.println("No exception available"); - } - out.println("

"); - String[] chain = servMsg.getErrorChain(); - out.println("Causes:"); - if (chain != null && chain.length > 0 && !chain[0].equals("")) { - out.println("

    "); - for (String msg : chain) { - out.println("
  1. " + msg); - } - out.println("
"); - } else { - out.println("No additional causes available."); - } - out.println("
"); - out.println("See system log for more information."); - - out.println(""); - - } else { - htmlOutput(response, - "Error response could not be parsed, no output."); - } - - } - - /** - * Handles a URI product response. - * - * @param response - * the servlet response object - * @param responseStr - * the EDEX response from JMS - * - * @throws ServletException - * if a error occurs extracting information from the EDEX - * response - * @throws IOException - * if an IO error occurs - */ - private void handleServiceResponse(HttpServletResponse response, - String responseStr) throws ServletException, IOException { - ResponseMessageURI servMsg = null; - try { - responseStr = extractResponseFromMessage(responseStr, "responseURI"); - } catch (Exception e) { - throw new ServletException(e); - } - - // try { - // IBindingFactory bfact = BindingDirectory - // .getFactory(ResponseMessageURI.class); - // IUnmarshallingContext uctx = bfact.createUnmarshallingContext(); - // servMsg = (ResponseMessageURI) uctx - // .unmarshalDocument(new StringReader(responseStr)); - // } catch (JiBXException e) { - // e.printStackTrace(); - // throw new ServletException(e); - // } catch (Throwable e) { - // e.printStackTrace(); - // } - if (servMsg != null) { - theLogger.info("processing URI response " + servMsg.getDataURI() - + ":" + servMsg.getValidTime()); - String type = servMsg.getFileType(); - URI[] uriArray = servMsg.getProductURI(); - for (int counter = 0; counter < 1; counter++) { - String path = uriArray[counter].getPath(); - - if (type.startsWith("tile-")) { - theLogger.info("Tiled image!"); - type = type.substring(5); // chop off "tile-" - path += "/0/000000." + type; // grab the first tile - } - - setContentType(response, type); - - theLogger.info("Writing image(" + type + ") to output."); - - OutputStream out = response.getOutputStream(); - File imgFile = new File(path); - out.write(FileUtil.file2bytes(imgFile)); - } - } else { - htmlOutput(response, - "Service response could not be parsed, no output."); - } - } - - /** - * Handles a in line product response. - * - * @param response - * the servlet response object - * @param responseStr - * the EDEX response from JMS - * - * @throws ServletException - * if a error occurs extracting information from the EDEX - * response - * @throws IOException - * if an IO error occurs - */ - private void handleProductResponse(HttpServletResponse response, - String responseStr) throws ServletException, IOException { - ResponseMessageInline prodMsg = null; - try { - responseStr = extractResponseFromMessage(responseStr, - "responseInline"); - } catch (Exception e) { - throw new ServletException(e); - } - - // try { - // IBindingFactory bfact = BindingDirectory - // .getFactory(ResponseMessageInline.class); - // IUnmarshallingContext uctx = bfact.createUnmarshallingContext(); - // prodMsg = (ResponseMessageInline) uctx - // .unmarshalDocument(new StringReader(responseStr)); - // } catch (JiBXException e) { - // throw new ServletException(e); - // } - - if ((prodMsg != null) && (prodMsg.getZippedData() != null) - && (prodMsg.getZippedData().size() > 0)) { - theLogger.info("processing inline response " + prodMsg.getDataURI() - + ":" + prodMsg.getValidTime()); - - setContentType(response, prodMsg.getFileType()); - - theLogger.info("Writing image(" + prodMsg.getFileType() - + ") to output."); - - OutputStream out = response.getOutputStream(); - - // Just return the first response in multi-image responses - for (int counter = 0; counter < 1; counter++) { - ZipInputStream zis = new ZipInputStream( - new ByteArrayInputStream(prodMsg.getZippedData().get( - counter))); - ZipEntry entry = zis.getNextEntry(); - while (entry != null) { - if (!entry.getName().endsWith(".wld")) { - byte[] temp = new byte[1024]; - long read = zis.read(temp); - while (read > 0) { - out.write(temp, 0, (int) read); - read = zis.read(temp); - } - break; // only do one - } - entry = zis.getNextEntry(); - } - - } - } else { - htmlOutput(response, - "Product response could not be parsed, no output"); - } - } - - /** - * Sets the content type of the returned message. - * - * @param response - * the servlet response object - * @param fileType - * the file type of the response - */ - private void setContentType(HttpServletResponse response, String fileType) { - if ("png".equalsIgnoreCase(fileType)) { - response.setContentType("image/png"); - } else if (("jpg".equalsIgnoreCase(fileType)) - || ("jpeg".equalsIgnoreCase(fileType))) { - response.setContentType("image/jpeg"); - } else if ("gif".equalsIgnoreCase(fileType)) { - response.setContentType("image/gif"); - } else if (("htm".equalsIgnoreCase(fileType)) - || ("html".equalsIgnoreCase(fileType))) { - response.setContentType("text/html"); - } else if ("ascii".equalsIgnoreCase(fileType)) { - response.setContentType("text/html"); - } else if ("tiff".equalsIgnoreCase(fileType)) { - response.setContentType("image/tiff"); - } - // TODO: add cases for other output types - } - - /** - * Wraps content in HTML. The HTML is returned using the response object's - * print writer. This is intended to return error messages. - * - * @param response - * the servlet response object - * @param msg - * the message to return - * - * @throws IOException - * if an IO error occurs - */ - private void htmlOutput(HttpServletResponse response, String msg) - throws IOException { - theLogger.info(msg); - - response.setContentType("text/html"); - PrintWriter out = response.getWriter(); - - out.println(""); - out.println("RunAction"); - out.println(""); - - out.println(msg); - - out.println(""); - } - - /** - * Determines if a checkbox was checked. - * - * @param checkBox - * the value of the checkbox from the form - * - * @return true if the check box is checked - */ - private boolean isCheckboxOn(String checkBox) { - return (checkBox != null && checkBox.equalsIgnoreCase("on")); - } - - /* - * The next methods create the subscription key based on the information - * available from the request. These only work with the "form based" - * unsubscribe web pages. - */ - /* - * Note: the web client does not have access to the plug-ins, so any change - * to the data URI defined in the Satellite plug-in will require some - * recoding here. - */ - private String makeImageDataURI(HttpServletRequest request) - throws Exception { - StringBuffer dataUri = new StringBuffer(); - String plugin = request.getParameter("plugin"); - String dataType = request.getParameter("datatype"); - String location = request.getParameter("location"); - String parameter = request.getParameter("parameter"); - dataUri.append("/").append(plugin); - dataUri.append("/").append(plugin); - dataUri.append("/").append(dataType); - dataUri.append("/").append(".+?"); - dataUri.append("/").append(location); - dataUri.append("/").append(".+?"); - dataUri.append("/").append(parameter); - dataUri.append("/").append(".+"); - return dataUri.toString().replaceAll(" ", "_") - .replaceAll("\\(", "\\\\(").replaceAll("\\)", "\\\\)"); - } - - /* - * Note: the web client does not have access to the plug-ins, so any change - * to the data URI defined in the METAR plug-in will require some recoding - * here. - */ - private String makeAsciiDataURI(HttpServletRequest request) - throws Exception { - // /.+?/METAR/KABQ/.+ or /.+?/METAR/.+?/.+ - StringBuffer dataUri = new StringBuffer(); - String type = request.getParameter("type"); - String station = request.getParameter("station"); - dataUri.append("/").append( - (type.equalsIgnoreCase("taf") ? "taf" : "obs")); - dataUri.append("/.+?"); - dataUri.append("/").append(type); - if (StringUtil.isEmptyString(station)) { - dataUri.append("/.+?"); - } else { - dataUri.append("/").append(station); - } - dataUri.append("/").append(".+"); - System.out.println(dataUri); - return dataUri.toString().replaceAll(" ", "_") - .replaceAll("\\(", "\\\\(").replaceAll("\\)", "\\\\)"); - - } - - /* - * Note: the web client does not have access to the plug-ins, so any change - * to the data URI defined in the GRIB plug-in will require some recoding - * here. - */ - private String makeGribDataURI(HttpServletRequest request) throws Exception { - // /.+?/.+?/.+?/.+?/.+?/TMP/2/.+?/0 - String parameter = request.getParameter("parameter"); - String level1 = request.getParameter("level1"); - String level2 = request.getParameter("level2"); - String units = request.getParameter("unit"); - String forecast = request.getParameter("forecast"); - if (StringUtil.isEmptyString(forecast)) { - forecast = ".+"; - } - StringBuffer levelInfo = new StringBuffer(); - if (!StringUtil.isEmptyString(level2)) { - levelInfo.append(level2); - } - if (!StringUtil.isEmptyString(level1)) { - if (!StringUtil.isEmptyString(level2)) { - levelInfo.append("-"); - } - levelInfo.append(level1); - } - if (!StringUtil.isEmptyString(units)) { - if (levelInfo.length() != 0) { - levelInfo.append("_").append(units); - } - } - StringBuffer dataUri = new StringBuffer(); - dataUri.append("/grid"); - dataUri.append("/").append(".+?"); - dataUri.append("/").append(".+?"); - dataUri.append("/").append(".+?"); - dataUri.append("/").append(".+?"); - dataUri.append("/").append(".+?"); - dataUri.append("/").append(parameter); - dataUri.append("/").append(".+?"); - dataUri.append("/").append(levelInfo); - dataUri.append("/").append(forecast); - return dataUri.toString().replaceAll(" ", "_") - .replaceAll("\\(", "\\\\(").replaceAll("\\)", "\\\\)"); - } - - /* - * Note: the web client does not have access to the plug-ins, so any change - * to the data URI defined in the Radar plug-in will require some recoding - * here. - */ - private String makeRadarDataURI(HttpServletRequest request) - throws Exception { - String location = request.getParameter("station"); - if (StringUtil.isEmptyString(location)) { - location = ".+?"; - } - String productCode = request.getParameter("productcode"); - if (StringUtil.isEmptyString(productCode)) { - productCode = ".+?"; - } - String elevation = request.getParameter("elevation"); - if (StringUtil.isEmptyString(elevation)) { - elevation = ".+?"; - } - StringBuffer dataUri = new StringBuffer(); - dataUri.append("/radar"); - dataUri.append("/").append(location); - dataUri.append("/").append(productCode); - dataUri.append("/").append(elevation); - dataUri.append("/").append(".+"); - return dataUri.toString().replaceAll(" ", "_") - .replaceAll("\\(", "\\\\(").replaceAll("\\)", "\\\\)"); - } -} diff --git a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/ScriptTestDriver.java b/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/ScriptTestDriver.java deleted file mode 100644 index 2b96eb5312..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/ScriptTestDriver.java +++ /dev/null @@ -1,123 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ - -package com.raytheon.edex.uengine.web; - -import java.io.File; -import java.util.HashMap; -import java.util.Map; - -import com.raytheon.uf.common.dataquery.requests.RequestConstraint; -import com.raytheon.uf.common.velocity.VelocityManager; -import com.raytheon.uf.edex.core.props.EnvProperties; -import com.raytheon.uf.edex.core.props.PropertiesFactory; - -/** - * Creates the scripts on the fly based on input from the web page. - * - *
- * 
- *    SOFTWARE HISTORY
- *   
- *    Date          Ticket#     Engineer    Description
- *    ------------  ----------  ----------- --------------------------
- *    11/25/06                  brockwoo    Initial Creation.
- *    12/07/06      #108        brockwoo    Added reproject to the grid and
- *                                          radar test interfaces
- *    05/10/07      #273        brockwoo    Updated script generation to
- *                                          Javascript
- *    11/27/07      #214        brockwoo    Added colormap capability to radar
- *    Feb 18, 2013  1638        mschenke    Moved ScriptFactory code into common VelocityManager class
- * 
- * 
- * - * @author brockwoo - * @version 1 - */ -public class ScriptTestDriver { - - private static File DEFAULT_TEMPLATE; - - public ScriptTestDriver() { - } - - public String createScript(HashMap terms, - String imageCount, String engine) { - if (DEFAULT_TEMPLATE == null) { - DEFAULT_TEMPLATE = new File( - "../webapps/uEngineWeb/templates/standardTemplate.vm"); - } - - HashMap queryTerms = new HashMap(); - - String pluginName = null; - String library = "BaseRequest"; - - for (String term : terms.keySet()) { - RequestConstraint newRequest = new RequestConstraint(); - newRequest.setConstraintValue(terms.get(term)); - queryTerms.put(term, newRequest); - if ("pluginName".equals(term)) { - pluginName = terms.get(term); - } - } - - String script = null; - - if (pluginName == null) { - script = new String(); - } else { - if ("grid".equals(pluginName)) { - library = "GridRequest"; - } else if ("satellite".equals(pluginName)) { - library = "SatelliteRequest"; - } else if ("radar".equals(pluginName)) { - library = "RadarRequest"; - } else if ("obs".equals(pluginName)) { - library = "ObsRequest"; - } - } - - try { - int maxRecords = Integer.parseInt(imageCount); - - String logDir = ""; - EnvProperties properties = PropertiesFactory.getInstance() - .getEnvProperties(); - if (properties != null) { - logDir = properties.getEnvValue("LOGDIR"); - } - - Map templateObjects = new HashMap(); - templateObjects.put("scriptMetadata", queryTerms); - templateObjects.put("maxRecords", maxRecords); - templateObjects.put("scriptLibrary", library); - templateObjects.put("mode", engine); - - script = VelocityManager.executeTemplate(DEFAULT_TEMPLATE, - DEFAULT_TEMPLATE.getParentFile(), new File(logDir), - templateObjects); - } catch (Exception e) { - System.out.println("Error creating script for " + library); - e.printStackTrace(); - } - return script; - } -} diff --git a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/TestDataDriver.java b/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/TestDataDriver.java deleted file mode 100644 index de0972c3f5..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/com/raytheon/edex/uengine/web/TestDataDriver.java +++ /dev/null @@ -1,161 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ - -package com.raytheon.edex.uengine.web; - -import java.io.File; -import java.io.FileInputStream; -import java.io.FileNotFoundException; -import java.io.FileOutputStream; -import java.io.IOException; -import java.nio.MappedByteBuffer; -import java.nio.channels.FileChannel; -import java.util.Arrays; - -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; - -/** - * Implements a web based interface to copy over test data. - * - *
- *   
- *    SOFTWARE HISTORY
- *   
- *    Date          Ticket#     Engineer    Description
- *    ------------  ----------  ----------- --------------------------
- *    11/08/06                  brockwoo    Initial Creation.
- *    
- * 
- * - * @author brockwoo - * @version 1 - */ -public class TestDataDriver { - - private static Log logger = LogFactory.getLog(TestDataDriver.class); - - private String baseDirectory; - - public TestDataDriver(){ - String os = System.getProperty("os.name"); - if(os.indexOf("Linux") > -1 || os.indexOf("Mac") > -1){ - baseDirectory = "../../opt/data/sbn/"; - } - else if(os.indexOf("Windows") > -1){ - File cFolder = new File("C:/awips"); - File dFolder = new File("D:/awips"); - if(cFolder.exists()){ - baseDirectory = "../../opt/data/sbn/"; - } - else if(dFolder.exists()){ - baseDirectory = "../../opt/data/sbn/"; - } - } - } - - public boolean ingestTestDataFiles(String dataDirectory, String decodeDirectory, String fileName) { - boolean copySucceeded = false; - if(fileName == null){ - return copySucceeded; - } - File sourceFile = new File(baseDirectory + dataDirectory + fileName); - File destFile = new File(baseDirectory + decodeDirectory + fileName); - if(sourceFile.isFile()){ - try { - copyTestFile(sourceFile, destFile); - copySucceeded = true; - } catch (IOException e) { - e.printStackTrace(); - } - } - return copySucceeded; - } - - public String[] listTestDataFiles(String dataDirectory) { - String[] files = null; - File dir = new File(baseDirectory + dataDirectory); - files = dir.list(); - if(files == null){ - files = new String[1]; - files[0] = "No Files Available"; - return files; - } - Arrays.sort(files); - return files; - } - - public String viewTestDataFiles(String dataDirectory, String fileName) { - FileInputStream sourceFileStream = null; - String testFile = ""; - String theFileDirectory = baseDirectory + dataDirectory; - String theFileLocation = theFileDirectory + fileName; - File sourceFile = new File(theFileLocation); - int fileSize = (int)sourceFile.length(); - if(fileSize > 30000){ - testFile = "The test file '" + fileName + "' is greater than 30K and will not be sent."; - return testFile; - } - byte[] sourceFileContents = new byte[fileSize]; - try { - sourceFileStream = new FileInputStream(sourceFile); - sourceFileStream.read(sourceFileContents); - } catch (FileNotFoundException e) { - testFile = "The file '" + fileName + "' was not found in directory '" + theFileDirectory + "'. Please try again."; - return testFile; - } catch (IOException e) { - testFile = "There was an error reading the file. Please check the file located at\n" + theFileLocation; - return testFile; - } - finally{ - if(sourceFileStream != null) - { - try { - sourceFileStream.close(); - } catch (IOException e) { - logger.error("Unable to close file input stream", e); - } - } - } - - - testFile = new String(sourceFileContents); - return testFile; - } - - private static void copyTestFile(File source, File dest) throws IOException { - FileChannel in = null, out = null; - try { - in = new FileInputStream(source).getChannel(); - out = new FileOutputStream(dest).getChannel(); - long size = in.size(); - MappedByteBuffer buf = in.map(FileChannel.MapMode.READ_ONLY, 0, size); - out.write(buf); - } - finally { - if (in != null){ - in.close(); - } - if (out != null){ - out.close(); - } - } - } -} diff --git a/edexOsgi/com.raytheon.edex.uengine/src/test/JmsEngineTest.java b/edexOsgi/com.raytheon.edex.uengine/src/test/JmsEngineTest.java deleted file mode 100644 index 6d2734dba8..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/test/JmsEngineTest.java +++ /dev/null @@ -1,184 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ - -package test; - -import java.io.IOException; - -import javax.jms.Connection; -import javax.jms.DeliveryMode; -import javax.jms.JMSException; -import javax.jms.MessageProducer; -import javax.jms.Session; -import javax.jms.TextMessage; - -/** - * @author fpg - */ -public class JmsEngineTest extends ToolSupport { - - protected int messageCount = 10; - - protected long sleepTime = 0L; - - protected boolean verbose = true; - - protected int messageSize = 255; - - private long timeToLive; - - private String scriptFileName; - - public static void main(String[] args) { - runTest(args, new JmsEngineTest()); - } - - protected static void runTest(String[] args, JmsEngineTest tool) { - tool.clientID = null; - if (args.length > 0) { - tool.url = args[0]; - } - if (args.length > 1) { - tool.topic = args[1].equalsIgnoreCase("true"); - } - if (args.length > 2) { - tool.subject = args[2]; - } - if (args.length > 3) { - tool.durable = args[3].equalsIgnoreCase("true"); - } - if (args.length > 4) { - tool.messageCount = Integer.parseInt(args[4]); - } - if (args.length > 5) { - tool.messageSize = Integer.parseInt(args[5]); - } - if (args.length > 6) { - if (!"null".equals(args[6])) { - tool.clientID = args[6]; - } - } - if (args.length > 7) { - tool.timeToLive = Long.parseLong(args[7]); - } - if (args.length > 8) { - tool.sleepTime = Long.parseLong(args[8]); - } - if (args.length > 9) { - tool.transacted = "true".equals(args[9]); - } - if (args.length > 10) { - tool.scriptFileName = args[10]; - } - tool.run(); - } - - private void run() { - System.out.println("Running JMS message send with script: " - + scriptFileName); - try { - System.out.println("Connecting to URL: " + url); - System.out.println("Publishing a Message with size " + messageSize - + " to " + (topic ? "topic" : "queue") + ": " + subject); - System.out.println("Using " + (durable ? "durable" : "non-durable") - + " publishing"); - System.out.println("Sleeping between publish " + sleepTime + " ms"); - - if (timeToLive != 0) { - System.out.println("Messages time to live " + timeToLive - + " ms"); - } - Connection connection = createConnection(); - Session session = createSession(connection); - MessageProducer producer = createProducer(session); - - TextMessage message = session - .createTextMessage(getInputDataString(scriptFileName)); - - producer.send(message); - - if (transacted) { - session.commit(); - } - - System.out.println("Done."); - close(connection, session); - } catch (Exception e) { - System.out.println("Caught: " + e); - e.printStackTrace(); - } - } - - protected MessageProducer createProducer(Session session) - throws JMSException { - MessageProducer producer = session.createProducer(destination); - if (durable) { - producer.setDeliveryMode(DeliveryMode.PERSISTENT); - } else { - producer.setDeliveryMode(DeliveryMode.NON_PERSISTENT); - } - if (timeToLive != 0) - producer.setTimeToLive(timeToLive); - - return producer; - } - - /* - * Reads the specified file into memory, and returns a StringReader object - * which reads from that in-memory buffer.

This method exists just to - * demonstrate that the input to the digester doesn't need to be from a - * file; for example, xml could be read from a database or generated - * dynamically; any old buffer in memory can be processed by the digester. - *

Clearly, if the data is always coming from a file, then calling the - * Digester.parse method that takes a File object would be more sensible - * (see AddressBook example). - */ - // private static java.io.Reader getInputData(String filename) { - // return new java.io.StringReader( getInputDataString(filename) ); - // } - private static String getInputDataString(String filename) { - java.io.File srcfile = new java.io.File(filename); - - java.io.ByteArrayOutputStream baos = new java.io.ByteArrayOutputStream( - 1000); - byte[] buf = new byte[100]; - java.io.FileInputStream fis = null; - try { - fis = new java.io.FileInputStream(srcfile); - for (;;) { - int nread = fis.read(buf); - if (nread == -1) { - break; - } - baos.write(buf, 0, nread); - } - } catch (java.io.IOException ioe) { - ioe.printStackTrace(); - } finally { - try { - fis.close(); - } catch (IOException e) { - e.printStackTrace(); - } - } - - return baos.toString(); - } -} diff --git a/edexOsgi/com.raytheon.edex.uengine/src/test/ProducerTool.javaorg b/edexOsgi/com.raytheon.edex.uengine/src/test/ProducerTool.javaorg deleted file mode 100644 index dfce879a2a..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/test/ProducerTool.javaorg +++ /dev/null @@ -1,158 +0,0 @@ -/** - * - * Copyright 2004 Protique Ltd - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - **/ - -import javax.jms.Connection; -import javax.jms.DeliveryMode; -import javax.jms.JMSException; -import javax.jms.MessageProducer; -import javax.jms.Session; -import javax.jms.TextMessage; -import java.util.Date; - -/** - * A simple tool for publishing messages - * - * @version $Revision: 1.2 $ - */ -public class ProducerTool extends ToolSupport { - - protected int messageCount = 10; - protected long sleepTime = 0L; - protected boolean verbose = true; - protected int messageSize = 255; - private long timeToLive; - - public static void main(String[] args) { - runTool(args, new ProducerTool()); - } - - protected static void runTool(String[] args, ProducerTool tool) { - tool.clientID = null; - if (args.length > 0) { - tool.url = args[0]; - } - if (args.length > 1) { - tool.topic = args[1].equalsIgnoreCase("true"); - } - if (args.length > 2) { - tool.subject = args[2]; - } - if (args.length > 3) { - tool.durable = args[3].equalsIgnoreCase("true"); - } - if (args.length > 4) { - tool.messageCount = Integer.parseInt(args[4]); - } - if (args.length > 5) { - tool.messageSize = Integer.parseInt(args[5]); - } - if (args.length > 6) { - if( ! "null".equals(args[6]) ) { - tool.clientID = args[6]; - } - } - if (args.length > 7) { - tool.timeToLive = Long.parseLong(args[7]); - } - if (args.length > 8) { - tool.sleepTime = Long.parseLong(args[8]); - } - if (args.length > 9) { - tool.transacted = "true".equals(args[9]); - } - tool.run(); - } - - public void run() { - try { - System.out.println("Connecting to URL: " + url); - System.out.println("Publishing a Message with size " + messageSize + " to " + (topic ? "topic" : "queue") + ": " + subject); - System.out.println("Using " + (durable ? "durable" : "non-durable") + " publishing"); - System.out.println("Sleeping between publish "+sleepTime+" ms"); - if( timeToLive!=0 ) { - System.out.println("Messages time to live "+timeToLive+" ms"); - } - Connection connection = createConnection(); - Session session = createSession(connection); - MessageProducer producer = createProducer(session); - sendLoop(session, producer); - - System.out.println("Done."); - close(connection, session); - } - catch (Exception e) { - System.out.println("Caught: " + e); - e.printStackTrace(); - } - } - - protected MessageProducer createProducer(Session session) throws JMSException { - MessageProducer producer = session.createProducer(destination); - if (durable) { - producer.setDeliveryMode(DeliveryMode.PERSISTENT); - } - else { - producer.setDeliveryMode(DeliveryMode.NON_PERSISTENT); - } - if( timeToLive!=0 ) - producer.setTimeToLive(timeToLive); - return producer; - } - - protected void sendLoop(Session session, MessageProducer producer) throws Exception { - - for (int i = 0; i < messageCount || messageCount==0 ; i++) { - - - TextMessage message = session.createTextMessage(createMessageText(i)); - - if (verbose) { - String msg = message.getText(); - if (msg.length() > 50) { - msg = msg.substring(0, 50) + "..."; - } - System.out.println("Sending message: " + msg); - } - - producer.send(message); - if(transacted) { - session.commit(); - } - - Thread.sleep(sleepTime); - - } - - } - - /** - * @param i - * @return - */ - private String createMessageText(int index) { - StringBuffer buffer = new StringBuffer(messageSize); - buffer.append("Message: " + index + " sent at: " + new Date()); - if (buffer.length() > messageSize) { - return buffer.substring(0, messageSize); - } - for (int i = buffer.length(); i < messageSize; i++) { - buffer.append(' '); - } - return buffer.toString(); - } -} diff --git a/edexOsgi/com.raytheon.edex.uengine/src/test/ToolSupport.java b/edexOsgi/com.raytheon.edex.uengine/src/test/ToolSupport.java deleted file mode 100644 index 297bfe9e02..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/test/ToolSupport.java +++ /dev/null @@ -1,107 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ - -package test; -/** - * - * Copyright 2004 Protique Ltd - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - **/ - -import javax.jms.Connection; -import javax.jms.Destination; -import javax.jms.JMSException; -import javax.jms.Session; - -import org.apache.activemq.ActiveMQConnection; -import org.apache.activemq.ActiveMQConnectionFactory; -import org.apache.activemq.util.IndentPrinter; - -/** - * Abstract base class useful for implementation inheritence - * - * @version $Revision: 1.2 $ - */ -public class ToolSupport { - - - protected Destination destination; - protected String subject = "TOOL.DEFAULT"; - protected boolean topic = false; - protected String user = ActiveMQConnection.DEFAULT_USER; - protected String pwd = ActiveMQConnection.DEFAULT_PASSWORD; - protected String url = ActiveMQConnection.DEFAULT_BROKER_URL; - protected boolean transacted = false; - protected boolean durable = false; - protected String clientID; - protected int ackMode = Session.AUTO_ACKNOWLEDGE; - protected String consumerName = "James"; - - - protected Session createSession(Connection connection) throws Exception { - Session session = connection.createSession(transacted, ackMode); - if (topic) { - destination = session.createTopic(subject); - } - else { - destination = session.createQueue(subject); - } - return session; - } - - protected Connection createConnection() throws JMSException, Exception { - ActiveMQConnectionFactory connectionFactory = new ActiveMQConnectionFactory(user, pwd, url); - Connection connection = connectionFactory.createConnection(); - if (durable && clientID!=null) { - connection.setClientID(clientID); - } - connection.start(); - return connection; - } - - protected void close(Connection connection, Session session) throws JMSException { - // lets dump the stats - dumpStats(connection); - - if (session != null) { - session.close(); - } - if (connection != null) { - connection.close(); - } - } - - protected void dumpStats(Connection connection) { - ActiveMQConnection c = (ActiveMQConnection) connection; - c.getConnectionStats().dump(new IndentPrinter()); - } -} diff --git a/edexOsgi/com.raytheon.edex.uengine/src/test/build.xml b/edexOsgi/com.raytheon.edex.uengine/src/test/build.xml deleted file mode 100644 index 60ad019359..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/test/build.xml +++ /dev/null @@ -1,49 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Running JmsEngineTest against server at $$url = ${url} for subject $$subject = ${subject} - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.edex.uengine/src/test/imageDecodeAction.xml b/edexOsgi/com.raytheon.edex.uengine/src/test/imageDecodeAction.xml deleted file mode 100644 index 75d28d8376..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/src/test/imageDecodeAction.xml +++ /dev/null @@ -1,17 +0,0 @@ - - - - TIGE06_131531_1__20050413154930.dat - ../../data/sbn/tst - - - - - - - ../../data/output - testfile - png - - - diff --git a/edexOsgi/com.raytheon.edex.uengine/testScript.bat b/edexOsgi/com.raytheon.edex.uengine/testScript.bat deleted file mode 100644 index 858500d537..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/testScript.bat +++ /dev/null @@ -1,12 +0,0 @@ -@echo off -rem batch script to demo exec adapter -echo These are the arguments: -echo %* -echo And then we have some fun test output: -echo this is a test -echo testing testing 123 -echo ...and now some giberish... -echo asfwefpwofjwefojwefpofjwpefjwfpjwfkjaw;efjf;jsdfsdfj -echo qpweoijsdflkjal;gj;vajap awpeoruqw epior uqwpeoru234 -echo qw[eriqw[erijq-werjqw-r9023ui-q29r02-234jskdfm;lsdfkma; -echo done \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web.deploy b/edexOsgi/com.raytheon.edex.uengine/web.deploy deleted file mode 100644 index ccc4140465..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web.deploy +++ /dev/null @@ -1 +0,0 @@ -war.name=uEngineWeb \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/AsciiInterface.js b/edexOsgi/com.raytheon.edex.uengine/web/AsciiInterface.js deleted file mode 100644 index 3215e050c2..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/AsciiInterface.js +++ /dev/null @@ -1,133 +0,0 @@ -function AsciiInterface(defaultMode){ - this.asciiForm = document.getElementById("asciiForm"); - this.location = document.getElementById("ascLocation"); - this.type = document.getElementById("ascType"); - this.time = document.getElementById("ascTime"); - this.count = document.getElementById("ascCount"); - this.timeout = document.getElementById("ascTimeout"); - - this.request = document.getElementById("requestViewBox"); - - this.hasInit = false; -} - -AsciiInterface.prototype.init = function(){ - if(!this.hasInit){ - this.getData("location"); - this.hasInit = true; - } -} - -AsciiInterface.prototype.getData = function(type){ - this.disableControls(); - var self = this; - var ascType = this.type.options[this.type.selectedIndex].value; - if(ascType == "TAF"){ - switch(type){ - case "location": - var queryArray = {"plugin" : "taf"}; - RequestTestDriver.requestCatalog("stationId",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "time": - var location = this.location.options[this.location.selectedIndex].value; - var queryArray = {"plugin" : "taf" , "stationId" : location}; - RequestTestDriver.requestCatalog("dataTime",queryArray,60000,function(output){self.processData(type,output);}); - break; - } - } - else{ - switch(type){ - case "location": - var queryArray = {"plugin" : "obs" , "reportType" : ascType}; - RequestTestDriver.requestCatalog("location.stationId",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "time": - var location = this.location.options[this.location.selectedIndex].value; - var queryArray = {"plugin" : "obs" , "location.stationId" : location , "reportType" : ascType}; - RequestTestDriver.requestCatalog("dataTime",queryArray,60000,function(output){self.processData(type,output);}); - break; - } - } -} - -AsciiInterface.prototype.processData = function(type,output){ - if(output == null || output.length == 0){ - alert("The ascii index appears to be empty. Please ingest data and try again."); - this.location.options.length = 0; - this.time.options.length = 0; - this.hasInit = false; - this.enableControls(); - return false; - } - output.sort(); - switch(type){ - case "location": - this.location.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.location.options[i] = new Option(output[i],output[i]); - } - if(this.location.options.length > 0){ - this.getData("time"); - } - else{ - this.enableControls(); - } - break; - case "time": - this.time.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.time.options[i] = new Option(output[i],output[i]); - } - output = null; - if(this.time.options.length > 0){ - this.createScript(); - } - else{ - this.enableControls(); - } - break; - } - output = null; -} - -AsciiInterface.prototype.createScript = function(){ - if(this.location.options.length == 0){ - return false; - } - this.disableControls(); - var location = this.location.options[this.location.selectedIndex].value; - var type = this.type.options[this.type.selectedIndex].value; - var time = this.time.options[this.time.selectedIndex].value; - var count = this.count.options[this.count.selectedIndex].value; - var engine = document.getElementById("scriptInterface").checked ? "xmljs" : "xml"; - var self = this; - if(type == "TAF"){ - var queryArray = {"pluginName" : "taf", "stationId" : location , "dataTime" : time}; - } else { - var queryArray = {"pluginName" : "obs" , "reportType" : type , "location.stationId" : location , "dataTime" : time}; - } - ScriptTestDriver.createScript(queryArray,count,engine,function(output){self.processScript(output);}) -} - -AsciiInterface.prototype.getTimeout = function(){ - var timeout = this.timeout.options[this.timeout.selectedIndex].value; - return timeout; -} - -AsciiInterface.prototype.processScript = function(output){ - this.request.value = output; - output = null; - this.enableControls(); -} - -AsciiInterface.prototype.disableControls = function(){ - for(var i = 0; i < this.asciiForm.length; i++){ - this.asciiForm[i].disabled = true; - } -} - -AsciiInterface.prototype.enableControls = function(){ - for(var i = 0; i < this.asciiForm.length; i++){ - this.asciiForm[i].disabled = false; - } -} diff --git a/edexOsgi/com.raytheon.edex.uengine/web/GridInterface.js b/edexOsgi/com.raytheon.edex.uengine/web/GridInterface.js deleted file mode 100644 index 5aa27f3da7..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/GridInterface.js +++ /dev/null @@ -1,234 +0,0 @@ -function GridInterface(defaultMode){ - this.gridForm = document.getElementById("gridForm"); - - this.model = document.getElementById("grdModel"); - this.basetime = document.getElementById("grdBasetime"); - this.parameter = document.getElementById("grdParameter"); - this.level = document.getElementById("grdLevel"); - this.levelone = document.getElementById("grdlevelone"); - this.leveltwo = document.getElementById("grdleveltwo"); - //this.forecasthour = document.getElementById("grdForecasthour"); - - this.colormap = document.getElementById("grdColormap"); - this.reproject = document.getElementById("grdReproject"); - this.format = document.getElementById("grdFormat"); - this.jython = document.getElementById("grdJython"); - this.count = document.getElementById("grdCount"); - this.timeout = document.getElementById("grdTimeout"); - - this.request = document.getElementById("requestViewBox"); - - this.hasInit = false; -} - -GridInterface.prototype.init = function(){ - if(!this.hasInit){ - this.getData("model"); - this.hasInit = true; - } -} - -GridInterface.prototype.getData = function(type){ - this.disableControls(); - var self = this; - switch(type){ - case "model": - var queryArray = {"plugin":"grid"}; - RequestTestDriver.requestCatalog("info.datasetId",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "basetime": - var model = this.model.options[this.model.selectedIndex].value; - var queryArray = {"plugin":"grid","info.datasetId":model}; - RequestTestDriver.requestCatalog("dataTime",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "parameter": - var model = this.model.options[this.model.selectedIndex].value; - var basetime = this.basetime.options[this.basetime.selectedIndex].value; - var queryArray = {"plugin":"grid","info.datasetId":model,"dataTime":basetime}; - RequestTestDriver.requestCatalog("info.parameter.name",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "level": - var model = this.model.options[this.model.selectedIndex].value; - var basetime = this.basetime.options[this.basetime.selectedIndex].value; - var parameter = this.parameter.options[this.parameter.selectedIndex].value; - var queryArray = {"plugin":"grid","info.datasetId":model,"dataTime":basetime,"info.parameter.name":parameter}; - RequestTestDriver.requestCatalog("info.level.masterLevel.name",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "levelone": - var model = this.model.options[this.model.selectedIndex].value; - var basetime = this.basetime.options[this.basetime.selectedIndex].value; - var parameter = this.parameter.options[this.parameter.selectedIndex].value; - var level = this.level.options[this.level.selectedIndex].value; - var queryArray = {"plugin":"grid","info.datasetId":model,"dataTime":basetime,"info.parameter.name":parameter,"info.level.masterLevel.name":level}; - RequestTestDriver.requestCatalog("info.level.levelonevalue",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "leveltwo": - var model = this.model.options[this.model.selectedIndex].value; - var basetime = this.basetime.options[this.basetime.selectedIndex].value; - var parameter = this.parameter.options[this.parameter.selectedIndex].value; - var level = this.level.options[this.level.selectedIndex].value; - var levelone = this.levelone.options[this.levelone.selectedIndex].value; - var queryArray = {"plugin":"grid","info.datasetId":model,"dataTime":basetime,"info.parameter.name":parameter,"info.level.masterLevel.name":level, -"info.level.levelonevalue":levelone}; - RequestTestDriver.requestCatalog("info.level.leveltwovalue",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "colormap": - RequestTestDriver.requestColormaps(60000,function(output){self.processData(type,output);}); - break; - } -} - -GridInterface.prototype.processData = function(type,output){ - if(type != 'leveltwo' && (output == null || output.length == 0)){ - alert("The grid index appears to be empty. Please ingest data and try again."); - this.hasInit = false; - this.enableControls(); - return false; - } - if (output != null && output.length > 0) { - output.sort(); - } - switch(type){ - case "model": - this.model.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.model.options[i] = new Option(output[i],output[i]); - } - if(this.model.options.length > 0){ - this.getData("basetime"); - } - else{ - this.enableControls(); - } - break; - case "basetime": - this.basetime.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.basetime.options[i] = new Option(output[i],output[i]); - } - if(this.basetime.options.length > 0){ - this.getData("parameter"); - } - else{ - this.enableControls(); - } - break; - case "parameter": - this.parameter.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.parameter.options[i] = new Option(output[i],output[i]); - } - output = null; - if(this.parameter.options.length > 0){ - this.getData("level"); - } - else{ - this.enableControls(); - } - break; - case "level": - this.level.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.level.options[i] = new Option(output[i],output[i]); - } - output = null; - if(this.level.options.length > 0){ - this.getData("levelone"); - } - else{ - this.enableControls(); - } - break; - case "levelone": - this.levelone.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.levelone.options[i] = new Option(output[i],output[i]); - } - output = null; - if(this.levelone.options.length > 0){ - this.getData("leveltwo"); - } - else{ - this.enableControls(); - } - break; - case "leveltwo": - this.leveltwo.options.length = 0; - if (output != null) { - for(var i = 0; i < output.length; i++){ - this.leveltwo.options[i] = new Option(output[i],output[i]); - } - } - output = null; - this.getData("colormap"); - break; - case "colormap": - this.colormap.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.colormap.options[i] = new Option(output[i],output[i]); - } - output = null; - if(this.colormap.options.length > 0){ - this.createScript(); - } - else{ - this.enableControls(); - } - break; - } - output = null; -} - -GridInterface.prototype.createScript = function(){ - if(this.model.options.length == 0){ - return 0; - } - this.disableControls(); - var model = this.model.options[this.model.selectedIndex].value; - var basetime = this.basetime.options[this.basetime.selectedIndex].value; - var parameter = this.parameter.options[this.parameter.selectedIndex].value; - var level = this.level.options[this.level.selectedIndex].value; - var levelone = this.levelone.options[this.levelone.selectedIndex].value; - var jython = this.jython.value; - var reproject = this.reproject.checked ? 1 : 0; - var colormap = this.colormap.options[this.colormap.selectedIndex].value; - var format = this.format.options[this.format.selectedIndex].value; - var count = this.count.options[this.count.selectedIndex].value; - var self = this; - var engine = document.getElementById("scriptInterface").checked ? "imagejs" : "image"; - if (this.leveltwo.selectedIndex >= 0) { - var leveltwo = this.leveltwo.options[this.leveltwo.selectedIndex].value; - var queryArray = {"pluginName":"grid","info.datasetId":model,"dataTime":basetime, - "info.parameter.name":parameter,"info.level.masterLevel.name":level, - "info.level.levelonevalue":levelone, "info.level.leveltwovalue":leveltwo, - "colormap":colormap,"reproject":reproject,"format":format}; - } else { - var queryArray = {"pluginName":"grid","info.datasetId":model,"dataTime":basetime, - "info.parameter.name":parameter,"info.level.masterLevel.name":level, - "info.level.levelonevalue":levelone, "colormap":colormap,"reproject":reproject,"format":format}; - } - ScriptTestDriver.createScript(queryArray,count,engine,function(output){self.processScript(output);}); -} - -GridInterface.prototype.getTimeout = function(){ - var timeout = this.timeout.options[this.timeout.selectedIndex].value; - return timeout; -} - -GridInterface.prototype.processScript = function(output){ - this.request.value = output; - output = null; - this.enableControls(); -} - -GridInterface.prototype.disableControls = function(){ - for(var i = 0; i < this.gridForm.length; i++){ - this.gridForm[i].disabled = true; - } -} - -GridInterface.prototype.enableControls = function(){ - for(var i = 0; i < this.gridForm.length; i++){ - this.gridForm[i].disabled = false; - } -} diff --git a/edexOsgi/com.raytheon.edex.uengine/web/HelloWorld.jsp b/edexOsgi/com.raytheon.edex.uengine/web/HelloWorld.jsp deleted file mode 100644 index 2b6a37dfba..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/HelloWorld.jsp +++ /dev/null @@ -1,61 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Hello World - - - - - - - - - -

μEngine Demonstration
Say Hello!

-This page creates the JS uEngine script prior to submitting the form request. -
- -

- - - - - - - - - - -
Enter your message:
- -
- - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/METARandTAF.jsp b/edexOsgi/com.raytheon.edex.uengine/web/METARandTAF.jsp deleted file mode 100644 index 1c02c3967b..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/METARandTAF.jsp +++ /dev/null @@ -1,124 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Multi Product Request - - - - - - - - - -

μEngine Demonstration
METAR and TAF Retrieval

-This script displays observations and tafs.
-It uses ObsRequest.js and TafRequest.js from the script library.
-This page contains the entire demo script. -
- -
- - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/RadarInterface.js b/edexOsgi/com.raytheon.edex.uengine/web/RadarInterface.js deleted file mode 100644 index 471590de80..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/RadarInterface.js +++ /dev/null @@ -1,178 +0,0 @@ -function RadarInterface(defaultMode){ - this.radarForm = document.getElementById("radarForm"); - this.location = document.getElementById("radLocation"); - this.type = document.getElementById("radType"); - this.elevation = document.getElementById("radElevation"); - this.time = document.getElementById("radTime"); - this.colorMap = document.getElementById("radColormap"); - this.reproject = document.getElementById("radReproject"); - this.format = document.getElementById("radFormat"); - this.count = document.getElementById("radCount"); - this.timeout = document.getElementById("radTimeout"); - - this.request = document.getElementById("requestViewBox"); - - this.radarType = {19:"Level 3 16 Level Base Reflectivity",27:"Level 3 16 Level Base Velocity",56:"Level 3 16 Level Storm Relative Mean Radial Velocity",94:"8-bit Reflectivity",99:"8-bit Velocity",300:"Level 2 Base Reflectivity",301:"Level 2 Base Velocity"}; - - this.hasInit = false; -} - -RadarInterface.prototype.init = function(){ - if(!this.hasInit){ - this.getData("type"); - this.hasInit = true; - } -} - -RadarInterface.prototype.getData = function(type){ - this.disableControls(); - var self = this; - switch(type){ - case "type": - var queryArray = {"plugin" : "radar"}; - RequestTestDriver.requestCatalog("productCode",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "elevation": - var radType = this.type.options[this.type.selectedIndex].value; - var queryArray = {"plugin" : "radar", "productCode" : radType}; - RequestTestDriver.requestCatalog("primaryElevationAngle",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "location": - var radType = this.type.options[this.type.selectedIndex].value; - var elevation = this.elevation.options[this.elevation.selectedIndex].value; - var queryArray = {"plugin" : "radar", "productCode" : radType, "primaryElevationAngle" : elevation}; - RequestTestDriver.requestCatalog("icao",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "time": - var radType = this.type.options[this.type.selectedIndex].value; - var elevation = this.elevation.options[this.elevation.selectedIndex].value; - var location = this.location.options[this.location.selectedIndex].value; - var queryArray = {"plugin" : "radar", "icao" : location , "primaryElevationAngle" : elevation, "productCode" : radType}; - RequestTestDriver.requestCatalog("dataTime",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "colormap": - RequestTestDriver.requestColormaps(60000,function(output){self.processData(type,output);}); - break; - } -} - -RadarInterface.prototype.processData = function(type,output){ - if(output == null || output.length == 0){ - alert("The radar index appears to be empty. Please ingest data and try again."); - this.hasInit = false; - this.enableControls(); - return false; - } - output.sort(); - switch(type){ - case "type": - this.type.options.length = 0; - for(var i = 0; i < output.length; i++){ - var s = this.radarType[output[i]]; - if (s == null) { - s = "Product code " + output[i]; - } - this.type.options[i] = new Option(s,output[i]); - } - if(this.type.options.length > 0){ - this.getData("elevation"); - } - else{ - this.enableControls(); - } - break; - case "elevation": - this.elevation.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.elevation.options[i] = new Option(output[i],output[i]); - } - if(this.elevation.options.length > 0){ - this.getData("location"); - } - else{ - this.enableControls(); - } - break; - case "location": - this.location.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.location.options[i] = new Option(output[i],output[i]); - } - if(this.location.options.length > 0){ - this.getData("time"); - } - else{ - this.enableControls(); - } - break; - case "time": - this.time.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.time.options[i] = new Option(output[i],output[i]); - } - output = null; - if(this.time.options.length > 0){ - this.getData("colormap"); - } - else{ - this.enableControls(); - } - break; - case "colormap": - this.colorMap.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.colorMap.options[i] = new Option(output[i],output[i]); - } - output = null; - if(this.colorMap.options.length > 0){ - this.createScript(); - } - else{ - this.enableControls(); - } - break; - } - output = null; -} - -RadarInterface.prototype.createScript = function(){ - if(this.type.options.length == 0){ - return false; - } - this.disableControls(); - var location = this.location.options[this.location.selectedIndex].value; - var elevation = this.elevation.options[this.elevation.selectedIndex].value; - var type = this.type.options[this.type.selectedIndex].value; - var time = this.time.options[this.time.selectedIndex].value; - var colormap = this.colorMap.options[this.colorMap.selectedIndex].value; - var reproject = this.reproject.checked ? 1 : 0; - var format = this.format.options[this.format.selectedIndex].value; - var count = this.count.options[this.count.selectedIndex].value; - var engine = document.getElementById("scriptInterface").checked ? "imagejs" : "image"; - var self = this; - var queryArray = {"pluginName":"radar","icao":location,"productCode":type,"dataTime":time,"primaryElevationAngle":elevation,"colormap":colormap,"reproject":reproject,"format":format}; - ScriptTestDriver.createScript(queryArray,count,engine,function(output){self.processScript(output);}); -} - -RadarInterface.prototype.getTimeout = function(){ - var timeout = this.timeout.options[this.timeout.selectedIndex].value; - return timeout; -} - -RadarInterface.prototype.processScript = function(output){ - this.request.value = output; - output = null; - this.enableControls(); -} - -RadarInterface.prototype.disableControls = function(){ - for(var i = 0; i < this.radarForm.length; i++){ - this.radarForm[i].disabled = true; - } -} - -RadarInterface.prototype.enableControls = function(){ - for(var i = 0; i < this.radarForm.length; i++){ - this.radarForm[i].disabled = false; - } -} diff --git a/edexOsgi/com.raytheon.edex.uengine/web/SatelliteInterface.js b/edexOsgi/com.raytheon.edex.uengine/web/SatelliteInterface.js deleted file mode 100644 index b7b30485c5..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/SatelliteInterface.js +++ /dev/null @@ -1,153 +0,0 @@ -function SatelliteInterface(defaultMode){ - this.satelliteForm = document.getElementById("satelliteForm"); - this.location = document.getElementById("satLocation"); - this.parameter = document.getElementById("satParameter"); - this.time = document.getElementById("satTime"); - this.colorMap = document.getElementById("satColormap"); - this.reproject = document.getElementById("satReproject"); - this.format = document.getElementById("satFormat"); - this.count = document.getElementById("satCount"); - this.timeout = document.getElementById("satTimeout"); - this.jython = document.getElementById("satJython"); - - this.request = document.getElementById("requestViewBox"); - - this.hasInit = false; -} - -SatelliteInterface.prototype.init = function(){ - if(!this.hasInit){ - this.getData("location"); - this.hasInit = true; - } -} - -SatelliteInterface.prototype.getData = function(type){ - this.disableControls(); - var self = this; - switch(type){ - case "location": - var queryArray = {"plugin" : "satellite"}; - RequestTestDriver.requestCatalog("sectorID",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "parameter": - var location = this.location.options[this.location.selectedIndex].value; - var queryArray = {"plugin" : "satellite", "sectorID" : location}; - RequestTestDriver.requestCatalog("physicalElement",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "time": - var location = this.location.options[this.location.selectedIndex].value; - var parameter = this.parameter.options[this.parameter.selectedIndex].value; - var queryArray = {"plugin" : "satellite", "sectorID" : location , "physicalElement" : parameter}; - RequestTestDriver.requestCatalog("dataTime",queryArray,60000,function(output){self.processData(type,output);}); - break; - case "colormap": - RequestTestDriver.requestColormaps(60000,function(output){self.processData(type,output);}); - break; - } -} - -SatelliteInterface.prototype.processData = function(type,output){ - if(output == null || output.length == 0){ - alert("The satellite index appears to be empty. Please ingest data and try again."); - this.hasInit = false; - this.enableControls(); - return false; - } - output.sort(); - switch(type){ - case "location": - this.location.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.location.options[i] = new Option(output[i],output[i]); - } - if(this.location.options.length > 0){ - this.getData("parameter"); - } - else{ - this.enableControls(); - } - break; - case "parameter": - this.parameter.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.parameter.options[i] = new Option(output[i],output[i]); - } - if(this.parameter.options.length > 0){ - this.getData("time"); - } - else{ - this.enableControls(); - } - break; - case "time": - this.time.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.time.options[i] = new Option(output[i],output[i]); - } - output = null; - if(this.time.options.length > 0){ - this.getData("colormap"); - } - else{ - this.enableControls(); - } - break; - case "colormap": - this.colorMap.options.length = 0; - for(var i = 0; i < output.length; i++){ - this.colorMap.options[i] = new Option(output[i],output[i]); - } - output = null; - if(this.colorMap.options.length > 0){ - this.createScript(); - } - else{ - this.enableControls(); - } - break; - } - output = null; -} - -SatelliteInterface.prototype.createScript = function(){ - if(this.location.options.length == 0){ - return false; - } - this.disableControls(); - var location = this.location.options[this.location.selectedIndex].value; - var parameter = this.parameter.options[this.parameter.selectedIndex].value; - var time = this.time.options[this.time.selectedIndex].value; - var jython = this.jython.value; - var format = this.format.options[this.format.selectedIndex].value; - var colormap = this.colorMap.options[this.colorMap.selectedIndex].value; - var reproject = this.reproject.checked ? 1 : 0; - var count = this.count.options[this.count.selectedIndex].value; - var engine = document.getElementById("scriptInterface").checked ? "imagejs" : "image"; - var self = this; - var queryArray = {"pluginName":"satellite","sectorID":location,"physicalElement":parameter,"dataTime":time,"colormap":colormap,"reproject":reproject,"format":format}; - ScriptTestDriver.createScript(queryArray,count,engine,function(output){self.processScript(output);}); -} - -SatelliteInterface.prototype.getTimeout = function(){ - var timeout = this.timeout.options[this.timeout.selectedIndex].value; - return timeout; -} - -SatelliteInterface.prototype.processScript = function(output){ - this.request.value = output; - output = null; - this.enableControls(); -} - -SatelliteInterface.prototype.disableControls = function(){ - for(var i = 0; i < this.satelliteForm.length; i++){ - this.satelliteForm[i].disabled = true; - } -} - -SatelliteInterface.prototype.enableControls = function(){ - for(var i = 0; i < this.satelliteForm.length; i++){ - this.satelliteForm[i].disabled = false; - } -} diff --git a/edexOsgi/com.raytheon.edex.uengine/web/StringBuffer.js b/edexOsgi/com.raytheon.edex.uengine/web/StringBuffer.js deleted file mode 100644 index 3785b3bcc9..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/StringBuffer.js +++ /dev/null @@ -1,12 +0,0 @@ - function StringBuffer() { - this.buffer = []; - } - - StringBuffer.prototype.append = function append(string) { - this.buffer.push(string); - return this; - }; - - StringBuffer.prototype.toString = function toString() { - return this.buffer.join(""); - }; \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/TestDriverUI.js b/edexOsgi/com.raytheon.edex.uengine/web/TestDriverUI.js deleted file mode 100644 index e9c5b4b621..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/TestDriverUI.js +++ /dev/null @@ -1,13 +0,0 @@ -function TestDriverUI(){ - this.expandImg = new Image(); - this.expandImg.src = "expand.gif"; - this.hideImg = new Image(); - this.hideImg.src = "hide.gif"; -} - -TestDriverUI.prototype.toggleSection = function(divName,divControlImg){ - var divToToggle = document.getElementById(divName); - var divImgToggle = document.getElementById(divControlImg); - divImgToggle.src = divToToggle.style.display == "none" ? this.hideImg.src : this.expandImg.src; - divToToggle.style.display = divToToggle.style.display == "none" ? "block" : "none"; -} \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/WEB-INF/classes/log4j.properties b/edexOsgi/com.raytheon.edex.uengine/web/WEB-INF/classes/log4j.properties deleted file mode 100644 index 40f031003d..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/WEB-INF/classes/log4j.properties +++ /dev/null @@ -1,16 +0,0 @@ -# -# Log4j configuration -# Available priorities are: OFF, FATAL, ERROR, WARN, INFO, DEBUG, ALL -# - -log4j.rootLogger=ALL,null -log4j.logger.com.raytheon.edex.uengine=INFO,console - -#appender for the rootLogger, set to null -log4j.appender.null=org.apache.log4j.varia.NullAppender - -#appender for the console, set to ConsoleAppender -log4j.appender.console=org.apache.log4j.ConsoleAppender -log4j.appender.console.layout=org.apache.log4j.PatternLayout -log4j.appender.console.layout.conversionPattern=%d [%t] %p %l %m%n - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/WEB-INF/dwr.xml b/edexOsgi/com.raytheon.edex.uengine/web/WEB-INF/dwr.xml deleted file mode 100644 index 49ad891307..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/WEB-INF/dwr.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/WEB-INF/web.xml b/edexOsgi/com.raytheon.edex.uengine/web/WEB-INF/web.xml deleted file mode 100644 index f3c282d931..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/WEB-INF/web.xml +++ /dev/null @@ -1,59 +0,0 @@ - - - - uEngineWeb - - - webAppRootKey - uEngineWeb - - - - - RunAction - RunAction - com.raytheon.edex.uengine.web.RunAction - - - - dwr-invoker - DWR Servlet - uk.ltd.getahead.dwr.DWRServlet - - debug - true - - - - - dwr-invoker - /dwr/* - - - - RunAction - /runAction.jas - - - - /index.html - - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/applicationExecute.jsp b/edexOsgi/com.raytheon.edex.uengine/web/applicationExecute.jsp deleted file mode 100644 index 262dd7f425..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/applicationExecute.jsp +++ /dev/null @@ -1,92 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Execute External Process - - - - - - - - -

μEngine Demonstration
AdapterSrv Demo Script

- -

-

- - - -
Enter/Edit the Action JS Script into the textbox and press Execute.
- -
-
-
- - -Timeout: - -
-
-
- - - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/asciiDemoUnsubscribe.jsp b/edexOsgi/com.raytheon.edex.uengine/web/asciiDemoUnsubscribe.jsp deleted file mode 100644 index 5deb82e2f8..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/asciiDemoUnsubscribe.jsp +++ /dev/null @@ -1,81 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -ASCII Request - - - - - - - - -

μEngine Demonstration
ASCII Product Unsubscribe

-
Form Driven Test Page
-
- -
-
- - - - - - - - - - - - - - - -
-Enter Action Script Parameters and press Submit. -
Name:
Type: -METAR -SPECI -Mesowest - -
Station:
Time:(YYYYMMDDhhmmss)
-Base -Reference -Cardinal -
-
-
- -Timeout: - - -
-
- - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/compactBarnesAnalysisWinds.jsp b/edexOsgi/com.raytheon.edex.uengine/web/compactBarnesAnalysisWinds.jsp deleted file mode 100644 index 51f39ff6a6..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/compactBarnesAnalysisWinds.jsp +++ /dev/null @@ -1,249 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Barnes Analysis - - - - - - - - - -

-μEngine Demonstration
-JScript Script Runner
-Barnes Analysis -

-
-This script demonstrates using Barnes Scheme analysis to correct a Wind Speed grid.
-The Wind Speed grid is generated by combining the Wind-U and Wind-V parameters.
-A spatial query is performed to obtain the wind speed observations.
-This page uses GribWinds.js, GribImage.js, and ObsSpatial.js from the script library. -
-
- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/compactBarnesTemperature.jsp b/edexOsgi/com.raytheon.edex.uengine/web/compactBarnesTemperature.jsp deleted file mode 100644 index 710fc293ba..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/compactBarnesTemperature.jsp +++ /dev/null @@ -1,100 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -ASCII Request - - - - - - - - -

μEngine Demonstration
JScript Script Runner
Barnes Analysis

-
-This script demonstrates using Barnes Scheme analysis to correct a temperature grid.
-This page uses BarnesTemperatureAnalysis.js from the script library. -
-
- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/compactFilteredImage.jsp b/edexOsgi/com.raytheon.edex.uengine/web/compactFilteredImage.jsp deleted file mode 100644 index 958cc1f3e0..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/compactFilteredImage.jsp +++ /dev/null @@ -1,85 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Filtered Image Demo - - - - - - - - - -

-μEngine Demonstration
-JScript Script Runner
-Scripted Image Filtering -

-Uses MEUtils.byteHighLowFilterImage() to filter image.
-This page uses FilteredImage.js from the script library. -
- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/compactMessageFormat.jsp b/edexOsgi/com.raytheon.edex.uengine/web/compactMessageFormat.jsp deleted file mode 100644 index 2e8e7d9bc2..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/compactMessageFormat.jsp +++ /dev/null @@ -1,78 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -JS Script Test - - - - - - - - -

-μEngine Demonstration
-GOES Image Retrieval -

-Uses SatelliteRequest.js from the script library. -
-

-

- - - -
Enter/Edit the Action JS Script into the textbox and press Submit.
- -
-
-
- - -Timeout: - -
-
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/compactSpatialQuery.jsp b/edexOsgi/com.raytheon.edex.uengine/web/compactSpatialQuery.jsp deleted file mode 100644 index f0673d283e..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/compactSpatialQuery.jsp +++ /dev/null @@ -1,82 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Spatial Query Demo - - - - - - - - -

-μEngine Demonstration
-JScript Script Runner
-Sample Spatial Query -

-
-This script demonstrates using a Spatial Query to obtain observation records.
-This page uses SpatialObQuery,js from the script library. -
- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/compactStopLightImage.jsp b/edexOsgi/com.raytheon.edex.uengine/web/compactStopLightImage.jsp deleted file mode 100644 index e7e40fdc60..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/compactStopLightImage.jsp +++ /dev/null @@ -1,86 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Stop Light Demo - - - - - - - - -

-μEngine Demonstration
-JScript Script Runner
-Stop Light Chart

-
Uses StopLightImage task to convert image.
-Simulates creation of a "Stop Light" decision chart based on temperature.
-Uses the StopLightImage task to convert image.
-This page uses StoplightMaker.js from the script library. -
- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/compactStopLightWinds.jsp b/edexOsgi/com.raytheon.edex.uengine/web/compactStopLightWinds.jsp deleted file mode 100644 index 8a1550ae25..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/compactStopLightWinds.jsp +++ /dev/null @@ -1,91 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Stoplight Demo - - - - - - - - -

μEngine Demonstration
-JScript Script Runner
-Wind Stop Light Chart -

-
-Combines two GRIB records to create a Wind Speed stoplight chart.
-Uses the StopLightImage and ConvertWindsData tasks to convert image.
-This page uses WindStopLight.js from the script library. -
-
- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/compactWindSpeedImage.jsp b/edexOsgi/com.raytheon.edex.uengine/web/compactWindSpeedImage.jsp deleted file mode 100644 index dcbd321ec7..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/compactWindSpeedImage.jsp +++ /dev/null @@ -1,188 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -ASCII Request - - - - - - - - - -

-μEngine Demonstration
-JScript Script Runner
-Create Wind Speed Chart

-
-
-This script creates a Wind Speed Chart from a multiple GRIB retrieval.
-This page uses GribWind.js and GribImage.js from the script library. -
- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/dataPurge/dataPurge.html b/edexOsgi/com.raytheon.edex.uengine/web/dataPurge/dataPurge.html deleted file mode 100644 index 638a1200d5..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/dataPurge/dataPurge.html +++ /dev/null @@ -1,132 +0,0 @@ - - - - - - - AWIPS II Purge Admin Interface - - - - - For All Plugins:

- - -



- For Specific Plugin:

- Plugin Name:
- - -



- DEFAULT RULE: - -

- - -

- - - - - - - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/expand.gif b/edexOsgi/com.raytheon.edex.uengine/web/expand.gif deleted file mode 100644 index 6b01912313a04203c719b7f55088cc7ee8d0fdc2..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 870 zcmZ?wbhEHb - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -ASCII Request - - - - - - - - -

μEngine Demonstration
ASCII Product Retrieval

-
Form Driven Test Page
- -

- - - - - - - - - - - - - - -
Enter Search Values
Name:
Type: -METAR -SPECI -Mesowest -TAF -
Station:(Required for TAF)
Time:(YYYYMMDDhhmmss)
-Base -Reference -Cardinal -
Count: -
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/goesDemoSubscribe.jsp b/edexOsgi/com.raytheon.edex.uengine/web/goesDemoSubscribe.jsp deleted file mode 100644 index a468aa0079..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/goesDemoSubscribe.jsp +++ /dev/null @@ -1,148 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Image Retrieval - - - - - - - - -

μEngine Demonstration
GOES Image Retrieval

-
Form Driven Test Page
- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Enter Action Script Parameters and press Submit.
Name:
DataType:Satellite
Query Parameters:Location: - -
Parameter: - -
Count: - -
Image Options:Color Map: - -
Format: - -
ReprojectTile Image
Actions:Disseminate: - - -
-Subscribe -Execute -
-
-
- - -Timeout: - -
-
-
- - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/goesDemoUnsubscribe.jsp b/edexOsgi/com.raytheon.edex.uengine/web/goesDemoUnsubscribe.jsp deleted file mode 100644 index db636bed70..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/goesDemoUnsubscribe.jsp +++ /dev/null @@ -1,72 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Image Retrieval - - - - - - - - -

μEngine Demonstration
GOES Image Unsubscribe

-
Form Driven Test Page
-
-
- - - - - - - - - - - - -
Enter Action Script Parameters to unsubscribe and press Submit.
Name:
DataType:Satellite
Location: - -
Parameter: - -
-
-
- -Timeout: - -
-
- - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/gribDemoUnsubscribe.jsp b/edexOsgi/com.raytheon.edex.uengine/web/gribDemoUnsubscribe.jsp deleted file mode 100644 index d9e680ccc7..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/gribDemoUnsubscribe.jsp +++ /dev/null @@ -1,72 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -GRIB Request - - - - - - - - -

μEngine Demonstration
GRIB Product Unsubscribe

-
Form Driven Test Page
-
- -
- - - - - - - - - - - - - - - - - - -
Enter Action Script Parameters to unsubscribe and press Submit.
Name:
DataType:Grib
ParametersName
Level: - - -
Forecast Time:
-
-
- -Timeout: - -
-
- - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/hide.gif b/edexOsgi/com.raytheon.edex.uengine/web/hide.gif deleted file mode 100644 index 202bbfe6f822c038610e723bdf6039bb21dd2f92..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 868 zcmZ?wbhEHb - - - - - - - - - - - - - - - - - AWIPS Test Driver Interface - - - - -
-
-
Satellite Data
-
Radar Data
-
Grid Data
-
ASCII Data
-
-
-
- Test Driver -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Script Engine:
- JavaScript
- Python -
- -
-
-
- Request/Response Message -
- - Archived Data -
- -
-
-
- - - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/index.jsp b/edexOsgi/com.raytheon.edex.uengine/web/index.jsp deleted file mode 100644 index a212d04552..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/index.jsp +++ /dev/null @@ -1,194 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - - -Action - - - -
- - - - - -
-Click here for the Test Driver Interface -
-μEngine Demonstration Page
-
-

-

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-Select the demonstration script to execute. -
Subscription/Notificaton Demos
-ASCII Retrieval - -GRIB Retrieval - -IMAGE Retrieval - -Radar Retrieval -
-ASCII Unsubscribe - -GRIB Unsubscribe - -IMAGE Unsubscribe - -Radar Unsubscribe -
-Test Editor Pages: -
JS Script editors -JScript Editor - -JScript Unsubscribe -
Hello World Demo -Form Version - -Demo Script -
-VTEC Retrieval Demos -
-Simple Retrieval - -Object Retrieval - -Query VTN - -Update VTN -
-Legacy Adaptor Test Scripts: -
-Execute External Process - -AdapterSrv Test (bat) - -AdapterSrv Test (exe) -
-Test scripts demonstrating JS Scripting — Full Message Format:
-
-GOES Image Retrieval - -Full Script - -Compact Version -
-Observation Retrival via Spatial Query - -Full Script - -Compact Version -
-Retrieval scripts with some Java Processing: -
-GOES Image Filtering - -Full Script - -Compact Version -
-Stoplight Chart from GRIB Retrieval - -Full Script - -Compact Version -
-Retrieval scripts demonstrating more complex products: -
-Two GRID retrieval – Computes Wind Speed - -Full Script - -Compact Version -
-Sample Math Scripting – Emulates creation of wind warning chart - -Full Script - -Compact Version -
-Barnes Scheme Analysis – Corrects Temperature - -Full Script - -Compact Version -
-Multi-product Retrievals: - -
-Two Product Retrieval - -OBs and Image - -OBs and TAFs -
-Barnes Scheme Analysis – Corrects Wind Speed - -Full Script - -Compact Version -
-
- - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/jsGetVTECAction.jsp b/edexOsgi/com.raytheon.edex.uengine/web/jsGetVTECAction.jsp deleted file mode 100644 index 6f9fe3d955..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/jsGetVTECAction.jsp +++ /dev/null @@ -1,82 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -JS Script Runner - - - - - - - -

-μEngine Demonstration
-VTEC Request Demo -

- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/jsGetVTECActionNew.jsp b/edexOsgi/com.raytheon.edex.uengine/web/jsGetVTECActionNew.jsp deleted file mode 100644 index 432e735f7f..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/jsGetVTECActionNew.jsp +++ /dev/null @@ -1,83 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -JS Script Runner - - - - - - - -

-μEngine Demonstration
-VTEC Request Demo
-Query by Example -

- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/jsRunScript.jsp b/edexOsgi/com.raytheon.edex.uengine/web/jsRunScript.jsp deleted file mode 100644 index ca8293655c..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/jsRunScript.jsp +++ /dev/null @@ -1,70 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -JS Script Runner - - - - - - - -

-μEngine Demonstration
-JScript Script Runner -

- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/jsUnsubscribe.jsp b/edexOsgi/com.raytheon.edex.uengine/web/jsUnsubscribe.jsp deleted file mode 100644 index 5fd8dc99c6..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/jsUnsubscribe.jsp +++ /dev/null @@ -1,63 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -JS Script Runner - - - - - - - - -

-μEngine Demonstration
-JScript Product Unsubscribe -

-
-
- - - - - - - - - - -
Enter Subscription Values
Name:
Subscription URI:
-
-
- -Timeout: - - -
-
- - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/jsVTECEventQuery.jsp b/edexOsgi/com.raytheon.edex.uengine/web/jsVTECEventQuery.jsp deleted file mode 100644 index b89a5c3dcb..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/jsVTECEventQuery.jsp +++ /dev/null @@ -1,100 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Event Tracking Query - - - - - - - - - - -

-μEngine Demonstration
-Event Tracking Query -

-This page creates a μEngine Script "on the fly". -
- -
- - - - - - - - - - - - -
- -
Enter Values for Message
Office:
Phenomena:
Significance:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/jsVTECEventUpdate.jsp b/edexOsgi/com.raytheon.edex.uengine/web/jsVTECEventUpdate.jsp deleted file mode 100644 index c320e319ed..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/jsVTECEventUpdate.jsp +++ /dev/null @@ -1,103 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Event Tracking Update - - - - - - - - - - -

-μEngine Demonstration
-Event Tracking Update -

-This page creates a μEngine Script "on the fly". -
- -
- - - - - - - - - - - - - -
- -
Enter Values for Message
Office:
Phenomena:
Significance:
New VTN:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/makeASCIIandImage.jsp b/edexOsgi/com.raytheon.edex.uengine/web/makeASCIIandImage.jsp deleted file mode 100644 index 2912a3d391..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/makeASCIIandImage.jsp +++ /dev/null @@ -1,116 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Multi Product Request - - - - - - - -
-

μEngine Demonstration
-JScript Script Runner
-Multi-Product Retrieval

-
-This script retrieves and displays observations and generates an image.
-This page uses SatelliteRequest.js and ObsRequest.js from the script library.
-This page contains the entire demo script. -
- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/makeBarnesAnalysisWinds.jsp b/edexOsgi/com.raytheon.edex.uengine/web/makeBarnesAnalysisWinds.jsp deleted file mode 100644 index 2aed9e5acc..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/makeBarnesAnalysisWinds.jsp +++ /dev/null @@ -1,466 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Barnes Analysis - - - - - - - - - -

-μEngine Demonstration
-JScript Script Runner
-Barnes Analysis -

-
-This script demonstrates using Barnes Scheme analysis to correct a Wind Speed grid.
-The Wind Speed grid is generated by combining the Wind-U and Wind-V parameters.
-A spatial query is performed to obtain the wind speed observations.
-This page shows the entire script. -
-
- -
- - - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/makeBarnesTemperature.jsp b/edexOsgi/com.raytheon.edex.uengine/web/makeBarnesTemperature.jsp deleted file mode 100644 index 0b2cb84e90..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/makeBarnesTemperature.jsp +++ /dev/null @@ -1,263 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Barnes Analysis - - - - - - - - -

μEngine Demonstration
JScript Script Runner
Barnes Analysis

-
-This script demonstrates using Barnes Scheme analysis to correct a temperature grid.
-This page shows the entire script. -
-
- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/makeEventUpdate.jsp b/edexOsgi/com.raytheon.edex.uengine/web/makeEventUpdate.jsp deleted file mode 100644 index cf65324cd2..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/makeEventUpdate.jsp +++ /dev/null @@ -1,90 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Event Tracking Update - - - - - - - - - - -

-μEngine Demonstration
-Event Tracking Update -

-This page creates a μEngine Script "on the fly". -
- -
- - - - - - - - - - - - - -
Enter Values for Message
Office:
Phenomena:
Significance:
New VTN:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/makeFilteredImage.jsp b/edexOsgi/com.raytheon.edex.uengine/web/makeFilteredImage.jsp deleted file mode 100644 index 860d914e24..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/makeFilteredImage.jsp +++ /dev/null @@ -1,204 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Filtered Image Demo - - - - - - - - -

-μEngine Demonstration
-JScript Script Runner
-Scripted Image Filtering -

-Uses MEUtils.byteHighLowFilterImage() to filter image.
-This page contains the entire script. -
- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/makeHelloWorld.jsp b/edexOsgi/com.raytheon.edex.uengine/web/makeHelloWorld.jsp deleted file mode 100644 index b454fdd14a..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/makeHelloWorld.jsp +++ /dev/null @@ -1,114 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Hello World - - - - - - - - - - -

-μEngine Demonstration
-Say Hello! -

-This page modifies the JS uEngine script prior to submitting the form request. -
- -
- - - - - - - - - - -
- -
Enter Values for Message
Enter message: - -
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/makeSpatialQuery.jsp b/edexOsgi/com.raytheon.edex.uengine/web/makeSpatialQuery.jsp deleted file mode 100644 index 7ac6475df3..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/makeSpatialQuery.jsp +++ /dev/null @@ -1,165 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Spatial Query Demo - - - - - - - - -

-μEngine Demonstration
-JScript Script Runner
-Sample Spatial Query -

-
-This script demonstrates using a Spatial Query to obtain observation records.
-This page uses the SpatialQuery task to obtain the station list. -
- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/makeStopLightImage.jsp b/edexOsgi/com.raytheon.edex.uengine/web/makeStopLightImage.jsp deleted file mode 100644 index ceb3263a42..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/makeStopLightImage.jsp +++ /dev/null @@ -1,200 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Stop Light Demo - - - - - - - - -

-μEngine Demonstration
-JScript Script Runner
-Stop Light Chart

-
Uses StopLightImage task to convert image.
-Simulates creation of a "Stop Light" decision chart based on temperature.
-Uses the StopLightImage task to convert image.
-This page contains the entire script. -
- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/makeStopLightWinds.jsp b/edexOsgi/com.raytheon.edex.uengine/web/makeStopLightWinds.jsp deleted file mode 100644 index f55cbeed4b..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/makeStopLightWinds.jsp +++ /dev/null @@ -1,223 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Stoplight Demo - - - - - - - - -
-

μEngine Demonstration
-JScript Script Runner
-Wind Stop Light Chart -

-
-
-Combines two GRIB records to create a Wind Speed stoplight chart.
-Uses the StopLightImage and ConvertWindsData tasks to convert image.
-This page contains the complete script. -
-
- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/makeWindSpeedImage.jsp b/edexOsgi/com.raytheon.edex.uengine/web/makeWindSpeedImage.jsp deleted file mode 100644 index 4ff6f831ca..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/makeWindSpeedImage.jsp +++ /dev/null @@ -1,336 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -ASCII Request - - - - - - - -

-μEngine Demonstration
-JScript Script Runner
-Create Wind Speed Chart

-
-
-This script creates a Wind Speed Chart from a multiple GRIB retrieval.
-This page shows the entire script. -
-
- -
- - - - - - - - - - - -
- -
Enter Values for Message
Name:
Action: -Validate -Subscribe -Execute
-
-
- - -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/radarSubscribe.jsp b/edexOsgi/com.raytheon.edex.uengine/web/radarSubscribe.jsp deleted file mode 100644 index 83df003135..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/radarSubscribe.jsp +++ /dev/null @@ -1,151 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Radar Retrieval - - - - - - - - -

μEngine Demonstration
Simple Radar Retrieval

-
Form Driven Test Page
- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Enter Action Script Parameters and press Submit.
Name:
DataType:Radar
Query Parameters:Station:
Product Code:
Elevation Angle:
Count: - -
Image Options:Color Map: - -
Format: - -
ReprojectTile Image
Actions:Disseminate: - - -
-Subscribe -Execute
-
-
- - -Timeout: - -
-
-
- - - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/radarUnsubscribe.jsp b/edexOsgi/com.raytheon.edex.uengine/web/radarUnsubscribe.jsp deleted file mode 100644 index 295b95cf1f..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/radarUnsubscribe.jsp +++ /dev/null @@ -1,84 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Radar Retrieval - - - - - - - - -

μEngine Demonstration
Radar Image Unsubscribe

-
Form Driven Test Page
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Enter Action Script Parameters to unsubscribe and press Submit.
Name:
DataType:Radar
Station:
Product Code:
Elevation Angle:
- -
-
- -Timeout: - -
-
- - \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/rayAWIPS.jpg b/edexOsgi/com.raytheon.edex.uengine/web/rayAWIPS.jpg deleted file mode 100644 index 7c0fbe56f1b2b5e2174ab07936fd6a27498ac950..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 5217 zcmbW*XD}RIy8!UjqL(S<~mRU&$bjS^kh*och?n+?0NYDf@7TdW`!(WAGpIzjXr zY*rUNdUTPnUjKXVym#h)y7xY3&ZqO7GtY0HnKNh3#l*!tfaRV6*Z@FAMg~Z_9Ds{y zfF6L3nwp0C3LOm%4LuzlJrg$z6C)#&00$?KTU1C~OhicJs)US+oP@NJ^i`3YI`T?t z>YAFG;y3Pq^==!gXlSbca|jt7Jv|d66F&%HWLHel2^CCB$H~Rb!z(T!DJ6YP38bu|s&-57 zj=sTNL-0LID{C9u2X^+bC(ch@p1HbtzC?R@`}q2WybTQte-{ynO?aP}l>8wDmz|TF z_bI=iu;_DDHNK{{uD+rDYe#2ScTaEM=osNUaeQKOYGH9{d1dwI+WN-c{=wnV@yYMg zKmWMM02Kep`nT+VxPX@~a!N`HO6q@HWaQqLlLAOdbyfZftByJKV7(MUR8s_LT{mgmj6KOSk zQ-5nX;gl|uBooI*H^??PRQG;MY`#U3ihs2*zwoVl!k*%97A-;5`2RxyL)LW$7u&U_EsJ1BqA z;MX_s%ShMJ=F(g_F-pkk5T)YdT8{Q7n0&(6YJKzARW8<;&-w_)CJV!QMwztw;a6mX zAZY1UZYrsSDa|iu8u3cU8Krxg$~RJ1dIyb6bkz6Ri7)Q=h2O5dPT$E;5~aZQSzq7* z+f)OiBs9?pyj4auz}OcvN$Jl!#oZZbR~&ffUev5$gub&YZlxu&Znj3J&62=Npa#w0 z+}6H6ewH2S$W9byz@cGqm6ZqfU4OwmUZk}=32Y;;ttbJ+CjTVntd1=_&ih#KsMT$1 zr~3AN_fL?UH8s90)9ozmb+IIS#rox&TU5_B6`^i6tZlgt-Eak#O10DAgQ0+)l5@Cu zZ6&@sY*F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>%pj56c?QnEBGZ;k{_FB)XUNo#=?10CR(7C#@bhHXd;}KjHq#G57#ZROo6&L>#5XEKD$;v8m5m zEmH$otR9KPEPGqUT(O&&mm?6F@)rkHOg-smBFf|wgPA{I{m5sp7%tZRJvTqI1z_x; za}TuR9ku%^YprFu8Gm<=m7;7q3c5`iaqWq7d6ze{PvuO5E6J*#J{Dy6PBM*&`pdiw zU>b}-eS_@y_kZ~i_IGb*IYph5XZ|Q#MY&e?x>bMSjHifbQlx~2A<5^YY^jX|yt%rw zsc`@5%+Bm49sA5I>12k8(07CT$b2pQG$qQh?3qBwu-{ydH>fn=FaQ+F5WwP3P_-Vp zO4aW>?#fClaCp#Y;=le*Xe~slOh4zJc96Rp8+{IM&J`8C@;*Daq$|~QZMRvMzS!Zo zA@Q?aRM?~HN01JqTZKKXTb^@y2&IQnNuw(RtRJ#tvXhY*j?*K5`uRT+3?jMk@fwy;?%o!l&KvM$s?Q{}BBgmD&Y^fS?|&_9tg zW`J$DLb`eI2c{pP+Q>>Cepvs3Vq^a7hB|KriGNQ#HE_w?6~HZsqFx#ULHS6Q z^naJQrf%GDvr7=vCx}OcRC^8C!xN~ z=u`wIrny?-acB2Xv7V{VWDlp0aEpr)EMQ@b_-P6u?UVLSZran*sRtW=1Lem?UR9A! z4A>fDEVJ>)kg3K1$%U2lEG8J$1)ymLw^?!+1qYF_Ah+%HXiHajj7kwAC=$=EbxS(; zQ{(#ODwK(rM{7l)yq!VxFbxo>}dx3~KG`A(hyFSZ)Lx+LAz1(*(`7i%u{`>#{ diff --git a/edexOsgi/com.raytheon.edex.uengine/web/scriptExecute.jsp b/edexOsgi/com.raytheon.edex.uengine/web/scriptExecute.jsp deleted file mode 100644 index a6079d2db7..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/scriptExecute.jsp +++ /dev/null @@ -1,92 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -Execute External Process - - - - - - - - -

μEngine Demonstration
AdapterSrv Demo Script

- -

-

- - - -
Enter/Edit the Action JS Script into the textbox and press Execute.
- -
-
-
- - -Timeout: - -
-
-
- - - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/simpleGrib.jsp b/edexOsgi/com.raytheon.edex.uengine/web/simpleGrib.jsp deleted file mode 100644 index fd96ecf738..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/simpleGrib.jsp +++ /dev/null @@ -1,174 +0,0 @@ -<%@ page language="java" contentType="text/html; charset=ISO-8859-1" - pageEncoding="ISO-8859-1"%> - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -GRIB Request - - - - - - - - -

μEngine Demonstration
Simple GRIB Retrieval

-
Form Driven Test Page
- -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Enter Action Script Parameters and press Submit.
Name:
DataType:Grib
Query Parameters:Parameter Name:
Parameter Level: - - -
Forecast Time:
Count: - -
Grib Mapping:Factor:
Minimum:
Maximum:
Image Options:Color Map: - -
Format: - -
ReprojectTile Image
Actions:Disseminate: - - -
-Subscribe -Execute
-
-
- - -Timeout: - -
-
-
- - - diff --git a/edexOsgi/com.raytheon.edex.uengine/web/td.css b/edexOsgi/com.raytheon.edex.uengine/web/td.css deleted file mode 100644 index e8b5a38a45..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/td.css +++ /dev/null @@ -1,51 +0,0 @@ -body{ - font-family: Helvetica; - margin-left: 75px; - margin-right: 75px; - background: #E0E0E0; -} -#banner{ - background: white; - font-family: Lucida Sans; - font-size: 24pt; - text-align: center; - border: 1px solid #C0C0C0; -} -#interfaceBody{ - margin-top: 10px; -} -#interfaceRight{ - border: 1px solid #000000; - background: white; - margin-left: 149px; - padding: 10px; -} -#leftTabs{ - font-size: 10pt; - float: left; - width: 150px; -} -.leftTabSelected{ - background: white; - text-align: center; - border-top: 1px solid black; - border-left: 1px solid black; - border-bottom: 1px solid black; - cursor: default; -} -.leftTabEntry{ - background: #A0A0A0; - text-align: center; - border: 1px solid black; - cursor: pointer; -} - -.testDriverTitle{ - font-size: 14pt; - text-align: center; -} - -.testDriverFileSelect{ - margin-left: 20px; - width: 40%; -} diff --git a/edexOsgi/com.raytheon.edex.uengine/web/templates/VM_global_library.vm b/edexOsgi/com.raytheon.edex.uengine/web/templates/VM_global_library.vm deleted file mode 100644 index 5121f72a34..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/templates/VM_global_library.vm +++ /dev/null @@ -1,204 +0,0 @@ -#macro(standardSelect $scriptLibrary $maxRecords $scriptMetadata $ignoreDataTime) -import ${scriptLibrary} -#set($pluginName = $scriptMetadata.get("pluginName").constraintValue) -dataRequest = ${scriptLibrary}.${scriptLibrary}("${pluginName}") -dataRequest.setCount(${maxRecords}) -#foreach (${key} in ${scriptMetadata.keySet()}) -#if(${key}) -#if(${key} != "pluginName" && (${key} != "dataTime" || !${ignoreDataTime})) -#set($constraint = $scriptMetadata.get($key)) -#if(${constraint.constraintType} == "IN") -dataRequest.addList("${key}", "${constraint.constraintValue}") -#elseif(${constraint.constraintType} == "LIKE") -dataRequest.addParameter("${key}", "${constraint.constraintValue}", "like") -#elseif ($constraint.constraintType == "ISNULL") -dataRequest.addParameter("${key}", "${constraint.constraintValue}", "isnull") -#else -dataRequest.addParameter("${key}", "${constraint.constraintValue}") -#end -#end -#end -#end -return dataRequest.execute() -#end - -#macro(standardSelectJs $scriptLibrary $maxRecords $scriptMetadata $ignoreDataTime) -include("${scriptLibrary}.js"); -#set($pluginName = $scriptMetadata.get("pluginName").constraintValue) -var dataRequest = new ${scriptLibrary}("${pluginName}"); -dataRequest.setCount(${maxRecords}); -#foreach (${key} in ${scriptMetadata.keySet()}) -#if(${key}) -#if(${key} != "pluginName" && (${key} != "dataTime" || !${ignoreDataTime})) -#set($constraint = $scriptMetadata.get($key)) -#if(${constraint.constraintType} == "IN") -dataRequest.addList("${key}", "${constraint.constraintValue}"); -#elseif(${constraint.constraintType} == "LIKE") -dataRequest.addParameter("${key}", "${constraint.constraintValue}", "like"); -#elseif ($constraint.constraintType == "ISNULL") -dataRequest.addParameter("${key}", "${constraint.constraintValue}", "isnull"); -#else -dataRequest.addParameter("${key}", "${constraint.constraintValue}"); -#end -#end -#end -#end -dataRequest.execute(); -#end - -#macro(standardImageSelect $scriptLibrary $maxRecords $scriptMetadata $ignoreDataTime) -#set($pluginName = $scriptMetadata.get("pluginName").constraintValue) -#set($colorMap = $scriptMetadata.remove("colormap").constraintValue) -#set($reproject = $scriptMetadata.remove("reproject").constraintValue) -#set($format = $scriptMetadata.remove("format").constraintValue) -import ${scriptLibrary} -#if($pluginName == "grid") -dataRequest = ${scriptLibrary}.${scriptLibrary}("${pluginName}") -#else -dataRequest = ${scriptLibrary}.${scriptLibrary}() -#end -dataRequest.requestImage(1) -dataRequest.setColormap("${colorMap}") -dataRequest.setCount(${maxRecords}) -dataRequest.reprojectImage(${reproject}) -#foreach (${key} in ${scriptMetadata.keySet()}) -#if(${key}) -#if(${key} != "pluginName" && (${key} != "dataTime" || !${ignoreDataTime})) -#set($constraint = $scriptMetadata.get($key)) -#if(${constraint.constraintType} == "IN") -dataRequest.addList("${key}", "${constraint.constraintValue}") -#elseif(${constraint.constraintType} == "LIKE") -dataRequest.addParameter("${key}", "${constraint.constraintValue}", "like") -#elseif ($constraint.constraintType == "ISNULL") -dataRequest.addParameter("${key}", "${constraint.constraintValue}", "isnull"); -#else -dataRequest.addParameter("${key}", "${constraint.constraintValue}") -#end -#end -#end -#end -#if(${pluginName} == "grid") -dataRequest.setScaleFactor(1) -#end -dataRequest.setFormat("${format}") -return dataRequest.execute() -#end - -#macro(standardImageSelectJs $scriptLibrary $maxRecords $scriptMetadata $ignoreDataTime) -include("${scriptLibrary}.js"); -#set($pluginName = $scriptMetadata.get("pluginName").constraintValue) -#set($colorMap = $scriptMetadata.remove("colormap").constraintValue) -#set($reproject = $scriptMetadata.remove("reproject").constraintValue) -#set($format = $scriptMetadata.remove("format").constraintValue) -var dataRequest = new ${scriptLibrary}(); -dataRequest.requestImage(1); -dataRequest.setCount(${maxRecords}); -dataRequest.setColormap("${colorMap}"); -dataRequest.reprojectImage(${reproject}); -#foreach (${key} in ${scriptMetadata.keySet()}) -#if(${key}) -#if(${key} != "pluginName" && (${key} != "dataTime" || !${ignoreDataTime})) -#set($constraint = $scriptMetadata.get($key)) -#if(${constraint.constraintType} == "IN") -dataRequest.addList("${key}", "${constraint.constraintValue}"); -#elseif(${constraint.constraintType} == "LIKE") -dataRequest.addParameter("${key}", "${constraint.constraintValue}", "like"); -#elseif ($constraint.constraintType == "ISNULL") -dataRequest.addParameter("${key}", "${constraint.constraintValue}", "isnull"); -#else -dataRequest.addParameter("${key}", "${constraint.constraintValue}"); -#end -#end -#end -#end -#if(${pluginName} == "grid") -dataRequest.setScaleFactor(1); -#end -dataRequest.setFormat("${format}"); -dataRequest.execute(); -#end - -#macro(standardCatalog $scriptLibrary $scriptMetadata) -query = CatalogQuery.CatalogQuery("$scriptMetadata.get("pluginName").constraintValue") -query.setDistinctField("$scriptMetadata.get("fieldName").constraintValue") - -#foreach (${name} in ${scriptMetadata.keySet()}) -#if(${name} != "pluginName") -#set($constraint = $scriptMetadata.get($name)) -#if ($name == "pluginName") -#set($name = "plugin") -#end -#if($name != "fieldName") -#set($operand = "=") -#if ($constraint.constraintType == "NOT_EQUALS") -#set($operand = "!=") -#elseif ($constraint.constraintType == "GREATER_THAN") -#set($operand = ">") -#elseif ($constraint.constraintType == "GREATER_THAN_EQUALS") -#set($operand = ">=") -#elseif ($constraint.constraintType == "LESS_THAN") -#set($operand = "<") -#elseif ($constraint.constraintType == "LESS_THAN_EQUALS") -#set($operand = "<=") -#elseif ($constraint.constraintType == "BETWEEN") -#set($operand = "between") -#elseif ($constraint.constraintType == "IN") -#set($operand = "in") -#elseif ($constraint.constraintType == "LIKE") -#set($operand = "like") -#elseif ($constraint.constraintType == "ISNULL") -#set($operand = "isnull") -#end -query.addConstraint("${name}","${constraint.constraintValue}","${operand}") -#end -#end -#end -return query.execute() -#end - -#macro(standardLatestTime $scriptMetadata) -import LatestTime -ltq = LatestTime.LatestTime('$scriptMetadata.get("uriList").constraintValue') -return ltq.execute() -#end - -#macro(standardDbQuery $scriptMetadata) -import DbQuery -query = DbQuery.DbQuery("$scriptMetadata.remove("dbName").constraintValue","$scriptMetadata.remove("className").constraintValue") -#if ($scriptMetadata.containsKey("distinctField")) -query.setDistinctField("$scriptMetadata.remove("distinctField").constraintValue") -#end -#if ($scriptMetadata.containsKey("orderBy")) -query.setOrderByList("$scriptMetadata.remove("orderBy").constraintValue","$scriptMetadata.remove("sortOrder").constraintValue") -#end -query.setReturnedFieldList("$scriptMetadata.remove("columns").constraintValue") -#foreach (${name} in ${scriptMetadata.keySet()}) -#set($constraint = $scriptMetadata.get($name)) -#if($name != "pluginName") -#set($operand = "=") -#if ($constraint.constraintType == "NOT_EQUALS") -#set($operand = "!=") -#elseif ($constraint.constraintType == "GREATER_THAN") -#set($operand = ">") -#elseif ($constraint.constraintType == "GREATER_THAN_EQUALS") -#set($operand = ">=") -#elseif ($constraint.constraintType == "LESS_THAN") -#set($operand = "<") -#elseif ($constraint.constraintType == "LESS_THAN_EQUALS") -#set($operand = "<=") -#elseif ($constraint.constraintType == "BETWEEN") -#set($operand = "between") -#elseif ($constraint.constraintType == "IN") -#set($operand = "in") -#elseif ($constraint.constraintType == "LIKE") -#set($operand = "like") -#elseif ($constraint.constraintType == "ILIKE") -#set($operand = "ilike") -#elseif ($constraint.constraintType == "ISNULL") -#set($operand = "isnull") -#end -query.addConstraint("${name}","${constraint.constraintValue}","${operand}") -#end -#end -return query.execute() -#end \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.uengine/web/templates/standardTemplate.vm b/edexOsgi/com.raytheon.edex.uengine/web/templates/standardTemplate.vm deleted file mode 100644 index c0c45aec68..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/templates/standardTemplate.vm +++ /dev/null @@ -1,18 +0,0 @@ -## The standard template gets all of its behavior from VM_global_library macros -#if($mode == "select") -#standardSelect($scriptLibrary $maxRecords $scriptMetadata false) -#elseif($mode == "catalog") -#standardCatalog($scriptLibrary $scriptMetadata) -#elseif($mode == "latestTime") -#standardLatestTime($scriptMetadata) -#elseif($mode == "xml") -#standardSelect($scriptLibrary $maxRecords $scriptMetadata false) -#elseif($mode == "xmljs") -#standardSelectJs($scriptLibrary $maxRecords $scriptMetadata false) -#elseif($mode == "image") -#standardImageSelect($scriptLibrary $maxRecords $scriptMetadata false) -#elseif($mode == "imagejs") -#standardImageSelectJs($scriptLibrary $maxRecords $scriptMetadata false) -#elseif($mode == "dbquery") -#standardDbQuery($scriptMetadata) -#end diff --git a/edexOsgi/com.raytheon.edex.uengine/web/testDriverControls.js b/edexOsgi/com.raytheon.edex.uengine/web/testDriverControls.js deleted file mode 100644 index 97fbfa7729..0000000000 --- a/edexOsgi/com.raytheon.edex.uengine/web/testDriverControls.js +++ /dev/null @@ -1,347 +0,0 @@ -function TestDriverControls(defaultMode){ - this.decodeDir = ""; - this.dataDir = ""; - this.tab = null; - this.queryForm = null; - this.displayViewButton = false; - this.busy = false; - this.tabHolder = document.getElementById("leftTabs"); - this.fileSelectBox = document.getElementById("files"); - this.fileViewButton = document.getElementById("fileViewButton"); - this.fileViewBox = document.getElementById("fileViewBox"); - this.testDriverName = document.getElementById("testDriverName"); - this.actionScriptBox = document.getElementById("requestViewBox"); - this.actionResponseBox = document.getElementById("responseViewBox"); - this.returnData = document.getElementById("returnedData"); - - this.satInterface = document.getElementById("satelliteInterface"); - this.radInterface = document.getElementById("radarInterface"); - this.grdInterface = document.getElementById("gridInterface"); - this.ascInterface = document.getElementById("asciiInterface"); - this.satInterfaceInit = false; - this.radInterfaceInit = false; - this.grdInterfaceInit = false; - this.ascInterfaceInit = false; - - this.currentInterface = null; - - this.setMode(defaultMode); -} - -TestDriverControls.prototype.updateCatalog = function(type){ - this.currentInterface.getData(type); -} - -TestDriverControls.prototype.createScript = function(){ - this.currentInterface.createScript(); -} - -TestDriverControls.prototype.getFileList = function(){ - this.currentInterface.disableControls(); - var self = this; - TestDataDriver.listTestDataFiles(this.dataDir,function(files){ self.processFileList(files); }); -} - -TestDriverControls.prototype.processFileList = function(files){ - this.fileSelectBox.options.length = 0; - for(var i = 0; i < files.length; i++){ - this.fileSelectBox.options[this.fileSelectBox.options.length] = new Option(files[i],files[i]); - } - files = null; - this.currentInterface.enableControls(); -} - -TestDriverControls.prototype.viewFile = function(){ - var fileName = this.getFileName(); - if(fileName != "NONE"){ - var self = this; - TestDataDriver.viewTestDataFiles(this.dataDir, fileName, function(response){self.processFileView(response);}); - } -} - -TestDriverControls.prototype.processFileView = function(fileData){ - this.fileViewBox.value = fileData; - fileData = null; -} - -TestDriverControls.prototype.copyFile = function(){ - this.currentInterface.disableControls(); - this.busy = true; - var fileName = this.getFileName(); - if(fileName != "NONE"){ - var self = this; - TestDataDriver.ingestTestDataFiles(this.dataDir, this.decodeDir, fileName, function(response){self.copyFileStatus(response);}); - } -} - -TestDriverControls.prototype.getFileName = function(){ - if(this.fileSelectBox.selectedIndex < 0){ - alert("Please select a file from the box above."); - return "NONE"; - } - var fileName = this.fileSelectBox.options[this.fileSelectBox.selectedIndex].value; - if(fileName == "No Files Available"){ - alert("No files are available."); - return "NONE"; - } - return fileName; -} - -TestDriverControls.prototype.copyFileStatus = function(copySuccess){ - if(copySuccess){ - alert("The file was copied to the decode directory. Please wait for a few seconds to allow time to ingest."); - } - else{ - alert("The copy failed. Please check the data and decode directories for any problems."); - } - copySuccess = null; - this.currentInterface.enableControls(); - this.busy = false; -} - -TestDriverControls.prototype.setMode = function(mode){ - if(mode == this.mode || this.busy){ - return false; - } - this.currentInterface = null; - var displayViewButton = false; - var initInterface = false; - this.mode = mode; - this.queryForm = document.getElementById(this.mode + "Form"); - for(var i = 0; i < this.tabHolder.childNodes.length; i++){ - this.tabHolder.childNodes[i].className = "leftTabEntry"; - } - this.satInterface.style.display = "none"; - this.radInterface.style.display = "none"; - this.grdInterface.style.display = "none"; - this.ascInterface.style.display = "none"; - document.getElementById(this.mode + "Tab").className = "leftTabSelected"; - switch(this.mode){ - case "satellite": - this.decodeDir = "sat/"; - this.dataDir = "tst/satellite/"; - displayViewButton = false; - this.satInterface.style.display = "block"; - this.currentInterface = new SatelliteInterface(); - if(!this.satInterfaceInit){ - this.satInterfaceInit = true; - initInterface = true; - } - break; - case "radar": - this.decodeDir = "radar/"; - this.dataDir = "tst/radar/"; - displayViewButton = false; - this.radInterface.style.display = "block"; - this.currentInterface = new RadarInterface(); - if(!this.radInterfaceInit){ - this.radInterfaceInit = true; - initInterface = true; - } - break; - case "grid": - this.decodeDir = "grib/"; - this.dataDir = "tst/grib/"; - displayViewButton = false; - this.grdInterface.style.display = "block"; - this.currentInterface = new GridInterface(); - if(!this.grdInterfaceInit){ - this.grdInterfaceInit = true; - initInterface = true; - } - break; - case "ascii": - this.decodeDir = "ascii/"; - this.dataDir = "tst/ascii/"; - displayViewButton = true; - this.ascInterface.style.display = "block" - this.currentInterface = new AsciiInterface(); - if(!this.ascInterfaceInit){ - this.ascInterfaceInit = true; - initInterface = true; - } - break; - } - if(displayViewButton){ - this.fileViewBox.value = ""; - this.fileViewButton.style.visibility = "visible"; - this.fileViewBox.style.visibility = "visible"; - } - else{ - this.fileViewButton.style.visibility = "hidden"; - this.fileViewBox.style.visibility = "hidden"; - } - if(initInterface){ - this.currentInterface.init(); - } - else{ - this.currentInterface.createScript(); - } - this.testDriverName.childNodes[0].nodeValue = this.mode.toUpperCase() + " Test Driver"; - this.getFileList(); - while(this.returnData.hasChildNodes()){ - this.returnData.removeChild(this.returnData.firstChild); - } -} - -TestDriverControls.prototype.requestData = function(){ - this.busy = true; - var scriptJs = document.getElementById("scriptInterface"); - this.currentInterface.disableControls(); - var timeout = this.currentInterface.getTimeout(); - var script = this.actionScriptBox.value; - if(script.length == 0){ - alert("No script was available to send. Please check 'Request' in the 'Request/Response Message' area."); - return false; - } - this.actionResponseBox.value = ""; - var self = this; - RequestTestDriver.requestProduct(script,timeout,scriptJs.checked,function(response){self.processDataRequest(response);}); -} - -TestDriverControls.prototype.processDataRequest = function(response){ - while(this.returnData.hasChildNodes()){ - this.returnData.removeChild(this.returnData.firstChild); - } - this.actionResponseBox.value = response["Response"]; - if(response["TYPE"] == "URI"){ - this.processURIResponse(response); - } - else if(response["TYPE"] == "XML"){ - this.processAsciiResponse(response); - } - else if(response["TYPE"] == "ERROR"){ - alert("A 'responseError' message was returned. Please look in 'Request/Response' to see the raw response."); - } - else{ - alert("The response type was " + response["TYPE"] + " which is not supported. Please look in 'Request/Response' to see the raw response."); - } - this.busy = false; - this.currentInterface.enableControls(); -} - -TestDriverControls.prototype.purgeData = function(){ - this.busy = true; - this.currentInterface.disableControls(); - var self = this; - if (!window.confirm("you are about to purge the database on " + window.location.hostname + - "\nAre you sure you want to perform this pruge?" + - "\n(Cancel to exit pruge, OK to perform purge)\n")) { - exit(); - } - RequestTestDriver.purgeDataStore(function(response){self.processPurgeRequest(response);}); -} - -TestDriverControls.prototype.processPurgeRequest = function(response){ - if(response){ - alert("Request for data purge sent successfully. Please allow thirty seconds for the purge to complete."); - } - else{ - alert("Request for data purge failed. Please check the Tomcat log for errors."); - } - this.busy = false; - this.currentInterface.enableControls(); -} - -TestDriverControls.prototype.processURIResponse = function(response){ - var uriCount = response["URICOUNT"]; - for(var i = 0; i < uriCount; i++){ - var spacer = null; - var productLocation = "/uEngineProducts/" + response["URI" + i]; - var productAnchor = document.createElement("a"); - productAnchor.setAttribute("href",productLocation); - productAnchor.setAttribute("target","_new"); - if(response["TYPE"+i] == "tiff" || response["TYPE"+i] == "kml"){ - var productName = document.createTextNode(response["URI" + i]); - productAnchor.appendChild(productName); - spacer = document.createElement("br"); - - } else{ - var productImage = document.createElement("img"); - productImage.setAttribute("src",productLocation); - productImage.setAttribute("width","200px"); - productImage.setAttribute("border","0"); - productImage.setAttribute("title",response["DATE"+i]); - productAnchor.appendChild(productImage); - spacer = document.createTextNode(" "); - } - this.returnData.appendChild(productAnchor); - this.returnData.appendChild(spacer); - } -} - -TestDriverControls.prototype.processAsciiResponse = function(response){ - for(var i = 0; i < response["XMLCOUNT"]; i++){ - var doc = null; - var spacer = document.createElement("br"); - if (window.ActiveXObject){ - doc=new ActiveXObject("Microsoft.XMLDOM"); - doc.async="false"; - doc.loadXML(response["MESSAGE" + i]); - } - else{ - var parser=new DOMParser(); - var doc=parser.parseFromString(response["MESSAGE" + i],"text/xml"); - } - var wxDoc = doc.documentElement; - var fullObs = this.traverse(wxDoc,""); - this.returnData.appendChild(fullObs); - this.returnData.appendChild(spacer); - } -} - -TestDriverControls.prototype.traverse = function(tree,title) { - if(tree.hasChildNodes()) { - var title = tree.tagName; - var baseDoc = document.createElement("ul"); - var docEntry = document.createElement("li"); - var titleText = document.createTextNode(tree.tagName + " : "); - docEntry.appendChild(titleText); - var nodes=tree.childNodes.length; - for(var i=0; i - -<% -response.setHeader("Pragma", "no-cache"); -response.setHeader("Cache-Control", "no-cache"); -response.setDateHeader("Expires", 0); -%> - - - -JS Script Test - - - - - - - - - -

μEngine Demonstration
GOES Image Retrieval

-This page contains the entire demo script. -
- -
- - - -
Enter/modify the Action JS Script into the textbox and press Submit.
- -
-
-
- - -Timeout: - -
-
-
- - From 023622a2c52f9a9a64d5a9b12e44915425a798a6 Mon Sep 17 00:00:00 2001 From: Brad Gonzales Date: Mon, 14 Apr 2014 09:40:09 -0500 Subject: [PATCH 016/188] Issue #2937 Fixed from user in xmpp message. Change-Id: I9d7ad994a3f683f2fb3dce37a71ebdcec04f4890 Former-commit-id: 67ccbb2e7eb96028137b9f82bca550bfb9e89345 --- .../detailedfeedlog/listener/DetailedFeedLogEventListener.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/javaUtilities/com.raytheon.openfire.plugin.detailedfeedlog/java/com/raytheon/openfire/plugin/detailedfeedlog/listener/DetailedFeedLogEventListener.java b/javaUtilities/com.raytheon.openfire.plugin.detailedfeedlog/java/com/raytheon/openfire/plugin/detailedfeedlog/listener/DetailedFeedLogEventListener.java index c62c14e957..e165f8046c 100644 --- a/javaUtilities/com.raytheon.openfire.plugin.detailedfeedlog/java/com/raytheon/openfire/plugin/detailedfeedlog/listener/DetailedFeedLogEventListener.java +++ b/javaUtilities/com.raytheon.openfire.plugin.detailedfeedlog/java/com/raytheon/openfire/plugin/detailedfeedlog/listener/DetailedFeedLogEventListener.java @@ -52,6 +52,7 @@ import com.raytheon.openfire.plugin.detailedfeedlog.LogEntry; * ------------ ---------- ----------- -------------------------- * Jul 25, 2012 mnash Initial creation * Apr 07, 2014 2937 bgonzale Handle errors processing room events. + * Fixed message from user. * * * @@ -98,7 +99,7 @@ public class DetailedFeedLogEventListener implements MUCEventListener { // set all the necessary values in the message to be // sent out message.setTo(user); - message.setFrom(roomJID + "/" + nickname); + message.setFrom(roomJID + "/" + sendUser); String body = HISTORY_START + entry.getDate().getTime() + "|" + sendUser + "|" + entry.getSite() + "|" From 189282166d0586b6cfd0fd6bf669fc1f3d4f448e Mon Sep 17 00:00:00 2001 From: Brad Gonzales Date: Mon, 14 Apr 2014 14:30:00 -0500 Subject: [PATCH 017/188] Issue #2937 Moved presence/site determination from feed log to feed listener. Use MUCRoom to get presence and role because UserManager is not able to understand nicnames. Change-Id: Ie27d804cfea37a27df7e3c0d4445b16f3f2c12a7 Former-commit-id: e975a825046c8d0505223093e5765d5283425b2f --- .../DetailedFeedLogPlugin.java | 59 +++---------------- .../DetailedFeedLogEventListener.java | 49 +++++++++++---- 2 files changed, 45 insertions(+), 63 deletions(-) diff --git a/javaUtilities/com.raytheon.openfire.plugin.detailedfeedlog/java/com/raytheon/openfire/plugin/detailedfeedlog/DetailedFeedLogPlugin.java b/javaUtilities/com.raytheon.openfire.plugin.detailedfeedlog/java/com/raytheon/openfire/plugin/detailedfeedlog/DetailedFeedLogPlugin.java index 8c0178c50f..6f6c214951 100644 --- a/javaUtilities/com.raytheon.openfire.plugin.detailedfeedlog/java/com/raytheon/openfire/plugin/detailedfeedlog/DetailedFeedLogPlugin.java +++ b/javaUtilities/com.raytheon.openfire.plugin.detailedfeedlog/java/com/raytheon/openfire/plugin/detailedfeedlog/DetailedFeedLogPlugin.java @@ -35,15 +35,11 @@ import java.util.Queue; import java.util.TimerTask; import java.util.concurrent.ConcurrentLinkedQueue; -import org.dom4j.Element; import org.jivesoftware.openfire.MessageRouter; import org.jivesoftware.openfire.XMPPServer; import org.jivesoftware.openfire.container.Plugin; import org.jivesoftware.openfire.container.PluginManager; import org.jivesoftware.openfire.muc.MUCEventDispatcher; -import org.jivesoftware.openfire.user.User; -import org.jivesoftware.openfire.user.UserManager; -import org.jivesoftware.openfire.user.UserNotFoundException; import org.jivesoftware.util.JiveGlobals; import org.jivesoftware.util.Log; import org.jivesoftware.util.PropertyEventDispatcher; @@ -51,13 +47,15 @@ import org.jivesoftware.util.PropertyEventListener; import org.jivesoftware.util.TaskEngine; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import org.xmpp.packet.Message; -import org.xmpp.packet.Presence; import com.raytheon.openfire.plugin.detailedfeedlog.listener.DetailedFeedLogEventListener; /** - * Plugin that logs and purges qualifying packets in Openfire + * Plugin that logs and purges qualifying packets in Openfire. + * + * This plugin handles logging history so to prevent conflicting messages, the + * group chat history settings need to be turned off on the Openfire server. + * Group Chat > Group Chat Setting > History Settings > Don't Show History * *
  * 
@@ -73,6 +71,7 @@ import com.raytheon.openfire.plugin.detailedfeedlog.listener.DetailedFeedLogEven
  * Apr 07, 2014 2937       bgonzale    Use new LogEntry toString and fromString methods
  *                                     and changed error handling to log each bad line.
  *                                     Create new DateFormatter for the purge thread.
+ *                                     Moved presence/site determination out of log method.
  * 
  * 
* @@ -116,8 +115,6 @@ public class DetailedFeedLogPlugin implements Plugin, PropertyEventListener { private DetailedFeedLogEventListener feedListener; - public static final String SITE_INFO = "Site"; - private static final String ROOM_DIR = "Rooms"; private static final String DATE_FORMAT_STR = "MM/dd/yyyy h:mm a"; @@ -227,27 +224,6 @@ public class DetailedFeedLogPlugin implements Plugin, PropertyEventListener { } } - /** - * Log a message - * - * @param message - */ - public static void log(Message message, String room) { - User user = null; - try { - user = UserManager.getInstance().getUser( - message.getFrom().getResource()); - } catch (UserNotFoundException e) { - logger.error("Unable to get user for Room: " + room - + " and Message: " + message.toXML(), e); - } - - String site = getSiteFromPresence(user); - - // format it with the site so the site can be sent with the packet later - log(user.getUsername(), site, message.getBody(), room); - } - /** * To log in openfire * @@ -255,7 +231,7 @@ public class DetailedFeedLogPlugin implements Plugin, PropertyEventListener { * - fqname * @param message */ - private static void log(String user, String site, String message, + public static void log(String user, String site, String message, String room) { logger.info("Logging : " + user + " \"" + message + "\""); Date date = new Date(); @@ -290,27 +266,6 @@ public class DetailedFeedLogPlugin implements Plugin, PropertyEventListener { entries.remove(room); } - private static String getSiteFromPresence(User user) { - Presence presence = XMPPServer.getInstance().getPresenceManager() - .getPresence(user); - - // need to get the site from the presence, add that to the text that we - // log, and use that for filtering on the client side - Element props = presence.getChildElement("properties", - "http://www.jivesoftware.com/xmlns/xmpp/properties"); - String site = null; - for (Object propObj : props.elements("property")) { - Element prop = (Element) propObj; - String name = prop.elementText("name"); - String value = prop.elementText("value"); - if (SITE_INFO.equals(name)) { - site = value; - break; - } - } - return site; - } - /** * Write out the current in memory log to a file */ diff --git a/javaUtilities/com.raytheon.openfire.plugin.detailedfeedlog/java/com/raytheon/openfire/plugin/detailedfeedlog/listener/DetailedFeedLogEventListener.java b/javaUtilities/com.raytheon.openfire.plugin.detailedfeedlog/java/com/raytheon/openfire/plugin/detailedfeedlog/listener/DetailedFeedLogEventListener.java index e165f8046c..8cf396e7c8 100644 --- a/javaUtilities/com.raytheon.openfire.plugin.detailedfeedlog/java/com/raytheon/openfire/plugin/detailedfeedlog/listener/DetailedFeedLogEventListener.java +++ b/javaUtilities/com.raytheon.openfire.plugin.detailedfeedlog/java/com/raytheon/openfire/plugin/detailedfeedlog/listener/DetailedFeedLogEventListener.java @@ -22,19 +22,19 @@ package com.raytheon.openfire.plugin.detailedfeedlog.listener; import java.util.Queue; import java.util.TimerTask; +import org.dom4j.Element; import org.jivesoftware.openfire.MessageRouter; import org.jivesoftware.openfire.XMPPServer; import org.jivesoftware.openfire.muc.MUCEventListener; +import org.jivesoftware.openfire.muc.MUCRole; import org.jivesoftware.openfire.muc.MUCRoom; -import org.jivesoftware.openfire.user.User; -import org.jivesoftware.openfire.user.UserManager; -import org.jivesoftware.openfire.user.UserNotFoundException; import org.jivesoftware.util.TaskEngine; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.xmpp.packet.JID; import org.xmpp.packet.Message; import org.xmpp.packet.Message.Type; +import org.xmpp.packet.Presence; import com.raytheon.openfire.plugin.detailedfeedlog.DetailedFeedLogPlugin; import com.raytheon.openfire.plugin.detailedfeedlog.LogEntry; @@ -53,7 +53,10 @@ import com.raytheon.openfire.plugin.detailedfeedlog.LogEntry; * Jul 25, 2012 mnash Initial creation * Apr 07, 2014 2937 bgonzale Handle errors processing room events. * Fixed message from user. - * + * Added getSiteFromPresence. Use + * MUCRoom to get presence and role + * because UserManager is not able to + * understand nicknames. * * * @author mnash @@ -73,6 +76,8 @@ public class DetailedFeedLogEventListener implements MUCEventListener { // this tag will tell CAVE that this is a history message private static final String HISTORY_START = "[[HISTORY]]"; + private static final String SITE_INFO = "Site"; + /** * When the occupant joins, we want to send out the history to them. This * only happens in the permanent feed room. @@ -85,17 +90,14 @@ public class DetailedFeedLogEventListener implements MUCEventListener { TimerTask messageTask = new TimerTask() { @Override public void run() { - UserManager userManager = UserManager.getInstance(); Queue log = DetailedFeedLogPlugin.getLog(roomJID .getNode()); for (LogEntry entry : log) { Message message = new Message(); message.setTo(roomJID + "/" + nickname); - String usr = entry.getUsername(); + String sendUser = entry.getUsername(); try { - User sendUser = userManager - .getUser(entry.getUser()); // set all the necessary values in the message to be // sent out message.setTo(user); @@ -110,8 +112,6 @@ public class DetailedFeedLogEventListener implements MUCEventListener { router.route(message); logger.info("Routed message : " + message.getBody() + " from " + sendUser + " to " + user); - } catch (UserNotFoundException e) { - logger.error(usr + " not found", e); } catch (ArrayIndexOutOfBoundsException e) { logger.error( "Failed to parse log history for Routing. Bad Entry was date: " @@ -135,11 +135,38 @@ public class DetailedFeedLogEventListener implements MUCEventListener { Message message) { if (isLoggedRoom(roomJID)) { if (message.getBody().startsWith(COMMAND_START) == false) { - DetailedFeedLogPlugin.log(message, roomJID.getNode()); + MUCRoom mucRoom = XMPPServer.getInstance() + .getMultiUserChatManager() + .getMultiUserChatService(roomJID) + .getChatRoom(roomJID.getNode()); + MUCRole role = mucRoom.getOccupantByFullJID(user); + DetailedFeedLogPlugin.log(role.getNickname(), + getSiteFromPresence(role.getPresence()), + message.getBody(), + roomJID.getNode()); } } } + private String getSiteFromPresence(Presence presence) { + // need to get the site from the presence, add that to the text that we + // log, and use that for filtering on the client side + Element props = presence.getChildElement("properties", + "http://www.jivesoftware.com/xmlns/xmpp/properties"); + String site = null; + for (Object propObj : props.elements("property")) { + Element prop = (Element) propObj; + String name = prop.elementText("name"); + String value = prop.elementText("value"); + if (SITE_INFO.equals(name)) { + site = value; + break; + } + } + return site; + } + + /** * Determine if this is the room that we want to log for here * From 02e801b359271f67d952c11e2242821911da73f8 Mon Sep 17 00:00:00 2001 From: Matt Nash Date: Mon, 14 Apr 2014 14:48:24 -0500 Subject: [PATCH 018/188] Issue #3019 modify JUtil to support sets and frozensets Change-Id: Ia72d8c1670c0adb1529937b1943fa9e2d1195692 Former-commit-id: 795cba334038d920beab93f5c872b02acf29c7f9 --- .../common_static/base/python/JUtilHandler.py | 45 ++++++++++++++----- 1 file changed, 34 insertions(+), 11 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.python/utility/common_static/base/python/JUtilHandler.py b/edexOsgi/com.raytheon.uf.common.python/utility/common_static/base/python/JUtilHandler.py index 7fef449aa2..1ae332971f 100644 --- a/edexOsgi/com.raytheon.uf.common.python/utility/common_static/base/python/JUtilHandler.py +++ b/edexOsgi/com.raytheon.uf.common.python/utility/common_static/base/python/JUtilHandler.py @@ -171,7 +171,7 @@ fallbackBasics = OrderedDict({Number:_toPythonFloat}) The following methods will handle Python and Java collection conversion. ''' from java.lang import Object -from java.util import Collections, HashMap, LinkedHashMap, ArrayList +from java.util import Collections, HashMap, LinkedHashMap, ArrayList, HashSet from java.util import Date from java.lang.reflect import Array from java.util import List, Set, Map @@ -226,23 +226,24 @@ def _toPythonDict(obj, customConverter=None): ''' Converts to a Python dict. ''' - return __toPythonDict(obj, {}, customConverter) + return __toPythonDictInternal(obj, {}, customConverter) def _toPythonSet(obj, customConverter=None): ''' Converts to a Python set. ''' retVal = set() - size = obj.size() - for i in range(size): - retVal.add(JUtil.javaObjToPyVal(obj.get(i), customConverter)) + itr = obj.iterator() + while itr.hasNext(): + val = itr.next() + retVal.add(JUtil.javaObjToPyVal(val, customConverter)) return retVal def _toPythonOrderedDict(obj, customConverter=None): ''' Converts to a Python OrderedDict. ''' - return __toPythonDict(obj, OrderedDict(), customConverter) + return __toPythonDictInternal(obj, OrderedDict(), customConverter) def _fromJavaArray(obj, customConverter=None): ''' @@ -264,7 +265,7 @@ def _fromJepArray(obj, customConverter=None): retVal.append(JUtil.javaObjToPyVal(obj[i], customConverter)) return retVal -def __toPythonDict(javaMap, pyDict, customConverter=None): +def __toPythonDictInternal(javaMap, pyDict, customConverter=None): ''' Converts to a Python dict. Passed in the dict type, and then handles the key conversion. ''' @@ -311,15 +312,37 @@ def _toJavaLinkedMap(val): ''' Turns a Python OrderedDict to a Java LinkedHashMap ''' - return __toJavaMap(val, LinkedHashMap()) + return __toJavaMapInternal(val, LinkedHashMap()) def _toJavaMap(val): ''' Turns a Python dict to a Java HashMap ''' - return __toJavaMap(val, HashMap()) + return __toJavaMapInternal(val, HashMap()) -def __toJavaMap(pyDict, jmap): +def _toJavaSet(val): + ''' + Turns a Python set to a Java set + ''' + return __toJavaSetInternal(val) + +def _toJavaUnmodifiableSet(val): + ''' + Turns a Python frozenset to a Java unmodifiableset + ''' + return Collections.unmodifiableSet(__toJavaSetInternal(val)) + +def __toJavaSetInternal(val): + ''' + Does the actual conversion of the elements inside of the set or frozenset to Set + ''' + retObj = HashSet() + for v in val : + retObj.add(JUtil.pyValToJavaObj(v)) + return retObj + + +def __toJavaMapInternal(pyDict, jmap): ''' Does the actual conversion of the elements inside of the dict to Map ''' @@ -328,7 +351,7 @@ def __toJavaMap(pyDict, jmap): return jmap javaCollections = OrderedDict({'java.util.ArrayList':_toPythonList, 'java.util.Arrays$ArrayList':_toPythonList, 'java.util.Collections$UnmodifiableRandomAccessList':_toPythonTuple, 'java.util.HashMap':_toPythonDict, 'java.util.LinkedHashMap':_toPythonOrderedDict}) -pythonCollections = OrderedDict({ list:_toJavaList, tuple:_toJavaUnmodifiableList, OrderedDict:_toJavaLinkedMap, dict:_toJavaMap }) +pythonCollections = OrderedDict({ list:_toJavaList, tuple:_toJavaUnmodifiableList, OrderedDict:_toJavaLinkedMap, dict:_toJavaMap, set:_toJavaSet, frozenset:_toJavaUnmodifiableSet }) fallbackCollections = OrderedDict({ List:_toPythonList, Map:_toPythonDict, Set:_toPythonSet }) ''' From 6e2d68e10239b9dcd20149ec08fde02e719b6e6c Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Mon, 14 Apr 2014 16:28:26 -0500 Subject: [PATCH 019/188] Issue #2984 remove unnecessary plugins from features remove unnecessary uengine dependencies from manifests Change-Id: Ic76eb5faa4b14cb4ea133ab74532bacd1a05c23d Former-commit-id: c59a5d99ce31464bacd7c266543f10f523719a07 --- .../feature.xml | 7 ------- .../feature.xml | 13 ------------- .../META-INF/MANIFEST.MF | 1 - .../uengine/tasks/radar/DecodeRadarImage.java | 15 +++++---------- .../META-INF/MANIFEST.MF | 3 +-- .../META-INF/MANIFEST.MF | 3 +-- .../META-INF/MANIFEST.MF | 3 +-- .../gpd/query/GenericPointDataQuery.java | 7 +++---- .../META-INF/MANIFEST.MF | 1 - .../META-INF/MANIFEST.MF | 1 - .../META-INF/MANIFEST.MF | 1 - 11 files changed, 11 insertions(+), 44 deletions(-) diff --git a/cave/com.raytheon.uf.viz.dataplugin.obs.feature/feature.xml b/cave/com.raytheon.uf.viz.dataplugin.obs.feature/feature.xml index 66481fea61..6325da8b55 100644 --- a/cave/com.raytheon.uf.viz.dataplugin.obs.feature/feature.xml +++ b/cave/com.raytheon.uf.viz.dataplugin.obs.feature/feature.xml @@ -22,13 +22,6 @@ - - - - - - * */ -public class DecodeRadarImage extends ScriptTask { +@Deprecated +public class DecodeRadarImage { - private static final IUFStatusHandler handler = UFStatus.getHandler(DecodeRadarImage.class); + private static final IUFStatusHandler handler = UFStatus + .getHandler(DecodeRadarImage.class); private RadarRecord radarRecord; @@ -75,12 +76,6 @@ public class DecodeRadarImage extends ScriptTask { geometry = radarTiler.constructGridGeometry(); } - /* - * (non-Javadoc) - * - * @see com.raytheon.edex.uengine.js.tasks.ScriptTask#execute() - */ - @Override public byte[] execute() { byte[] bi = null; diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.qc/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.plugin.qc/META-INF/MANIFEST.MF index 412794d00c..46d5912f4e 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.qc/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.plugin.qc/META-INF/MANIFEST.MF @@ -15,7 +15,6 @@ Require-Bundle: com.raytheon.edex.common;bundle-version="1.11.17", javax.persistence;bundle-version="1.0.0", ucar.nc2;bundle-version="1.0.0" Export-Package: com.raytheon.uf.edex.plugin.qc.common -Import-Package: com.raytheon.edex.uengine.tasks.query, - com.raytheon.uf.common.message.response, +Import-Package: com.raytheon.uf.common.message.response, com.raytheon.uf.common.status, org.apache.commons.logging diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.satellite.mcidas/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.plugin.satellite.mcidas/META-INF/MANIFEST.MF index 9931669e57..b2771eb115 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.satellite.mcidas/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.plugin.satellite.mcidas/META-INF/MANIFEST.MF @@ -14,8 +14,7 @@ Require-Bundle: com.raytheon.edex.common, com.raytheon.uf.common.dataplugin.satellite;bundle-version="1.0.0", com.raytheon.edex.plugin.satellite;bundle-version="1.12.1174" Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -Import-Package: com.raytheon.edex.uengine.tasks.query, - com.raytheon.uf.common.localization, +Import-Package: com.raytheon.uf.common.localization, com.raytheon.uf.common.menus, com.raytheon.uf.common.menus.xml, com.raytheon.uf.common.status diff --git a/ncep/gov.noaa.nws.ncep.common.dataplugin.gpd/META-INF/MANIFEST.MF b/ncep/gov.noaa.nws.ncep.common.dataplugin.gpd/META-INF/MANIFEST.MF index a47e6be5ba..15e7cc558a 100644 --- a/ncep/gov.noaa.nws.ncep.common.dataplugin.gpd/META-INF/MANIFEST.MF +++ b/ncep/gov.noaa.nws.ncep.common.dataplugin.gpd/META-INF/MANIFEST.MF @@ -10,8 +10,7 @@ Require-Bundle: com.raytheon.edex.common;bundle-version="1.12.1174", com.raytheon.uf.common.parameter;bundle-version="1.0.0", com.raytheon.uf.common.dataplugin.level;bundle-version="1.12.1174", com.raytheon.uf.common.status;bundle-version="1.12.1174" -Import-Package: com.raytheon.edex.uengine.tasks.query, - com.raytheon.uf.common.pointdata, +Import-Package: com.raytheon.uf.common.pointdata, com.raytheon.uf.common.serialization.comm, com.raytheon.uf.edex.pointdata, org.apache.commons.logging diff --git a/ncep/gov.noaa.nws.ncep.common.dataplugin.gpd/src/gov/noaa/nws/ncep/common/dataplugin/gpd/query/GenericPointDataQuery.java b/ncep/gov.noaa.nws.ncep.common.dataplugin.gpd/src/gov/noaa/nws/ncep/common/dataplugin/gpd/query/GenericPointDataQuery.java index e55e603f4b..ac8d6c0d9d 100644 --- a/ncep/gov.noaa.nws.ncep.common.dataplugin.gpd/src/gov/noaa/nws/ncep/common/dataplugin/gpd/query/GenericPointDataQuery.java +++ b/ncep/gov.noaa.nws.ncep.common.dataplugin.gpd/src/gov/noaa/nws/ncep/common/dataplugin/gpd/query/GenericPointDataQuery.java @@ -7,8 +7,9 @@ * SOFTWARE HISTORY * * Date Ticket# Engineer Description - * ------- ------- -------- ----------- - * 05/30/2013 Chin J. Chen Initial coding + * ------- ------- -------- ----------- + * 05/30/2013 Chin J. Chen Initial coding + * 04/14/2014 2984 njensen Remove unused uengine dependency * * * @@ -25,7 +26,6 @@ import java.util.HashSet; import java.util.List; import java.util.Map; -import com.raytheon.edex.uengine.tasks.query.TableQuery; import com.raytheon.uf.common.dataplugin.PluginException; import com.raytheon.uf.common.datastorage.records.FloatDataRecord; import com.raytheon.uf.common.datastorage.records.IDataRecord; @@ -41,7 +41,6 @@ import com.raytheon.uf.edex.pointdata.PointDataQuery; public class GenericPointDataQuery extends PointDataQuery { - protected TableQuery tq; public GenericPointDataQuery(String plugin) throws DataAccessLayerException, PluginException { super(plugin); diff --git a/ncep/gov.noaa.nws.ncep.common.dataplugin.mcidas/META-INF/MANIFEST.MF b/ncep/gov.noaa.nws.ncep.common.dataplugin.mcidas/META-INF/MANIFEST.MF index b98cf6da91..f4da11c2a4 100644 --- a/ncep/gov.noaa.nws.ncep.common.dataplugin.mcidas/META-INF/MANIFEST.MF +++ b/ncep/gov.noaa.nws.ncep.common.dataplugin.mcidas/META-INF/MANIFEST.MF @@ -14,7 +14,6 @@ Require-Bundle: com.raytheon.edex.common;bundle-version="1.11.17", javax.measure;bundle-version="1.0.0", org.apache.commons.lang;bundle-version="2.3.0", javax.persistence;bundle-version="1.0.0", - com.raytheon.edex.uengine;bundle-version="1.11.17", org.apache.commons.codec;bundle-version="1.3.0", edu.wisc.ssec.mcidas;bundle-version="1.0.0", com.raytheon.uf.common.numeric;bundle-version="1.14.0" diff --git a/ncep/gov.noaa.nws.ncep.viz.rsc.satellite/META-INF/MANIFEST.MF b/ncep/gov.noaa.nws.ncep.viz.rsc.satellite/META-INF/MANIFEST.MF index ae8bd1e1d2..a5fb99995c 100644 --- a/ncep/gov.noaa.nws.ncep.viz.rsc.satellite/META-INF/MANIFEST.MF +++ b/ncep/gov.noaa.nws.ncep.viz.rsc.satellite/META-INF/MANIFEST.MF @@ -17,7 +17,6 @@ Require-Bundle: org.eclipse.ui, com.raytheon.viz.ui, javax.measure;bundle-version="1.0.0", javax.persistence;bundle-version="1.0.0", - com.raytheon.edex.uengine;bundle-version="1.11.17", org.apache.commons.lang, org.geotools, com.raytheon.uf.common.colormap;bundle-version="1.11.7", diff --git a/ost/gov.noaa.nws.ost.edex.plugin.regionalsat/META-INF/MANIFEST.MF b/ost/gov.noaa.nws.ost.edex.plugin.regionalsat/META-INF/MANIFEST.MF index bfbcf1bd2e..4ba2227cec 100644 --- a/ost/gov.noaa.nws.ost.edex.plugin.regionalsat/META-INF/MANIFEST.MF +++ b/ost/gov.noaa.nws.ost.edex.plugin.regionalsat/META-INF/MANIFEST.MF @@ -15,7 +15,6 @@ Require-Bundle: com.raytheon.edex.common, ucar.nc2;bundle-version="1.0.0" Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Import-Package: - com.raytheon.edex.uengine.tasks.query, com.raytheon.edex.util.satellite, com.raytheon.uf.common.dataplugin.satellite, com.raytheon.uf.common.localization, From 8d5486d1ff81ac000bd87031de6884ef8f67adcf Mon Sep 17 00:00:00 2001 From: Mike Duff Date: Mon, 14 Apr 2014 15:39:38 -0500 Subject: [PATCH 020/188] Issue #2907 - Rename com.raytheon.edex.dataplugin.redbook to com.raytheon.uf.edex.dataplugin.redbook Change-Id: I375877b285671ef7a4d993b4c16ee3437fd0a32a Former-commit-id: 4d37938e12c7803af84713f3e009f7e4f37f9c0d --- .../.classpath | 0 .../.project | 2 +- .../.settings/org.eclipse.jdt.core.prefs | 0 .../Documentation/SampleFiles/ReadMe | 0 .../Documentation/SampleFiles/RedbookCPCMenus.xml | 0 .../Documentation/SampleFiles/RedbookHPCMenus.xml | 0 .../SampleFiles/RedbookHazardMenus.xml | 0 .../Documentation/SampleFiles/RedbookMPCMenus.xml | 0 .../Documentation/SampleFiles/RedbookNCOMenus.xml | 0 .../Documentation/SampleFiles/RedbookUAMenus.xml | 0 .../META-INF/MANIFEST.MF | 6 +++--- .../build.properties | 0 .../com.raytheon.edex.plugin.redbook.ecl | 0 .../res/spring/redbook-common.xml | 4 ++-- .../res/spring/redbook-ingest.xml | 4 ++-- .../uf}/edex/plugin/redbook/RedbookDecoder.java | 6 +++--- .../uf}/edex/plugin/redbook/RedbookSeparator.java | 2 +- .../uf}/edex/plugin/redbook/dao/RedbookDao.java | 2 +- .../plugin/redbook/decoder/RedbookFcstMap.java | 2 +- .../edex/plugin/redbook/decoder/RedbookParser.java | 2 +- .../redbook/ingest/RedbookMenuSubscriber.java | 14 +++++++------- .../edex/plugin/redbook/ingest/xml/MenuEntry.java | 2 +- .../plugin/redbook/ingest/xml/MenuEntryType.java | 2 +- .../plugin/redbook/ingest/xml/RedbookMenusXML.java | 2 +- .../plugin/redbook/menu/RedbookCpcMenuUtil.java | 2 +- .../redbook/menu/RedbookHazardsMenuUtil.java | 2 +- .../plugin/redbook/menu/RedbookHpcMenuUtil.java | 2 +- .../edex/plugin/redbook/menu/RedbookMenuUtil.java | 8 ++++---- .../plugin/redbook/menu/RedbookMpcMenuUtil.java | 2 +- .../plugin/redbook/menu/RedbookNcoMenuUtil.java | 2 +- .../plugin/redbook/menu/RedbookUaMenuUtil.java | 2 +- .../common_static/base/path/redbookPathKeys.xml | 0 .../common_static/base/purge/redbookPurgeRules.xml | 0 .../edex_static/base/distribution/redbook.xml | 0 .../edex_static/base/redbook/redbookFcstMap.xml | 0 .../build.xml | 6 +++--- .../feature.xml | 2 +- tests/.classpath | 2 +- .../Redbook/PMNA01_KWNS_220049_47355211.rb.Result | 2 +- .../Redbook/PSBB08_KWNH_220000_46836601.rb.Result | 2 +- .../Redbook/PYMA20_KWBC_220000_47396312.rb.Result | 2 +- tests/resources/res/conf/RedbookBlocks.properties | 8 ++++---- .../serialization/TestJaxbableClassesLocator.java | 2 +- .../edex/plugin/redbook/RedbookDecoderTest.java | 5 +++-- 44 files changed, 51 insertions(+), 50 deletions(-) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/.classpath (100%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/.project (92%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/.settings/org.eclipse.jdt.core.prefs (100%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/Documentation/SampleFiles/ReadMe (100%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/Documentation/SampleFiles/RedbookCPCMenus.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/Documentation/SampleFiles/RedbookHPCMenus.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/Documentation/SampleFiles/RedbookHazardMenus.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/Documentation/SampleFiles/RedbookMPCMenus.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/Documentation/SampleFiles/RedbookNCOMenus.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/Documentation/SampleFiles/RedbookUAMenus.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/META-INF/MANIFEST.MF (81%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/build.properties (100%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/com.raytheon.edex.plugin.redbook.ecl (100%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/res/spring/redbook-common.xml (83%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/res/spring/redbook-ingest.xml (93%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/RedbookDecoder.java (98%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/RedbookSeparator.java (98%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/dao/RedbookDao.java (98%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/decoder/RedbookFcstMap.java (98%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/decoder/RedbookParser.java (99%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/ingest/RedbookMenuSubscriber.java (89%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/ingest/xml/MenuEntry.java (99%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/ingest/xml/MenuEntryType.java (97%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/ingest/xml/RedbookMenusXML.java (97%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/menu/RedbookCpcMenuUtil.java (97%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/menu/RedbookHazardsMenuUtil.java (98%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/menu/RedbookHpcMenuUtil.java (97%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/menu/RedbookMenuUtil.java (97%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/menu/RedbookMpcMenuUtil.java (97%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/menu/RedbookNcoMenuUtil.java (97%) rename edexOsgi/{com.raytheon.edex.plugin.redbook/src/com/raytheon => com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf}/edex/plugin/redbook/menu/RedbookUaMenuUtil.java (97%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/utility/common_static/base/path/redbookPathKeys.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/utility/common_static/base/purge/redbookPurgeRules.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/utility/edex_static/base/distribution/redbook.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.redbook => com.raytheon.uf.edex.dataplugin.redbook}/utility/edex_static/base/redbook/redbookFcstMap.xml (100%) rename tests/unit/com/raytheon/{ => uf}/edex/plugin/redbook/RedbookDecoderTest.java (97%) diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/.classpath b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/.classpath similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/.classpath rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/.classpath diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/.project b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/.project similarity index 92% rename from edexOsgi/com.raytheon.edex.plugin.redbook/.project rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/.project index 15ff33f375..c4aac51892 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/.project +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/.project @@ -1,6 +1,6 @@ - com.raytheon.edex.plugin.redbook + com.raytheon.uf.edex.plugin.redbook diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/.settings/org.eclipse.jdt.core.prefs b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/.settings/org.eclipse.jdt.core.prefs similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/.settings/org.eclipse.jdt.core.prefs rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/.settings/org.eclipse.jdt.core.prefs diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/Documentation/SampleFiles/ReadMe b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/ReadMe similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/Documentation/SampleFiles/ReadMe rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/ReadMe diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/Documentation/SampleFiles/RedbookCPCMenus.xml b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookCPCMenus.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/Documentation/SampleFiles/RedbookCPCMenus.xml rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookCPCMenus.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/Documentation/SampleFiles/RedbookHPCMenus.xml b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookHPCMenus.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/Documentation/SampleFiles/RedbookHPCMenus.xml rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookHPCMenus.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/Documentation/SampleFiles/RedbookHazardMenus.xml b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookHazardMenus.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/Documentation/SampleFiles/RedbookHazardMenus.xml rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookHazardMenus.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/Documentation/SampleFiles/RedbookMPCMenus.xml b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookMPCMenus.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/Documentation/SampleFiles/RedbookMPCMenus.xml rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookMPCMenus.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/Documentation/SampleFiles/RedbookNCOMenus.xml b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookNCOMenus.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/Documentation/SampleFiles/RedbookNCOMenus.xml rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookNCOMenus.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/Documentation/SampleFiles/RedbookUAMenus.xml b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookUAMenus.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/Documentation/SampleFiles/RedbookUAMenus.xml rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookUAMenus.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/META-INF/MANIFEST.MF similarity index 81% rename from edexOsgi/com.raytheon.edex.plugin.redbook/META-INF/MANIFEST.MF rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/META-INF/MANIFEST.MF index dd73487ef7..1dbdd18505 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/META-INF/MANIFEST.MF @@ -1,7 +1,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Redbook Plug-in -Bundle-SymbolicName: com.raytheon.edex.plugin.redbook +Bundle-SymbolicName: com.raytheon.uf.edex.plugin.redbook Bundle-Version: 1.14.0.qualifier Eclipse-RegisterBuddy: com.raytheon.edex.common, com.raytheon.uf.common.serialization Bundle-Vendor: RAYTHEON @@ -13,6 +13,6 @@ Require-Bundle: com.raytheon.edex.common, com.raytheon.uf.edex.ndm;bundle-version="1.14.0", com.raytheon.uf.edex.menus;bundle-version="1.0.0", com.raytheon.uf.common.dataplugin.redbook;bundle-version="1.14.0" -Export-Package: com.raytheon.edex.plugin.redbook, - com.raytheon.edex.plugin.redbook.decoder +Export-Package: com.raytheon.uf.edex.plugin.redbook, + com.raytheon.uf.edex.plugin.redbook.decoder Bundle-RequiredExecutionEnvironment: JavaSE-1.6 diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/build.properties b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/build.properties similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/build.properties rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/build.properties diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/com.raytheon.edex.plugin.redbook.ecl b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/com.raytheon.edex.plugin.redbook.ecl similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/com.raytheon.edex.plugin.redbook.ecl rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/com.raytheon.edex.plugin.redbook.ecl diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/res/spring/redbook-common.xml b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/res/spring/redbook-common.xml similarity index 83% rename from edexOsgi/com.raytheon.edex.plugin.redbook/res/spring/redbook-common.xml rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/res/spring/redbook-common.xml index 11dcc70fb0..d46d088fc1 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/res/spring/redbook-common.xml +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/res/spring/redbook-common.xml @@ -8,8 +8,8 @@ - - + + diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/res/spring/redbook-ingest.xml b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/res/spring/redbook-ingest.xml similarity index 93% rename from edexOsgi/com.raytheon.edex.plugin.redbook/res/spring/redbook-ingest.xml rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/res/spring/redbook-ingest.xml index 96a29588a0..7940f30cac 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/res/spring/redbook-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/res/spring/redbook-ingest.xml @@ -3,7 +3,7 @@ xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd"> - + @@ -13,7 +13,7 @@ - + diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/RedbookDecoder.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/RedbookDecoder.java similarity index 98% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/RedbookDecoder.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/RedbookDecoder.java index a65a0b9ea9..fb97406918 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/RedbookDecoder.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/RedbookDecoder.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook; +package com.raytheon.uf.edex.plugin.redbook; import java.util.ArrayList; import java.util.Date; @@ -25,8 +25,6 @@ import java.util.Date; import com.raytheon.edex.esb.Headers; import com.raytheon.edex.exception.DecoderException; import com.raytheon.edex.plugin.AbstractDecoder; -import com.raytheon.edex.plugin.redbook.dao.RedbookDao; -import com.raytheon.edex.plugin.redbook.decoder.RedbookParser; import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.common.dataplugin.PluginException; import com.raytheon.uf.common.dataplugin.redbook.RedbookRecord; @@ -37,6 +35,8 @@ import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.time.util.ITimer; import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.edex.database.plugin.PluginFactory; +import com.raytheon.uf.edex.plugin.redbook.dao.RedbookDao; +import com.raytheon.uf.edex.plugin.redbook.decoder.RedbookParser; import com.raytheon.uf.edex.wmo.message.WMOHeader; /** diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/RedbookSeparator.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/RedbookSeparator.java similarity index 98% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/RedbookSeparator.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/RedbookSeparator.java index 53f2d82a37..d8eb5248b7 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/RedbookSeparator.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/RedbookSeparator.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook; +package com.raytheon.uf.edex.plugin.redbook; import java.util.ArrayList; import java.util.List; diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/dao/RedbookDao.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/dao/RedbookDao.java similarity index 98% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/dao/RedbookDao.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/dao/RedbookDao.java index ef91f971af..adc687058d 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/dao/RedbookDao.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/dao/RedbookDao.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook.dao; +package com.raytheon.uf.edex.plugin.redbook.dao; import java.io.FileNotFoundException; import java.util.List; diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/decoder/RedbookFcstMap.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookFcstMap.java similarity index 98% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/decoder/RedbookFcstMap.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookFcstMap.java index 701489756a..8ff233403f 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/decoder/RedbookFcstMap.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookFcstMap.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook.decoder; +package com.raytheon.uf.edex.plugin.redbook.decoder; import java.util.HashMap; diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/decoder/RedbookParser.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookParser.java similarity index 99% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/decoder/RedbookParser.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookParser.java index 4477bd6162..68e605571e 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/decoder/RedbookParser.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookParser.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook.decoder; +package com.raytheon.uf.edex.plugin.redbook.decoder; import java.nio.BufferUnderflowException; import java.nio.ByteBuffer; diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/ingest/RedbookMenuSubscriber.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/RedbookMenuSubscriber.java similarity index 89% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/ingest/RedbookMenuSubscriber.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/RedbookMenuSubscriber.java index e2dad64468..2c6e47864c 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/ingest/RedbookMenuSubscriber.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/RedbookMenuSubscriber.java @@ -17,19 +17,19 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook.ingest; +package com.raytheon.uf.edex.plugin.redbook.ingest; import java.io.File; -import com.raytheon.edex.plugin.redbook.menu.RedbookCpcMenuUtil; -import com.raytheon.edex.plugin.redbook.menu.RedbookHazardsMenuUtil; -import com.raytheon.edex.plugin.redbook.menu.RedbookHpcMenuUtil; -import com.raytheon.edex.plugin.redbook.menu.RedbookMpcMenuUtil; -import com.raytheon.edex.plugin.redbook.menu.RedbookNcoMenuUtil; -import com.raytheon.edex.plugin.redbook.menu.RedbookUaMenuUtil; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.edex.ndm.ingest.INationalDatasetSubscriber; +import com.raytheon.uf.edex.plugin.redbook.menu.RedbookCpcMenuUtil; +import com.raytheon.uf.edex.plugin.redbook.menu.RedbookHazardsMenuUtil; +import com.raytheon.uf.edex.plugin.redbook.menu.RedbookHpcMenuUtil; +import com.raytheon.uf.edex.plugin.redbook.menu.RedbookMpcMenuUtil; +import com.raytheon.uf.edex.plugin.redbook.menu.RedbookNcoMenuUtil; +import com.raytheon.uf.edex.plugin.redbook.menu.RedbookUaMenuUtil; /** * Redbook menu subscriber. Takes redbook menu files and passes them to the diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/ingest/xml/MenuEntry.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntry.java similarity index 99% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/ingest/xml/MenuEntry.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntry.java index 54bde87e7c..7a08a9b1ce 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/ingest/xml/MenuEntry.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntry.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook.ingest.xml; +package com.raytheon.uf.edex.plugin.redbook.ingest.xml; import java.util.ArrayList; import java.util.List; diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/ingest/xml/MenuEntryType.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntryType.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/ingest/xml/MenuEntryType.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntryType.java index 42dfe99660..05a9426e36 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/ingest/xml/MenuEntryType.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntryType.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook.ingest.xml; +package com.raytheon.uf.edex.plugin.redbook.ingest.xml; import javax.xml.bind.annotation.XmlEnum; import javax.xml.bind.annotation.XmlEnumValue; diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/ingest/xml/RedbookMenusXML.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/RedbookMenusXML.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/ingest/xml/RedbookMenusXML.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/RedbookMenusXML.java index 85d9bd5fde..1aeba28642 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/ingest/xml/RedbookMenusXML.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/RedbookMenusXML.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook.ingest.xml; +package com.raytheon.uf.edex.plugin.redbook.ingest.xml; import java.util.ArrayList; import java.util.List; diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookCpcMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookCpcMenuUtil.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookCpcMenuUtil.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookCpcMenuUtil.java index 94ffd157c3..7411bf4c07 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookCpcMenuUtil.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookCpcMenuUtil.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook.menu; +package com.raytheon.uf.edex.plugin.redbook.menu; import java.io.File; diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookHazardsMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHazardsMenuUtil.java similarity index 98% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookHazardsMenuUtil.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHazardsMenuUtil.java index 59e525c1a4..1394bc99c2 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookHazardsMenuUtil.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHazardsMenuUtil.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook.menu; +package com.raytheon.uf.edex.plugin.redbook.menu; import java.io.File; diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookHpcMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHpcMenuUtil.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookHpcMenuUtil.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHpcMenuUtil.java index 1a3ad5138b..cad4438bbf 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookHpcMenuUtil.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHpcMenuUtil.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook.menu; +package com.raytheon.uf.edex.plugin.redbook.menu; import java.io.File; diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMenuUtil.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookMenuUtil.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMenuUtil.java index 39ce80d826..d70eb3da38 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookMenuUtil.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMenuUtil.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook.menu; +package com.raytheon.uf.edex.plugin.redbook.menu; import java.io.File; import java.util.ArrayList; @@ -27,9 +27,6 @@ import javax.xml.bind.JAXBContext; import javax.xml.bind.JAXBException; import javax.xml.bind.Unmarshaller; -import com.raytheon.edex.plugin.redbook.ingest.xml.MenuEntry; -import com.raytheon.edex.plugin.redbook.ingest.xml.MenuEntryType; -import com.raytheon.edex.plugin.redbook.ingest.xml.RedbookMenusXML; import com.raytheon.uf.common.menus.xml.CommonAbstractMenuContribution; import com.raytheon.uf.common.menus.xml.CommonBundleMenuContribution; import com.raytheon.uf.common.menus.xml.CommonSeparatorMenuContribution; @@ -41,6 +38,9 @@ import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.edex.menus.AbstractMenuUtil; +import com.raytheon.uf.edex.plugin.redbook.ingest.xml.MenuEntry; +import com.raytheon.uf.edex.plugin.redbook.ingest.xml.MenuEntryType; +import com.raytheon.uf.edex.plugin.redbook.ingest.xml.RedbookMenusXML; /** * Parent class for NCEP/Hydro Redbook menu contributions for NDM. diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookMpcMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMpcMenuUtil.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookMpcMenuUtil.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMpcMenuUtil.java index 71d7c18fbf..e401e712be 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookMpcMenuUtil.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMpcMenuUtil.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook.menu; +package com.raytheon.uf.edex.plugin.redbook.menu; import java.io.File; diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookNcoMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookNcoMenuUtil.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookNcoMenuUtil.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookNcoMenuUtil.java index 86851bb7d7..05a310c7f1 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookNcoMenuUtil.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookNcoMenuUtil.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook.menu; +package com.raytheon.uf.edex.plugin.redbook.menu; import java.io.File; diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookUaMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookUaMenuUtil.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookUaMenuUtil.java rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookUaMenuUtil.java index 00bac7940d..58c8c6b479 100644 --- a/edexOsgi/com.raytheon.edex.plugin.redbook/src/com/raytheon/edex/plugin/redbook/menu/RedbookUaMenuUtil.java +++ b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookUaMenuUtil.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook.menu; +package com.raytheon.uf.edex.plugin.redbook.menu; import java.io.File; diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/utility/common_static/base/path/redbookPathKeys.xml b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/common_static/base/path/redbookPathKeys.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/utility/common_static/base/path/redbookPathKeys.xml rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/common_static/base/path/redbookPathKeys.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/utility/common_static/base/purge/redbookPurgeRules.xml b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/common_static/base/purge/redbookPurgeRules.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/utility/common_static/base/purge/redbookPurgeRules.xml rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/common_static/base/purge/redbookPurgeRules.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/utility/edex_static/base/distribution/redbook.xml b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/edex_static/base/distribution/redbook.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/utility/edex_static/base/distribution/redbook.xml rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/edex_static/base/distribution/redbook.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.redbook/utility/edex_static/base/redbook/redbookFcstMap.xml b/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/edex_static/base/redbook/redbookFcstMap.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.redbook/utility/edex_static/base/redbook/redbookFcstMap.xml rename to edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/edex_static/base/redbook/redbookFcstMap.xml diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/build.xml index f30c95c06a..de824ef366 100644 --- a/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/build.xml +++ b/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/build.xml @@ -246,7 +246,7 @@ - + @@ -314,7 +314,7 @@ - + - + diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml b/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml index 88b29cdbf5..48b22fbeb5 100644 --- a/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml +++ b/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml @@ -214,7 +214,7 @@ unpack="false"/> - + diff --git a/tests/data/Redbook/PMNA01_KWNS_220049_47355211.rb.Result b/tests/data/Redbook/PMNA01_KWNS_220049_47355211.rb.Result index bd2757dd2a..742ba018d8 100644 --- a/tests/data/Redbook/PMNA01_KWNS_220049_47355211.rb.Result +++ b/tests/data/Redbook/PMNA01_KWNS_220049_47355211.rb.Result @@ -1 +1 @@ - + diff --git a/tests/data/Redbook/PSBB08_KWNH_220000_46836601.rb.Result b/tests/data/Redbook/PSBB08_KWNH_220000_46836601.rb.Result index a113cd8b9d..8304ad46c3 100644 --- a/tests/data/Redbook/PSBB08_KWNH_220000_46836601.rb.Result +++ b/tests/data/Redbook/PSBB08_KWNH_220000_46836601.rb.Result @@ -1 +1 @@ -FCST_USED +FCST_USED diff --git a/tests/data/Redbook/PYMA20_KWBC_220000_47396312.rb.Result b/tests/data/Redbook/PYMA20_KWBC_220000_47396312.rb.Result index 03d785c79e..33dd0afc2e 100644 --- a/tests/data/Redbook/PYMA20_KWBC_220000_47396312.rb.Result +++ b/tests/data/Redbook/PYMA20_KWBC_220000_47396312.rb.Result @@ -1 +1 @@ - + diff --git a/tests/resources/res/conf/RedbookBlocks.properties b/tests/resources/res/conf/RedbookBlocks.properties index 97b1025d00..73f945c5ea 100644 --- a/tests/resources/res/conf/RedbookBlocks.properties +++ b/tests/resources/res/conf/RedbookBlocks.properties @@ -1,4 +1,4 @@ -001_001=com.raytheon.edex.plugin.redbook.common.blocks.ProductIdBlock -001_002=com.raytheon.edex.plugin.redbook.common.blocks.EndOfProductBlock -004_016=com.raytheon.edex.plugin.redbook.common.blocks.Block_004_016 -004_017=com.raytheon.edex.plugin.redbook.common.blocks.Block_004_017 +001_001=com.raytheon.uf.edex.plugin.redbook.common.blocks.ProductIdBlock +001_002=com.raytheon.uf.edex.plugin.redbook.common.blocks.EndOfProductBlock +004_016=com.raytheon.uf.edex.plugin.redbook.common.blocks.Block_004_016 +004_017=com.raytheon.uf.edex.plugin.redbook.common.blocks.Block_004_017 diff --git a/tests/unit/com/raytheon/uf/common/serialization/TestJaxbableClassesLocator.java b/tests/unit/com/raytheon/uf/common/serialization/TestJaxbableClassesLocator.java index 4328a5cc6b..92c14c279f 100644 --- a/tests/unit/com/raytheon/uf/common/serialization/TestJaxbableClassesLocator.java +++ b/tests/unit/com/raytheon/uf/common/serialization/TestJaxbableClassesLocator.java @@ -64,7 +64,7 @@ public class TestJaxbableClassesLocator implements IJaxbableClassesLocator { Class[] array = new Class[] { com.raytheon.uf.common.archive.config.ArchiveConfig.class, com.raytheon.uf.common.archive.config.CategoryConfig.class, - com.raytheon.edex.plugin.redbook.decoder.RedbookFcstMap.class, + com.raytheon.uf.edex.plugin.redbook.decoder.RedbookFcstMap.class, com.raytheon.uf.common.datadelivery.registry.AdhocSubscription.class, com.raytheon.uf.common.datadelivery.registry.Connection.class, com.raytheon.uf.common.datadelivery.registry.Coverage.class, diff --git a/tests/unit/com/raytheon/edex/plugin/redbook/RedbookDecoderTest.java b/tests/unit/com/raytheon/uf/edex/plugin/redbook/RedbookDecoderTest.java similarity index 97% rename from tests/unit/com/raytheon/edex/plugin/redbook/RedbookDecoderTest.java rename to tests/unit/com/raytheon/uf/edex/plugin/redbook/RedbookDecoderTest.java index 11c4754488..1de261ff6b 100644 --- a/tests/unit/com/raytheon/edex/plugin/redbook/RedbookDecoderTest.java +++ b/tests/unit/com/raytheon/uf/edex/plugin/redbook/RedbookDecoderTest.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.redbook; +package com.raytheon.uf.edex.plugin.redbook; import static org.junit.Assert.assertEquals; @@ -47,6 +47,7 @@ import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.common.dataplugin.redbook.RedbookRecord; import com.raytheon.uf.common.localization.PathManagerFactoryTest; import com.raytheon.uf.common.util.FileUtil; +import com.raytheon.uf.edex.plugin.redbook.RedbookDecoder; /** * Regression Test RedbookRecords decoded by the RedbookDecoder against known @@ -253,7 +254,7 @@ public class RedbookDecoderTest { /** * Test method for - * {@link com.raytheon.edex.plugin.redbook.RedbookDecoder#decode(byte[], com.raytheon.edex.esb.Headers)} + * {@link com.raytheon.uf.edex.plugin.redbook.RedbookDecoder#decode(byte[], com.raytheon.edex.esb.Headers)} * . * * @throws DecoderException From 4aaa7c7096e4fc3e78c8936cffc59a0e46f39519 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Tue, 15 Apr 2014 09:34:25 -0500 Subject: [PATCH 021/188] Issue #2984 attempt to fix build Change-Id: I1447939ec3950425ef5b052e65e464a1ac99257d Former-commit-id: 60dc6b2552cc2108f9c5c0bc25eae4a1829b62f9 --- rpms/awips2.edex/Installer.edex/component.spec | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/rpms/awips2.edex/Installer.edex/component.spec b/rpms/awips2.edex/Installer.edex/component.spec index 4a2385dc40..5982cf19a0 100644 --- a/rpms/awips2.edex/Installer.edex/component.spec +++ b/rpms/awips2.edex/Installer.edex/component.spec @@ -54,6 +54,11 @@ mkdir -p %{_build_root}/etc/init.d if [ $? -ne 0 ]; then exit 1 fi +mkdir -p %{_build_root}/awips2/edex/webapps +if [ $? -ne 0 ]; then + exit 1 +fi + DEPLOY_SCRIPT="build.edex/deploy-common/deploy-esb.xml" From 81e4c9b05d891f5b1cf5b7d973defcd6069a3cec Mon Sep 17 00:00:00 2001 From: Mike Duff Date: Tue, 15 Apr 2014 10:10:18 -0500 Subject: [PATCH 022/188] Issue #2785 - Fix loading of groups in sub request dialog Change-Id: If42e1f3fe80bde16fcc86dfa0a0b5673e5359722 Former-commit-id: e72a852935dcb519604b37dc873645d4b419ee43 --- .../uf/viz/collaboration/ui/SubRequestDialog.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/SubRequestDialog.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/SubRequestDialog.java index 8f86176596..ee02c77be7 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/SubRequestDialog.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/SubRequestDialog.java @@ -54,6 +54,7 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * Jan 31, 2014 2700 bclement don't prompt for group if user is already in one * Feb 13, 2014 2755 bclement roster addition now done in account manager, user input passed back * Apr 07, 2014 2785 mpduff Changed to implement CaveSWTDialog + * Fix loading of groups * * * @@ -148,11 +149,11 @@ public class SubRequestDialog extends CaveSWTDialog { if (connection == null) { return new String[0]; } - Collection groups = connection.getContactsManager() + Collection rosterGroups = connection.getContactsManager() .getGroups(); - List groupList = new ArrayList(groups.size()); - for (String group : groupList) { - groupList.add(group); + List groupList = new ArrayList(rosterGroups.size()); + for (RosterGroup group : rosterGroups) { + groupList.add(group.getName()); } Collections.sort(groupList); From 0845eef9271f7c767f9b6872efea2b366ae6e203 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Tue, 15 Apr 2014 10:54:39 -0500 Subject: [PATCH 023/188] Issue #2907 fix datauri doc utility Change-Id: Iafb1feb73e416acac28369c3c96acbc305928b22 Former-commit-id: 948b1c1eb060963c943eccc31033af27b70804b0 --- javaUtilities/com.raytheon.uf.docs.datauri/.classpath | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/javaUtilities/com.raytheon.uf.docs.datauri/.classpath b/javaUtilities/com.raytheon.uf.docs.datauri/.classpath index 8cff3531d9..a721ea282d 100644 --- a/javaUtilities/com.raytheon.uf.docs.datauri/.classpath +++ b/javaUtilities/com.raytheon.uf.docs.datauri/.classpath @@ -19,7 +19,6 @@ - @@ -148,5 +147,6 @@ + From e0818472250994966d05c5d4e944dda4032147cc Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Tue, 15 Apr 2014 11:16:24 -0500 Subject: [PATCH 024/188] Issue #2984 remove dead ncep purge util plugin and web page Change-Id: Ifca01d858586ce3bf968f4b1203eb9853be97829 Former-commit-id: 9f01e8a242ba44dec510fdc5ca75be566f8fa008 --- edexOsgi/build.edex/esb/conf/modes.xml | 3 - .../feature.xml | 7 - .../.classpath | 7 - .../gov.noaa.nws.ncep.edex.purgeutil/.project | 28 --- .../.settings/org.eclipse.jdt.core.prefs | 7 - .../META-INF/MANIFEST.MF | 16 -- .../build.properties | 5 - .../gov.noaa.nws.ncep.edex.purgeutil.ecl | 0 .../res/spring/purgeutil-request.xml | 63 ------- .../common/web/NcepLoggerSettingServlet.java | 73 -------- .../noaa/nws/ncep/edex/purgeutil/DbPurge.java | 160 ------------------ .../web.deploy | 1 - .../web/WEB-INF/classes/log4j.properties | 15 -- .../web/WEB-INF/dwr.xml | 12 -- .../web/WEB-INF/web.xml | 59 ------- .../web/index.html | 45 ----- .../web/index.html-test | 49 ------ .../web/ncepEdexRequestLoggerSetting.html | 49 ------ .../web/purgeControls.js | 22 --- .../web/rayAWIPS.jpg | Bin 5217 -> 0 bytes .../web/td.css | 16 -- 21 files changed, 637 deletions(-) delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/.classpath delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/.project delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/.settings/org.eclipse.jdt.core.prefs delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/META-INF/MANIFEST.MF delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/build.properties delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/gov.noaa.nws.ncep.edex.purgeutil.ecl delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/res/spring/purgeutil-request.xml delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/src/gov/noaa/nws/ncep/common/web/NcepLoggerSettingServlet.java delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/src/gov/noaa/nws/ncep/edex/purgeutil/DbPurge.java delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/web.deploy delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/web/WEB-INF/classes/log4j.properties delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/web/WEB-INF/dwr.xml delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/web/WEB-INF/web.xml delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/web/index.html delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/web/index.html-test delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/web/ncepEdexRequestLoggerSetting.html delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/web/purgeControls.js delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/web/rayAWIPS.jpg delete mode 100644 ncep/gov.noaa.nws.ncep.edex.purgeutil/web/td.css diff --git a/edexOsgi/build.edex/esb/conf/modes.xml b/edexOsgi/build.edex/esb/conf/modes.xml index a8183ab588..6a8906e922 100644 --- a/edexOsgi/build.edex/esb/conf/modes.xml +++ b/edexOsgi/build.edex/esb/conf/modes.xml @@ -73,9 +73,6 @@ .*request.* .*common.* excludeDpaAndOgc - - purgeutil-request.xml - webservices.xml diff --git a/ncep/com.raytheon.uf.edex.ncep.feature/feature.xml b/ncep/com.raytheon.uf.edex.ncep.feature/feature.xml index 8a3f2f725c..8a9859b709 100644 --- a/ncep/com.raytheon.uf.edex.ncep.feature/feature.xml +++ b/ncep/com.raytheon.uf.edex.ncep.feature/feature.xml @@ -220,13 +220,6 @@ version="0.0.0" unpack="false"/> - - - - - - - - diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/.project b/ncep/gov.noaa.nws.ncep.edex.purgeutil/.project deleted file mode 100644 index 7bf1f1e16b..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - gov.noaa.nws.ncep.edex.purgeutil - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - - diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/.settings/org.eclipse.jdt.core.prefs b/ncep/gov.noaa.nws.ncep.edex.purgeutil/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index 4723ee73a3..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,7 +0,0 @@ -#Tue Nov 23 13:42:17 EST 2010 -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 -org.eclipse.jdt.core.compiler.compliance=1.6 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.6 diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/META-INF/MANIFEST.MF b/ncep/gov.noaa.nws.ncep.edex.purgeutil/META-INF/MANIFEST.MF deleted file mode 100644 index d45016e903..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/META-INF/MANIFEST.MF +++ /dev/null @@ -1,16 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: Purgeutil Plug-in -Bundle-SymbolicName: gov.noaa.nws.ncep.edex.purgeutil -Bundle-Version: 1.0.0.qualifier -Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -Import-Package: com.raytheon.edex.db.dao, - com.raytheon.edex.plugin, - com.raytheon.uf.common.dataplugin, - gov.noaa.nws.ncep.common.log.logger, - javax.servlet, - javax.servlet.http, - org.hibernate -Require-Bundle: gov.noaa.nws.ncep.edex.common;bundle-version="1.0.0", - com.raytheon.edex.common, - org.apache.http;bundle-version="4.1.2" diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/build.properties b/ncep/gov.noaa.nws.ncep.edex.purgeutil/build.properties deleted file mode 100644 index 5791d48d5f..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/build.properties +++ /dev/null @@ -1,5 +0,0 @@ -source.. = src/ -output.. = bin/ -bin.includes = META-INF/,\ - .,\ - res/ diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/gov.noaa.nws.ncep.edex.purgeutil.ecl b/ncep/gov.noaa.nws.ncep.edex.purgeutil/gov.noaa.nws.ncep.edex.purgeutil.ecl deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/res/spring/purgeutil-request.xml b/ncep/gov.noaa.nws.ncep.edex.purgeutil/res/spring/purgeutil-request.xml deleted file mode 100644 index 01f52a124e..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/res/spring/purgeutil-request.xml +++ /dev/null @@ -1,63 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/src/gov/noaa/nws/ncep/common/web/NcepLoggerSettingServlet.java b/ncep/gov.noaa.nws.ncep.edex.purgeutil/src/gov/noaa/nws/ncep/common/web/NcepLoggerSettingServlet.java deleted file mode 100644 index aafdc5ced7..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/src/gov/noaa/nws/ncep/common/web/NcepLoggerSettingServlet.java +++ /dev/null @@ -1,73 +0,0 @@ -package gov.noaa.nws.ncep.common.web; - -import gov.noaa.nws.ncep.common.log.logger.NcepLoggerManager; - -import java.io.IOException; - -//import javax.servlet.RequestDispatcher; -import javax.servlet.Servlet; -//import javax.servlet.ServletConfig; -import javax.servlet.ServletException; -//import javax.servlet.ServletRequest; -//import javax.servlet.ServletResponse; -import javax.servlet.http.HttpServlet; -import javax.servlet.http.HttpServletRequest; -import javax.servlet.http.HttpServletResponse; - -public class NcepLoggerSettingServlet extends HttpServlet implements Servlet { - - /** - * - */ - private static final long serialVersionUID = -8785343518113487908L; - -// @Override -// public void init(ServletConfig config) throws ServletException { -// // TODO Auto-generated method stub -// -// } -// -// @Override -// public ServletConfig getServletConfig() { -// // TODO Auto-generated method stub -// return null; -// } -// -// @Override -// public void service(ServletRequest req, ServletResponse res) -// throws ServletException, IOException { -// // TODO Auto-generated method stub -// -// } -// -// @Override -// public String getServletInfo() { -// // TODO Auto-generated method stub -// return null; -// } -// -// @Override -// public void destroy() { -// // TODO Auto-generated method stub -// -// } - - @Override - protected void doGet(HttpServletRequest req, HttpServletResponse resp) - throws ServletException, IOException { - String logName = req.getParameter("log-name"); - String logLevel = req.getParameter("log-level"); - NcepLoggerManager.setNcepLoggerLevel(logName, logLevel); - - // RequestDispatcher rd = null; - resp.sendRedirect("ncepEdexRequestLoggerSetting.html"); - } - - @Override - protected void doPost(HttpServletRequest req, HttpServletResponse resp) - throws ServletException, IOException { - doGet(req, resp); - } - - -} diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/src/gov/noaa/nws/ncep/edex/purgeutil/DbPurge.java b/ncep/gov.noaa.nws.ncep.edex.purgeutil/src/gov/noaa/nws/ncep/edex/purgeutil/DbPurge.java deleted file mode 100644 index 130f5ed0db..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/src/gov/noaa/nws/ncep/edex/purgeutil/DbPurge.java +++ /dev/null @@ -1,160 +0,0 @@ -package gov.noaa.nws.ncep.edex.purgeutil; - -/** - * - * gov.noaa.nws.ncep.edex.purgeutil.DbPurge - * - * This java class provides AWIPS web plugin DB purging interface implementations. - * This code has been developed by the SIB for use in the AWIPS2 system. - * - *
- * SOFTWARE HISTORY
- * 
- * Date         Ticket#    	Engineer    Description
- * -------		------- 	-------- 	-----------
- * 12/02/2010	TBD			Chin Chen	Initial coding
- *
- * 
- * - * @author Chin Chen - * @version 1.0 - */ - -import java.io.ByteArrayOutputStream; -import java.io.IOException; -import java.io.InputStream; - -import org.apache.http.HttpResponse; -import org.apache.http.client.methods.HttpPost; -import org.apache.http.entity.StringEntity; -import org.apache.http.impl.conn.tsccm.ThreadSafeClientConnManager; -import org.apache.http.util.EntityUtils; - -import com.raytheon.uf.edex.core.EdexException; -import com.raytheon.uf.edex.database.plugin.PluginDao; -import com.raytheon.uf.edex.database.plugin.PluginFactory; - -public class DbPurge { - - private static org.apache.http.impl.client.DefaultHttpClient client; - - /* - * This is purge entry point called by JavaScript PurgeControls.purge - * (purgeControls.js) from AWIPS Plugin Database Purge web interface. - */ - public String purgeDbTable(String plugin) { - // System.out.println("purging "+ plugin); - if (plugin == null || plugin.length() == 0) - return "Purge failed! "; - - try { - String response = requestHTTP(plugin); - return response; - } catch (EdexException e1) { - // TODO Auto-generated catch block - e1.printStackTrace(); - return "Purge " + plugin + " failed! "; - } - - } - - public String purgeAllTable(String plugin) { - // System.out.println("purgeAllTable entered"); - PluginFactory pf = PluginFactory.getInstance(); - if (pf.isRegistered(plugin)) { - PluginDao dao = null; - try { - dao = pf.getPluginDao(plugin); - dao.purgeAllData(); - } catch (Throwable e) { - System.out.println("purge all failed"); - e.printStackTrace(); - return "Purge " + plugin + " failed!"; - } - - } else - return plugin + " is not registered as plugin!"; - - return "Purge " + plugin + " is done!"; - } - - /* - * Since web browser is running on its own JVM, a HTTP request to EDEX - * server JVM is used. Http address - * http://localhost:9581/services/purgePlugin, and Executing Java bean - * (DbPurge) and method (purgeAllTable) are defined in Spring XML - - * purgeutil-request.xml. - */ - public static String requestHTTP(String message) throws EdexException { - if (client == null) - client = new org.apache.http.impl.client.DefaultHttpClient( - new ThreadSafeClientConnManager()); - - try { - - HttpPost put = new HttpPost( - "http://localhost:9581/services/purgePlugin"); - put.setEntity(new StringEntity(message, "text/xml", "ISO-8859-1")); - - HttpResponse resp = client.execute(put); - int code = resp.getStatusLine().getStatusCode(); - - if (code != 200) { - throw new EdexException( - "Error reading server response. Got error message: " - + EntityUtils.toString(resp.getEntity())); - } - - ByteArrayOutputStream baos = null; - InputStream is = null; - try { - is = resp.getEntity().getContent(); - baos = new ByteArrayOutputStream(); - int read = 0; - do { - byte[] tmp = new byte[1024]; - read = is.read(tmp); - - if (read > 0) - baos.write(tmp, 0, read); - } while (read > 0); - - return new String(baos.toByteArray()); - } finally { - // It seems we do not need to do this with 4.1 closing the - // input stream from the entity ( 'is' at the time of - // writing ) should allow the connection te be released - - // if (put != null) { - // put.releaseConnection(); - // } - - try { - if (baos != null) - baos.close(); - } catch (IOException e1) { - // ignore - } - try { - if (is != null) - is.close(); - } catch (IOException e) { - // ignore - } - - try { - if (resp != null && resp.getEntity() != null) { - EntityUtils.consume(resp.getEntity()); - } - } catch (IOException e) { - // if there was an error reading the input stream, assume it - // was closed - // TODO - log? - } - } - } catch (Exception e) { - throw new EdexException("Unable to connect to server", e); - } - - } -} diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web.deploy b/ncep/gov.noaa.nws.ncep.edex.purgeutil/web.deploy deleted file mode 100644 index e4fb53999d..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web.deploy +++ /dev/null @@ -1 +0,0 @@ -war.name=purgeWeb \ No newline at end of file diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/WEB-INF/classes/log4j.properties b/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/WEB-INF/classes/log4j.properties deleted file mode 100644 index 5d11a0f600..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/WEB-INF/classes/log4j.properties +++ /dev/null @@ -1,15 +0,0 @@ -# -# Log4j configuration -# Available priorities are: OFF, FATAL, ERROR, WARN, INFO, DEBUG, ALL -# - -log4j.rootLogger=ALL,null -log4j.logger.com.raytheon.edex.uengine=INFO,console - -#appender for the rootLogger, set to null -log4j.appender.null=org.apache.log4j.varia.NullAppender - -#appender for the console, set to ConsoleAppender -log4j.appender.console=org.apache.log4j.ConsoleAppender -log4j.appender.console.layout=org.apache.log4j.PatternLayout -log4j.appender.console.layout.conversionPattern=%d [%t] %p %l %m%n diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/WEB-INF/dwr.xml b/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/WEB-INF/dwr.xml deleted file mode 100644 index 6b8a4720cd..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/WEB-INF/dwr.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - - - - - diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/WEB-INF/web.xml b/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/WEB-INF/web.xml deleted file mode 100644 index 546fad72be..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/WEB-INF/web.xml +++ /dev/null @@ -1,59 +0,0 @@ - - - - purgeWeb - - - webAppRootKey - purgeWeb - - - - - NcepLoggerServlet - NcepLoggerServlet - gov.noaa.nws.ncep.common.web.NcepLoggerSettingServlet - - - - dwr-invoker - DWR Servlet - uk.ltd.getahead.dwr.DWRServlet - - debug - true - - - - - dwr-invoker - /dwr/* - - - - NcepLoggerServlet - ncepLoggerSetting - - - - /index.html - - diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/index.html b/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/index.html deleted file mode 100644 index cb8a938296..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/index.html +++ /dev/null @@ -1,45 +0,0 @@ - - - - - - - - - - AWIPS Plugin Database Purge Interface - - - - -
-
- - - - - -
Plugin Name:
- - - - - - - -
Purging Result:
-
-
-
-
- Go to NCEP Logger Setting for Edex Request Server - - - - \ No newline at end of file diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/index.html-test b/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/index.html-test deleted file mode 100644 index 7a337f5b4e..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/index.html-test +++ /dev/null @@ -1,49 +0,0 @@ - - - - - - - - - - - - - AWIPS DB Purge Interface - - -
-
- -
- Table Name: - - -
- - - - - - \ No newline at end of file diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/ncepEdexRequestLoggerSetting.html b/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/ncepEdexRequestLoggerSetting.html deleted file mode 100644 index aa7aac114b..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/ncepEdexRequestLoggerSetting.html +++ /dev/null @@ -1,49 +0,0 @@ - - - - - - AWIPS NCEP Logger Setting Interface - - - - -
- -

Set NCEP Logger Level

-
- - - - - - - - - - - - -
Log Name:
Log Level: - -
-   - -
-
-
-
-
- Go to the EDEX Purge Interface - - - \ No newline at end of file diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/purgeControls.js b/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/purgeControls.js deleted file mode 100644 index fc4edb80af..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/purgeControls.js +++ /dev/null @@ -1,22 +0,0 @@ -function PurgeControls(){ - alert("Purgecontrol created"); - this.tbName = document.getElementById("tbName"); - this.purgeResult = document.getElementById("result"); - this.purgeResult.value = ""; - this.tbName.value = ""; -} -PurgeControls.prototype.purge = function(){ - var inputtbName = this.tbName.value; - var self = this; - self.processResult("Purging! May take a while!"); - DbPurge.purgeDbTable(inputtbName, function(data) { self.processResult(data); }); -} - -PurgeControls.prototype.processResult = function(data){ - this.purgeResult.value = data; -} - -PurgeControls.prototype.reset = function(data){ - this.purgeResult.value = ""; - this.tbName.value = ""; -} diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/rayAWIPS.jpg b/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/rayAWIPS.jpg deleted file mode 100644 index 7c0fbe56f1b2b5e2174ab07936fd6a27498ac950..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 5217 zcmbW*XD}RIy8!UjqL(S<~mRU&$bjS^kh*och?n+?0NYDf@7TdW`!(WAGpIzjXr zY*rUNdUTPnUjKXVym#h)y7xY3&ZqO7GtY0HnKNh3#l*!tfaRV6*Z@FAMg~Z_9Ds{y zfF6L3nwp0C3LOm%4LuzlJrg$z6C)#&00$?KTU1C~OhicJs)US+oP@NJ^i`3YI`T?t z>YAFG;y3Pq^==!gXlSbca|jt7Jv|d66F&%HWLHel2^CCB$H~Rb!z(T!DJ6YP38bu|s&-57 zj=sTNL-0LID{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y2&IQnNuw(RtRJ#tvXhY*j?*K5`uRT+3?jMk@fwy;?%o!l&KvM$s?Q{}BBgmD&Y^fS?|&_9tg zW`J$DLb`eI2c{pP+Q>>Cepvs3Vq^a7hB|KriGNQ#HE_w?6~HZsqFx#ULHS6Q z^naJQrf%GDvr7=vCx}OcRC^8C!xN~ z=u`wIrny?-acB2Xv7V{VWDlp0aEpr)EMQ@b_-P6u?UVLSZran*sRtW=1Lem?UR9A! z4A>fDEVJ>)kg3K1$%U2lEG8J$1)ymLw^?!+1qYF_Ah+%HXiHajj7kwAC=$=EbxS(; zQ{(#ODwK(rM{7l)yq!VxFbxo>}dx3~KG`A(hyFSZ)Lx+LAz1(*(`7i%u{`>#{ diff --git a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/td.css b/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/td.css deleted file mode 100644 index 5f150b3c3b..0000000000 --- a/ncep/gov.noaa.nws.ncep.edex.purgeutil/web/td.css +++ /dev/null @@ -1,16 +0,0 @@ -body{ - font-family: Helvetica; - margin-left: 75px; - margin-right: 75px; - background: #E0E0E0; -} -#banner{ - background: white; - font-family: Lucida Sans; - font-size: 24pt; - text-align: center; - border: 1px solid #C0C0C0; -} -#interfaceBody{ - margin-top: 10px; -} From 4709e66b34831520e1b2dea3e3d597050de263fd Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Mon, 14 Apr 2014 20:01:34 -0500 Subject: [PATCH 025/188] Issue #2726: Fix edex_camel to wait for process to finish on stop, add logging of service calls to log files. Change-Id: Ie1e8fce80e7e06b294e01deaf9174a6fb7180d5d Former-commit-id: dc798a7ca6badfcd6d732b43bb3e0175770398be --- .../Installer.edex/scripts/init.d/edex_camel | 162 +++++++++++------- 1 file changed, 102 insertions(+), 60 deletions(-) diff --git a/rpms/awips2.edex/Installer.edex/scripts/init.d/edex_camel b/rpms/awips2.edex/Installer.edex/scripts/init.d/edex_camel index 628e5d0999..e9b374ea67 100644 --- a/rpms/awips2.edex/Installer.edex/scripts/init.d/edex_camel +++ b/rpms/awips2.edex/Installer.edex/scripts/init.d/edex_camel @@ -37,16 +37,16 @@ else fi # Who to run EDEX server as, usually "awips". (NOT "root") -EDEXUSER=awips +export EDEXUSER=awips # Todays date in format of YYYYMMDD. -TODAY=`/bin/date +%Y%m%d` +export TODAY=`/bin/date +%Y%m%d` # We will no longer be using hard-coded paths that need to be replaced. # Use rpm to find the paths that we need. export JAVA_INSTALL="/awips2/java" export PYTHON_INSTALL="/awips2/python" -EDEX_INSTALL="/awips2/edex" +export EDEX_INSTALL="/awips2/edex" export PSQL_INSTALL="/awips2/psql" # The path that is to be used for the script @@ -57,76 +57,119 @@ export LD_PRELOAD=${PYTHON_INSTALL}/lib/libpython2.7.so export AMQP_SPEC="" export DATA_ARCHIVE_ROOT=/tmp/sbn +# what to do to get pids of an EDEX instance +# $1 == instance token +getCamelAndWrapperPids() { + _camel_pid=`pgrep -f "java.*-Dedex.run.mode=${1} "` + if [ "$_camel_pid" != "" ]; then + # grab wrapper pid from edex process, run throw awk to throw away leading white space + _wrapper_pid=`ps --no-headers -p $_camel_pid -o ppid | awk '{print $1}'` + else + # camel not up, double check wrapper pid file + pidfile=${EDEX_INSTALL}/bin/${1}.pid + + if [ -f $pidfile ]; then + _wrapper_pid=`cat $pidfile` + if [ "$_wrapper_pid" != "" ]; then + # double check process is indeed a wrapper process + check=`ps -p $_wrapper_pid -o pid,args | grep -c wrapper.conf` + if [ $check -eq 0 ]; then + _wrapper_pid="" + fi + fi + else + _wrapper_pid="" + fi + fi +} + # what to do to start an EDEX instance # $1 == instance token startEDEX() { - pidfile=${EDEX_INSTALL}/bin/${1}.pid - CAMELPROCESS=`ps -ef | grep "aw.site.identifier"|grep -c "edex.run.mode=${1} " ` - if [ $CAMELPROCESS -eq 1 ]; then + getCamelAndWrapperPids ${1} + if [ "$_wrapper_pid" != "" ]; then echo "WARNING: EDEX ${1} instance already running, not starting another instance" return 1 fi - EXTRA_ARGS="-noConsole" + local EXTRA_ARGS="-noConsole" + local DAEMON="${EDEX_INSTALL}/bin/start.sh ${EXTRA_ARGS} ${1}" + local LOG=${EDEX_INSTALL}/logs/start-edex-${1}-$TODAY.log + local TIME=`/bin/date "+%F %T"` + echo "$TIME: Service edex_camel Starting EDEX ${1}" >> $LOG - DAEMON="${EDEX_INSTALL}/bin/start.sh ${EXTRA_ARGS} ${1}" - EDEXSTARTLOG=${EDEX_INSTALL}/logs/start-edex-${1}-$TODAY.log - su $EDEXUSER -c "$DAEMON &" >> $EDEXSTARTLOG 2>&1 - sleep 5 - pid=`cat ${pidfile}` - if [ "$pid" == "" ]; then - echo "WARNING: No Wrapper Pid Found, EDEX ${1} did not start properly" + su $EDEXUSER -c "$DAEMON &" >> $LOG 2>&1 + sleep 10 + local pidfile=${EDEX_INSTALL}/bin/${1}.pid + + if [ -f $pidfile ]; then + pid=`cat ${pidfile}` + if [ "$pid" == "" ]; then + echo "WARNING: No Wrapper Pid File Found, EDEX ${1} did not start properly" + else + checkStatus ${1} + fi + else + echo "WARNING: No Wrapper Pid File Found, EDEX ${1} did not start properly" fi } # what to do to stop an EDEX instance # $1 == instance token stopEDEX() { - pidfile=${EDEX_INSTALL}/bin/${1}.pid - if [ ! -f $pidfile ]; then + getCamelAndWrapperPids ${1} + if [ "$_wrapper_pid" == "" -a "$_camel_pid" == "" ]; then echo "WARNING: EDEX ${1} instance not running, no shutdown attempted" return 1 fi - pidid=`cat ${pidfile}` - kill $pidid - savepid=$pidid - CNT=0 - TOTCNT=0 - while [ "X$pidid" != "X" ]; do - if [ "$CNT" -lt "3" ]; then - let CNT=${CNT}+1 - else - CNT=0 + local LOG=${EDEX_INSTALL}/logs/start-edex-${1}-$TODAY.log + local TIME=`/bin/date "+%F %T"` + echo "$TIME: Service edex_camel Stopping EDEX ${1}" >> $LOG + + if [ "$_wrapper_pid" != "" -a "$_wrapper_pid" != "1" ]; then + kill $_wrapper_pid + else + # occasionally wrapper dies and camel process is still running + kill $_camel_pid + fi + + cnt=0 + savepid=$_wrapper_pid + while [ "${_wrapper_pid}${_camel_pid}" != "" ]; do + if [ "$_wrapper_pid" != "$savepid" ]; then + echo "WARNING: EDEX ${1} instance running under new pid, started by another user?" + return 1 fi - let TOTCNT=${TOTCNT}+1 + + let cnt+=1 + + if [ $cnt -eq 10 ]; then + echo "Waiting for EDEX ${1} to shutdown" + cnt=0; + fi + sleep 1 - CAMELPROCESS=`ps -p $savepid -o args | grep home=${EDEX_INSTALL}/bin|grep -c "edex.run.mode=${1}"` - if [ $CAMELPROCESS -eq 1 ]; then - pidid=$savepid - else - pidid="" - fi + getCamelAndWrapperPids ${1} done + + echo "EDEX ${1} shutdown" } # what to use to check status # $1 == instance token checkStatus() { - if [ -f ${EDEX_INSTALL}/bin/${1}.pid ]; then - pidid=`cat ${EDEX_INSTALL}/bin/${1}.pid` - CAMELPROCESS=`ps --ppid $pidid -o args | grep -c "edex.run.mode=${1}"` - if [ $CAMELPROCESS -eq 1 ]; then - JAVAPROCESS=`ps --ppid $pidid -o pid,args | grep "edex.run.mode=${1}"` - JAVAPROCESS=`echo $JAVAPROCESS | cut -d ' ' -f 1` - echo "EDEX Camel (${1}) is running (wrapper PID $pidid)" - echo "EDEX Camel (${1}) is running (java PID $JAVAPROCESS)" - else - echo "EDEX Camel (${1}) is not running" - fi - else - echo "EDEX Camel (${1}) is not running" - fi + getCamelAndWrapperPids ${1} + if [ "$_wrapper_pid" == "" ]; then + echo "EDEX Camel (${1}) is not running" + elif [ "$_wrapper_pid" == "1" ]; then + echo "WARNING: EDEX Camel (${1}) wrapper is not running" + echo "WARNING: EDEX Camel (${1}) is running (java PID $_camel_pid)" + echo "WARNING: Recommend restarting EDEX Camel ${1}" + else + echo "EDEX Camel (${1}) is running (wrapper PID $_wrapper_pid)" + echo "EDEX Camel (${1}) is running (java PID $_camel_pid)" + fi } # Verify root user @@ -151,37 +194,36 @@ case $func in checkUser for service in ${SERVICES[*]}; do - echo -n "Starting EDEX Camel ($service): " - startEDEX $service - echo OK + echo "Starting EDEX Camel ($service): " + startEDEX $service & done + wait RETVAL=$? ;; stop) checkUser for service in ${SERVICES[*]}; do - echo -n "Stopping EDEX Camel ($service): " - stopEDEX $service - echo OK + echo "Stopping EDEX Camel ($service): " + stopEDEX $service & done + wait RETVAL=$? ;; restart) checkUser for service in ${SERVICES[*]}; do - echo -n "Stopping EDEX Camel ($service): " - stopEDEX $service - echo OK + echo "Stopping EDEX Camel ($service): " + stopEDEX $service & done - sleep 5 + wait for service in ${SERVICES[*]}; do - echo -n "Starting EDEX Camel ($service): " - startEDEX $service - echo OK + echo "Starting EDEX Camel ($service): " + startEDEX $service & done + wait RETVAL=$? ;; status) From b8b3b9eb8ef0d4577523ae264223b629de8a0027 Mon Sep 17 00:00:00 2001 From: Mike Duff Date: Tue, 15 Apr 2014 12:14:58 -0500 Subject: [PATCH 026/188] Issue #2907 - Change directory name to match project name. Change-Id: I9f3cd8bc28047b1da295dcc6da5d91a2d3583848 Former-commit-id: db7f966c43292a321793655fe283cc3feacfd9f1 --- .../.classpath | 0 .../.project | 0 .../.settings/org.eclipse.jdt.core.prefs | 0 .../Documentation/SampleFiles/ReadMe | 0 .../Documentation/SampleFiles/RedbookCPCMenus.xml | 0 .../Documentation/SampleFiles/RedbookHPCMenus.xml | 0 .../Documentation/SampleFiles/RedbookHazardMenus.xml | 0 .../Documentation/SampleFiles/RedbookMPCMenus.xml | 0 .../Documentation/SampleFiles/RedbookNCOMenus.xml | 0 .../Documentation/SampleFiles/RedbookUAMenus.xml | 0 .../META-INF/MANIFEST.MF | 0 .../build.properties | 0 .../com.raytheon.edex.plugin.redbook.ecl | 0 .../res/spring/redbook-common.xml | 0 .../res/spring/redbook-ingest.xml | 0 .../src/com/raytheon/uf/edex/plugin/redbook/RedbookDecoder.java | 0 .../src/com/raytheon/uf/edex/plugin/redbook/RedbookSeparator.java | 0 .../src/com/raytheon/uf/edex/plugin/redbook/dao/RedbookDao.java | 0 .../raytheon/uf/edex/plugin/redbook/decoder/RedbookFcstMap.java | 0 .../raytheon/uf/edex/plugin/redbook/decoder/RedbookParser.java | 0 .../uf/edex/plugin/redbook/ingest/RedbookMenuSubscriber.java | 0 .../com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntry.java | 0 .../raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntryType.java | 0 .../uf/edex/plugin/redbook/ingest/xml/RedbookMenusXML.java | 0 .../raytheon/uf/edex/plugin/redbook/menu/RedbookCpcMenuUtil.java | 0 .../uf/edex/plugin/redbook/menu/RedbookHazardsMenuUtil.java | 0 .../raytheon/uf/edex/plugin/redbook/menu/RedbookHpcMenuUtil.java | 0 .../com/raytheon/uf/edex/plugin/redbook/menu/RedbookMenuUtil.java | 0 .../raytheon/uf/edex/plugin/redbook/menu/RedbookMpcMenuUtil.java | 0 .../raytheon/uf/edex/plugin/redbook/menu/RedbookNcoMenuUtil.java | 0 .../raytheon/uf/edex/plugin/redbook/menu/RedbookUaMenuUtil.java | 0 .../utility/common_static/base/path/redbookPathKeys.xml | 0 .../utility/common_static/base/purge/redbookPurgeRules.xml | 0 .../utility/edex_static/base/distribution/redbook.xml | 0 .../utility/edex_static/base/redbook/redbookFcstMap.xml | 0 35 files changed, 0 insertions(+), 0 deletions(-) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/.classpath (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/.project (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/.settings/org.eclipse.jdt.core.prefs (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/Documentation/SampleFiles/ReadMe (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/Documentation/SampleFiles/RedbookCPCMenus.xml (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/Documentation/SampleFiles/RedbookHPCMenus.xml (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/Documentation/SampleFiles/RedbookHazardMenus.xml (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/Documentation/SampleFiles/RedbookMPCMenus.xml (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/Documentation/SampleFiles/RedbookNCOMenus.xml (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/Documentation/SampleFiles/RedbookUAMenus.xml (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/META-INF/MANIFEST.MF (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/build.properties (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/com.raytheon.edex.plugin.redbook.ecl (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/res/spring/redbook-common.xml (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/res/spring/redbook-ingest.xml (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/RedbookDecoder.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/RedbookSeparator.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/dao/RedbookDao.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookFcstMap.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookParser.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/ingest/RedbookMenuSubscriber.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntry.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntryType.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/RedbookMenusXML.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookCpcMenuUtil.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHazardsMenuUtil.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHpcMenuUtil.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMenuUtil.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMpcMenuUtil.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookNcoMenuUtil.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookUaMenuUtil.java (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/utility/common_static/base/path/redbookPathKeys.xml (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/utility/common_static/base/purge/redbookPurgeRules.xml (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/utility/edex_static/base/distribution/redbook.xml (100%) rename edexOsgi/{com.raytheon.uf.edex.dataplugin.redbook => com.raytheon.uf.edex.plugin.redbook}/utility/edex_static/base/redbook/redbookFcstMap.xml (100%) diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/.classpath b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/.classpath similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/.classpath rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/.classpath diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/.project b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/.project similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/.project rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/.project diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/.settings/org.eclipse.jdt.core.prefs b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/.settings/org.eclipse.jdt.core.prefs similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/.settings/org.eclipse.jdt.core.prefs rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/.settings/org.eclipse.jdt.core.prefs diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/ReadMe b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/Documentation/SampleFiles/ReadMe similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/ReadMe rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/Documentation/SampleFiles/ReadMe diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookCPCMenus.xml b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/Documentation/SampleFiles/RedbookCPCMenus.xml similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookCPCMenus.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/Documentation/SampleFiles/RedbookCPCMenus.xml diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookHPCMenus.xml b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/Documentation/SampleFiles/RedbookHPCMenus.xml similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookHPCMenus.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/Documentation/SampleFiles/RedbookHPCMenus.xml diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookHazardMenus.xml b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/Documentation/SampleFiles/RedbookHazardMenus.xml similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookHazardMenus.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/Documentation/SampleFiles/RedbookHazardMenus.xml diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookMPCMenus.xml b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/Documentation/SampleFiles/RedbookMPCMenus.xml similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookMPCMenus.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/Documentation/SampleFiles/RedbookMPCMenus.xml diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookNCOMenus.xml b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/Documentation/SampleFiles/RedbookNCOMenus.xml similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookNCOMenus.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/Documentation/SampleFiles/RedbookNCOMenus.xml diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookUAMenus.xml b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/Documentation/SampleFiles/RedbookUAMenus.xml similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/Documentation/SampleFiles/RedbookUAMenus.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/Documentation/SampleFiles/RedbookUAMenus.xml diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/META-INF/MANIFEST.MF similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/META-INF/MANIFEST.MF rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/META-INF/MANIFEST.MF diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/build.properties b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/build.properties similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/build.properties rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/build.properties diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/com.raytheon.edex.plugin.redbook.ecl b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/com.raytheon.edex.plugin.redbook.ecl similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/com.raytheon.edex.plugin.redbook.ecl rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/com.raytheon.edex.plugin.redbook.ecl diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/res/spring/redbook-common.xml b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/res/spring/redbook-common.xml similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/res/spring/redbook-common.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/res/spring/redbook-common.xml diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/res/spring/redbook-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/res/spring/redbook-ingest.xml similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/res/spring/redbook-ingest.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/res/spring/redbook-ingest.xml diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/RedbookDecoder.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/RedbookDecoder.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/RedbookDecoder.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/RedbookDecoder.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/RedbookSeparator.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/RedbookSeparator.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/RedbookSeparator.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/RedbookSeparator.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/dao/RedbookDao.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/dao/RedbookDao.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/dao/RedbookDao.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/dao/RedbookDao.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookFcstMap.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookFcstMap.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookFcstMap.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookFcstMap.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookParser.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookParser.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookParser.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/decoder/RedbookParser.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/RedbookMenuSubscriber.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/RedbookMenuSubscriber.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/RedbookMenuSubscriber.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/RedbookMenuSubscriber.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntry.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntry.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntry.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntry.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntryType.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntryType.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntryType.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/MenuEntryType.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/RedbookMenusXML.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/RedbookMenusXML.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/RedbookMenusXML.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/ingest/xml/RedbookMenusXML.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookCpcMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookCpcMenuUtil.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookCpcMenuUtil.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookCpcMenuUtil.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHazardsMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHazardsMenuUtil.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHazardsMenuUtil.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHazardsMenuUtil.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHpcMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHpcMenuUtil.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHpcMenuUtil.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookHpcMenuUtil.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMenuUtil.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMenuUtil.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMenuUtil.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMpcMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMpcMenuUtil.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMpcMenuUtil.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMpcMenuUtil.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookNcoMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookNcoMenuUtil.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookNcoMenuUtil.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookNcoMenuUtil.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookUaMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookUaMenuUtil.java similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookUaMenuUtil.java rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookUaMenuUtil.java diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/common_static/base/path/redbookPathKeys.xml b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/utility/common_static/base/path/redbookPathKeys.xml similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/common_static/base/path/redbookPathKeys.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/utility/common_static/base/path/redbookPathKeys.xml diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/common_static/base/purge/redbookPurgeRules.xml b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/utility/common_static/base/purge/redbookPurgeRules.xml similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/common_static/base/purge/redbookPurgeRules.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/utility/common_static/base/purge/redbookPurgeRules.xml diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/edex_static/base/distribution/redbook.xml b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/utility/edex_static/base/distribution/redbook.xml similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/edex_static/base/distribution/redbook.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/utility/edex_static/base/distribution/redbook.xml diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/edex_static/base/redbook/redbookFcstMap.xml b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/utility/edex_static/base/redbook/redbookFcstMap.xml similarity index 100% rename from edexOsgi/com.raytheon.uf.edex.dataplugin.redbook/utility/edex_static/base/redbook/redbookFcstMap.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.redbook/utility/edex_static/base/redbook/redbookFcstMap.xml From ecbd0d57209ce94f1b1ab5ec1b8ef76091eb1fc7 Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Tue, 15 Apr 2014 11:40:18 -0500 Subject: [PATCH 027/188] Issue #2726: Fix context mappings for topics Change-Id: I636883170c5061cdaf42cbfafffdd4b4b7e3e23f Former-commit-id: b3d978d0e22b371eaa826d856156ba5360ee7be9 --- .../edex/esb/camel/context/ContextData.java | 28 +++++++++++++++---- .../Installer.edex/scripts/init.d/edex_camel | 4 +++ 2 files changed, 27 insertions(+), 5 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextData.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextData.java index bf6b01c8ac..8070afe4a5 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextData.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextData.java @@ -21,9 +21,11 @@ package com.raytheon.uf.edex.esb.camel.context; import java.util.Collections; import java.util.HashMap; +import java.util.HashSet; import java.util.LinkedList; import java.util.List; import java.util.Map; +import java.util.Set; import java.util.regex.Matcher; import java.util.regex.Pattern; @@ -52,6 +54,18 @@ import com.raytheon.uf.edex.core.EdexException; * @version 1.0 */ public class ContextData { + /** + * Set of endpoint types that allow multiple consumers. + */ + private static final Set MULTIPLE_CONSUMER_TYPES; + + static { + Set multipleConsumerTypes = new HashSet(1, 1); + multipleConsumerTypes.add("topic"); + MULTIPLE_CONSUMER_TYPES = Collections + .unmodifiableSet(multipleConsumerTypes); + } + private final List contexts; private final Map consumerRouteMapping; @@ -63,7 +77,7 @@ public class ContextData { * the endpoint URI. */ private static final Pattern endpointUriParsePattern = Pattern - .compile("([^:]+)://([^?]+)"); + .compile("(?:[^:]+:)*([^:]+):(?://)?([^?]+)\\??.*$"); /** * Parses passed contexts for route and endpoint data about all contexts. @@ -78,9 +92,11 @@ public class ContextData { .unmodifiableMap(generateRouteMappings(this.contexts)); Map idUriMapping = new HashMap( consumerRouteMapping.size(), 1); - for (Route route : consumerRouteMapping.values()) { - idUriMapping.put(route.getId(), route.getEndpoint() - .getEndpointUri()); + for (CamelContext ctx : this.contexts) { + for (Route route : ctx.getRoutes()) { + idUriMapping.put(route.getId(), route.getEndpoint() + .getEndpointUri()); + } } this.routeIdUriMapping = Collections.unmodifiableMap(idUriMapping); @@ -109,7 +125,9 @@ public class ContextData { String endpointName = typeAndName.getSecond(); Route prev = routeMapping.put(endpointName, route); - if (prev != null) { + if ((prev != null) + && !MULTIPLE_CONSUMER_TYPES + .contains(typeAndName.getFirst())) { throw new ConfigurationException( "Two contexts listen to the same endpoint name [" + endpointName diff --git a/rpms/awips2.edex/Installer.edex/scripts/init.d/edex_camel b/rpms/awips2.edex/Installer.edex/scripts/init.d/edex_camel index e9b374ea67..a55038350e 100644 --- a/rpms/awips2.edex/Installer.edex/scripts/init.d/edex_camel +++ b/rpms/awips2.edex/Installer.edex/scripts/init.d/edex_camel @@ -218,6 +218,10 @@ case $func in stopEDEX $service & done wait + + # small sleep for wrapper lock to disappear so that we don't make .1 version of log files + sleep 5 + for service in ${SERVICES[*]}; do echo "Starting EDEX Camel ($service): " From a2354a1d2abf9ce86f72be08eb8f72a0ed0767ea Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Tue, 15 Apr 2014 13:16:17 -0500 Subject: [PATCH 028/188] Issue #2984 another attempt to fix build Change-Id: Ie7a678bc9b56072e0c5d7d4b9f5cbefc99a9ebfb Former-commit-id: 38195dc5de31cefd435f507a3aa9f7f60965c0ff --- rpms/awips2.edex/Installer.edex/component.spec | 1 - 1 file changed, 1 deletion(-) diff --git a/rpms/awips2.edex/Installer.edex/component.spec b/rpms/awips2.edex/Installer.edex/component.spec index 5982cf19a0..a60fc03fa9 100644 --- a/rpms/awips2.edex/Installer.edex/component.spec +++ b/rpms/awips2.edex/Installer.edex/component.spec @@ -172,7 +172,6 @@ rm -rf ${RPM_BUILD_ROOT} /awips2/edex/lib/* %dir /awips2/edex/logs %dir /awips2/edex/webapps -/awips2/edex/webapps/* %dir /awips2/edex/bin/yajsw /awips2/edex/bin/yajsw/* From ba1f83db17abbee47003d54cff5e5aaeb5419ef4 Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Tue, 15 Apr 2014 14:28:03 -0500 Subject: [PATCH 029/188] Issue #2726: Update endpoint pattern and remove System.out.printlns Change-Id: I6d54cf695b8e339f9ac84b0a901cd47118e1872d Former-commit-id: a724d7a0ed98f8f2860325a8578cf38e71e3ffcf --- .../META-INF/MANIFEST.MF | 1 + .../src/com/raytheon/uf/edex/esb/Main.java | 88 +++++++++++-------- .../raytheon/uf/edex/esb/camel/Executor.java | 79 ++++++++--------- .../edex/esb/camel/context/ContextData.java | 21 +---- 4 files changed, 93 insertions(+), 96 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/META-INF/MANIFEST.MF index 300e7c7726..d50e09c69a 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/META-INF/MANIFEST.MF @@ -6,3 +6,4 @@ Bundle-Version: 1.12.1174.qualifier Bundle-Vendor: Raytheon Main-Class: com.raytheon.uf.edex.esb.Main Bundle-RequiredExecutionEnvironment: JavaSE-1.6 +Require-Bundle: org.slf4j diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/src/com/raytheon/uf/edex/esb/Main.java b/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/src/com/raytheon/uf/edex/esb/Main.java index 8dc121d339..02fbcd6644 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/src/com/raytheon/uf/edex/esb/Main.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/src/com/raytheon/uf/edex/esb/Main.java @@ -32,11 +32,13 @@ import java.util.ArrayList; import java.util.Arrays; import java.util.Comparator; import java.util.HashSet; -import java.util.Iterator; import java.util.List; import java.util.Set; import java.util.StringTokenizer; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + /** * Provides a launcher for starting the ESB * @@ -47,8 +49,9 @@ import java.util.StringTokenizer; * SOFTWARE HISTORY * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Nov 14, 2008 chammack Initial creation - * Feb 15, 2013 1638 mschenke Removed reference to unused "stop" method + * Nov 14, 2008 chammack Initial creation. + * Feb 15, 2013 1638 mschenke Removed reference to unused "stop" method. + * Apr 15, 2014 2726 rjpeter Use slf4j logger. * * * @author chammack @@ -61,14 +64,16 @@ public class Main { private File edexHome; - private Set classPath = new HashSet(); + private final Set classPath = new HashSet(); - private Set extensions = new HashSet(); + private final Set extensions = new HashSet(); private ClassLoader classLoader; private static final int MAXIMUM_RECURSION_DEPTH = 6; + private static final Logger logger = LoggerFactory.getLogger(Main.class); + public static void main(String[] args) { boolean valid = true; @@ -82,9 +87,11 @@ public class Main { } if (!valid) { - System.out.println("Invalid or missing arguments."); - System.out.println("Usage: edex [operation]"); - System.out.println(" where operation is start."); + StringBuilder msg = new StringBuilder(200); + msg.append("Invalid or missing arguments.") + .append("\nUsage: edex [operation]") + .append("\n where operation is start."); + logger.error(msg.toString()); System.exit(0); } @@ -121,10 +128,12 @@ public class Main { try { fr = new FileReader(banner); br = new BufferedReader(fr); + StringBuilder msg = new StringBuilder(250); while (br.ready()) { String line = br.readLine(); - System.out.println(line); + msg.append("\n").append(line); } + logger.info(msg.toString()); } catch (Throwable e) { // ignore } finally { @@ -136,12 +145,13 @@ public class Main { } } - if (fr != null) + if (fr != null) { try { fr.close(); } catch (RuntimeException e) { // ignore } + } } @@ -152,16 +162,17 @@ public class Main { } System.exit(0); } catch (ClassNotFoundException e) { - System.out.println("Could not load class: " + e.getMessage()); + logger.error("Could not load class", e); if (cl != null) { - System.out.println("Class loader setup: "); - printClassLoaderTree(cl); + StringBuilder msg = new StringBuilder(1000); + msg.append("Class loader setup:"); + printClassLoaderTree(cl, msg); + logger.info(msg.toString()); } System.exit(1); } catch (Throwable e) { - e.printStackTrace(); - printClassLoaderTree(cl); + logger.error("Error occurred during startup: ", e); System.exit(1); } } @@ -173,13 +184,12 @@ public class Main { ArrayList urls = new ArrayList(500); - for (Iterator iter = classPath.iterator(); iter.hasNext();) { - File dir = iter.next(); + for (File dir : classPath) { try { urls.add(dir.toURI().toURL()); } catch (MalformedURLException e) { - System.out.println("Bad directory entry: " + dir - + ":: Skipping."); + logger.warn("Bad directory entry: " + dir + + ":: Skipping.", e); } } @@ -188,6 +198,7 @@ public class Main { // Sort the dirs so that classpath built is // consistently in the same order Arrays.sort(extensionsArray, new Comparator() { + @Override public int compare(File f1, File f2) { return f1.getPath().compareTo(f2.getPath()); } @@ -201,19 +212,20 @@ public class Main { // Sort the jars so that classpath built is // consistently in the same order Arrays.sort(files, new Comparator() { + @Override public int compare(File f1, File f2) { return f1.getName().compareTo(f2.getName()); } }); - for (int j = 0; j < files.length; j++) { - if (files[j].getName().endsWith(".zip") - || files[j].getName().endsWith(".jar")) { + for (File file : files) { + if (file.getName().endsWith(".zip") + || file.getName().endsWith(".jar")) { try { - urls.add(files[j].toURI().toURL()); + urls.add(file.toURI().toURL()); } catch (MalformedURLException e) { - System.out.println("Bad jar entry: " - + dir + ":: Skipping."); + logger.warn("Bad jar entry: " + dir + + ":: Skipping.", e); } } } @@ -241,10 +253,8 @@ public class Main { } } } else { - System.out - .println("WARNING: " - + file - + " exceeded maximum recursion depth. Not traversing further."); + logger.warn(file + + ": exceeded maximum recursion depth. Not traversing further."); } } @@ -281,7 +291,7 @@ public class Main { } public void addClassPathList(String fileList) { - if (fileList != null && fileList.length() > 0) { + if ((fileList != null) && (fileList.length() > 0)) { StringTokenizer tokenizer = new StringTokenizer(fileList, ";"); while (tokenizer.hasMoreTokens()) { addClassPath(new File(tokenizer.nextToken())); @@ -303,28 +313,30 @@ public class Main { * @param cl * @return depth */ - private static int printClassLoaderTree(ClassLoader cl) { + private static int printClassLoaderTree(ClassLoader cl, StringBuilder msg) { int depth = 0; if (cl.getParent() != null) { - depth = printClassLoaderTree(cl.getParent()) + 1; + depth = printClassLoaderTree(cl.getParent(), msg) + 1; } - StringBuffer indent = new StringBuffer(); + StringBuilder indent = new StringBuilder(2 * depth); for (int i = 0; i < depth; i++) { indent.append(" "); } if (cl instanceof URLClassLoader) { URLClassLoader ucl = (URLClassLoader) cl; - System.out.println(indent + cl.getClass().getName() + " {"); + msg.append("\n").append(indent).append(cl.getClass().getName()) + .append(" {"); URL[] urls = ucl.getURLs(); - for (int i = 0; i < urls.length; i++) { - System.out.println(indent + " " + urls[i]); + for (URL url : urls) { + msg.append("\n").append(indent).append(" ").append(url); } - System.out.println(indent + "}"); + msg.append("\n").append(indent).append("}"); } else { - System.out.println(indent + cl.getClass().getName()); + msg.append("\n").append(indent).append(cl.getClass().getName()); } + return depth; } diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/Executor.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/Executor.java index 2a11413746..4b6fb4a58a 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/Executor.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/Executor.java @@ -29,6 +29,8 @@ import java.util.List; import java.util.Properties; import java.util.concurrent.CountDownLatch; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; import org.springframework.context.support.ClassPathXmlApplicationContext; import com.raytheon.uf.common.time.util.TimeUtil; @@ -67,6 +69,9 @@ public class Executor { private static final CountDownLatch shutdownLatch = new CountDownLatch(1); + private static final Logger logger = LoggerFactory + .getLogger(Executor.class); + public static void start() throws Exception { final long t0 = System.currentTimeMillis(); @@ -76,24 +81,23 @@ public class Executor { ContextManager ctxMgr = ContextManager.getInstance(); long t1 = System.currentTimeMillis(); - System.out - .println("**************************************************"); - System.out - .println("* EDEX ESB is shutting down *"); - System.out - .println("**************************************************"); + StringBuilder msg = new StringBuilder(250); + msg.append( + "\n**************************************************") + .append("\n* EDEX ESB is shutting down *") + .append("\n**************************************************"); + logger.info(msg.toString()); ctxMgr.stopContexts(); long t2 = System.currentTimeMillis(); - System.out - .println("**************************************************"); - System.out - .println("* EDEX ESB is shut down *"); - System.out.println("* Total time to shutdown: " - + TimeUtil.prettyDuration(t2 - t1)); - System.out.println("* EDEX ESB uptime: " - + TimeUtil.prettyDuration(t2 - t0)); - System.out - .println("**************************************************"); + msg.setLength(0); + msg.append("\n**************************************************"); + msg.append("\n* EDEX ESB is shut down *"); + msg.append("\n* Total time to shutdown: ") + .append(TimeUtil.prettyDuration(t2 - t1)).append(""); + msg.append("\n* EDEX ESB uptime: ") + .append(TimeUtil.prettyDuration(t2 - t0)).append(""); + msg.append("\n**************************************************"); + logger.info(msg.toString()); shutdownLatch.countDown(); } }); @@ -137,29 +141,24 @@ public class Executor { String modeName = System.getProperty("edex.run.mode"); if ((modeName != null) && (modeName.length() > 0)) { - System.out.println("EDEX run configuration: " + modeName); + logger.info("EDEX run configuration: " + modeName); } else { - System.out - .println("No EDEX run configuration specified, defaulting to use all discovered spring XML files"); + logger.info("No EDEX run configuration specified, defaulting to use all discovered spring XML files"); } - System.out.println("EDEX site configuration: " + logger.info("EDEX site configuration: " + System.getProperty("aw.site.identifier")); List discoveredPlugins = EDEXModesUtil.extractSpringXmlFiles( xmlFiles, modeName); - System.out.println(); - System.out.println(" "); - System.out.println("EDEX configuration files: "); - System.out.println("-----------------------"); - System.out.println(printList(springList)); - System.out.println(" "); - System.out.println(" "); - System.out.println("Spring-enabled Plugins:"); - System.out.println("-----------------------"); - System.out.println(printList(discoveredPlugins)); - System.out.println(" "); - System.out.println(" "); + StringBuilder msg = new StringBuilder(1000); + msg.append("\n\nEDEX configuration files: "); + msg.append("\n-----------------------"); + msg.append("\n").append(printList(springList)); + msg.append("\n\nSpring-enabled Plugins:"); + msg.append("\n-----------------------"); + msg.append("\n").append(printList(discoveredPlugins)).append("\n"); + logger.info(msg.toString()); ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext( xmlFiles.toArray(new String[xmlFiles.size()])); @@ -171,14 +170,14 @@ public class Executor { ctxMgr.startContexts(); long t1 = System.currentTimeMillis(); - System.out - .println("**************************************************"); - System.out - .println("* EDEX ESB is now operational *"); - System.out.println("* Total startup time: " - + TimeUtil.prettyDuration(t1 - t0)); - System.out - .println("**************************************************"); + msg.setLength(0); + msg.append("\n**************************************************"); + msg.append("\n* EDEX ESB is now operational *"); + msg.append("\n* Total startup time: ").append( + TimeUtil.prettyDuration(t1 - t0)); + msg.append("\n**************************************************"); + logger.info(msg.toString()); + msg = null; System.setProperty("System.status", "Operational"); EDEXUtil.notifyIsRunning(); diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextData.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextData.java index 8070afe4a5..ef38e8babf 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextData.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextData.java @@ -21,11 +21,9 @@ package com.raytheon.uf.edex.esb.camel.context; import java.util.Collections; import java.util.HashMap; -import java.util.HashSet; import java.util.LinkedList; import java.util.List; import java.util.Map; -import java.util.Set; import java.util.regex.Matcher; import java.util.regex.Pattern; @@ -46,7 +44,7 @@ import com.raytheon.uf.edex.core.EdexException; * * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Apr 10, 2014 2726 rjpeter Initial creation + * Apr 10, 2014 2726 rjpeter Initial creation. * * * @@ -54,18 +52,6 @@ import com.raytheon.uf.edex.core.EdexException; * @version 1.0 */ public class ContextData { - /** - * Set of endpoint types that allow multiple consumers. - */ - private static final Set MULTIPLE_CONSUMER_TYPES; - - static { - Set multipleConsumerTypes = new HashSet(1, 1); - multipleConsumerTypes.add("topic"); - MULTIPLE_CONSUMER_TYPES = Collections - .unmodifiableSet(multipleConsumerTypes); - } - private final List contexts; private final Map consumerRouteMapping; @@ -77,7 +63,7 @@ public class ContextData { * the endpoint URI. */ private static final Pattern endpointUriParsePattern = Pattern - .compile("(?:[^:]+:)*([^:]+):(?://)?([^?]+)\\??.*$"); + .compile("([^:]+)://([^?]+)"); /** * Parses passed contexts for route and endpoint data about all contexts. @@ -126,8 +112,7 @@ public class ContextData { Route prev = routeMapping.put(endpointName, route); if ((prev != null) - && !MULTIPLE_CONSUMER_TYPES - .contains(typeAndName.getFirst())) { + && !endpointName.startsWith("topic:")) { throw new ConfigurationException( "Two contexts listen to the same endpoint name [" + endpointName From 8ab1bab97477d9c4ddc1cae7b3b8fe0aa8f3c268 Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Mon, 7 Apr 2014 10:15:49 -0500 Subject: [PATCH 030/188] Issue #2903 made xmpp reconnect an explicit action by user moved non-session classes out of session package connection classes moved to connection package made separate classes for connection listeners removed password from heap login dialog remembers last server used added reconnect handler to prompt user to re-login after disconnect Former-commit-id: 762e7d3a1ff47f794aa843d2b159ac78b4ab12a3 --- .../META-INF/MANIFEST.MF | 4 +- .../collaboration/comm/identity/ISession.java | 2 +- .../roster/ISubscriptionResponder.java | 2 +- .../{session => account}/AccountManager.java | 6 +- .../ClientAuthManager.java | 3 +- .../ISubscriptionRequestCompleteAction.java | 3 +- .../SubscriptionPacketListener.java | 4 +- .../CollaborationConnection.java | 519 ++++++------------ .../CollaborationConnectionData.java | 27 +- .../PeerToPeerCommHelper.java | 9 +- .../connection/SessionInviteListener.java | 149 +++++ .../connection/SmackConfigScrubber.java | 97 ++++ .../connection/XmppConnectionListener.java | 123 +++++ .../comm/provider/session/BaseSession.java | 1 + .../comm/provider/session/PeerToPeerChat.java | 4 +- .../session/SharedDisplaySession.java | 3 + .../comm/provider/session/VenueSession.java | 6 +- .../comm/provider/user/ContactsManager.java | 89 ++- .../CollaborationObjectEventStorage.java | 4 +- .../ui/AbstractUserLabelProvider.java | 2 +- .../ui/ChangePasswordDialog.java | 2 +- .../ui/CollaborationGroupView.java | 51 +- .../ui/ConnectionSubscriber.java | 11 +- .../collaboration/ui/CreateGroupDialog.java | 2 +- .../collaboration/ui/CreateSessionDialog.java | 4 +- .../collaboration/ui/DisconnectHandler.java | 101 ++++ .../uf/viz/collaboration/ui/InviteDialog.java | 2 +- .../collaboration/ui/SubRequestDialog.java | 2 +- .../collaboration/ui/UserSearchDialog.java | 2 +- .../ui/UsersTreeContentProvider.java | 2 +- .../ui/UsersTreeLabelProvider.java | 2 +- .../ui/actions/AddToGroupAction.java | 2 +- .../ui/actions/ArchiveViewerAction.java | 2 +- .../ui/actions/ChangeFontAction.java | 2 +- .../ui/actions/ChangePasswordAction.java | 2 +- .../ui/actions/ChangeRoleAction.java | 2 +- .../ui/actions/ChangeSiteAction.java | 2 +- .../ui/actions/ChangeStatusAction.java | 2 +- .../ui/actions/ChangeStatusMessageAction.java | 2 +- .../ui/actions/CollaborationGroupAction.java | 25 +- .../ui/actions/CreateGroupAction.java | 2 +- .../ui/actions/CreateSessionAction.java | 2 +- .../ui/actions/DeleteGroupAction.java | 2 +- .../ui/actions/DisplayFeedAction.java | 2 +- .../ui/actions/InviteAction.java | 2 +- .../ui/actions/LinkToEditorAction.java | 2 +- .../collaboration/ui/actions/LoginAction.java | 24 +- .../ui/actions/LogoutAction.java | 11 +- .../ui/actions/PeerToPeerChatAction.java | 2 +- .../ui/actions/RemoveFromGroupAction.java | 2 +- .../ui/actions/RemoveFromRosterAction.java | 2 +- .../ui/actions/SendSubReqAction.java | 2 +- .../ui/actions/UserSearchAction.java | 2 +- .../ui/data/CollaborationGroupContainer.java | 2 +- .../ui/data/SessionGroupContainer.java | 2 +- .../collaboration/ui/jobs/AwayTimeOut.java | 2 +- .../collaboration/ui/login/LoginDialog.java | 119 ++-- .../ui/notifier/NotifierTools.java | 2 +- ...CollaborationAlertWordsPreferencePage.java | 2 +- .../ui/prefs/CollaborationPreferencePage.java | 2 +- .../prefs/ContactNotifierPreferencePage.java | 2 +- .../collaboration/ui/prefs/HandleUtil.java | 2 +- .../ui/prefs/SubscriptionResponderImpl.java | 4 +- .../ui/session/AbstractSessionView.java | 2 +- .../ui/session/ParticipantsLabelProvider.java | 2 +- .../ui/session/PeerToPeerView.java | 2 +- .../ui/session/SessionFeedView.java | 2 +- .../ui/session/SessionMsgArchiveBrowser.java | 2 +- .../collaboration/ui/session/SessionView.java | 2 +- 69 files changed, 945 insertions(+), 542 deletions(-) rename cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/{session => account}/AccountManager.java (96%) rename cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/{session => account}/ClientAuthManager.java (98%) rename cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/{session => account}/ISubscriptionRequestCompleteAction.java (91%) rename cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/{session => account}/SubscriptionPacketListener.java (96%) rename cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/{session => connection}/CollaborationConnection.java (55%) rename cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/{session => connection}/CollaborationConnectionData.java (88%) rename cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/{session => connection}/PeerToPeerCommHelper.java (97%) create mode 100644 cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/SessionInviteListener.java create mode 100644 cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/SmackConfigScrubber.java create mode 100644 cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/XmppConnectionListener.java create mode 100644 cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/DisconnectHandler.java diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/META-INF/MANIFEST.MF b/cave/com.raytheon.uf.viz.collaboration.comm/META-INF/MANIFEST.MF index 776585c02e..94affcc88b 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/META-INF/MANIFEST.MF +++ b/cave/com.raytheon.uf.viz.collaboration.comm/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Collaboratioin Bundle-SymbolicName: com.raytheon.uf.viz.collaboration.comm;singleton:=true -Bundle-Version: 1.13.0.qualifier +Bundle-Version: 1.14.0.qualifier Bundle-Activator: com.raytheon.uf.viz.collaboration.comm.Activator Bundle-Vendor: RAYTHEON Eclipse-RegisterBuddy: com.raytheon.uf.viz.core @@ -32,6 +32,8 @@ Export-Package: com.raytheon.uf.viz.collaboration.comm, com.raytheon.uf.viz.collaboration.comm.identity.user, com.raytheon.uf.viz.collaboration.comm.packet, com.raytheon.uf.viz.collaboration.comm.provider, + com.raytheon.uf.viz.collaboration.comm.provider.account, + com.raytheon.uf.viz.collaboration.comm.provider.connection, com.raytheon.uf.viz.collaboration.comm.provider.event, com.raytheon.uf.viz.collaboration.comm.provider.info, com.raytheon.uf.viz.collaboration.comm.provider.session, diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/ISession.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/ISession.java index 3ca27459fe..9dd80fb3ad 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/ISession.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/ISession.java @@ -40,7 +40,7 @@ package com.raytheon.uf.viz.collaboration.comm.identity; import com.raytheon.uf.viz.collaboration.comm.identity.event.IEventPublisher; import com.raytheon.uf.viz.collaboration.comm.identity.user.IUser; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; /** * Base interface for sessions in which the client is interacting with others on diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/roster/ISubscriptionResponder.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/roster/ISubscriptionResponder.java index 708c2e7974..a0f5aa4748 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/roster/ISubscriptionResponder.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/roster/ISubscriptionResponder.java @@ -19,7 +19,7 @@ **/ package com.raytheon.uf.viz.collaboration.comm.identity.roster; -import com.raytheon.uf.viz.collaboration.comm.provider.session.ISubscriptionRequestCompleteAction; +import com.raytheon.uf.viz.collaboration.comm.provider.account.ISubscriptionRequestCompleteAction; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; /** diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/AccountManager.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/AccountManager.java similarity index 96% rename from cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/AccountManager.java rename to cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/AccountManager.java index c3f3ec0739..6aadbb1bd0 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/AccountManager.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/AccountManager.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.uf.viz.collaboration.comm.provider.session; +package com.raytheon.uf.viz.collaboration.comm.provider.account; import java.util.Arrays; import java.util.Map; @@ -34,6 +34,7 @@ import com.raytheon.uf.viz.collaboration.comm.identity.ISession; import com.raytheon.uf.viz.collaboration.comm.identity.IVenueSession; import com.raytheon.uf.viz.collaboration.comm.identity.roster.ISubscriptionResponder; import com.raytheon.uf.viz.collaboration.comm.provider.Tools; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.event.UserPresenceChangedEvent; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; @@ -60,6 +61,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; * Feb 12, 2014 2797 bclement added protective copy to sendPresence * Feb 13, 2014 2755 bclement added user input for which group to add contact to * Apr 07, 2014 2785 mpduff Moved PacketListener implementation to its own class + * Apr 14, 2014 2903 bclement moved from session subpackage to account, made constructor public * * * @@ -81,7 +83,7 @@ public class AccountManager implements IAccountManager { * * @param adapter */ - AccountManager(CollaborationConnection manager) { + public AccountManager(CollaborationConnection manager) { sessionManager = manager; subscriptionEventListener = new SubscriptionPacketListener( sessionManager); diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/ClientAuthManager.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/ClientAuthManager.java similarity index 98% rename from cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/ClientAuthManager.java rename to cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/ClientAuthManager.java index f529f675ab..a037e07377 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/ClientAuthManager.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/ClientAuthManager.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.uf.viz.collaboration.comm.provider.session; +package com.raytheon.uf.viz.collaboration.comm.provider.account; import java.net.URI; import java.security.GeneralSecurityException; @@ -50,6 +50,7 @@ import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Feb 24, 2014 2756 bclement Initial creation + * Apr 14, 2014 2903 bclement moved from session subpackage to account * * * diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/ISubscriptionRequestCompleteAction.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/ISubscriptionRequestCompleteAction.java similarity index 91% rename from cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/ISubscriptionRequestCompleteAction.java rename to cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/ISubscriptionRequestCompleteAction.java index 4d4dcbc4f6..5230322ea1 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/ISubscriptionRequestCompleteAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/ISubscriptionRequestCompleteAction.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.uf.viz.collaboration.comm.provider.session; +package com.raytheon.uf.viz.collaboration.comm.provider.account; import com.raytheon.uf.viz.collaboration.comm.identity.roster.SubscriptionResponse; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; @@ -32,6 +32,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Apr 04, 2014 2785 mpduff Initial creation + * Apr 14, 2014 2903 bclement moved from session subpackage to account * * * diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SubscriptionPacketListener.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/SubscriptionPacketListener.java similarity index 96% rename from cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SubscriptionPacketListener.java rename to cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/SubscriptionPacketListener.java index 6eaca2e188..a5f23cd2e0 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SubscriptionPacketListener.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/SubscriptionPacketListener.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.uf.viz.collaboration.comm.provider.session; +package com.raytheon.uf.viz.collaboration.comm.provider.account; import org.jivesoftware.smack.PacketListener; import org.jivesoftware.smack.RosterEntry; @@ -32,6 +32,7 @@ import com.raytheon.uf.viz.collaboration.comm.identity.event.IRosterChangeEvent; import com.raytheon.uf.viz.collaboration.comm.identity.event.RosterChangeType; import com.raytheon.uf.viz.collaboration.comm.identity.roster.ISubscriptionResponder; import com.raytheon.uf.viz.collaboration.comm.identity.roster.SubscriptionResponse; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.event.RosterChangeEvent; import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; import com.raytheon.uf.viz.collaboration.comm.provider.user.IDConverter; @@ -49,6 +50,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Apr 04, 2014 2785 mpduff Initial creation + * Apr 14, 2014 2903 bclement moved from session subpackage to account * * * diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/CollaborationConnection.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/CollaborationConnection.java similarity index 55% rename from cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/CollaborationConnection.java rename to cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/CollaborationConnection.java index 8197c7775d..bab15aa72c 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/CollaborationConnection.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/CollaborationConnection.java @@ -17,30 +17,21 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.uf.viz.collaboration.comm.provider.session; +package com.raytheon.uf.viz.collaboration.comm.provider.connection; import java.util.Collection; -import java.util.HashMap; import java.util.Map; import java.util.Map.Entry; import java.util.concurrent.ConcurrentHashMap; -import org.apache.commons.lang.StringUtils; -import org.jivesoftware.smack.Connection; import org.jivesoftware.smack.ConnectionConfiguration; -import org.jivesoftware.smack.ConnectionListener; -import org.jivesoftware.smack.Roster; -import org.jivesoftware.smack.RosterEntry; -import org.jivesoftware.smack.RosterListener; import org.jivesoftware.smack.XMPPConnection; import org.jivesoftware.smack.XMPPException; import org.jivesoftware.smack.filter.PacketTypeFilter; import org.jivesoftware.smack.packet.Message; import org.jivesoftware.smack.packet.Presence; -import org.jivesoftware.smack.packet.StreamError; import org.jivesoftware.smack.packet.XMPPError; import org.jivesoftware.smack.provider.ProviderManager; -import org.jivesoftware.smackx.muc.InvitationListener; import org.jivesoftware.smackx.muc.MultiUserChat; import com.google.common.eventbus.EventBus; @@ -54,24 +45,20 @@ import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; import com.raytheon.uf.viz.collaboration.comm.identity.IAccountManager; import com.raytheon.uf.viz.collaboration.comm.identity.ISession; import com.raytheon.uf.viz.collaboration.comm.identity.event.IEventPublisher; -import com.raytheon.uf.viz.collaboration.comm.identity.event.IRosterChangeEvent; import com.raytheon.uf.viz.collaboration.comm.identity.event.IVenueInvitationEvent; -import com.raytheon.uf.viz.collaboration.comm.identity.event.RosterChangeType; import com.raytheon.uf.viz.collaboration.comm.identity.invite.SharedDisplayVenueInvite; -import com.raytheon.uf.viz.collaboration.comm.identity.invite.VenueInvite; import com.raytheon.uf.viz.collaboration.comm.packet.SessionPayload; -import com.raytheon.uf.viz.collaboration.comm.packet.SessionPayload.PayloadType; import com.raytheon.uf.viz.collaboration.comm.packet.SessionPayloadProvider; -import com.raytheon.uf.viz.collaboration.comm.provider.Tools; -import com.raytheon.uf.viz.collaboration.comm.provider.event.RosterChangeEvent; -import com.raytheon.uf.viz.collaboration.comm.provider.event.ServerDisconnectEvent; -import com.raytheon.uf.viz.collaboration.comm.provider.event.VenueInvitationEvent; +import com.raytheon.uf.viz.collaboration.comm.provider.account.AccountManager; +import com.raytheon.uf.viz.collaboration.comm.provider.account.ClientAuthManager; import com.raytheon.uf.viz.collaboration.comm.provider.event.VenueUserEvent; +import com.raytheon.uf.viz.collaboration.comm.provider.session.CreateSessionData; +import com.raytheon.uf.viz.collaboration.comm.provider.session.PeerToPeerChat; +import com.raytheon.uf.viz.collaboration.comm.provider.session.SharedDisplaySession; +import com.raytheon.uf.viz.collaboration.comm.provider.session.VenueSession; import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; -import com.raytheon.uf.viz.collaboration.comm.provider.user.IDConverter; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserSearch; -import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueId; import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; /** @@ -119,6 +106,8 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; * changed session map to a concurrent hash map * Apr 07, 2014 2785 mpduff Changed the order of startup, sets up listeners before actually connecting. * Apr 09, 2014 2785 mpduff Throw error when not connected and the connection should exist. + * Apr 14, 2014 2903 bclement moved from session subpackage to connection, removed password from memory, + * moved listeners to own classes, reworked connect/register listeners/login order * * * @@ -140,13 +129,11 @@ public class CollaborationConnection implements IEventPublisher { private static final transient IUFStatusHandler statusHandler = UFStatus .getHandler(CollaborationConnection.class); - private static CollaborationConnection instance = null; + private static volatile CollaborationConnection instance = null; - private static Map instanceMap = new HashMap(); + private final Map sessions; - private Map sessions; - - private UserId user; + private final UserId user; private Presence userPresence; @@ -154,7 +141,7 @@ public class CollaborationConnection implements IEventPublisher { private IAccountManager accountManager = null; - private EventBus eventBus; + private final EventBus eventBus; private ContactsManager contactsMgr; @@ -162,6 +149,8 @@ public class CollaborationConnection implements IEventPublisher { private XMPPConnection connection; + private final ConnectionConfiguration smackConfig; + private ClientAuthManager authManager; private static boolean COMPRESS = true; @@ -178,59 +167,127 @@ public class CollaborationConnection implements IEventPublisher { } } + /** + * Returns the currently connected connection or null if it's not connected + * + * @return + */ + public static CollaborationConnection getConnection() { + return instance; + } + + /** + * Create a {@link CollaborationConnection} given the + * {@link CollaborationConnectionData} + * + * @param userData + * @return + * @throws CollaborationException + */ + public static CollaborationConnection createConnection( + CollaborationConnectionData userData) throws CollaborationException { + synchronized (CollaborationConnection.class) { + if (instance == null) { + instance = new CollaborationConnection(userData); + } else { + throw new CollaborationException("Already connected"); + } + } + + return getConnection(); + } + private CollaborationConnection(CollaborationConnectionData connectionData) throws CollaborationException { this.connectionData = connectionData; - init(); - } - - /** - * Initialize this object. - */ - private void init() throws CollaborationException { - eventBus = new EventBus(); - sessions = new ConcurrentHashMap(); - - HostAndPort hnp = HostAndPort.fromString(connectionData.getServer()); - ConnectionConfiguration conConfig; - if (hnp.hasPort()) { - conConfig = new ConnectionConfiguration(hnp.getHostText(), - hnp.getPort()); - } else { - conConfig = new ConnectionConfiguration(hnp.getHostText()); - } - - conConfig.setCompressionEnabled(COMPRESS); - - connection = new XMPPConnection(conConfig); - accountManager = new AccountManager(this); - + this.eventBus = new EventBus(); + this.sessions = new ConcurrentHashMap(); + this.smackConfig = createSmackConfiguration(connectionData); + /* connects to XMPP server, but doesn't log in */ + this.connection = createXmppConnection(smackConfig); + /* create managers and listeners before login */ + this.accountManager = new AccountManager(this); this.user = new UserId(connectionData.getUserName(), connection.getServiceName()); - - setupInternalConnectionListeners(); - getPeerToPeerSession(); - - instanceMap.put(connectionData, this); - if (instance == null) { - instance = this; - } + this.chatInstance = initPeerToPeerSession(); + this.contactsMgr = new ContactsManager(this, this.getXmppConnection()); + registerEventHandler(this.contactsMgr); + MultiUserChat.addInvitationListener(connection, + new SessionInviteListener(this)); + PeerToPeerCommHelper helper = new PeerToPeerCommHelper(this); + this.connection.addPacketListener(helper, new PacketTypeFilter( + Message.class)); + this.connection.addConnectionListener(new XmppConnectionListener(this)); + /* login called externally */ } /** - * connect to XMPP server and login + * Create smack xmpp configuration object from collaboration connection + * options + * + * @param connectionData + * @return + */ + private static ConnectionConfiguration createSmackConfiguration( + CollaborationConnectionData connectionData) { + ConnectionConfiguration rval; + HostAndPort hnp = HostAndPort.fromString(connectionData.getServer()); + if (hnp.hasPort()) { + rval = new ConnectionConfiguration(hnp.getHostText(), hnp.getPort()); + } else { + rval = new ConnectionConfiguration(hnp.getHostText()); + } + + rval.setCompressionEnabled(COMPRESS); + rval.setReconnectionAllowed(false); + return rval; + } + + /** + * Create xmpp connection object and connect. This method does not login + * + * @param config + * @return + * @throws CollaborationException + */ + private static XMPPConnection createXmppConnection( + ConnectionConfiguration config) throws CollaborationException { + XMPPConnection rval = new XMPPConnection(config); + try { + rval.connect(); + } catch (XMPPException e) { + throw new CollaborationException( + "Problem establishing connection to XMPP server", e); + } + return rval; + } + + /** + * Login to the XMPP server. This needs to be called after the + * CollaborationConnection has been created and initialized. + * + * @param password + * @throws CollaborationException + */ + public void login(String password) throws CollaborationException { + loginInternal(connectionData.getUserName(), password); + /* auth needs to be logged in to register public key */ + authManager = new ClientAuthManager(getXmppConnection()); + } + + /** + * login to XMPP server * * @param username * @param password * @throws CollaborationException */ - private void connectInternal(String username, String password) + private void loginInternal(String username, String password) throws CollaborationException { try { - connection.connect(); connection.login(username, password); } catch (XMPPException e) { - closeInternals(); + close(); // get a nice reason for the user String msg; XMPPError xmppErr = e.getXMPPError(); @@ -252,9 +309,15 @@ public class CollaborationConnection implements IEventPublisher { msg = e.getLocalizedMessage(); } throw new CollaborationException("Login failed: " + msg, e); + } finally { + /* remove password from smack */ + SmackConfigScrubber.scrubConfig(smackConfig); } } + /** + * @return login data used to create this connection + */ public CollaborationConnectionData getConnectionData() { return connectionData; } @@ -292,18 +355,25 @@ public class CollaborationConnection implements IEventPublisher { } /** - * Is this SessionManager currently connected? + * Is this client currently connected to the XMPP server? * - * @return Is this SessionManager currently connected? + * @return */ public boolean isConnected() { - return ((connection != null) && (connection.getConnectionID() != null)); + return connection != null && connection.isConnected(); } - private void closeInternals() { + /** + * close any open sessions and disconnect from XMPP server + */ + public void close() { + // Close any created sessions. + for (Entry entry : sessions.entrySet()) { + entry.getValue().close(); + } + sessions.clear(); + chatInstance = null; if (connection != null) { - - chatInstance = null; // Get rid of the account and roster managers if (connection.isConnected()) { connection.disconnect(); @@ -311,31 +381,11 @@ public class CollaborationConnection implements IEventPublisher { connection = null; } PeerToPeerCommHelper.reset(); - instanceMap.remove(connectionData); - if (this == instance) { - instance = null; - } - } - - /** - * - */ - public void close() { - if (connection != null) { - // Close any created sessions. - Collection toRemove = sessions.values(); - sessions.clear(); - for (ISession session : toRemove) { - if ((chatInstance != null) && chatInstance.equals(session)) { - chatInstance.close(); - chatInstance = null; - } else { - session.close(); - } + synchronized (CollaborationConnection.class) { + if (this == instance) { + instance = null; } - chatInstance = null; } - closeInternals(); } /** @@ -345,14 +395,23 @@ public class CollaborationConnection implements IEventPublisher { * @throws CollaborationException */ public ISession getPeerToPeerSession() throws CollaborationException { - if (chatInstance == null) { - chatInstance = new PeerToPeerChat(eventBus, this); - sessions.put(chatInstance.getSessionId(), chatInstance); - postEvent(chatInstance); - } return chatInstance; } + /** + * Create and initialize peer to peer chat session object. + * + * @return + * @throws CollaborationException + */ + private PeerToPeerChat initPeerToPeerSession() + throws CollaborationException { + PeerToPeerChat rval = new PeerToPeerChat(eventBus, this); + sessions.put(rval.getSessionId(), rval); + postEvent(rval); + return rval; + } + /** * Create shared display venue object. This does not create the venue on the * server. The session should be unregistered when no longer active using @@ -450,6 +509,7 @@ public class CollaborationConnection implements IEventPublisher { } /** + * unregister session with connection and notify UI elements * * @param session */ @@ -458,227 +518,16 @@ public class CollaborationConnection implements IEventPublisher { postEvent(session); } - // *************************** - // Connection listener - // *************************** - /** + * Get registered session * + * @param sessionId + * @return */ - private void setupInternalConnectionListeners() { - final Roster roster = connection.getRoster(); - roster.addRosterListener(new RosterListener() { - - @Override - public void presenceChanged(Presence presence) { - String fromId = presence.getFrom(); - if (contactsMgr != null) { - UserId u = IDConverter.convertFrom(fromId); - if (u != null) { - RosterEntry entry = contactsMgr.getRosterEntry(u); - eventBus.post(entry); - IRosterChangeEvent event = new RosterChangeEvent( - RosterChangeType.PRESENCE, entry, presence); - eventBus.post(event); - } - } - } - - @Override - public void entriesUpdated(Collection addresses) { - send(addresses, RosterChangeType.MODIFY); - } - - @Override - public void entriesDeleted(Collection addresses) { - send(addresses, RosterChangeType.DELETE); - } - - @Override - public void entriesAdded(Collection addresses) { - send(addresses, RosterChangeType.ADD); - } - - /** - * Send event bus notification for roster - * - * @param addresses - * @param type - */ - private void send(Collection addresses, - RosterChangeType type) { - for (String addy : addresses) { - RosterEntry entry = roster.getEntry(addy); - if (entry != null) { - IRosterChangeEvent event = new RosterChangeEvent(type, - entry); - eventBus.post(event); - } - } - } - }); - } - public ISession getSession(String sessionId) { return sessions.get(sessionId); } - private void setupP2PComm() throws CollaborationException { - if (isConnected()) { - PeerToPeerCommHelper helper = new PeerToPeerCommHelper(this); - connection.addPacketListener(helper, new PacketTypeFilter( - Message.class)); - } else { - throw new CollaborationException( - "The Collaboration XMPP connection has not been established."); - } - } - - private void setupConnectionListener() throws CollaborationException { - if (isConnected()) { - connection.addConnectionListener(new ConnectionListener() { - - @Override - public void reconnectionSuccessful() { - statusHandler - .debug("Client successfully reconnected to server"); - postSystemMessageToVenues("Connection to collaboration server reestablished."); - } - - @Override - public void reconnectionFailed(Exception e) { - String reason = getErrorReason(e); - statusHandler.error("Client can't reconnect to server: " - + reason, e); - sendDisconnectNotice(reason); - } - - @Override - public void reconnectingIn(int seconds) { - statusHandler.debug("Client reconnecting to server in " - + seconds + " seconds"); - } - - @Override - public void connectionClosedOnError(Exception e) { - String reason = getErrorReason(e); - statusHandler.error("Server closed on error: " + reason, e); - // don't shutdown yet, we might be able to reconnect - postSystemMessageToVenues("Not currently connected to collaboration server."); - } - - private String getErrorReason(Exception e) { - String msg = null; - if (e instanceof XMPPException) { - StreamError streamError = ((XMPPException) e) - .getStreamError(); - if (streamError != null) { - if ("conflict".equalsIgnoreCase(streamError - .getCode())) { - msg = "User account in use on another client"; - } - } - } - return msg == null ? e.getLocalizedMessage() : msg; - } - - @Override - public void connectionClosed() { - statusHandler.info("Server closed connection"); - sendDisconnectNotice("Normal termination"); - } - - private void sendDisconnectNotice(String reason) { - ServerDisconnectEvent event = new ServerDisconnectEvent( - reason); - eventBus.post(event); - } - }); - } else { - throw new CollaborationException( - "The Collaboration XMPP connection has not been established."); - } - } - - // *************************** - // Venue invitation listener management - // *************************** - - /** - * Set up the invitation listener. - * - * @throws CollaborationException - */ - private void setupInternalVenueInvitationListener() - throws CollaborationException { - if (isConnected()) { - MultiUserChat.addInvitationListener(connection, - new InvitationListener() { - @Override - public void invitationReceived(Connection conn, - String room, String inviter, String reason, - String password, Message message) { - // TODO handle password protected rooms - VenueId venueId = new VenueId(); - venueId.setName(Tools.parseName(room)); - venueId.setHost(Tools.parseHost(room)); - UserId invitor = IDConverter.convertFrom(inviter); - - if (message != null) { - SessionPayload payload = (SessionPayload) message - .getExtension(PacketConstants.COLLAB_XMLNS); - if (payload != null) { - handleCollabInvite(venueId, invitor, - payload); - return; - } - } - if (reason != null - && reason.startsWith(Tools.CMD_PREAMBLE)) { - reason = "Shared display invitation from incompatible version of CAVE. " - + "Session will be chat-only if invitation is accepted"; - } - handleChatRoomInvite(venueId, invitor, reason, - message); - } - }); - } else { - throw new CollaborationException( - "The Collaboration XMPP connection has not been established."); - } - } - - private void handleChatRoomInvite(VenueId venueId, UserId invitor, - String reason, Message message) { - VenueInvite invite = new VenueInvite(); - if (!StringUtils.isBlank(reason)) { - invite.setMessage(reason); - } else if (!StringUtils.isBlank(message.getBody())) { - invite.setMessage(message.getBody()); - } else { - invite.setMessage(""); - } - invite.setSubject(message.getSubject()); - IVenueInvitationEvent event = new VenueInvitationEvent(venueId, - invitor, invite); - eventBus.post(event); - } - - private void handleCollabInvite(VenueId venueId, UserId invitor, - SessionPayload payload) { - Object obj = payload.getData(); - if (obj == null - || !payload.getPayloadType().equals(PayloadType.Invitation) - || !(obj instanceof VenueInvite)) { - statusHandler.warn("Received unsupported invite payload"); - return; - } - VenueInvite invite = (VenueInvite) obj; - IVenueInvitationEvent event = new VenueInvitationEvent(venueId, - invitor, invite); - eventBus.post(event); - } - /** * Register an event handler with this * @@ -712,38 +561,10 @@ public class CollaborationConnection implements IEventPublisher { return sessions.values(); } - /** - * Returns the currently connected connection or null if it's not connected - * - * @return - */ - public static CollaborationConnection getConnection() { - return instance; - } - - /** - * Create a {@link CollaborationConnection} given the - * {@link CollaborationConnectionData} - * - * @param userData - * @return - * @throws CollaborationException - */ - public static CollaborationConnection createConnection( - CollaborationConnectionData userData) throws CollaborationException { - if (instance != null) { - throw new CollaborationException("Already connected"); - } - - instance = new CollaborationConnection(userData); - - return getConnection(); - } - /** * @return Smack connection object */ - protected XMPPConnection getXmppConnection() { + public XMPPConnection getXmppConnection() { return connection; } @@ -776,23 +597,9 @@ public class CollaborationConnection implements IEventPublisher { } /** - * Connect to the XMPP server. This needs to be called after the - * CollaborationConnection has been created and initialized. - * - * @throws CollaborationException + * @return the statusHandler */ - public void connect() throws CollaborationException { - contactsMgr = new ContactsManager(this, this.getXmppConnection()); - registerEventHandler(instance.getContactsManager()); - - connectInternal(connectionData.getUserName(), - connectionData.getPassword()); - - authManager = new ClientAuthManager(getXmppConnection()); - - // Finish setup - setupInternalVenueInvitationListener(); - setupP2PComm(); - setupConnectionListener(); + protected static IUFStatusHandler getStatusHandler() { + return statusHandler; } } diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/CollaborationConnectionData.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/CollaborationConnectionData.java similarity index 88% rename from cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/CollaborationConnectionData.java rename to cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/CollaborationConnectionData.java index 84d3b80484..b66b03b22d 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/CollaborationConnectionData.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/CollaborationConnectionData.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.uf.viz.collaboration.comm.provider.session; +package com.raytheon.uf.viz.collaboration.comm.provider.connection; import java.util.HashMap; import java.util.Map; @@ -36,6 +36,7 @@ import org.jivesoftware.smack.packet.Presence.Mode; * ------------ ---------- ----------- -------------------------- * Jun 18, 2012 mschenke Initial creation * Jan 15, 2014 2630 bclement connection data stores status as Mode object + * Apr 14, 2014 2903 bclement removed password, moved from session subpackage to connection * * * @@ -49,8 +50,6 @@ public class CollaborationConnectionData { private String userName; - private String password; - private Mode status; private String message; @@ -91,21 +90,6 @@ public class CollaborationConnectionData { this.userName = userName; } - /** - * @return the password - */ - public String getPassword() { - return password; - } - - /** - * @param password - * the password to set - */ - public void setPassword(String password) { - this.password = password; - } - /** * @return the status */ @@ -163,8 +147,6 @@ public class CollaborationConnectionData { result = prime * result + ((attributes == null) ? 0 : attributes.hashCode()); result = prime * result + ((message == null) ? 0 : message.hashCode()); - result = prime * result - + ((password == null) ? 0 : password.hashCode()); result = prime * result + ((server == null) ? 0 : server.hashCode()); result = prime * result + ((status == null) ? 0 : status.hashCode()); result = prime * result @@ -196,11 +178,6 @@ public class CollaborationConnectionData { return false; } else if (!message.equals(other.message)) return false; - if (password == null) { - if (other.password != null) - return false; - } else if (!password.equals(other.password)) - return false; if (server == null) { if (other.server != null) return false; diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/PeerToPeerCommHelper.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/PeerToPeerCommHelper.java similarity index 97% rename from cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/PeerToPeerCommHelper.java rename to cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/PeerToPeerCommHelper.java index e3291e8cce..e8117767a2 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/PeerToPeerCommHelper.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/PeerToPeerCommHelper.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.uf.viz.collaboration.comm.provider.session; +package com.raytheon.uf.viz.collaboration.comm.provider.connection; import java.net.URI; import java.net.URL; @@ -63,6 +63,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; * Feb 17, 2014 2756 bclement null check for message from field * moved url validation from regex to java utility * Feb 24, 2014 2756 bclement moved xmpp objects to new packages + * Apr 14, 2014 2903 bclement moved from session subpackage to connection * * * @@ -72,8 +73,8 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; public class PeerToPeerCommHelper implements PacketListener { - private static final transient IUFStatusHandler statusHandler = UFStatus - .getHandler(PeerToPeerCommHelper.class); + private static final transient IUFStatusHandler statusHandler = CollaborationConnection + .getStatusHandler(); private static volatile String httpServer; @@ -88,7 +89,7 @@ public class PeerToPeerCommHelper implements PacketListener { return httpServer; } - private CollaborationConnection manager; + private final CollaborationConnection manager; /** * diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/SessionInviteListener.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/SessionInviteListener.java new file mode 100644 index 0000000000..10eafcf701 --- /dev/null +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/SessionInviteListener.java @@ -0,0 +1,149 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.viz.collaboration.comm.provider.connection; + +import org.apache.commons.lang.StringUtils; +import org.jivesoftware.smack.Connection; +import org.jivesoftware.smack.packet.Message; +import org.jivesoftware.smackx.muc.InvitationListener; + +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.xmpp.PacketConstants; +import com.raytheon.uf.viz.collaboration.comm.identity.event.IVenueInvitationEvent; +import com.raytheon.uf.viz.collaboration.comm.identity.invite.VenueInvite; +import com.raytheon.uf.viz.collaboration.comm.packet.SessionPayload; +import com.raytheon.uf.viz.collaboration.comm.packet.SessionPayload.PayloadType; +import com.raytheon.uf.viz.collaboration.comm.provider.Tools; +import com.raytheon.uf.viz.collaboration.comm.provider.event.VenueInvitationEvent; +import com.raytheon.uf.viz.collaboration.comm.provider.user.IDConverter; +import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; +import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueId; + +/** + * Handles incoming session invitations and routes to event bus + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 11, 2014 2903       bclement     Initial creation
+ * 
+ * 
+ * + * @author bclement + * @version 1.0 + */ +public class SessionInviteListener implements InvitationListener { + + private static final IUFStatusHandler statusHandler = CollaborationConnection + .getStatusHandler(); + + private final CollaborationConnection manager; + + /** + * @param manager + */ + public SessionInviteListener(CollaborationConnection manager) { + this.manager = manager; + } + + /* + * (non-Javadoc) + * + * @see + * org.jivesoftware.smackx.muc.InvitationListener#invitationReceived(org + * .jivesoftware.smack.Connection, java.lang.String, java.lang.String, + * java.lang.String, java.lang.String, + * org.jivesoftware.smack.packet.Message) + */ + @Override + public void invitationReceived(Connection conn, String room, + String inviter, String reason, String password, Message message) { + // TODO handle password protected rooms + VenueId venueId = new VenueId(); + venueId.setName(Tools.parseName(room)); + venueId.setHost(Tools.parseHost(room)); + UserId invitor = IDConverter.convertFrom(inviter); + + SessionPayload payload = null; + if (message != null) { + payload = (SessionPayload) message + .getExtension(PacketConstants.COLLAB_XMLNS); + } + if (reason != null && reason.startsWith(Tools.CMD_PREAMBLE)) { + reason = "Shared display invitation from incompatible version of CAVE. " + + "Session will be chat-only if invitation is accepted"; + } + if (payload != null) { + handleCollabInvite(venueId, invitor, payload); + } else { + handleChatRoomInvite(venueId, invitor, reason, message); + } + } + + /** + * Handles acceptance of a text only session invitation + * + * @param venueId + * @param invitor + * @param reason + * @param message + */ + private void handleChatRoomInvite(VenueId venueId, UserId invitor, + String reason, Message message) { + VenueInvite invite = new VenueInvite(); + if (!StringUtils.isBlank(reason)) { + invite.setMessage(reason); + } else if (!StringUtils.isBlank(message.getBody())) { + invite.setMessage(message.getBody()); + } else { + invite.setMessage(""); + } + invite.setSubject(message.getSubject()); + IVenueInvitationEvent event = new VenueInvitationEvent(venueId, + invitor, invite); + manager.postEvent(event); + } + + /** + * Handles acceptance of a shared display session invitation + * + * @param venueId + * @param invitor + * @param payload + */ + private void handleCollabInvite(VenueId venueId, UserId invitor, + SessionPayload payload) { + Object obj = payload.getData(); + if (obj == null + || !payload.getPayloadType().equals(PayloadType.Invitation) + || !(obj instanceof VenueInvite)) { + statusHandler.warn("Received unsupported invite payload"); + return; + } + VenueInvite invite = (VenueInvite) obj; + IVenueInvitationEvent event = new VenueInvitationEvent(venueId, + invitor, invite); + manager.postEvent(event); + } + +} diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/SmackConfigScrubber.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/SmackConfigScrubber.java new file mode 100644 index 0000000000..95057b7f3c --- /dev/null +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/SmackConfigScrubber.java @@ -0,0 +1,97 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.viz.collaboration.comm.provider.connection; + +import java.lang.reflect.Field; + +import org.jivesoftware.smack.ConnectionConfiguration; + +import com.raytheon.uf.common.status.IUFStatusHandler; + +/** + * Sanitizes smack configuration object to keep sensitive information out of the + * heap + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 11, 2014 2903       bclement     Initial creation
+ * 
+ * 
+ * + * @author bclement + * @version 1.0 + */ +public class SmackConfigScrubber { + + private static final IUFStatusHandler log = CollaborationConnection + .getStatusHandler(); + + private static volatile Field passwordField; + + private static final String PASSWORD_FIELD_NAME = "password"; + + private SmackConfigScrubber() { + } + + /** + * remove sensitive information from smack configuration + * + * @param config + */ + public static void scrubConfig(ConnectionConfiguration config) { + if (passwordField == null) { + synchronized (SmackConfigScrubber.class) { + if (passwordField == null) { + passwordField = createPasswordField(); + } + } + } + if (passwordField != null) { + try { + passwordField.set(config, null); + } catch (Exception e) { + log.debug("Unable to scrub xmpp configuration: " + + e.getLocalizedMessage()); + } + } + } + + /** + * Create a field object for the connection configuration class object + * + * @return null if unable to create + */ + private static Field createPasswordField() { + try { + Class c = ConnectionConfiguration.class; + Field rval = c.getDeclaredField(PASSWORD_FIELD_NAME); + rval.setAccessible(true); + return rval; + } catch (Exception e) { + log.debug("Unable to access xmpp configuration: " + + e.getLocalizedMessage()); + return null; + } + } +} diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/XmppConnectionListener.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/XmppConnectionListener.java new file mode 100644 index 0000000000..84d7066714 --- /dev/null +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/XmppConnectionListener.java @@ -0,0 +1,123 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.viz.collaboration.comm.provider.connection; + +import org.jivesoftware.smack.ConnectionListener; +import org.jivesoftware.smack.XMPPException; +import org.jivesoftware.smack.packet.StreamError; + +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.viz.collaboration.comm.provider.event.ServerDisconnectEvent; + +/** + * Handles connection events from the XMPP server + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 11, 2014 2903       bclement     Initial creation
+ * 
+ * 
+ * + * @author bclement + * @version 1.0 + */ +public class XmppConnectionListener implements ConnectionListener { + + private static final IUFStatusHandler statusHandler = CollaborationConnection + .getStatusHandler(); + + private final CollaborationConnection manager; + + /** + * @param manager + */ + public XmppConnectionListener(CollaborationConnection manager) { + this.manager = manager; + } + + @Override + public void reconnectionSuccessful() { + /* this will not be called since we don't allow auto reconnect */ + statusHandler.debug("Client successfully reconnected to server"); + manager.postSystemMessageToVenues("Connection to collaboration server reestablished."); + } + + @Override + public void reconnectionFailed(Exception e) { + /* this will not be called since we don't allow auto reconnect */ + String reason = getErrorReason(e); + statusHandler.error("Client can't reconnect to server: " + reason, e); + sendDisconnectNotice(reason); + } + + @Override + public void reconnectingIn(int seconds) { + /* this will not be called since we don't allow auto reconnect */ + statusHandler.debug("Client reconnecting to server in " + seconds + + " seconds"); + } + + @Override + public void connectionClosedOnError(Exception e) { + String reason = getErrorReason(e); + statusHandler.error("Server closed on error: " + reason, e); + sendDisconnectNotice(reason); + } + + /** + * Attempt to get the most meaningful message from XMPP exception + * + * @param e + * @return + */ + private String getErrorReason(Exception e) { + String msg = null; + if (e instanceof XMPPException) { + StreamError streamError = ((XMPPException) e).getStreamError(); + if (streamError != null) { + if ("conflict".equalsIgnoreCase(streamError.getCode())) { + msg = "User account in use on another client"; + } + } + } + return msg == null ? e.getLocalizedMessage() : msg; + } + + @Override + public void connectionClosed() { + statusHandler.info("Server closed connection"); + /* don't send notice for normal termination */ + } + + /** + * Alert event bus listeners of disconnect + * + * @param reason + */ + private void sendDisconnectNotice(String reason) { + ServerDisconnectEvent event = new ServerDisconnectEvent(reason); + manager.postEvent(event); + } + +} diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/BaseSession.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/BaseSession.java index bb016f0e61..4ed7834e0f 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/BaseSession.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/BaseSession.java @@ -27,6 +27,7 @@ import com.google.common.eventbus.EventBus; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; import com.raytheon.uf.viz.collaboration.comm.identity.ISession; import com.raytheon.uf.viz.collaboration.comm.identity.user.IUser; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; /** * Base class for chat and collaboration sessions diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/PeerToPeerChat.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/PeerToPeerChat.java index a5aedda27e..a65221c96a 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/PeerToPeerChat.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/PeerToPeerChat.java @@ -34,6 +34,7 @@ import com.raytheon.uf.viz.collaboration.comm.identity.IPeerToPeer; import com.raytheon.uf.viz.collaboration.comm.identity.IPropertied.Property; import com.raytheon.uf.viz.collaboration.comm.identity.user.IUser; import com.raytheon.uf.viz.collaboration.comm.provider.TextMessage; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; /** @@ -51,6 +52,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; * Apr 18, 2012 njensen Cleanup * Dec 6, 2013 2561 bclement removed ECF * Feb 13, 2014 2751 bclement changed IQualifiedID objects to IUser + * Apr 11, 2014 2903 bclement made constructor public b/c connection code moved packages * * * @@ -66,7 +68,7 @@ public class PeerToPeerChat extends BaseSession implements IPeerToPeer { * @param externalBus * @param manager */ - PeerToPeerChat(EventBus externalBus, + public PeerToPeerChat(EventBus externalBus, CollaborationConnection manager) throws CollaborationException { super(externalBus, manager); } diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java index 3a0b61ddf2..a54ec03931 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java @@ -63,6 +63,9 @@ import com.raytheon.uf.viz.collaboration.comm.identity.user.SharedDisplayRole; import com.raytheon.uf.viz.collaboration.comm.packet.SessionPayload; import com.raytheon.uf.viz.collaboration.comm.packet.SessionPayload.PayloadType; import com.raytheon.uf.viz.collaboration.comm.provider.Tools; +import com.raytheon.uf.viz.collaboration.comm.provider.account.ClientAuthManager; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.PeerToPeerCommHelper; import com.raytheon.uf.viz.collaboration.comm.provider.event.LeaderChangeEvent; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java index 5d58853e22..00cbc8e9ae 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java @@ -56,6 +56,7 @@ import com.raytheon.uf.viz.collaboration.comm.packet.SessionPayload; import com.raytheon.uf.viz.collaboration.comm.packet.SessionPayload.PayloadType; import com.raytheon.uf.viz.collaboration.comm.provider.TextMessage; import com.raytheon.uf.viz.collaboration.comm.provider.Tools; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.event.UserNicknameChangedEvent; import com.raytheon.uf.viz.collaboration.comm.provider.event.VenueParticipantEvent; import com.raytheon.uf.viz.collaboration.comm.provider.event.VenueUserEvent; @@ -105,6 +106,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; * Mar 07, 2014 2848 bclement added getVenueName() and hasOtherParticipants() * moved muc close logic to closeMuc() * handle is now set in constructor + * Apr 11, 2014 2903 bclement made constructor public b/c connection code moved packages * * * @@ -145,7 +147,7 @@ public class VenueSession extends BaseSession implements IVenueSession { * @param container * @param eventBus */ - protected VenueSession(EventBus externalBus, + public VenueSession(EventBus externalBus, CollaborationConnection manager, String venueName, String handle, String sessionId) { super(externalBus, manager, sessionId); @@ -158,7 +160,7 @@ public class VenueSession extends BaseSession implements IVenueSession { * @param container * @param eventBus */ - protected VenueSession(EventBus externalBus, + public VenueSession(EventBus externalBus, CollaborationConnection manager, CreateSessionData data) { super(externalBus, manager); this.venueName = data.getName(); diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java index f575d60424..0064e55698 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java @@ -31,6 +31,7 @@ import org.apache.commons.lang.StringUtils; import org.jivesoftware.smack.Roster; import org.jivesoftware.smack.RosterEntry; import org.jivesoftware.smack.RosterGroup; +import org.jivesoftware.smack.RosterListener; import org.jivesoftware.smack.XMPPConnection; import org.jivesoftware.smack.XMPPException; import org.jivesoftware.smack.packet.Presence; @@ -47,8 +48,11 @@ import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.common.util.collections.UpdatingSet; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; +import com.raytheon.uf.viz.collaboration.comm.identity.event.IRosterChangeEvent; +import com.raytheon.uf.viz.collaboration.comm.identity.event.RosterChangeType; import com.raytheon.uf.viz.collaboration.comm.provider.Tools; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.event.RosterChangeEvent; /** * Manage contacts from local groups and roster on server @@ -71,6 +75,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConn * Jan 30, 2014 2698 bclement removed unneeded nickname changed event * Jan 31, 2014 2700 bclement added addToRoster, fixed add to group when in roster, but blocked * Feb 3, 2014 2699 bclement fixed assumption that username search was exact + * Apr 11, 2014 2903 bclement moved roster listener from collaboration connection to here * * * @@ -83,13 +88,13 @@ public class ContactsManager { .getHandler(ContactsManager.class); private final CollaborationConnection connection; - + private final XMPPConnection xmpp; private final UserSearch search; private Map localAliases; - + /** * Cached view of shared groups list on openfire. Will only reach out to * server if it hasn't updated in an hour. This will disable itself if there @@ -127,8 +132,61 @@ public class ContactsManager { this.search = connection.createSearch(); localAliases = UserIdWrapper.readAliasMap(); this.xmpp = xmpp; + final Roster roster = xmpp.getRoster(); + roster.addRosterListener(new RosterListener() { + + @Override + public void presenceChanged(Presence presence) { + String fromId = presence.getFrom(); + UserId u = IDConverter.convertFrom(fromId); + if (u != null) { + RosterEntry entry = getRosterEntry(u); + post(entry); + IRosterChangeEvent event = new RosterChangeEvent( + RosterChangeType.PRESENCE, entry, presence); + post(event); + } + } + + @Override + public void entriesUpdated(Collection addresses) { + send(addresses, RosterChangeType.MODIFY); + } + + @Override + public void entriesDeleted(Collection addresses) { + send(addresses, RosterChangeType.DELETE); + } + + @Override + public void entriesAdded(Collection addresses) { + send(addresses, RosterChangeType.ADD); + } + + /** + * Send event bus notification for roster + * + * @param addresses + * @param type + */ + private void send(Collection addresses, + RosterChangeType type) { + for (String addy : addresses) { + RosterEntry entry = roster.getEntry(addy); + if (entry != null) { + IRosterChangeEvent event = new RosterChangeEvent(type, + entry); + post(event); + } + } + } + + private void post(Object event) { + ContactsManager.this.connection.postEvent(event); + } + }); } - + /** * Get groups that are managed by server. These are not modifiable from the * client. @@ -272,19 +330,20 @@ public class ContactsManager { */ public void deleteFromGroup(String groupName, UserId user) { RosterEntry entry = getRosterEntry(user); - if ( entry == null){ - statusHandler.warn("Attempted to alter group for non-contact: " + user); + if (entry == null) { + statusHandler.warn("Attempted to alter group for non-contact: " + + user); return; } RosterGroup group = getRoster().getGroup(groupName); - if ( group != null){ + if (group != null) { deleteFromGroup(group, entry); } else { statusHandler.warn("Attempted to modify non-existent group: " + groupName); } } - + /** * Remove entry from group. * @@ -299,12 +358,13 @@ public class ContactsManager { } } catch (XMPPException e) { String msg = getGroupModInfo(e); - statusHandler.error("Problem removing entry from group: " - + IDConverter.convertFrom(entry) + " from " + statusHandler.error( + "Problem removing entry from group: " + + IDConverter.convertFrom(entry) + " from " + group.getName() + ". " + msg, e); } } - + /** * Attempt to get more information about group modification error. Returns * an empty string if no extra information is found. @@ -350,8 +410,9 @@ public class ContactsManager { public RosterGroup createGroup(String groupName) { Roster roster = getRoster(); RosterGroup rval = roster.getGroup(groupName); - if ( rval != null){ - statusHandler.debug("Attempted to create existing group: " + groupName); + if (rval != null) { + statusHandler.debug("Attempted to create existing group: " + + groupName); return rval; } rval = roster.createGroup(groupName); @@ -369,7 +430,7 @@ public class ContactsManager { public void deleteGroup(String groupName) { Roster roster = getRoster(); RosterGroup group = roster.getGroup(groupName); - if ( group == null){ + if (group == null) { statusHandler.warn("Attempted to delete non-existent group: " + groupName); return; diff --git a/cave/com.raytheon.uf.viz.collaboration.display/src/com/raytheon/uf/viz/collaboration/display/storage/CollaborationObjectEventStorage.java b/cave/com.raytheon.uf.viz.collaboration.display/src/com/raytheon/uf/viz/collaboration/display/storage/CollaborationObjectEventStorage.java index 5f6a5635ce..567c91d5b9 100644 --- a/cave/com.raytheon.uf.viz.collaboration.display/src/com/raytheon/uf/viz/collaboration/display/storage/CollaborationObjectEventStorage.java +++ b/cave/com.raytheon.uf.viz.collaboration.display/src/com/raytheon/uf/viz/collaboration/display/storage/CollaborationObjectEventStorage.java @@ -54,8 +54,8 @@ import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.viz.collaboration.comm.compression.CompressionUtil; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; import com.raytheon.uf.viz.collaboration.comm.identity.ISharedDisplaySession; -import com.raytheon.uf.viz.collaboration.comm.provider.session.ClientAuthManager; -import com.raytheon.uf.viz.collaboration.comm.provider.session.PeerToPeerCommHelper; +import com.raytheon.uf.viz.collaboration.comm.provider.account.ClientAuthManager; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.PeerToPeerCommHelper; import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; import com.raytheon.uf.viz.remote.graphics.Dispatcher; import com.raytheon.uf.viz.remote.graphics.events.AbstractDispatchingObjectEvent; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/AbstractUserLabelProvider.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/AbstractUserLabelProvider.java index 3022db8ea1..6b8787ab42 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/AbstractUserLabelProvider.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/AbstractUserLabelProvider.java @@ -35,7 +35,7 @@ import org.jivesoftware.smack.packet.RosterPacket.ItemType; import com.raytheon.uf.viz.collaboration.comm.identity.info.SiteConfigInformation; import com.raytheon.uf.viz.collaboration.comm.identity.user.IUser; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; /** diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/ChangePasswordDialog.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/ChangePasswordDialog.java index 0e3ffcb74d..253651478e 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/ChangePasswordDialog.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/ChangePasswordDialog.java @@ -37,7 +37,7 @@ import org.eclipse.swt.widgets.MessageBox; import org.eclipse.swt.widgets.Shell; import org.eclipse.swt.widgets.Text; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.viz.ui.dialogs.CaveSWTDialog; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CollaborationGroupView.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CollaborationGroupView.java index facbba4747..7db7506e18 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CollaborationGroupView.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CollaborationGroupView.java @@ -72,6 +72,7 @@ import org.eclipse.swt.widgets.TreeColumn; import org.eclipse.swt.widgets.TreeItem; import org.eclipse.ui.IViewPart; import org.eclipse.ui.IViewReference; +import org.eclipse.ui.PartInitException; import org.eclipse.ui.PlatformUI; import org.eclipse.ui.internal.WorkbenchMessages; import org.eclipse.ui.plugin.AbstractUIPlugin; @@ -85,9 +86,8 @@ import com.google.common.eventbus.Subscribe; import com.raytheon.uf.viz.collaboration.comm.identity.IVenueSession; import com.raytheon.uf.viz.collaboration.comm.identity.event.IRosterChangeEvent; import com.raytheon.uf.viz.collaboration.comm.identity.event.RosterChangeType; -import com.raytheon.uf.viz.collaboration.comm.provider.event.ServerDisconnectEvent; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.event.UserPresenceChangedEvent; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager.GroupListener; import com.raytheon.uf.viz.collaboration.comm.provider.user.IDConverter; @@ -119,10 +119,12 @@ import com.raytheon.uf.viz.collaboration.ui.data.AlertWordWrapper; import com.raytheon.uf.viz.collaboration.ui.data.CollaborationGroupContainer; import com.raytheon.uf.viz.collaboration.ui.data.SessionGroupContainer; import com.raytheon.uf.viz.collaboration.ui.notifier.NotifierTools; +import com.raytheon.uf.viz.collaboration.ui.prefs.CollabPrefConstants; import com.raytheon.uf.viz.collaboration.ui.session.AbstractSessionView; import com.raytheon.uf.viz.core.VizApp; import com.raytheon.uf.viz.core.icon.IconUtil; import com.raytheon.viz.ui.views.CaveFloatingView; +import com.raytheon.viz.ui.views.CaveWorkbenchPageManager; /** * This class is the main view to display the user's information and allow the @@ -149,6 +151,8 @@ import com.raytheon.viz.ui.views.CaveFloatingView; * Mar 05, 2014 2837 bclement separate rename action for groups, added more icons * Mar 05, 2014 2798 mpduff Add getter for displayFeedAction. * Mar 12, 2014 2632 mpduff Force group deletes from UI if last user is removed. + * Apr 11, 2014 2903 bclement login action changes, removed server disconnect listener, + * added static utility method to show view * * * @@ -227,12 +231,11 @@ public class CollaborationGroupView extends CaveFloatingView implements CollaborationConnection connection = CollaborationConnection .getConnection(); if (connection == null) { - new LoginAction().run(); - connection = CollaborationConnection.getConnection(); - if (connection == null) { + if (!new LoginAction().login()) { // user cancelled login return; } + connection = CollaborationConnection.getConnection(); } createFilterText(parent); @@ -871,7 +874,7 @@ public class CollaborationGroupView extends CaveFloatingView implements .getActivePage().getViewReferences()) { IViewPart viewPart = ref.getView(false); if (viewPart instanceof AbstractSessionView) { - ((AbstractSessionView) viewPart).setAlertWords(Arrays + ((AbstractSessionView) viewPart).setAlertWords(Arrays .asList(words.getAlertWords())); } } @@ -954,24 +957,32 @@ public class CollaborationGroupView extends CaveFloatingView implements refreshUsersTreeViewerAsync(group); } - @Subscribe - public void serverDisconnected(final ServerDisconnectEvent e) { - if (logOut == null) { - // we aren't logged in - return; - } - VizApp.runAsync(new Runnable() { - @Override - public void run() { - logOut.closeCollaboration(); - } - }); - } - /** * @return the displayFeedAction */ public DisplayFeedAction getDisplayFeedAction() { return displayFeedAction; } + + /** + * @see CaveWorkbenchPageManager#showView(String) + * + * @param initFeedView + * true if feed view should be initialized like this is the first + * time the view has been opened + * @throws PartInitException + */ + public static void showView(boolean initFeedView) throws PartInitException { + CollaborationGroupView view = (CollaborationGroupView) CaveWorkbenchPageManager + .getActiveInstance().showView(ID); + if (initFeedView) { + // if autojoin is selected (to join the default room) + if (Activator.getDefault().getPreferenceStore() + .getBoolean(CollabPrefConstants.AUTO_JOIN)) { + DisplayFeedAction action = view.getDisplayFeedAction(); + action.setChecked(true); + action.run(); + } + } + } } diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/ConnectionSubscriber.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/ConnectionSubscriber.java index e4bebf60c5..6c753aa145 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/ConnectionSubscriber.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/ConnectionSubscriber.java @@ -40,7 +40,7 @@ import com.raytheon.uf.viz.collaboration.comm.identity.event.ITextMessageEvent; import com.raytheon.uf.viz.collaboration.comm.identity.event.IVenueInvitationEvent; import com.raytheon.uf.viz.collaboration.comm.identity.user.IUser; import com.raytheon.uf.viz.collaboration.comm.provider.TextMessage; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.ui.actions.PeerToPeerChatAction; import com.raytheon.uf.viz.collaboration.ui.jobs.AwayTimeOut; @@ -70,6 +70,7 @@ import com.raytheon.viz.ui.views.CaveWorkbenchPageManager; * Feb 13, 2014 2751 bclement messages return IUser instead of IQualifiedID * Mar 06, 2014 2848 bclement moved SharedDisplaySessionMgr.joinSession call to InviteDialog * Apr 08, 2014 2785 mpduff removed preference listener + * Apr 11, 2014 2903 bclement added disconnect handler * * * @@ -88,6 +89,8 @@ public class ConnectionSubscriber { private final AwayTimeOut awayTimeOut = new AwayTimeOut(); + private final DisconnectHandler disconnect = new DisconnectHandler(); + private ConnectionSubscriber() { } @@ -124,6 +127,7 @@ public class ConnectionSubscriber { new SubscriptionResponderImpl(connection)); // Register handlers and events for the new sessionManager. connection.registerEventHandler(this); + connection.registerEventHandler(disconnect); try { ISession p2pSession = connection.getPeerToPeerSession(); p2pSession.registerEventHandler(this); @@ -159,11 +163,14 @@ public class ConnectionSubscriber { awayTimeOut.cancel(); try { ISession p2pSession = connection.getPeerToPeerSession(); - p2pSession.unregisterEventHandler(this); + if (p2pSession != null) { + p2pSession.unregisterEventHandler(this); + } } catch (CollaborationException e) { statusHandler.handle(Priority.PROBLEM, "Error unregistering peer to peer handler", e); } + connection.unregisterEventHandler(disconnect); connection.unregisterEventHandler(this); } PlatformUI.getWorkbench().removeWorkbenchListener(wbListener); diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateGroupDialog.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateGroupDialog.java index 9798c0c3bc..2f9530cca8 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateGroupDialog.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateGroupDialog.java @@ -33,7 +33,7 @@ import org.eclipse.swt.widgets.Label; import org.eclipse.swt.widgets.Shell; import org.eclipse.swt.widgets.Text; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.viz.ui.dialogs.CaveSWTDialog; /** diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateSessionDialog.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateSessionDialog.java index 6a176bca78..abebed40d7 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateSessionDialog.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateSessionDialog.java @@ -56,9 +56,9 @@ import com.raytheon.uf.viz.collaboration.comm.identity.ISharedDisplaySession; import com.raytheon.uf.viz.collaboration.comm.identity.IVenueSession; import com.raytheon.uf.viz.collaboration.comm.identity.user.SharedDisplayRole; import com.raytheon.uf.viz.collaboration.comm.provider.Tools; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.PeerToPeerCommHelper; import com.raytheon.uf.viz.collaboration.comm.provider.session.CreateSessionData; -import com.raytheon.uf.viz.collaboration.comm.provider.session.PeerToPeerCommHelper; import com.raytheon.uf.viz.collaboration.comm.provider.session.SharedDisplaySession; import com.raytheon.uf.viz.collaboration.comm.provider.session.VenueSession; import com.raytheon.uf.viz.collaboration.display.data.SharedDisplaySessionMgr; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/DisconnectHandler.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/DisconnectHandler.java new file mode 100644 index 0000000000..ed9ed3ae14 --- /dev/null +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/DisconnectHandler.java @@ -0,0 +1,101 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.viz.collaboration.ui; + +import org.eclipse.jface.dialogs.MessageDialog; +import org.eclipse.swt.widgets.Display; +import org.eclipse.swt.widgets.Shell; +import org.eclipse.ui.PartInitException; + +import com.google.common.eventbus.Subscribe; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.event.ServerDisconnectEvent; +import com.raytheon.uf.viz.collaboration.ui.actions.LogoutAction; +import com.raytheon.uf.viz.collaboration.ui.login.LoginDialog; +import com.raytheon.uf.viz.core.VizApp; + +/** + * Handles xmpp server disconnect events + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 11, 2014 2903       bclement     Initial creation
+ * 
+ * 
+ * + * @author bclement + * @version 1.0 + */ +public class DisconnectHandler { + + private static final String TITLE = "Disconnected from Collaboration Server"; + + private static final String DEFAULT_MESSAGE = "Click OK to re-login to the collaboration server"; + + /** + * + */ + public DisconnectHandler() { + } + + /** + * Handle a disconnect from the xmpp server + * + * @param e + */ + @Subscribe + public void serverDisconnected(final ServerDisconnectEvent e) { + CollaborationConnection conn = CollaborationConnection.getConnection(); + if (conn == null) { + // we aren't logged in + return; + } + VizApp.runAsync(new Runnable() { + @Override + public void run() { + /* close out existing collaboration components */ + LogoutAction.closeCollaboration(); + Shell shell = new Shell(Display.getCurrent()); + StringBuilder msg = new StringBuilder(); + String reason = e.getReason(); + if (reason != null && !reason.isEmpty()) { + msg.append("Reason: ").append(reason).append('\n'); + } + msg.append(DEFAULT_MESSAGE); + /* inform the user of disconnect then re-login if requested */ + if (MessageDialog.openConfirm(shell, TITLE, msg.toString()) + && new LoginDialog(shell).login()) { + try { + /* user has logged back in, put the view back */ + CollaborationGroupView.showView(true); + } catch (PartInitException e) { + Activator.statusHandler.error( + "Problem restoring collaboration view", e); + } + } + } + }); + } + +} diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/InviteDialog.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/InviteDialog.java index 4502bd49f3..617e800935 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/InviteDialog.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/InviteDialog.java @@ -42,7 +42,7 @@ import com.raytheon.uf.viz.collaboration.comm.identity.invite.SharedDisplayVenue import com.raytheon.uf.viz.collaboration.comm.identity.invite.VenueInvite; import com.raytheon.uf.viz.collaboration.comm.identity.user.IUser; import com.raytheon.uf.viz.collaboration.comm.identity.user.SharedDisplayRole; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.session.SharedDisplaySession; import com.raytheon.uf.viz.collaboration.comm.provider.session.VenueSession; import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueId; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/SubRequestDialog.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/SubRequestDialog.java index ee02c77be7..25a831a14a 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/SubRequestDialog.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/SubRequestDialog.java @@ -37,7 +37,7 @@ import org.eclipse.swt.widgets.Label; import org.eclipse.swt.widgets.Shell; import org.jivesoftware.smack.RosterGroup; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.viz.ui.dialogs.CaveSWTDialog; /** diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UserSearchDialog.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UserSearchDialog.java index c1e10eb941..fdac87ec7e 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UserSearchDialog.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UserSearchDialog.java @@ -54,7 +54,7 @@ import org.jivesoftware.smack.XMPPException; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserSearch; import com.raytheon.uf.viz.collaboration.ui.actions.AddToGroupAction; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UsersTreeContentProvider.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UsersTreeContentProvider.java index 94e5ac0a12..2abc7f20cc 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UsersTreeContentProvider.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UsersTreeContentProvider.java @@ -31,7 +31,7 @@ import org.eclipse.jface.viewers.ViewerFilter; import org.jivesoftware.smack.RosterEntry; import org.jivesoftware.smack.RosterGroup; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; import com.raytheon.uf.viz.collaboration.comm.provider.user.SharedGroup; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UsersTreeLabelProvider.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UsersTreeLabelProvider.java index a278997d31..6c0784f2af 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UsersTreeLabelProvider.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UsersTreeLabelProvider.java @@ -38,7 +38,7 @@ import org.jivesoftware.smack.packet.Presence; import com.raytheon.uf.viz.collaboration.comm.identity.IVenueSession; import com.raytheon.uf.viz.collaboration.comm.identity.info.IVenue; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; import com.raytheon.uf.viz.collaboration.comm.provider.user.IDConverter; import com.raytheon.uf.viz.collaboration.comm.provider.user.SharedGroup; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/AddToGroupAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/AddToGroupAction.java index 5f67258136..be2de69002 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/AddToGroupAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/AddToGroupAction.java @@ -30,8 +30,8 @@ import org.jivesoftware.smack.RosterEntry; import org.jivesoftware.smack.RosterGroup; import com.raytheon.uf.viz.collaboration.comm.identity.event.RosterChangeType; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.event.RosterChangeEvent; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; import com.raytheon.uf.viz.collaboration.comm.provider.user.IDConverter; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ArchiveViewerAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ArchiveViewerAction.java index d8b7bb3b8a..0d62c93744 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ArchiveViewerAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ArchiveViewerAction.java @@ -27,7 +27,7 @@ import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.viz.collaboration.comm.identity.IVenueSession; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.session.SessionMsgArchive; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeFontAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeFontAction.java index 3294fe6bf7..f6ac11196e 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeFontAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeFontAction.java @@ -26,7 +26,7 @@ import org.eclipse.swt.graphics.FontData; import org.eclipse.swt.widgets.Display; import org.eclipse.swt.widgets.FontDialog; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.core.icon.IconUtil; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangePasswordAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangePasswordAction.java index 0afd148ae6..f586e2eb34 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangePasswordAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangePasswordAction.java @@ -26,7 +26,7 @@ import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.ui.ChangePasswordDialog; /** diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeRoleAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeRoleAction.java index 0a69144cb1..ed5c8e8edb 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeRoleAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeRoleAction.java @@ -33,7 +33,7 @@ import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; import com.raytheon.uf.viz.collaboration.comm.identity.info.SiteConfigInformation; import com.raytheon.uf.viz.collaboration.comm.identity.info.SiteConfigInformation.SiteConfig; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.ui.SiteConfigurationManager; /** diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeSiteAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeSiteAction.java index 9f1d341798..955adf3e96 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeSiteAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeSiteAction.java @@ -33,7 +33,7 @@ import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; import com.raytheon.uf.viz.collaboration.comm.identity.info.SiteConfigInformation; import com.raytheon.uf.viz.collaboration.comm.identity.info.SiteConfigInformation.SiteConfig; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.ui.SiteConfigurationManager; import com.raytheon.uf.viz.collaboration.ui.session.SubscribeList; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeStatusAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeStatusAction.java index b5ca4e548a..95efa2fd4b 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeStatusAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeStatusAction.java @@ -33,7 +33,7 @@ import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; import com.raytheon.uf.viz.collaboration.comm.provider.Tools; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.CollaborationUtils; import com.raytheon.uf.viz.core.icon.IconUtil; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeStatusMessageAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeStatusMessageAction.java index f6d49ed67e..ce62a616dd 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeStatusMessageAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/ChangeStatusMessageAction.java @@ -28,7 +28,7 @@ import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; import com.raytheon.uf.viz.collaboration.comm.provider.Tools; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.login.ChangeStatusDialog; import com.raytheon.uf.viz.collaboration.ui.prefs.CollabPrefConstants; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/CollaborationGroupAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/CollaborationGroupAction.java index 3362de86e8..0aa339adcd 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/CollaborationGroupAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/CollaborationGroupAction.java @@ -28,11 +28,8 @@ import org.eclipse.ui.PartInitException; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; -import com.raytheon.uf.viz.collaboration.ui.Activator; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.ui.CollaborationGroupView; -import com.raytheon.uf.viz.collaboration.ui.prefs.CollabPrefConstants; -import com.raytheon.viz.ui.views.CaveWorkbenchPageManager; /** * Action to open the group view, as well as the default chat room @@ -45,6 +42,7 @@ import com.raytheon.viz.ui.views.CaveWorkbenchPageManager; * ------------ ---------- ----------- -------------------------- * Mar 1, 2012 rferrel Initial creation * Mar 05, 2014 2798 mpduff Don't create a new DisplayFeedAction + * Apr 11, 2014 2903 bclement moved collaboration view init to CollaborationGroupView * * * @@ -62,27 +60,12 @@ public class CollaborationGroupAction extends AbstractHandler { // If connection is null then user has not logged in boolean initialExecutionFlag = CollaborationConnection .getConnection() == null; - new LoginAction().run(); - CollaborationConnection connection = CollaborationConnection - .getConnection(); - if (connection == null) { + if (!new LoginAction().login()) { // user cancelled login return event; } - CollaborationGroupView view = (CollaborationGroupView) CaveWorkbenchPageManager - .getActiveInstance().showView(CollaborationGroupView.ID); - - // Is this is the first log in - if (initialExecutionFlag) { - // if autojoin is selected (to join the default room) - if (Activator.getDefault().getPreferenceStore() - .getBoolean(CollabPrefConstants.AUTO_JOIN)) { - DisplayFeedAction action = view.getDisplayFeedAction(); - action.setChecked(true); - action.run(); - } - } + CollaborationGroupView.showView(initialExecutionFlag); } catch (PartInitException e) { statusHandler.handle(Priority.PROBLEM, "Unable to open collaboration contact list", e); diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/CreateGroupAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/CreateGroupAction.java index 97954ec2ed..451d19c70c 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/CreateGroupAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/CreateGroupAction.java @@ -22,7 +22,7 @@ package com.raytheon.uf.viz.collaboration.ui.actions; import org.eclipse.jface.action.Action; import org.eclipse.swt.widgets.Display; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.CreateGroupDialog; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/CreateSessionAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/CreateSessionAction.java index 2f02eae42b..9aa4039cea 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/CreateSessionAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/CreateSessionAction.java @@ -29,7 +29,7 @@ import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.viz.collaboration.comm.identity.IVenueSession; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.session.CreateSessionData; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.ui.Activator; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/DeleteGroupAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/DeleteGroupAction.java index 85d3fb19d5..156d19bbc2 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/DeleteGroupAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/DeleteGroupAction.java @@ -21,7 +21,7 @@ package com.raytheon.uf.viz.collaboration.ui.actions; import org.eclipse.jface.action.Action; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.core.icon.IconUtil; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/DisplayFeedAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/DisplayFeedAction.java index 31505b2769..6fcbe99247 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/DisplayFeedAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/DisplayFeedAction.java @@ -40,7 +40,7 @@ import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; import com.raytheon.uf.viz.collaboration.comm.identity.ISession; import com.raytheon.uf.viz.collaboration.comm.identity.IVenueSession; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.session.VenueSession; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.prefs.HandleUtil; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/InviteAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/InviteAction.java index 5009bff159..9512195ba9 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/InviteAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/InviteAction.java @@ -42,7 +42,7 @@ import com.raytheon.uf.viz.collaboration.comm.identity.ISharedDisplaySession; import com.raytheon.uf.viz.collaboration.comm.identity.IVenueSession; import com.raytheon.uf.viz.collaboration.comm.identity.invite.SharedDisplayVenueInvite; import com.raytheon.uf.viz.collaboration.comm.identity.invite.VenueInvite; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; import com.raytheon.uf.viz.collaboration.display.data.SharedDisplaySessionMgr; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/LinkToEditorAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/LinkToEditorAction.java index 64708b1006..173102bd93 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/LinkToEditorAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/LinkToEditorAction.java @@ -32,7 +32,7 @@ import org.eclipse.ui.IWorkbenchWindow; import org.eclipse.ui.PlatformUI; import com.raytheon.uf.viz.collaboration.comm.identity.ISharedDisplaySession; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.display.IRemoteDisplayContainer; import com.raytheon.uf.viz.collaboration.display.editor.ICollaborationEditor; import com.raytheon.uf.viz.collaboration.display.roles.dataprovider.SharedEditorsManager; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/LoginAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/LoginAction.java index fc813adcb0..1f7c761bcc 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/LoginAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/LoginAction.java @@ -23,7 +23,7 @@ import org.eclipse.jface.action.Action; import org.eclipse.swt.widgets.Display; import org.eclipse.swt.widgets.Shell; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.login.LoginDialog; import com.raytheon.uf.viz.core.icon.IconUtil; @@ -38,6 +38,7 @@ import com.raytheon.uf.viz.core.icon.IconUtil; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Jul 11, 2012 bsteffen Initial creation + * Apr 11, 2014 2903 bclement added success flag * * * @@ -46,6 +47,8 @@ import com.raytheon.uf.viz.core.icon.IconUtil; */ public class LoginAction extends Action { + + private boolean success = false; public LoginAction() { super("Login...", IconUtil.getImageDescriptor(Activator.getDefault() @@ -62,9 +65,24 @@ public class LoginAction extends Action { if (shell == null) { return; } - LoginDialog dlg = new LoginDialog(shell); - dlg.open(); + success = new LoginDialog(shell).login(); } } + /** + * @return the success + */ + public boolean isSuccess() { + return success; + } + + /** + * Convenience method to run action and return results + * + * @return true if login was successful + */ + public boolean login() { + this.run(); + return isSuccess(); + } } diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/LogoutAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/LogoutAction.java index 4969746d3f..2e9147b457 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/LogoutAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/LogoutAction.java @@ -34,7 +34,7 @@ import org.eclipse.ui.PlatformUI; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.CollaborationGroupView; import com.raytheon.uf.viz.collaboration.ui.ConnectionSubscriber; @@ -54,6 +54,7 @@ import com.raytheon.viz.ui.views.CaveWorkbenchPageManager; * ------------ ---------- ----------- -------------------------- * Jul 11, 2012 bsteffen Initial creation * Dec 19, 2013 2563 bclement moved close logic to public method + * Apr 11, 2014 2903 bclement made close method static, added safety check * * * @@ -90,7 +91,7 @@ public class LogoutAction extends Action { * Close collaboration UI and close connection * */ - public void closeCollaboration() { + public static void closeCollaboration() { for (IViewReference ref : CaveWorkbenchPageManager.getActiveInstance() .getViewReferences()) { IViewPart view = ref.getView(false); @@ -118,8 +119,10 @@ public class LogoutAction extends Action { } CollaborationConnection connection = CollaborationConnection .getConnection(); - ConnectionSubscriber.unsubscribe(connection); - connection.close(); + if (connection != null) { + ConnectionSubscriber.unsubscribe(connection); + connection.close(); + } } } diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/PeerToPeerChatAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/PeerToPeerChatAction.java index c454c389d9..9cec60be46 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/PeerToPeerChatAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/PeerToPeerChatAction.java @@ -28,7 +28,7 @@ import org.jivesoftware.smack.packet.Presence.Type; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.session.PeerToPeerView; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/RemoveFromGroupAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/RemoveFromGroupAction.java index b131b1a4e5..fe3639a344 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/RemoveFromGroupAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/RemoveFromGroupAction.java @@ -21,7 +21,7 @@ package com.raytheon.uf.viz.collaboration.ui.actions; import org.eclipse.jface.action.Action; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.ui.Activator; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/RemoveFromRosterAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/RemoveFromRosterAction.java index 2604ca621d..91cc894ea9 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/RemoveFromRosterAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/RemoveFromRosterAction.java @@ -23,8 +23,8 @@ import org.eclipse.jface.action.Action; import org.jivesoftware.smack.RosterEntry; import com.raytheon.uf.viz.collaboration.comm.identity.event.RosterChangeType; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.event.RosterChangeEvent; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.core.icon.IconUtil; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/SendSubReqAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/SendSubReqAction.java index 0f36b59e7f..e9a5dd5b0d 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/SendSubReqAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/SendSubReqAction.java @@ -26,7 +26,7 @@ import org.jivesoftware.smack.packet.Presence.Type; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; import com.raytheon.uf.viz.collaboration.comm.identity.IAccountManager; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.IDConverter; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.core.icon.IconUtil; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/UserSearchAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/UserSearchAction.java index 0ed54b3fdc..6d5b81c47e 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/UserSearchAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/UserSearchAction.java @@ -22,7 +22,7 @@ package com.raytheon.uf.viz.collaboration.ui.actions; import org.eclipse.jface.action.Action; import org.eclipse.swt.widgets.Display; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.UserSearchDialog; import com.raytheon.uf.viz.core.icon.IconUtil; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/data/CollaborationGroupContainer.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/data/CollaborationGroupContainer.java index a04300722e..a202f9221d 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/data/CollaborationGroupContainer.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/data/CollaborationGroupContainer.java @@ -23,7 +23,7 @@ import java.util.ArrayList; import java.util.Collections; import java.util.List; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; /** diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/data/SessionGroupContainer.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/data/SessionGroupContainer.java index ce126d0ae3..be76a02631 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/data/SessionGroupContainer.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/data/SessionGroupContainer.java @@ -26,7 +26,7 @@ import java.util.List; import com.raytheon.uf.viz.collaboration.comm.identity.ISession; import com.raytheon.uf.viz.collaboration.comm.identity.IVenueSession; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; /** * Retrieve session objects from contacts list diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/jobs/AwayTimeOut.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/jobs/AwayTimeOut.java index c4a4fa0407..c841ba9523 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/jobs/AwayTimeOut.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/jobs/AwayTimeOut.java @@ -36,7 +36,7 @@ import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; import com.raytheon.uf.viz.collaboration.comm.provider.Tools; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.prefs.CollabPrefConstants; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/login/LoginDialog.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/login/LoginDialog.java index 5ad39b3d59..c699a541f6 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/login/LoginDialog.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/login/LoginDialog.java @@ -52,8 +52,8 @@ import com.raytheon.uf.viz.collaboration.comm.identity.info.SiteConfigInformatio import com.raytheon.uf.viz.collaboration.comm.identity.info.SiteConfigInformation.HostConfig; import com.raytheon.uf.viz.collaboration.comm.identity.info.SiteConfigInformation.SiteConfig; import com.raytheon.uf.viz.collaboration.comm.provider.Tools; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnectionData; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnectionData; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.CollaborationUtils; import com.raytheon.uf.viz.collaboration.ui.ConnectionSubscriber; @@ -75,6 +75,8 @@ import com.raytheon.uf.viz.collaboration.ui.prefs.CollabPrefConstants; * Jan 08, 2014 2563 bclement added Add/Remove buttons for server list * Jan 15, 2014 2630 bclement connection data stores status as Mode object * Apr 07, 2014 2785 mpduff Implemented change to CollaborationConnection + * Apr 11, 2014 2903 bclement added success flag, moved login logic to static method + * fixed populating server with previous, removed password from heap * * * @@ -110,6 +112,8 @@ public class LoginDialog extends Dialog { private Shell shell; + private boolean success = false; + /** * @param parentShell */ @@ -179,10 +183,11 @@ public class LoginDialog extends Dialog { Iterator iter = Iterators.concat(siteServers.iterator(), userServers.iterator()); int index = 0; + String prevServer = loginData.getServer(); for (int i = 0; iter.hasNext() && i < names.length; i++) { HostConfig config = iter.next(); names[i] = config.toString(); - if (loginData.getServer().equals(names[i])) { + if (config.getHostname().equals(prevServer)) { index = i; } } @@ -320,7 +325,7 @@ public class LoginDialog extends Dialog { @Override public void widgetSelected(SelectionEvent event) { loginData.setUserName(userText.getText().trim()); - loginData.setPassword(passwordText.getText().trim()); + String password = passwordText.getText().trim(); loginData.setServer(HostConfig.removeDescription(serverText .getText())); loginData.setStatus(CollaborationUtils.parseMode(statusCombo @@ -347,7 +352,7 @@ public class LoginDialog extends Dialog { } loginData.setServer(server); - if (loginData.getPassword().isEmpty()) { + if (password.isEmpty()) { errorMessages.add("Must enter a password."); } @@ -365,38 +370,10 @@ public class LoginDialog extends Dialog { messageBox.setMessage(sb.toString()); messageBox.open(); } else { - try { - // Create the connection - CollaborationConnection collabConnection = CollaborationConnection - .createConnection(loginData); - - // Subscribe to the collaboration connection - ConnectionSubscriber.subscribe(collabConnection); - - // Connect to the XMPP server - collabConnection.connect(); - + success = login(loginData, password); + if (success) { storeLoginData(); shell.dispose(); - - // send initial presence - Mode mode = loginData.getStatus(); - if (mode == null) { - mode = Mode.available; - } - - Presence initialPresence = new Presence(Type.available, - loginData.getMessage(), 0, mode); - Tools.setProperties(initialPresence, - loginData.getAttributes()); - - collabConnection.getAccountManager().sendPresence( - initialPresence); - - } catch (CollaborationException e) { - Activator.statusHandler.handle(Priority.PROBLEM, - "Error connecting to collaboration server: " - + e.getLocalizedMessage(), e); } } } @@ -414,6 +391,61 @@ public class LoginDialog extends Dialog { }); } + /** + * Attempt to login to xmpp server. + * + * @param loginData + * @param password + * @return true if login was successful + */ + public static boolean login(CollaborationConnectionData loginData, + String password) { + CollaborationConnection collabConnection = null; + boolean rval = false; + boolean subscribed = false; + try { + // Create the connection + collabConnection = CollaborationConnection + .createConnection(loginData); + + // Subscribe to the collaboration connection + ConnectionSubscriber.subscribe(collabConnection); + subscribed = true; + + // Login to the XMPP server + collabConnection.login(password); + + /* login was success, other errors are recoverable */ + rval = true; + + // send initial presence + Mode mode = loginData.getStatus(); + if (mode == null) { + mode = Mode.available; + } + + Presence initialPresence = new Presence(Type.available, + loginData.getMessage(), 0, mode); + Tools.setProperties(initialPresence, loginData.getAttributes()); + + collabConnection.getAccountManager().sendPresence(initialPresence); + + } catch (CollaborationException e) { + if (subscribed && collabConnection != null) { + ConnectionSubscriber.unsubscribe(collabConnection); + } + String msg; + if (rval) { + msg = "Error sending initial presence to collaboration server"; + } else { + msg = "Error connecting to collaboration server: " + + e.getLocalizedMessage(); + } + Activator.statusHandler.handle(Priority.PROBLEM, msg, e); + } + return rval; + } + private void storeLoginData() { preferences.setValue(CollabPrefConstants.P_USERNAME, loginData.getUserName()); @@ -435,4 +467,21 @@ public class LoginDialog extends Dialog { loginData.setMessage(preferences .getString(CollabPrefConstants.P_MESSAGE)); } + + /** + * @return the success + */ + public boolean isSuccess() { + return success; + } + + /** + * Convenience method to open dialog and return true if login was successful + * + * @return + */ + public boolean login() { + open(); + return isSuccess(); + } } diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/notifier/NotifierTools.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/notifier/NotifierTools.java index cfe420e52e..e3c962924a 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/notifier/NotifierTools.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/notifier/NotifierTools.java @@ -46,7 +46,7 @@ import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.util.FileUtil; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.IDConverter; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.core.sounds.SoundUtil; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/CollaborationAlertWordsPreferencePage.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/CollaborationAlertWordsPreferencePage.java index cdeaca66b8..7dc0b82164 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/CollaborationAlertWordsPreferencePage.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/CollaborationAlertWordsPreferencePage.java @@ -50,7 +50,7 @@ import com.raytheon.uf.common.localization.LocalizationContext.LocalizationType; import com.raytheon.uf.common.localization.LocalizationFile; import com.raytheon.uf.common.localization.PathManager; import com.raytheon.uf.common.localization.PathManagerFactory; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.CollaborationUtils; import com.raytheon.uf.viz.collaboration.ui.data.AlertWord; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/CollaborationPreferencePage.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/CollaborationPreferencePage.java index 5240a53746..2308086953 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/CollaborationPreferencePage.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/CollaborationPreferencePage.java @@ -28,7 +28,7 @@ import org.eclipse.jface.preference.StringFieldEditor; import org.eclipse.ui.IWorkbench; import org.eclipse.ui.IWorkbenchPreferencePage; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.prefs.CollabPrefConstants.HandleOption; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/ContactNotifierPreferencePage.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/ContactNotifierPreferencePage.java index 7a615073a8..eba3ea36d2 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/ContactNotifierPreferencePage.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/ContactNotifierPreferencePage.java @@ -43,7 +43,7 @@ import org.jivesoftware.smack.RosterEntry; import org.jivesoftware.smack.RosterGroup; import com.google.common.collect.Lists; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; import com.raytheon.uf.viz.collaboration.comm.provider.user.IDConverter; import com.raytheon.uf.viz.collaboration.comm.provider.user.SharedGroup; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/HandleUtil.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/HandleUtil.java index 39a5313797..730d77137d 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/HandleUtil.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/HandleUtil.java @@ -29,7 +29,7 @@ import org.jivesoftware.smack.packet.Presence; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.viz.collaboration.comm.identity.info.SiteConfigInformation; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserSearch; import com.raytheon.uf.viz.collaboration.ui.Activator; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/SubscriptionResponderImpl.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/SubscriptionResponderImpl.java index 33587e1fad..8759920497 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/SubscriptionResponderImpl.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/SubscriptionResponderImpl.java @@ -34,8 +34,8 @@ import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.viz.collaboration.comm.identity.roster.ISubscriptionResponder; import com.raytheon.uf.viz.collaboration.comm.identity.roster.SubscriptionResponse; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; -import com.raytheon.uf.viz.collaboration.comm.provider.session.ISubscriptionRequestCompleteAction; +import com.raytheon.uf.viz.collaboration.comm.provider.account.ISubscriptionRequestCompleteAction; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserSearch; import com.raytheon.uf.viz.collaboration.ui.Activator; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/AbstractSessionView.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/AbstractSessionView.java index 048c63e10b..8da2ef9eb7 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/AbstractSessionView.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/AbstractSessionView.java @@ -57,7 +57,7 @@ import com.google.common.eventbus.Subscribe; import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.viz.collaboration.comm.identity.IMessage; import com.raytheon.uf.viz.collaboration.comm.identity.user.IUser; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.CollaborationUtils; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/ParticipantsLabelProvider.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/ParticipantsLabelProvider.java index 3b0e583a84..0a1c48823a 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/ParticipantsLabelProvider.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/ParticipantsLabelProvider.java @@ -34,7 +34,7 @@ import com.raytheon.uf.viz.collaboration.comm.identity.ISession; import com.raytheon.uf.viz.collaboration.comm.identity.ISharedDisplaySession; import com.raytheon.uf.viz.collaboration.comm.identity.IVenueSession; import com.raytheon.uf.viz.collaboration.comm.identity.info.SiteConfigInformation; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.session.SharedDisplaySession; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/PeerToPeerView.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/PeerToPeerView.java index 4ff24e68de..5b3d4e1fc1 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/PeerToPeerView.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/PeerToPeerView.java @@ -42,7 +42,7 @@ import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; import com.raytheon.uf.viz.collaboration.comm.identity.IMessage; import com.raytheon.uf.viz.collaboration.comm.identity.IPeerToPeer; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.RosterItem; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.ui.actions.PrintLogActionContributionItem; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionFeedView.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionFeedView.java index e2569a33ba..d2a6ed2c9e 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionFeedView.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionFeedView.java @@ -41,7 +41,7 @@ import org.osgi.framework.Bundle; import com.google.common.eventbus.Subscribe; import com.raytheon.uf.viz.collaboration.comm.identity.IMessage; import com.raytheon.uf.viz.collaboration.comm.identity.info.SiteConfigInformation; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.SiteColorInformation; diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionMsgArchiveBrowser.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionMsgArchiveBrowser.java index 514af06d44..f2b8cee21c 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionMsgArchiveBrowser.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionMsgArchiveBrowser.java @@ -54,7 +54,7 @@ import com.raytheon.uf.common.localization.PathManagerFactory; import com.raytheon.uf.common.localization.exception.LocalizationException; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; /** diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionView.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionView.java index dbbba457e1..aa592840f4 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionView.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionView.java @@ -73,9 +73,9 @@ import com.raytheon.uf.viz.collaboration.comm.identity.IVenueSession; import com.raytheon.uf.viz.collaboration.comm.identity.event.IVenueParticipantEvent; import com.raytheon.uf.viz.collaboration.comm.identity.event.ParticipantEventType; import com.raytheon.uf.viz.collaboration.comm.identity.info.IVenue; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.event.UserNicknameChangedEvent; import com.raytheon.uf.viz.collaboration.comm.provider.event.VenueUserEvent; -import com.raytheon.uf.viz.collaboration.comm.provider.session.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.session.VenueSession; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; From 5250f7a4428195ef6e6bfbe00e5075eea92cb1cb Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Mon, 7 Apr 2014 12:07:37 -0500 Subject: [PATCH 031/188] Issue #2822 only allow transfer leader if participant is using shared display Former-commit-id: af9577548e40397c67f72eb60485ee8de48f169b --- .../comm/identity/ISharedDisplaySession.java | 7 ++ .../connection/CollaborationConnection.java | 18 +++++ .../provider/session/PubSubOperations.java | 71 +++++++++++++++++-- .../session/SharedDisplaySession.java | 70 ++++++++++++++++++ .../ui/session/CollaborationSessionView.java | 4 +- 5 files changed, 162 insertions(+), 8 deletions(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/ISharedDisplaySession.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/ISharedDisplaySession.java index af3affa717..7173441a2a 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/ISharedDisplaySession.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/ISharedDisplaySession.java @@ -36,6 +36,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; * Feb 13, 2014 2751 bclement changed sendObjectToPeer id to VenueParticipant * Feb 13, 2014 2751 njensen Added changeLeader() * Feb 19, 2014 2751 bclement Added isClosed() + * Apr 15, 2014 2822 bclement added isSharedDisplayClient() * * * @@ -124,4 +125,10 @@ public interface ISharedDisplaySession extends IVenueSession { */ public boolean isClosed(); + /** + * @param participant + * @return true if the participant is viewing the shared display + */ + public boolean isSharedDisplayClient(VenueParticipant participant); + } diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/CollaborationConnection.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/CollaborationConnection.java index bab15aa72c..b6e34ad338 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/CollaborationConnection.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/CollaborationConnection.java @@ -33,6 +33,10 @@ import org.jivesoftware.smack.packet.Presence; import org.jivesoftware.smack.packet.XMPPError; import org.jivesoftware.smack.provider.ProviderManager; import org.jivesoftware.smackx.muc.MultiUserChat; +import org.jivesoftware.smackx.pubsub.PubSubElementType; +import org.jivesoftware.smackx.pubsub.packet.PubSubNamespace; +import org.jivesoftware.smackx.pubsub.provider.SubscriptionProvider; +import org.jivesoftware.smackx.pubsub.provider.SubscriptionsProvider; import com.google.common.eventbus.EventBus; import com.google.common.net.HostAndPort; @@ -108,6 +112,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; * Apr 09, 2014 2785 mpduff Throw error when not connected and the connection should exist. * Apr 14, 2014 2903 bclement moved from session subpackage to connection, removed password from memory, * moved listeners to own classes, reworked connect/register listeners/login order + * Apr 15, 2014 2822 bclement added pubsub owner subscriptions provider registration * * * @@ -124,6 +129,19 @@ public class CollaborationConnection implements IEventPublisher { PacketConstants.COLLAB_XMLNS, new SessionPayloadProvider()); pm.addIQProvider(PacketConstants.QUERY_ELEMENT_NAME, AuthInfo.AUTH_QUERY_XMLNS, new AuthInfoProvider()); + /* + * smack doesn't support some of the OWNER operations such as getting + * all subscriptions on a node. PubSubOperations creates the request + * objects for these operations, but the response needs to be parsed. + * Here we register the existing smack parsers using the OWNER + * namespace. + */ + pm.addExtensionProvider( + PubSubElementType.SUBSCRIPTION.getElementName(), + PubSubNamespace.OWNER.getXmlns(), new SubscriptionProvider()); + pm.addExtensionProvider( + PubSubElementType.SUBSCRIPTIONS.getElementName(), + PubSubNamespace.OWNER.getXmlns(), new SubscriptionsProvider()); } private static final transient IUFStatusHandler statusHandler = UFStatus diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/PubSubOperations.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/PubSubOperations.java index ddc9539c45..bfe388b680 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/PubSubOperations.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/PubSubOperations.java @@ -19,9 +19,18 @@ **/ package com.raytheon.uf.viz.collaboration.comm.provider.session; +import java.util.List; + import org.jivesoftware.smack.XMPPConnection; import org.jivesoftware.smack.XMPPException; import org.jivesoftware.smack.packet.IQ; +import org.jivesoftware.smack.packet.IQ.Type; +import org.jivesoftware.smack.packet.Packet; +import org.jivesoftware.smackx.pubsub.Node; +import org.jivesoftware.smackx.pubsub.NodeExtension; +import org.jivesoftware.smackx.pubsub.PubSubElementType; +import org.jivesoftware.smackx.pubsub.Subscription; +import org.jivesoftware.smackx.pubsub.SubscriptionsExtension; import org.jivesoftware.smackx.pubsub.packet.PubSub; import org.jivesoftware.smackx.pubsub.packet.PubSubNamespace; import org.jivesoftware.smackx.pubsub.packet.SyncPacketSend; @@ -38,7 +47,8 @@ import com.raytheon.uf.common.xmpp.ext.ChangeAffiliationExtension; * * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Feb 18, 2014 2751 bclement Initial creation + * Feb 18, 2014 2751 bclement Initial creation + * Apr 15, 2014 2822 bclement added getAllSubscriptions() * * * @@ -47,11 +57,14 @@ import com.raytheon.uf.common.xmpp.ext.ChangeAffiliationExtension; */ public class PubSubOperations { + public static final String PUBSUB_SUBDOMAIN_PREFIX = "pubsub."; + private PubSubOperations() { } /** - * Send packet to change affiliation of user on a pubsub topic node + * Send packet to change affiliation of user on a pubsub topic node. Calling + * client must be owner of node. * * @param conn * @param affiliation @@ -59,12 +72,56 @@ public class PubSubOperations { */ public static void sendAffiliationPacket(XMPPConnection conn, ChangeAffiliationExtension affiliation) throws XMPPException { - PubSub packet = new PubSub(); - packet.setType(IQ.Type.SET); - packet.setTo("pubsub." + conn.getServiceName()); - packet.setPubSubNamespace(PubSubNamespace.OWNER); - packet.addExtension(affiliation); + PubSub packet = createOwnerPacket(conn, affiliation, IQ.Type.SET); SyncPacketSend.getReply(conn, packet); } + /** + * List all subscriptions on node. Calling client must be owner of node. + * + * @param conn + * @param n + * @return + * @throws XMPPException + */ + public static List getAllSubscriptions(XMPPConnection conn, + Node n) throws XMPPException { + PubSubElementType type = PubSubElementType.SUBSCRIPTIONS; + /* + * we need to use the OWNER namespace when we make the request, but we + * reuse the provider (parser) for the default namespace for the return. + * Use the default namespace to get the extension object from the packet + */ + String namespace = type.getNamespace().getXmlns(); + NodeExtension ext = new NodeExtension(type, n.getId()); + PubSub packet = createOwnerPacket(conn, ext, Type.GET); + Packet reply = SyncPacketSend.getReply(conn, packet); + SubscriptionsExtension resp = (SubscriptionsExtension) reply + .getExtension(type.getElementName(), namespace); + if (resp == null){ + throw new XMPPException( + "Subscriptions response missing content for topic: " + + n.getId()); + } + return resp.getSubscriptions(); + } + + /** + * Create pubsub packet object with owner namespace + * + * @param conn + * @param ext + * @param type + * @return + */ + private static PubSub createOwnerPacket(XMPPConnection conn, + NodeExtension ext, Type type) { + PubSub packet = new PubSub(); + packet.setType(type); + packet.setTo(PUBSUB_SUBDOMAIN_PREFIX + conn.getServiceName()); + packet.setPubSubNamespace(PubSubNamespace.OWNER); + packet.addExtension(ext); + return packet; + } + } diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java index a54ec03931..72af6271ba 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java @@ -23,7 +23,9 @@ import java.net.URI; import java.util.Collection; import java.util.HashSet; import java.util.List; +import java.util.Map; import java.util.Set; +import java.util.concurrent.ConcurrentHashMap; import org.apache.http.client.methods.HttpDelete; import org.jivesoftware.smack.XMPPConnection; @@ -67,6 +69,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.account.ClientAuthManager import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.connection.PeerToPeerCommHelper; import com.raytheon.uf.viz.collaboration.comm.provider.event.LeaderChangeEvent; +import com.raytheon.uf.viz.collaboration.comm.provider.user.IDConverter; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; @@ -95,6 +98,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; * Mar 07, 2014 2848 bclement moved pubsub close logic to closePubSub() * ensure that subscription is setup before joining room * Mar 31, 2014 2899 mpduff Improve error messages. + * Apr 15, 2014 2822 bclement added check for other participants being subscribed to topic * * * @@ -116,6 +120,8 @@ public class SharedDisplaySession extends VenueSession implements private LeafNode topic; + private final Map topicSubscribers = new ConcurrentHashMap(); + private XMPPConnection conn; private boolean closed = false; @@ -624,6 +630,36 @@ public class SharedDisplaySession extends VenueSession implements PubSubOperations.sendAffiliationPacket(conn, affiliation); } + /** + * @param user + * @return true if user has a subscription to the session topic + * @throws XMPPException + */ + private boolean isSubscribedToTopic(UserId user) + throws XMPPException { + Boolean rval = topicSubscribers.get(user); + if (rval == null) { + synchronized (topicSubscribers) { + List subs = PubSubOperations.getAllSubscriptions( + conn, topic); + for (Subscription sub : subs) { + topicSubscribers.put(IDConverter.convertFrom(sub.getJid()), + true); + } + } + rval = topicSubscribers.get(user); + if (rval == null) { + /* + * userid object hash includes resource, cache as a client that + * doesn't use topic + */ + topicSubscribers.put(user, false); + rval = false; + } + } + return rval; + } + @Override public void changeLeader(VenueParticipant newLeader) throws CollaborationException { @@ -645,6 +681,15 @@ public class SharedDisplaySession extends VenueSession implements boolean othersNotified = false; String revokeTarget = null; try { + /* + * make sure that the new leader is not just in the room, but also + * subscribed to the pubsub topic + */ + if (!isSubscribedToTopic(actualId)) { + throw new CollaborationException( + "Unable to grant ownership because new leader is not subscribed to session topic"); + } + // was formerly the data provider, so hand off pubsub ownership grantTopicOwnership(newLeaderId); topicOwnershipGranted = true; @@ -670,6 +715,8 @@ public class SharedDisplaySession extends VenueSession implements // 'member' instead of just down to 'admin' revokeTarget = "room"; muc.revokeAdmin(account.getNormalizedId()); + // clear cache of topic subscribers + topicSubscribers.clear(); } catch (XMPPException e) { if (!othersNotified) { // transaction, attempt to roll back the ownership changes @@ -713,4 +760,27 @@ public class SharedDisplaySession extends VenueSession implements return closed; } + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.viz.collaboration.comm.identity.ISharedDisplaySession + * #isSharedDisplayClient + * (com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant) + */ + @Override + public boolean isSharedDisplayClient(VenueParticipant participant) { + UserId actualId = getVenue().getParticipantUserid(participant); + boolean rval = false; + if (actualId != null) { + try { + rval = isSubscribedToTopic(actualId); + } catch (XMPPException e) { + log.error("Error checking if user is a shared display client", + e); + } + } + return rval; + } + } diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/CollaborationSessionView.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/CollaborationSessionView.java index b7c92ff443..a27ce5e13c 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/CollaborationSessionView.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/CollaborationSessionView.java @@ -100,6 +100,7 @@ import com.raytheon.viz.ui.input.EditableManager; * Mar 06, 2014 2848 bclement moved colormanager update code to session container * Mar 11, 2014 2865 lvenable Added null checks in threads * Mar 18, 2014 2895 njensen Fix lockAction enable/disable logic + * Apr 15, 2014 2822 bclement only allow transfer leader if participant is using shared display * * * @@ -539,7 +540,8 @@ public class CollaborationSessionView extends SessionView implements .getSelection(); VenueParticipant entry = (VenueParticipant) selection .getFirstElement(); - if (!entry.isSameUser(session.getUserID())) { + if (!entry.isSameUser(session.getUserID()) + && session.isSharedDisplayClient(entry)) { manager.add(leaderChangeAction); } } From 27885c8296ff6f1a34a6f2aef3a0ff36741d979c Mon Sep 17 00:00:00 2001 From: Everett Kladstrup Date: Tue, 15 Apr 2014 15:18:09 -0500 Subject: [PATCH 032/188] Issue #2725 Fix localization type for DerivParamLocalizationAdapter Former-commit-id: d9bd028d94f802e346a5396e9ae84a13b00691e3 --- cave/com.raytheon.uf.viz.derivparam.ui/plugin.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cave/com.raytheon.uf.viz.derivparam.ui/plugin.xml b/cave/com.raytheon.uf.viz.derivparam.ui/plugin.xml index 70280d8b04..fb6f570c5d 100644 --- a/cave/com.raytheon.uf.viz.derivparam.ui/plugin.xml +++ b/cave/com.raytheon.uf.viz.derivparam.ui/plugin.xml @@ -24,7 +24,7 @@ point="com.raytheon.uf.viz.localization.localizationpath"> Date: Tue, 15 Apr 2014 16:40:08 -0500 Subject: [PATCH 033/188] Issue #3031 - Added dispose check in the runAsync calls. Change-Id: I7996f58995aa261a1a66acc755768c3489130d43 Former-commit-id: 72f2908000301dd025a2c801b1ab129460d8cdf9 --- .../viz/texteditor/dialogs/AfosBrowserDlg.java | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/dialogs/AfosBrowserDlg.java b/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/dialogs/AfosBrowserDlg.java index 1dff46ba59..a82fb9c35c 100644 --- a/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/dialogs/AfosBrowserDlg.java +++ b/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/dialogs/AfosBrowserDlg.java @@ -102,6 +102,7 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * 29Jan2013 1496 rferrel Changes to designator hours query * off the UI thread. * Changes to have multiple query jobs. + * 15Apr2014 #3031 lvenable Added dispose check in the runAsync calls. * * * @author lvenable @@ -1606,6 +1607,9 @@ public class AfosBrowserDlg extends CaveSWTDialog implements @Override public void run() { + if (isDisposed()) { + return; + } startDesignatorTimeList(); } }); @@ -1657,6 +1661,9 @@ public class AfosBrowserDlg extends CaveSWTDialog implements @Override public void run() { + if (isDisposed()) { + return; + } for (TimesRequest result : resultList) { if (canceled) { break; @@ -1690,6 +1697,9 @@ public class AfosBrowserDlg extends CaveSWTDialog implements @Override public void run() { + if (isDisposed()) { + return; + } finishDesignatorTimeList(); } }); From 5dbedee47ad107633ba2e651820cbb2e0816981e Mon Sep 17 00:00:00 2001 From: Everett Kladstrup Date: Tue, 15 Apr 2014 16:53:07 -0500 Subject: [PATCH 034/188] Issue #2725 Move viirs derivparam python package to common_static Former-commit-id: e89895b8448e3eeb70f2850f84773e8345114c38 --- .../common_static/base}/derivedParameters/functions/viirs/Math.py | 0 .../base}/derivedParameters/functions/viirs/__init__.py | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename {cave/com.raytheon.uf.viz.npp.viirs/localization => edexOsgi/com.raytheon.uf.common.dataplugin.npp.viirs/utility/common_static/base}/derivedParameters/functions/viirs/Math.py (100%) rename {cave/com.raytheon.uf.viz.npp.viirs/localization => edexOsgi/com.raytheon.uf.common.dataplugin.npp.viirs/utility/common_static/base}/derivedParameters/functions/viirs/__init__.py (100%) diff --git a/cave/com.raytheon.uf.viz.npp.viirs/localization/derivedParameters/functions/viirs/Math.py b/edexOsgi/com.raytheon.uf.common.dataplugin.npp.viirs/utility/common_static/base/derivedParameters/functions/viirs/Math.py similarity index 100% rename from cave/com.raytheon.uf.viz.npp.viirs/localization/derivedParameters/functions/viirs/Math.py rename to edexOsgi/com.raytheon.uf.common.dataplugin.npp.viirs/utility/common_static/base/derivedParameters/functions/viirs/Math.py diff --git a/cave/com.raytheon.uf.viz.npp.viirs/localization/derivedParameters/functions/viirs/__init__.py b/edexOsgi/com.raytheon.uf.common.dataplugin.npp.viirs/utility/common_static/base/derivedParameters/functions/viirs/__init__.py similarity index 100% rename from cave/com.raytheon.uf.viz.npp.viirs/localization/derivedParameters/functions/viirs/__init__.py rename to edexOsgi/com.raytheon.uf.common.dataplugin.npp.viirs/utility/common_static/base/derivedParameters/functions/viirs/__init__.py From 726c122dc744a88b7bdd4bb9548740b98f3e76a9 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Tue, 15 Apr 2014 17:18:30 -0500 Subject: [PATCH 035/188] Issue #2956 safety checks for GLShadedShapeBase Change-Id: I7ec226af0de46ee3c7dffc34e82da9cf6846e451 Former-commit-id: 1249c06521c5575960605176dcd46b77cbe1a1bc --- .../viz/core/gl/GLGeometryPainter.java | 16 ++++++--- .../core/gl/internal/GLShadedShapeBase.java | 35 ++++++++++++++++--- .../viz/core/gl/internal/GLTarget.java | 7 ++-- 3 files changed, 47 insertions(+), 11 deletions(-) diff --git a/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/GLGeometryPainter.java b/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/GLGeometryPainter.java index 8f125409d1..9342741f9e 100644 --- a/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/GLGeometryPainter.java +++ b/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/GLGeometryPainter.java @@ -29,8 +29,8 @@ import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.viz.core.gl.GLGeometryObject2D.State; /** - * Separated from GLGeometryObject2D. Added checks on glDrawArrays and - * glMultiDrawArrays. + * Separated from GLGeometryObject2D. Adds checks on glDrawArrays and + * glMultiDrawArrays to ensure valid values are passed in. * *
  * 
@@ -38,7 +38,8 @@ import com.raytheon.viz.core.gl.GLGeometryObject2D.State;
  * 
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
- * Jun 7, 2011            njensen     Initial creation
+ * Jun 07, 2011            njensen     Initial creation
+ * Apr 15, 2014 2956       njensen     Fixed documentation
  * 
  * 
* @@ -48,6 +49,13 @@ import com.raytheon.viz.core.gl.GLGeometryObject2D.State; public class GLGeometryPainter { + /** + * Paints the geometries + * + * @param gl + * @param geoms + * @throws VizException + */ public static void paintGeometries(GL gl, GLGeometryObject2D... geoms) throws VizException { State state = State.INVALID; @@ -70,7 +78,7 @@ public class GLGeometryPainter { if (geom.data.mutable == false) { throw new VizException( "Could not paint, geometry was not created " - + "as mutable but in in the mutable state." + + "as mutable but is in the mutable state." + " Geometry must be compiled before use"); } } diff --git a/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLShadedShapeBase.java b/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLShadedShapeBase.java index 94c4373a16..75c7c8c6b6 100644 --- a/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLShadedShapeBase.java +++ b/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLShadedShapeBase.java @@ -41,6 +41,7 @@ import org.opengis.referencing.operation.TransformException; import com.raytheon.uf.common.geospatial.TransformFactory; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.viz.core.drawables.IShape; +import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.viz.core.gl.Activator; import com.vividsolutions.jts.geom.Coordinate; import com.vividsolutions.jts.geom.LineString; @@ -56,9 +57,11 @@ import com.vividsolutions.jts.geom.LineString; * * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Sep 3, 2011 bsteffen Initial creation + * Sep 3, 2011 bsteffen Initial creation * Apr 25, 2013 1954 bsteffen Speed up creation of * GLColormapShadedShapes. + * Apr 15, 2014 2956 njensen Safety check of buffers before glMultiDrawArray + * * * * @@ -148,6 +151,7 @@ public class GLShadedShapeBase implements IShape { polygons.add(buffers); } + @Override public synchronized void compile() { if (polygons.isEmpty()) { return; @@ -314,7 +318,8 @@ public class GLShadedShapeBase implements IShape { } protected synchronized void paint(GL gl, - boolean cardSupportsHighEndFeatures, float brightness) { + boolean cardSupportsHighEndFeatures, float brightness) + throws VizException { if (!polygons.isEmpty()) { compile(); } @@ -353,8 +358,17 @@ public class GLShadedShapeBase implements IShape { contourLengthBuffer.rewind(); contourStartBuffer.rewind(); if (cardSupportsHighEndFeatures) { - gl.glMultiDrawArrays(GL.GL_POLYGON, contourStartBuffer, - contourLengthBuffer, contourLengthBuffer.capacity()); + if (contourStartBuffer.capacity() > 0 + && contourLengthBuffer.capacity() > 0) { + gl.glMultiDrawArrays(GL.GL_POLYGON, contourStartBuffer, + contourLengthBuffer, contourLengthBuffer.capacity()); + } else { + throw new VizException( + "Dangerous parameters passed to glMultiDrawArrays: contourStartBufferCapacity=" + + contourStartBuffer.capacity() + + ", contourLengthBufferCapacity=" + + contourLengthBuffer.capacity()); + } } else { while (contourLengthBuffer.hasRemaining()) { gl.glDrawArrays(GL.GL_POLYGON, contourStartBuffer.get(), @@ -368,6 +382,7 @@ public class GLShadedShapeBase implements IShape { } } + @Override public synchronized void dispose() { polygons = new ArrayList(); vertexBuffer = null; @@ -383,14 +398,17 @@ public class GLShadedShapeBase implements IShape { private class Tessellator implements GLUtessellatorCallback { + @Override public void begin(int arg0) { } + @Override public void beginData(int arg0, Object arg1) { // Not necessary for type of tesselation } + @Override public void combine(double[] coordinates, Object[] v, float[] arg2, Object[] out) { double[] vertex = new double[3]; @@ -400,37 +418,45 @@ public class GLShadedShapeBase implements IShape { out[0] = vertex; } + @Override public void combineData(double[] arg0, Object[] arg1, float[] arg2, Object[] arg3, Object arg4) { // Not necessary for type of tesselation } + @Override public void edgeFlag(boolean arg0) { // No operation, but needed to force GL_TRIANGLES } + @Override public void edgeFlagData(boolean arg0, Object arg1) { } + @Override public void end() { } + @Override public void endData(Object arg0) { // Not necessary for type of tesselation } + @Override public void error(int arg0) { System.err.println("Tess Error: " + arg0); } + @Override public void errorData(int arg0, Object arg1) { // Not necessary for type of tesselation } + @Override public void vertex(Object data) { if (data instanceof double[]) { if (vertexBuffer.remaining() < 2) { @@ -448,6 +474,7 @@ public class GLShadedShapeBase implements IShape { } } + @Override public void vertexData(Object arg0, Object arg1) { // Not necessary for type of tesselation } diff --git a/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLTarget.java b/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLTarget.java index 8b3d5f5e15..19a06fe834 100644 --- a/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLTarget.java +++ b/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLTarget.java @@ -144,6 +144,7 @@ import com.sun.opengl.util.j2d.TextRenderer; * if changed * Apr 04, 2014 2920 bsteffen Allow strings to use mulitple styles. * Apr 08, 2014 2950 bsteffen Reduce oversized colormaps. + * Apr 15, 2014 2956 njensen Throw VizException from drawShadedShapesInternal * * * @@ -836,7 +837,7 @@ public class GLTarget extends AbstractGraphicsTarget implements IGLTarget { } private void drawShadedShapesInternal(List shapes, - float alpha, float brightness) { + float alpha, float brightness) throws VizException { brightness = Math.max(brightness, 0.0f); brightness = Math.min(brightness, 1.0f); @@ -1270,9 +1271,9 @@ public class GLTarget extends AbstractGraphicsTarget implements IGLTarget { } statusHandler.info("Reducing colormap to " + lessColors.size() + " colors because this graphics card only supports " - + capabilities.maxTextureSize + + capabilities.maxTextureSize + " colors and the colormap contains " - + glColorMap.getSize() + " colors."); + + glColorMap.getSize() + " colors."); glColorMap = new ColorMap(lessColors.size()); for (int i = 0; i < lessColors.size(); i += 1) { glColorMap.setColor(i, lessColors.get(i)); From 7afb1e66f535219195d07235b73be01fc86c2b66 Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Wed, 16 Apr 2014 09:23:00 -0500 Subject: [PATCH 036/188] Issue #2981 fixed NPE when cached shared group deleted on server Former-commit-id: 8ee453e3f5256d3ffed255aaebc792155001bc8e --- .../comm/provider/user/ContactsManager.java | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java index 0064e55698..b983dca2e4 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java @@ -76,6 +76,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.event.RosterChangeEvent; * Jan 31, 2014 2700 bclement added addToRoster, fixed add to group when in roster, but blocked * Feb 3, 2014 2699 bclement fixed assumption that username search was exact * Apr 11, 2014 2903 bclement moved roster listener from collaboration connection to here + * Apr 16, 2014 2981 bclement fixed NPE when cached shared group deleted on server * * * @@ -199,7 +200,13 @@ public class ContactsManager { Roster roster = getRoster(); for (String group : groups) { RosterGroup rg = roster.getGroup(group); - rval.add(new SharedGroup(rg)); + /* + * group will be null if it has been removed from server after + * cached in shared groups. + */ + if (rg != null) { + rval.add(new SharedGroup(rg)); + } } return rval; } From 7f068f164cc7ddfe928908ac0cda866632d74596 Mon Sep 17 00:00:00 2001 From: Lee Venable Date: Wed, 16 Apr 2014 13:14:03 -0500 Subject: [PATCH 037/188] Issue #3034 - added widget dispose checks in runAsync methods. Change-Id: I9182441c34c63c5a78023adda2ec036f2a51192e Former-commit-id: 8e8e65ecbc22dcebb7a494ddbd6b7183d67981a0 --- .../uf/viz/archive/ui/AbstractArchiveDlg.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/AbstractArchiveDlg.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/AbstractArchiveDlg.java index 1840f6293e..b17a977ee4 100644 --- a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/AbstractArchiveDlg.java +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/AbstractArchiveDlg.java @@ -77,6 +77,8 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * Aug 06, 2013 2222 rferrel Changes to display all selected data. * Nov 14, 2013 2549 rferrel Get category data moved off the UI thread. * Dec 11, 2013 2624 rferrel No longer clear table prior to populating. + * Apr 15, 2014 3034 lvenable Added dispose checks in runAsync calls. + * * * * @author bgonzale @@ -509,6 +511,11 @@ public abstract class AbstractArchiveDlg extends CaveSWTDialog implements @Override public void run() { + // If the dialog has been disposed then return. + if (isDisposed()) { + return; + } + try { if (displayDatas != null) { tableComp.populateTable(archiveName, categoryName, @@ -676,6 +683,11 @@ public abstract class AbstractArchiveDlg extends CaveSWTDialog implements @Override public void run() { + // If the dialog has been disposed then return. + if (isDisposed()) { + return; + } + tableComp.updateSize(myDisplayDatas); updateTotals(null); } From bfafb0d055b65006bf178fa92ee4a714a4c0a8ac Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Wed, 16 Apr 2014 14:26:17 -0500 Subject: [PATCH 038/188] Issue #3020 fixed error message when attempting to create already accessible room Former-commit-id: 738e4cb06a549e6067274af033cc7ba725b1a8e2 --- .../comm/provider/session/VenueSession.java | 26 ++++++++++++++----- 1 file changed, 20 insertions(+), 6 deletions(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java index 00cbc8e9ae..6320d6e1bb 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java @@ -107,6 +107,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; * moved muc close logic to closeMuc() * handle is now set in constructor * Apr 11, 2014 2903 bclement made constructor public b/c connection code moved packages + * Apr 16, 2014 3020 bclement added check for invited rooms in roomExistsOnServer() * * * @@ -147,9 +148,8 @@ public class VenueSession extends BaseSession implements IVenueSession { * @param container * @param eventBus */ - public VenueSession(EventBus externalBus, - CollaborationConnection manager, String venueName, String handle, - String sessionId) { + public VenueSession(EventBus externalBus, CollaborationConnection manager, + String venueName, String handle, String sessionId) { super(externalBus, manager, sessionId); this.venueName = venueName; this.handle = handle; @@ -160,8 +160,8 @@ public class VenueSession extends BaseSession implements IVenueSession { * @param container * @param eventBus */ - public VenueSession(EventBus externalBus, - CollaborationConnection manager, CreateSessionData data) { + public VenueSession(EventBus externalBus, CollaborationConnection manager, + CreateSessionData data) { super(externalBus, manager); this.venueName = data.getName(); this.handle = data.getHandle(); @@ -433,10 +433,11 @@ public class VenueSession extends BaseSession implements IVenueSession { public static boolean roomExistsOnServer(XMPPConnection conn, String roomId) throws XMPPException { String host = Tools.parseHost(roomId); + + /* check for public rooms */ ServiceDiscoveryManager serviceDiscoveryManager = new ServiceDiscoveryManager( conn); DiscoverItems result = serviceDiscoveryManager.discoverItems(host); - for (Iterator items = result.getItems(); items .hasNext();) { DiscoverItems.Item item = items.next(); @@ -444,6 +445,19 @@ public class VenueSession extends BaseSession implements IVenueSession { return true; } } + + /* check for private rooms that we have access to */ + try { + MultiUserChat.getRoomInfo(conn, roomId); + /* getRoomInfo only returns if the room was found */ + return true; + } catch (XMPPException e) { + /* + * getRoomInfo throws a 404 if the room does exist or is private and + * we don't have access. In either case, we can't say that the room + * exists + */ + } return false; } From 1112ca621e3887d308ce854c477f76b9b32e072d Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Wed, 16 Apr 2014 14:13:58 -0500 Subject: [PATCH 039/188] Issue #3021 increased width of create session dialog to fit error msg Former-commit-id: f0bcc20987d814a716994f712c6132bb79963457 --- .../raytheon/uf/viz/collaboration/ui/CreateSessionDialog.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateSessionDialog.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateSessionDialog.java index abebed40d7..2af30bbe76 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateSessionDialog.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateSessionDialog.java @@ -93,6 +93,7 @@ import com.raytheon.viz.ui.editor.IMultiPaneEditor; * Feb 7, 2014 2699 bclement removed handle validation * Feb 11, 2014 2699 bclement require non-blank handle * Mar 06, 2014 2848 bclement moved session creation logic to separate method + * Apr 16, 2014 3021 bclement increased width of dialog * * * @@ -138,7 +139,7 @@ public class CreateSessionDialog extends CaveSWTDialog { label.setText("Name: "); nameTF = new Text(body, SWT.BORDER); GridData gd = new GridData(SWT.FILL, SWT.FILL, true, true); - gd.minimumWidth = 200; + gd.minimumWidth = 300; nameTF.setLayoutData(gd); VerifyListener validNameListener = new VerifyListener() { From 709e3411c4825c4fc902319d1d0e73c0d95cb9a8 Mon Sep 17 00:00:00 2001 From: Ben Steffensmeier Date: Tue, 15 Apr 2014 17:42:23 -0500 Subject: [PATCH 040/188] Issue #2947 Redo satellite derived parameters to use an inventory to determine availability. Former-commit-id: 1a041cb3be1141f4af116335e5b9540beda817cb --- .../META-INF/MANIFEST.MF | 5 +- .../bundles/DerivedCONUSSatellite.xml | 157 +++--- .../bundles/DerivedCompositeSatellite.xml | 129 ++--- .../bundles/DerivedPOESSatellite.xml | 82 +-- .../localization/bundles/DerivedSatellite.xml | 96 ++-- cave/com.raytheon.viz.satellite/plugin.xml | 7 + .../res/spring/satellite-datacube-spring.xml | 2 +- .../satellite/SatelliteDataCubeAdapter.java | 525 ------------------ .../inventory/ComparableSatMapCoverage.java | 132 +++++ .../inventory/DerivedSatelliteRecord.java | 164 ++++++ .../inventory/SatelliteCoverageCache.java | 100 ++++ .../inventory/SatelliteDataCubeAdapter.java | 178 ++++++ .../inventory/SatelliteInventory.java | 229 ++++++++ .../inventory/SatelliteRequestableData.java | 214 +++++++ .../SatelliteRequestableLevelNode.java | 173 ++++++ .../inventory/SatelliteUnitRegistrar.java | 49 ++ .../satellite/rsc/SatBestResResourceData.java | 2 +- .../viz/satellite/rsc/SatResource.java | 27 +- .../satellite/tileset/SatDataRetriever.java | 36 +- .../satellite/units/SatelliteUnits.java | 61 +- .../units/goes/PercentOfNormalTPWPixel.java | 12 +- .../definitions/poesDif11u3_7uIR.xml | 6 +- .../definitions/satDif11u12uIR.xml | 6 +- .../definitions/satDif11u13uIR.xml | 6 +- .../definitions/satDif11u3_9uIR.xml | 6 +- .../definitions/satDivWVIR.xml | 6 +- .../functions/satDif11u3_9uIR.py | 0 .../functions/satDifference.py | 0 .../derivedParameters/functions/satDivWVIR.py | 0 .../common/dataplugin/PluginDataObject.java | 13 +- .../area/McIdasAreaProviderFactory.java | 1 - 31 files changed, 1573 insertions(+), 851 deletions(-) delete mode 100644 cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/SatelliteDataCubeAdapter.java create mode 100644 cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/ComparableSatMapCoverage.java create mode 100644 cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/DerivedSatelliteRecord.java create mode 100644 cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteCoverageCache.java create mode 100644 cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteDataCubeAdapter.java create mode 100644 cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteInventory.java create mode 100644 cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteRequestableData.java create mode 100644 cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteRequestableLevelNode.java create mode 100644 cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteUnitRegistrar.java rename edexOsgi/{com.raytheon.uf.common.derivparam => com.raytheon.uf.common.dataplugin.satellite}/utility/common_static/base/derivedParameters/definitions/poesDif11u3_7uIR.xml (82%) rename edexOsgi/{com.raytheon.uf.common.derivparam => com.raytheon.uf.common.dataplugin.satellite}/utility/common_static/base/derivedParameters/definitions/satDif11u12uIR.xml (80%) rename edexOsgi/{com.raytheon.uf.common.derivparam => com.raytheon.uf.common.dataplugin.satellite}/utility/common_static/base/derivedParameters/definitions/satDif11u13uIR.xml (79%) rename edexOsgi/{com.raytheon.uf.common.derivparam => com.raytheon.uf.common.dataplugin.satellite}/utility/common_static/base/derivedParameters/definitions/satDif11u3_9uIR.xml (79%) rename edexOsgi/{com.raytheon.uf.common.derivparam => com.raytheon.uf.common.dataplugin.satellite}/utility/common_static/base/derivedParameters/definitions/satDivWVIR.xml (80%) rename edexOsgi/{com.raytheon.uf.common.derivparam.python => com.raytheon.uf.common.dataplugin.satellite}/utility/common_static/base/derivedParameters/functions/satDif11u3_9uIR.py (100%) rename edexOsgi/{com.raytheon.uf.common.derivparam.python => com.raytheon.uf.common.dataplugin.satellite}/utility/common_static/base/derivedParameters/functions/satDifference.py (100%) rename edexOsgi/{com.raytheon.uf.common.derivparam.python => com.raytheon.uf.common.dataplugin.satellite}/utility/common_static/base/derivedParameters/functions/satDivWVIR.py (100%) diff --git a/cave/com.raytheon.viz.satellite/META-INF/MANIFEST.MF b/cave/com.raytheon.viz.satellite/META-INF/MANIFEST.MF index 562f578c2e..3186ca34c3 100644 --- a/cave/com.raytheon.viz.satellite/META-INF/MANIFEST.MF +++ b/cave/com.raytheon.viz.satellite/META-INF/MANIFEST.MF @@ -25,7 +25,10 @@ Require-Bundle: org.eclipse.ui, com.raytheon.viz.core, javax.measure, com.raytheon.uf.common.inventory;bundle-version="1.14.0", - com.raytheon.uf.viz.datacube;bundle-version="1.14.0" + com.raytheon.uf.viz.datacube;bundle-version="1.14.0", + com.raytheon.uf.common.dataplugin.level, + com.raytheon.uf.common.comm, + com.raytheon.uf.common.numeric Bundle-ActivationPolicy: lazy Export-Package: com.raytheon.viz.satellite, com.raytheon.viz.satellite.rsc diff --git a/cave/com.raytheon.viz.satellite/localization/bundles/DerivedCONUSSatellite.xml b/cave/com.raytheon.viz.satellite/localization/bundles/DerivedCONUSSatellite.xml index 27a695d178..d9cae0ae54 100644 --- a/cave/com.raytheon.viz.satellite/localization/bundles/DerivedCONUSSatellite.xml +++ b/cave/com.raytheon.viz.satellite/localization/bundles/DerivedCONUSSatellite.xml @@ -1,77 +1,98 @@ + + - - - + + + - - - - - - - - PLAIN_VIEW - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + - - + + - - - - - - - - - - - - - - - - - - - - - - - + + - - + + - - - + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - + + + diff --git a/cave/com.raytheon.viz.satellite/localization/bundles/DerivedCompositeSatellite.xml b/cave/com.raytheon.viz.satellite/localization/bundles/DerivedCompositeSatellite.xml index a55bb63544..534324c306 100644 --- a/cave/com.raytheon.viz.satellite/localization/bundles/DerivedCompositeSatellite.xml +++ b/cave/com.raytheon.viz.satellite/localization/bundles/DerivedCompositeSatellite.xml @@ -1,21 +1,39 @@ + + - + - + - + - + - - - - + - + - + - - - - - + + - - - @@ -82,21 +88,14 @@ - - + - + - - - - - + + - - - - + - - + - + - - - - - + + - - - - - - - - + + - - - @@ -198,20 +175,13 @@ - - + - + - - - - + - - - diff --git a/cave/com.raytheon.viz.satellite/localization/bundles/DerivedPOESSatellite.xml b/cave/com.raytheon.viz.satellite/localization/bundles/DerivedPOESSatellite.xml index 7c19d6c02e..05edbd0a20 100644 --- a/cave/com.raytheon.viz.satellite/localization/bundles/DerivedPOESSatellite.xml +++ b/cave/com.raytheon.viz.satellite/localization/bundles/DerivedPOESSatellite.xml @@ -1,37 +1,53 @@ - + + - - - - - - - - - PLAN_VIEW - - - - - - - - - - - - - - + + + + + + + + + + + + + + - - + + - - - - - - - + + + + + + + + + diff --git a/cave/com.raytheon.viz.satellite/localization/bundles/DerivedSatellite.xml b/cave/com.raytheon.viz.satellite/localization/bundles/DerivedSatellite.xml index 5898a9cc83..a528bcdec7 100644 --- a/cave/com.raytheon.viz.satellite/localization/bundles/DerivedSatellite.xml +++ b/cave/com.raytheon.viz.satellite/localization/bundles/DerivedSatellite.xml @@ -1,43 +1,61 @@ - + + - - - - - - - - - - - - PLAN_VIEW - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + - - + + - - - - - - - + + + + + + + + + + + + diff --git a/cave/com.raytheon.viz.satellite/plugin.xml b/cave/com.raytheon.viz.satellite/plugin.xml index c7d3cc2bce..f917820dcd 100644 --- a/cave/com.raytheon.viz.satellite/plugin.xml +++ b/cave/com.raytheon.viz.satellite/plugin.xml @@ -55,4 +55,11 @@ itemProvider="com.raytheon.viz.satellite.menu.SatBundleMenuContribution"> + + + +
diff --git a/cave/com.raytheon.viz.satellite/res/spring/satellite-datacube-spring.xml b/cave/com.raytheon.viz.satellite/res/spring/satellite-datacube-spring.xml index 37c16e1f3f..ce81af56b0 100644 --- a/cave/com.raytheon.viz.satellite/res/spring/satellite-datacube-spring.xml +++ b/cave/com.raytheon.viz.satellite/res/spring/satellite-datacube-spring.xml @@ -2,7 +2,7 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd"> - + - * - * SOFTWARE HISTORY - * Date Ticket# Engineer Description - * ------------ ---------- ----------- -------------------------- - * Jul 27, 2009 jsanchez Initial creation - * Nov 21, 2009 3576 rjpeter Refactored use of DerivParamDesc. - * Aug 03, 2012 798 jkorman Explicitly set interpolationLevels from - * "source" record. - * Apr 08, 2013 1293 bkowal Removed references to hdffileid. - * Jun 04, 2013 2041 bsteffen Switch derived parameters to use - * concurrent python for threading. - * Sep 9, 2013 2277 mschenke Got rid of ScriptCreator references - * - * - * @author jsanchez - * @version 1.0 - */ - -public class SatelliteDataCubeAdapter extends DefaultDataCubeAdapter { - - private static final String PE = "physicalElement"; - - public static final String DERIVED = "DERIVED"; - - private Map derParLibrary; - - /** - * @param pluginName - */ - public SatelliteDataCubeAdapter() { - super(SatelliteRecord.PLUGIN_ID); - } - - @Override - public PluginDataObject[] getData( - Map constraints, DataTime[] selectedTimes) - throws DataCubeException { - Map originalQuery = constraints; - if (originalQuery.containsKey(DERIVED) == false) { - return super.getData(originalQuery, selectedTimes); - } - - String requestedParam; - List initResponses = new ArrayList(); - List listOfRequests = new ArrayList(); - Map modifiedQuery = new HashMap( - originalQuery); - modifiedQuery.remove(DERIVED); - modifiedQuery.remove(PE); - - if (!originalQuery.containsKey(PE) - || !originalQuery.containsKey("pluginName")) { - throw new DataCubeException("getData method requires more query " - + "information for plugin : " - + originalQuery.get("pluginName").getConstraintValue()); - } else { - String[] physicalElements = originalQuery.get(PE) - .getConstraintValue().split(","); - requestedParam = physicalElements[physicalElements.length - 1]; - } - - List baseParams; - try { - baseParams = new ArrayList(Arrays.asList(CatalogQuery - .performQuery(PE, modifiedQuery))); - } catch (VizException e) { - throw new DataCubeException(e); - } - - if (!baseParams.contains(requestedParam) - && derParLibrary.containsKey(requestedParam)) { - DerivParamDesc desc = derParLibrary.get(requestedParam); - DerivParamMethod method = desc.getMethods().get(0); - boolean requestInitialized = false; - - for (IDerivParamField ifield : method.getFields()) { - DerivParamField field = (DerivParamField) ifield; - Map query = modifyQuery( - modifiedQuery, field); - - PluginDataObject[] pdos = super.getData(query, selectedTimes); - for (PluginDataObject pdo : pdos) { - SatelliteRecord record = (SatelliteRecord) pdo; - if (requestInitialized) { - for (DerivedParameterRequest definedRequest : listOfRequests) { - if (record.getDataTime().compareTo( - definedRequest.getBaseTime()) != 0) { - continue; - } - definedRequest.addBaseParam(record); - break; - } - } else { - DerivedParameterRequest request = new DerivedParameterRequest(); - request.setParameterAbbreviation(requestedParam); - request.setMethod(method.getName()); - request.addBaseParam(record); - request.setBaseTime(record.getDataTime()); - listOfRequests.add(request); - SatelliteRecord derivedRecord = new SatelliteRecord( - record.getDataURI()); - // Make sure to get the number of interpolation levels! - derivedRecord.setInterpolationLevels(record - .getInterpolationLevels()); - - derivedRecord.setPhysicalElement(originalQuery.get(PE) - .getConstraintValue()); - derivedRecord.setMessageData(request); - derivedRecord.setCoverage(record.getCoverage()); - // Reset dataURI after setting fields - derivedRecord.setDataURI(null); - - initResponses.add(derivedRecord); - } - } - requestInitialized = true; - } - for (int i = 0; i < initResponses.size(); i++) { - Object satObject = initResponses.get(i); - SatelliteRecord record = (SatelliteRecord) satObject; - DerivedParameterRequest currentRequest = (DerivedParameterRequest) record - .getMessageData(); - if (currentRequest.getBaseParams().size() != method.getFields() - .size()) { - if (initResponses.remove(satObject)) { - i--; - } - } - } - return initResponses.toArray(new PluginDataObject[0]); - } else { - return super.getData(originalQuery, selectedTimes); - } - } - - @Override - public IDataRecord[] getRecord(PluginDataObject obj) - throws DataCubeException { - if (obj.getMessageData() == null) { - return super.getRecord(obj); - } - - return null; - } - - @Override - public IDataRecord[] getRecord(PluginDataObject obj, Request req, - String dataset) throws DataCubeException { - if (obj.getMessageData() == null) { - return super.getRecord(obj, req, dataset); - } - - boolean interpolate = false; - int targetWidth = 0; - int targetHeight = 0; - ArrayList hdf5Files = new ArrayList(); - ArrayList datasets = new ArrayList(); - ArrayList records = new ArrayList(); - ArrayList bytes = new ArrayList(); - DerivedParameterRequest derivedRequest = (DerivedParameterRequest) obj - .getMessageData(); - // clone the request in case of multiple threads. - derivedRequest = new DerivedParameterRequest(derivedRequest); - for (Object param : derivedRequest.getBaseParams()) { - records.add((SatelliteRecord) param); - hdf5Files.add(HDF5Util.findHDF5Location((SatelliteRecord) param)); - datasets.add(getDataset(((SatelliteRecord) param).getDataURI(), - dataset)); - } - - int largestRecIdx = 0; - /* - * Need to update to take into account if more than 2 sat records are - * used in derived parameter - */ - GridGeometry2D geo = null; - if (!records.get(0).getCoverage().getNx() - .equals(records.get(1).getCoverage().getNx()) - || !records.get(0).getCoverage().getNy() - .equals(records.get(1).getCoverage().getNy())) { - interpolate = true; - SatMapCoverage coverage = records.get(largestRecIdx).getCoverage(); - geo = coverage.getGridGeometry(); - targetWidth = coverage.getNx(); - targetHeight = coverage.getNy(); - } - - try { - int i = 0; - for (File file : hdf5Files) { - IDataStore ds = DataStoreFactory.getDataStore(file); - IDataRecord rec = null; - if (interpolate && i != largestRecIdx) { - if (obj.getRecord() == null) { - rec = ds.retrieve("", datasets.get(i), Request.ALL); - int w = (int) ((ByteDataRecord) rec).getSizes()[0]; - int h = (int) ((ByteDataRecord) rec).getSizes()[1]; - obj.setRecord(interpolate((ByteDataRecord) rec, w, h, - targetWidth, targetHeight, geo)); - } - // cut out the tiles from that interpolated dataset - // and make an image from just that small subset - ByteDataRecord bdr = cutTile( - (ByteDataRecord) obj.getRecord(), req); - bytes.add(bdr); - } else { - rec = ds.retrieve("", datasets.get(i), req); - bytes.add((ByteDataRecord) rec); - } - - i++; - } - } catch (Exception e) { - throw new DataCubeException("Error in Satellite Data Cube", e); - } - - derivedRequest.setArgumentRecords(bytes.toArray(new Object[] {})); - List finalResult; - try { - finalResult = DerivedParameterGenerator.calculate(derivedRequest); - } catch (ExecutionException e) { - throw new DataCubeException(e); - } - - if (finalResult != null && finalResult.size() == 1) { - return new IDataRecord[] { ((ByteDataRecord) finalResult.get(0)) }; - } - return null; - } - - /* - * (non-Javadoc) - * - * @see - * com.raytheon.uf.viz.core.datastructure.IDataCubeAdapter#getRecords(java - * .util.List, com.raytheon.uf.common.datastorage.Request, java.lang.String) - */ - @Override - public void getRecords(List objs, Request req, - String dataset) throws DataCubeException { - for (PluginDataObject obj : objs) { - IDataRecord[] records = getRecord(obj, req, dataset); - obj.setMessageData(records); - } - } - - @Override - public void initInventory() { - derParLibrary = DerivedParameterGenerator.getDerParLibrary(); - } - - private String getDataset(String dataUri, String dataset) { - return "/" + dataUri + "/" + dataset; - } - - private ByteDataRecord interpolate(ByteDataRecord bdr, int width, - int height, int targetWidth, int targetHeight, GridGeometry2D geo) { - int[] nBits = new int[] { 8 }; - GridCoverageFactory factory = new GridCoverageFactory(); - ColorSpace cs = ColorSpace.getInstance(ColorSpace.CS_GRAY); - ColorModel cm = new ComponentColorModel(cs, nBits, false, true, - Transparency.OPAQUE, DataBuffer.TYPE_BYTE); - DataBufferByte data = new DataBufferByte(bdr.getByteData(), height - * width); - SampleModel sm = cm.createCompatibleSampleModel(width, height); - WritableRaster writeRaster = WritableRaster.createWritableRaster(sm, - data, null); - - // Create the coverage for the image - GridCoverage2D gc = factory - .create("in", writeRaster, geo.getEnvelope()); - GridCoverage2D projected = MapUtil.reprojectCoverage(gc, - geo.getCoordinateReferenceSystem(), geo, - Interpolation.getInstance(Interpolation.INTERP_NEAREST)); - - Raster currSatRaster = projected.getRenderedImage().getData(); - byte[] currSat = ((DataBufferByte) currSatRaster.getDataBuffer()) - .getData(); - - long newSizes[] = { (long) targetWidth, (long) targetHeight }; - - ByteDataRecord rval = new ByteDataRecord(bdr.getName(), bdr.getGroup(), - currSat, bdr.getDimension(), newSizes); - return rval; - } - - private ByteDataRecord cutTile(ByteDataRecord bdr, Request req) { - int minTileX = req.getMinIndexForSlab()[0]; - int minTileY = req.getMinIndexForSlab()[1]; - int maxTileX = req.getMaxIndexForSlab()[0]; - int maxTileY = req.getMaxIndexForSlab()[1]; - int widthOfWholeImage = (int) bdr.getSizes()[0]; - int newWidth = maxTileX - minTileX; - int newHeight = maxTileY - minTileY; - long newSizes[] = { (long) newWidth, (long) newHeight }; - - byte bytes[] = bdr.getByteData(); - byte newBytes[] = new byte[newHeight * newWidth]; - - int index = 0; - for (int j = minTileY; j < maxTileY; j++) { - for (int i = minTileX; i < maxTileX; i++) { - newBytes[index++] = bytes[j * widthOfWholeImage + i]; - - } - } - - ByteDataRecord rval = new ByteDataRecord(bdr.getName(), bdr.getGroup(), - newBytes, bdr.getDimension(), newSizes); - return rval; - } - - private static String getPhysicalElement(DerivParamField field) { - return field.getParam().replace("_", " ").replace("pp", ".") - .replace("oo", "(").replace("cc", ")").replace("hh", "-"); - } - - @Override - public List> getBaseUpdateConstraints( - Map constraints) { - if (constraints.containsKey(DERIVED)) { - - constraints = new HashMap(constraints); - constraints.remove(DERIVED); - RequestConstraint pe = constraints.remove(PE); - DerivParamDesc desc = derParLibrary.get(pe.getConstraintValue()); - DerivParamMethod method = desc.getMethods().get(0); - - pe = new RequestConstraint(null, ConstraintType.IN); - - for (IDerivParamField ifield : method.getFields()) { - DerivParamField field = (DerivParamField) ifield; - pe.addToConstraintValueList(getPhysicalElement(field)); - } - constraints.put(PE, pe); - } - return super.getBaseUpdateConstraints(constraints); - } - - @Override - public List> timeQuery(List requests) - throws DataCubeException { - Map derivedRequests = new HashMap(); - List baseRequests = new ArrayList( - requests.size()); - for (TimeQueryRequest request : requests) { - if (!request.getQueryTerms().containsKey("DERIVED")) { - baseRequests.add(request); - } else { - List derived = getDerivedRequests(request, - request.getBinOffset()); - derivedRequests.put(request, derived.size()); - baseRequests.addAll(derived); - // TODO it might be possible to merge the derived requests that - // have dependencies that are the same as some of the non - // derived requests to avoid hitting the db twice. - } - } - TimeQueryRequestSet set = new TimeQueryRequestSet(); - set.setRequests(baseRequests.toArray(new TimeQueryRequest[0])); - List> baseResults; - try { - baseResults = (List>) ThriftClient.sendRequest(set); - } catch (VizException e) { - throw new DataCubeException(e); - } - List> results = new ArrayList>( - requests.size()); - int baseIndex = 0; - for (TimeQueryRequest request : requests) { - if (derivedRequests.containsKey(request)) { - int size = derivedRequests.get(request); - List timeList = new ArrayList(); - for (int i = 0; i < size; i++) { - List derived = baseResults.get(baseIndex); - if (derived != null && !derived.isEmpty() - && timeList.size() == 0) { - timeList.addAll(derived); - } else if (derived != null && !derived.isEmpty() - && timeList.size() > 0) { - ArrayList newTimeList = new ArrayList(); - for (DataTime result : derived) { - for (DataTime check : timeList) { - if (check.equals(result)) { - newTimeList.add(result); - continue; - } - } - } - timeList = newTimeList; - } else if ((derived == null || derived.isEmpty()) - && timeList.size() > 0) { - timeList.clear(); - } - baseIndex += 1; - } - if (request.isMaxQuery() && !timeList.isEmpty()) { - Collections.sort(timeList); - results.add(Arrays.asList(timeList.get(timeList.size() - 1))); - } else { - results.add(timeList); - } - } else { - results.add(baseResults.get(baseIndex)); - baseIndex += 1; - } - - } - return results; - } - - private List getDerivedRequests(TimeQueryRequest request, - BinOffset binOffset) { - List result = new ArrayList(2); - Map queryParams = new HashMap( - request.getQueryTerms()); - String plugin = queryParams.get("pluginName").getConstraintValue(); - String param = queryParams.get(PE).getConstraintValue(); - if (plugin.matches("satellite") && derParLibrary.containsKey(param)) { - DerivParamDesc derParDesc = derParLibrary.get(param); - DerivParamMethod method = derParDesc.getMethods().get(0); - // We have a derived parameter for the requested grid - for (IDerivParamField ifield : method.getFields()) { - DerivParamField field = (DerivParamField) ifield; - TimeQueryRequest newRequest = new TimeQueryRequest(); - newRequest.setBinOffset(binOffset); - newRequest.setMaxQuery(false); - newRequest.setQueryTerms(modifyQuery(queryParams, field)); - newRequest.setPluginName("satellite"); - result.add(newRequest); - } - } - return result; - } - - private Map modifyQuery( - Map originalQuery, DerivParamField field) { - HashMap query = new HashMap( - originalQuery); - String paramAbb = getPhysicalElement(field); - query.put(PE, new RequestConstraint(paramAbb, - RequestConstraint.ConstraintType.EQUALS)); - query.remove(DERIVED); - - return query; - } -} diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/ComparableSatMapCoverage.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/ComparableSatMapCoverage.java new file mode 100644 index 0000000000..6a92d705dc --- /dev/null +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/ComparableSatMapCoverage.java @@ -0,0 +1,132 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.viz.satellite.inventory; + +import org.geotools.coverage.grid.GridEnvelope2D; +import org.geotools.coverage.grid.GridGeometry2D; +import org.geotools.geometry.Envelope2D; +import org.opengis.geometry.BoundingBox; +import org.opengis.referencing.crs.CoordinateReferenceSystem; + +import com.raytheon.uf.common.dataplugin.satellite.SatMapCoverage; +import com.raytheon.uf.common.geospatial.IGridGeometryProvider; +import com.raytheon.uf.common.inventory.IGridGeometryProviderComparable; + +/** + * A wrapper around {@link SatMapCoverage} that can be compared with other + * satellite coverages for derived parameters to be able to calculate between + * data at different resolution. It currently always chooses the higher + * resolutioon coverage when doing comparisons. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Apr 11, 2014  2947     bsteffen    Initial creation
+ * 
+ * 
+ * + * @author bsteffen + * @version 1.0 + */ +public class ComparableSatMapCoverage implements + IGridGeometryProviderComparable { + + private final SatMapCoverage coverage; + + + public ComparableSatMapCoverage(SatMapCoverage coverage) { + this.coverage = coverage; + } + + @Override + public GridGeometry2D getGridGeometry() { + return coverage.getGridGeometry(); + } + + @Override + public IGridGeometryProvider compare(IGridGeometryProvider other) { + if (other instanceof ComparableSatMapCoverage) { + ComparableSatMapCoverage otherCoverage = (ComparableSatMapCoverage) other; + if (otherCoverage.getCRS().equals(getCRS()) + && otherCoverage.getBoundingBox().intersects( + getBoundingBox())){ + if(getResolution() > otherCoverage.getResolution()){ + return this; + }else{ + return other; + } + } + } + return null; + } + + public SatMapCoverage getCoverage() { + return coverage; + } + + protected CoordinateReferenceSystem getCRS() { + return coverage.getGridGeometry().getCoordinateReferenceSystem(); + } + + protected BoundingBox getBoundingBox() { + return coverage.getGridGeometry().getEnvelope2D(); + } + + /** + * @return the resolution of the grid represented by this coverage in + * pixel/(m²). + */ + protected double getResolution() { + GridGeometry2D gg = coverage.getGridGeometry(); + Envelope2D e = gg.getEnvelope2D(); + GridEnvelope2D r = gg.getGridRange2D(); + return (r.width * r.height) / (e.width * e.height); + } + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + + ((coverage == null) ? 0 : coverage.hashCode()); + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + if (getClass() != obj.getClass()) + return false; + ComparableSatMapCoverage other = (ComparableSatMapCoverage) obj; + if (coverage == null) { + if (other.coverage != null) + return false; + } else if (!coverage.equals(other.coverage)) + return false; + return true; + } + +} diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/DerivedSatelliteRecord.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/DerivedSatelliteRecord.java new file mode 100644 index 0000000000..185de0e49b --- /dev/null +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/DerivedSatelliteRecord.java @@ -0,0 +1,164 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.viz.satellite.inventory; + +import java.awt.Rectangle; +import java.util.Collections; +import java.util.HashSet; +import java.util.Set; + +import javax.measure.unit.UnitFormat; + +import org.geotools.coverage.grid.GridEnvelope2D; +import org.geotools.coverage.grid.GridGeometry2D; +import org.opengis.geometry.Envelope; +import org.opengis.referencing.operation.TransformException; + +import com.raytheon.uf.common.dataplugin.satellite.SatMapCoverage; +import com.raytheon.uf.common.dataplugin.satellite.SatelliteRecord; +import com.raytheon.uf.common.datastorage.DataStoreFactory; +import com.raytheon.uf.common.datastorage.Request; +import com.raytheon.uf.common.geospatial.interpolation.GridDownscaler; +import com.raytheon.uf.common.inventory.data.AbstractRequestableData; +import com.raytheon.uf.common.inventory.exception.DataCubeException; + +/** + * Satellite record which performs derived parameter calculations to get data + * instead of requesting directly from hdf5. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Apr 09, 2014  2947     bsteffen    Initial creation
+ * 
+ * 
+ * + * @author bsteffen + * @version 1.0 + */ + +public class DerivedSatelliteRecord extends SatelliteRecord { + + private static final long serialVersionUID = 1L; + + private final AbstractRequestableData requestableData; + + public DerivedSatelliteRecord(AbstractRequestableData requestableData) + throws DataCubeException { + this.requestableData = requestableData; + setDataTime(requestableData.getDataTime()); + setPhysicalElement(requestableData.getParameter()); + setSectorID(requestableData.getSource()); + setUnits(UnitFormat.getUCUMInstance().format(requestableData.getUnit())); + + Set base = findBaseRecords(requestableData); + Set creatingEntities = new HashSet(); + int interpolationLevels = 1; + for (SatelliteRecord record : base) { + creatingEntities.add(record.getCreatingEntity()); + interpolationLevels = Math.max(interpolationLevels, + record.getInterpolationLevels()); + } + setInterpolationLevels(interpolationLevels); + if (creatingEntities.size() == 1) { + setCreatingEntity(creatingEntities.iterator().next()); + } else { + throw new DataCubeException("Too many creating entities: " + + creatingEntities); + } + if (requestableData.getSpace() instanceof SatMapCoverage) { + setCoverage((SatMapCoverage) requestableData.getSpace()); + } else if (requestableData.getSpace() instanceof ComparableSatMapCoverage) { + setCoverage(((ComparableSatMapCoverage) requestableData.getSpace()) + .getCoverage()); + } + } + + /** + * Perform the necessary calculations to get data that matches the provided + * request and dataset and store the result in the messageData field. + * + * @param req + * a {@link Request} specifying the amount of data to return + * @param dataset + * indicates the interpolation level to deriv, uses the same + * naming convention as raw satellite data. + * @throws DataCubeException + */ + public void deriveMessageData(Request req, String dataset) + throws DataCubeException { + Rectangle[] levels = GridDownscaler + .getDownscaleSizes(getGridGeometry()); + int level; + for (level = 0; level < levels.length; ++level) { + if (DataStoreFactory.createDataSetName(null, + SatelliteRecord.SAT_DATASET_NAME, level).equals( + dataset)) { + break; + } + } + if (level >= levels.length) { + throw new DataCubeException("Unrecognized dataset: " + dataset); + } + GridGeometry2D gridGeometry = new GridGeometry2D(new GridEnvelope2D( + levels[level]), getGridGeometry().getEnvelope()); + if (req.getType() == Request.Type.SLAB) { + int[] min = req.getMinIndexForSlab(); + int[] max = req.getMaxIndexForSlab(); + GridEnvelope2D range = new GridEnvelope2D(min[0], min[1], max[0] + - min[0], max[1] - min[1]); + Envelope env; + try { + env = gridGeometry.gridToWorld(range); + } catch (TransformException e) { + throw new DataCubeException(e); + } + gridGeometry = new GridGeometry2D(range, env); + } else if (req.getType() != Request.Type.ALL) { + throw new DataCubeException( + "Unsupported request type for derived satellite data: " + + req.getType()); + } + Object dataValue = requestableData.getDataValue(gridGeometry); + setMessageData(dataValue); + } + + private static Set findBaseRecords( + AbstractRequestableData data) { + if (data instanceof SatelliteRequestableData) { + SatelliteRequestableData srd = (SatelliteRequestableData) data; + return Collections.singleton(srd.getRecord()); + } else { + Set entities = new HashSet(); + for (AbstractRequestableData dep : data.getDependencies()) { + entities.addAll(findBaseRecords(dep)); + } + return entities; + } + } + + public String getName() { + return requestableData.getParameterName(); + } + +} diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteCoverageCache.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteCoverageCache.java new file mode 100644 index 0000000000..2dd0828386 --- /dev/null +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteCoverageCache.java @@ -0,0 +1,100 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.viz.satellite.inventory; + +import java.util.HashMap; +import java.util.Map; + +import com.raytheon.uf.common.dataplugin.satellite.SatMapCoverage; +import com.raytheon.uf.common.dataquery.requests.DbQueryRequest; +import com.raytheon.uf.common.dataquery.requests.RequestConstraint; +import com.raytheon.uf.common.dataquery.responses.DbQueryResponse; +import com.raytheon.uf.common.inventory.exception.DataCubeException; +import com.raytheon.uf.common.serialization.comm.RequestRouter; + +/** + * A cache of {@link SatMapCoverage} based off the gid field. This cache can be + * used to some types of satellite queries that need the SatMapCoverage because + * the query can only request the gid field and then load the full coverage from + * cache. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Apr 09, 2014  2947     bsteffen    Initial creation
+ * 
+ * 
+ * + * @author bsteffen + * @version 1.0 + */ + +public class SatelliteCoverageCache { + + private static final String GID = "gid"; + + /** + * Map containing cached coverages, all access to this map must be + * syncronized. + */ + private final Map cache = new HashMap(); + + public SatelliteCoverageCache() throws DataCubeException { + /* Prepopulate the cache. */ + DbQueryRequest request = new DbQueryRequest(); + request.setEntityClass(SatMapCoverage.class); + handleRequest(request); + } + + public SatMapCoverage get(int gid) throws DataCubeException { + synchronized (cache) { + SatMapCoverage result = cache.get(gid); + if (result == null) { + DbQueryRequest request = new DbQueryRequest(); + request.setEntityClass(SatMapCoverage.class); + request.addConstraint(GID, + new RequestConstraint(Integer.toString(gid))); + handleRequest(request); + result = cache.get(gid); + } + return result; + } + } + + private void handleRequest(DbQueryRequest request) throws DataCubeException { + DbQueryResponse response; + try { + response = (DbQueryResponse) RequestRouter.route(request); + } catch (Exception e) { + throw new DataCubeException(e); + } + SatMapCoverage[] coverages = response + .getEntityObjects(SatMapCoverage.class); + synchronized (cache) { + for (SatMapCoverage coverage : coverages) { + cache.put(coverage.getGid(), coverage); + } + } + } + +} diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteDataCubeAdapter.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteDataCubeAdapter.java new file mode 100644 index 0000000000..70479bb37d --- /dev/null +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteDataCubeAdapter.java @@ -0,0 +1,178 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.viz.satellite.inventory; + +import java.util.ArrayList; +import java.util.Collections; +import java.util.List; +import java.util.Map; + +import com.raytheon.uf.common.dataplugin.PluginDataObject; +import com.raytheon.uf.common.dataplugin.satellite.SatelliteRecord; +import com.raytheon.uf.common.dataquery.requests.RequestConstraint; +import com.raytheon.uf.common.datastorage.Request; +import com.raytheon.uf.common.derivparam.library.DerivedParameterGenerator; +import com.raytheon.uf.common.derivparam.tree.AbstractDerivedDataNode; +import com.raytheon.uf.common.inventory.data.AbstractRequestableData; +import com.raytheon.uf.common.inventory.exception.DataCubeException; +import com.raytheon.uf.common.inventory.tree.AbstractRequestableNode; +import com.raytheon.uf.common.inventory.tree.AbstractRequestableNode.Dependency; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.status.UFStatus.Priority; +import com.raytheon.uf.common.time.DataTime; +import com.raytheon.uf.viz.datacube.AbstractDataCubeAdapter; + +/** + * DataCubeAdapter for satellite + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 09, 2014  2947     bsteffen    Initial creation
+ * 
+ * 
+ * + * @author bsteffen + * @version 1.0 + */ + +public class SatelliteDataCubeAdapter extends AbstractDataCubeAdapter { + + private static final IUFStatusHandler statusHandler = UFStatus + .getHandler(SatelliteDataCubeAdapter.class); + + /** + * @deprecated This used to be a required key in derived request constraints + * but is no longer necessary + */ + @Deprecated + public static final String DERIVED = "DERIVED"; + + private SatelliteInventory inventory; + + public SatelliteDataCubeAdapter() { + super(new String[] { SatelliteInventory.SATELLITE }); + } + + @Override + public void initInventory() { + if (inventory == null) { + try { + SatelliteInventory inventory = new SatelliteInventory(); + inventory + .initTree(DerivedParameterGenerator.getDerParLibrary()); + this.inventory = inventory; + } catch (Exception e) { + statusHandler.handle(Priority.PROBLEM, + e.getLocalizedMessage(), e); + } + } + } + + @Override + public Object getInventory() { + return inventory; + } + + @Override + protected List evaluateRequestConstraints( + Map constraints) { + return inventory.evaluateRequestConstraints(constraints); + } + + @Override + protected List timeAgnosticQuery( + Map queryTerms) throws DataCubeException { + return inventory.timeAgnosticQuery(queryTerms); + } + + @Override + protected List getData( + Map constraints, + DataTime[] selectedTimes, List requesters) + throws DataCubeException { + List results = new ArrayList( + requesters.size()); + for (AbstractRequestableData requester : requesters) { + if(requester instanceof SatelliteRequestableData){ + results.add(((SatelliteRequestableData) requester).getRecord()); + } else { + results.add(new DerivedSatelliteRecord(requester)); + } + } + return results; + } + + @Override + public void getRecords(List objs, Request req, + String dataset) throws DataCubeException { + List simpleRecords = new ArrayList( + objs.size()); + for (PluginDataObject obj : objs) { + if (obj instanceof DerivedSatelliteRecord) { + ((DerivedSatelliteRecord) obj).deriveMessageData(req, dataset); + } else if (obj instanceof SatelliteRecord) { + simpleRecords.add(obj); + } else if (obj != null) { + throw new DataCubeException(this.getClass().getSimpleName() + + " cannot get records for a " + + obj.getClass().getSimpleName()); + } + } + if (!simpleRecords.isEmpty()) { + super.getRecords(simpleRecords, req, dataset); + } + } + + @Override + public List> getBaseUpdateConstraints( + Map constraints) { + List nodes = evaluateRequestConstraints(constraints); + List> baseConstraints = new ArrayList>( + nodes.size() * 2); + for (AbstractRequestableNode node : nodes) { + baseConstraints.addAll(getBaseUpdateConstraints(node)); + } + return baseConstraints; + } + + protected List> getBaseUpdateConstraints( + AbstractRequestableNode node) { + if (node instanceof SatelliteRequestableLevelNode) { + SatelliteRequestableLevelNode satNode = (SatelliteRequestableLevelNode) node; + return Collections.singletonList(satNode.getRequestConstraintMap()); + } else if (node instanceof AbstractDerivedDataNode) { + AbstractDerivedDataNode derivedNode = (AbstractDerivedDataNode) node; + List> baseConstraints = new ArrayList>(); + for (Dependency d : derivedNode.getDependencies()) { + baseConstraints.addAll(getBaseUpdateConstraints(d.node)); + } + return baseConstraints; + } + return Collections.emptyList(); + } + + + +} diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteInventory.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteInventory.java new file mode 100644 index 0000000000..6bfda8f9f8 --- /dev/null +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteInventory.java @@ -0,0 +1,229 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.viz.satellite.inventory; + +import java.util.Collection; +import java.util.Collections; +import java.util.Deque; +import java.util.HashMap; +import java.util.Iterator; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import com.raytheon.uf.common.comm.CommunicationException; +import com.raytheon.uf.common.dataplugin.PluginDataObject; +import com.raytheon.uf.common.dataplugin.level.Level; +import com.raytheon.uf.common.dataplugin.level.LevelFactory; +import com.raytheon.uf.common.dataplugin.satellite.SatelliteRecord; +import com.raytheon.uf.common.dataquery.requests.DbQueryRequest; +import com.raytheon.uf.common.dataquery.requests.RequestConstraint; +import com.raytheon.uf.common.dataquery.responses.DbQueryResponse; +import com.raytheon.uf.common.derivparam.inv.AbstractInventory; +import com.raytheon.uf.common.derivparam.library.DerivParamDesc; +import com.raytheon.uf.common.derivparam.library.DerivParamField; +import com.raytheon.uf.common.derivparam.library.DerivParamMethod; +import com.raytheon.uf.common.derivparam.tree.AbstractDerivedDataNode; +import com.raytheon.uf.common.inventory.data.AbstractRequestableData; +import com.raytheon.uf.common.inventory.exception.DataCubeException; +import com.raytheon.uf.common.inventory.tree.AbstractRequestableNode; +import com.raytheon.uf.common.inventory.tree.DataTree; +import com.raytheon.uf.common.inventory.tree.LevelNode; +import com.raytheon.uf.common.inventory.tree.ParameterNode; +import com.raytheon.uf.common.inventory.tree.SourceNode; +import com.raytheon.uf.common.serialization.comm.RequestRouter; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.status.UFStatus.Priority; +import com.raytheon.uf.common.time.DataTime; + +/** + * Inventory of available satellite data. sectorID is used for source and + * physicalElement for parameter, the level is always the entire atmosphere. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Apr 09, 2014  2947     bsteffen    Initial creation
+ * 
+ * 
+ * + * @author bsteffen + * @version 1.0 + */ +public class SatelliteInventory extends AbstractInventory { + + private static final IUFStatusHandler statusHandler = UFStatus + .getHandler(SatelliteInventory.class); + + public static final String SATELLITE = "satellite"; + + public static final String SECTOR_ID = "sectorID"; + + public static final String PHYSICALELEMENT = "physicalElement"; + + public static final String GID = "coverage.gid"; + + private SatelliteCoverageCache coverages; + + private Level level; + + @Override + public List timeAgnosticQuery(Map query) { + /* Returning null means no data will be time agnostic. */ + return null; + } + + @Override + public synchronized void initTree(Map derParLibrary) + throws DataCubeException { + try { + level = LevelFactory.getInstance().getLevel("EA", 0.0); + } catch (CommunicationException e) { + throw new DataCubeException(e); + } + coverages = new SatelliteCoverageCache(); + super.initTree(derParLibrary); + } + + @Override + protected DataTree createBaseTree() { + DbQueryRequest request = new DbQueryRequest(); + request.setEntityClass(SatelliteRecord.class); + request.setDistinct(true); + request.addRequestField(SECTOR_ID); + request.addRequestField(PHYSICALELEMENT); + + DbQueryResponse response; + try { + response = (DbQueryResponse) RequestRouter.route(request); + } catch (Exception e) { + // TODO Auto-generated catch block. Please revise as appropriate. + statusHandler.handle(Priority.PROBLEM, e.getLocalizedMessage(), e); + return null; + } + + String levelId = Long.toString(level.getId()); + + DataTree tree = new DataTree(); + for (Map result : response.getResults()) { + String sectorID = (String) result.get(SECTOR_ID); + String physicalElement = (String) result.get(PHYSICALELEMENT); + SourceNode sourceNode = tree.getSourceNode(sectorID); + if (sourceNode == null) { + sourceNode = new SourceNode(); + sourceNode.setValue(sectorID); + tree.getSourceNodes().put(sectorID, sourceNode); + } + + ParameterNode paramNode = sourceNode.getChildNode(physicalElement); + if (paramNode == null) { + paramNode = new ParameterNode(); + paramNode.setValue(physicalElement); + paramNode.setParameterName(physicalElement); + sourceNode.addChildNode(paramNode); + } + + LevelNode levelNode = paramNode.getChildNode(levelId); + if (levelNode == null) { + Map requestConstraints = new HashMap(); + requestConstraints.put(SECTOR_ID, new RequestConstraint( + sectorID)); + requestConstraints.put(PHYSICALELEMENT, new RequestConstraint( + physicalElement)); + requestConstraints.put(PluginDataObject.PLUGIN_NAME_ID, + new RequestConstraint(SATELLITE)); + levelNode = new SatelliteRequestableLevelNode(coverages, + requestConstraints); + levelNode.setValue(levelId); + paramNode.addChildNode(levelNode); + } + } + return tree; + } + + @Override + protected LevelNode getCubeNode(SourceNode sNode, DerivParamField field, + Deque stack, Set nodata) { + /* Returning null means cubes is not supported. */ + return null; + } + + @Override + protected AbstractDerivedDataNode getImportNode( + AbstractRequestableData nodeToImport, SourceNode destSourceNode, + DerivParamDesc desc, DerivParamMethod method, Level level) { + /* Returning null means import is not supported. */ + return null; + } + + @Override + protected AbstractDerivedDataNode getImportNode( + AbstractRequestableNode nodeToImport, + String nodeToImportSourceName, SourceNode destSourceNode, + DerivParamDesc desc, DerivParamMethod method, Level level) { + /* Returning null means import is not supported. */ + return null; + } + + @Override + protected Object resolvePluginStaticData(SourceNode sNode, + DerivParamField field, Level level) { + /* Returning null means static data is not supported. */ + return null; + } + + protected List evaluateRequestConstraints( + Map constraints) { + Collection sources = getAllSources(); + RequestConstraint sectorLimiter = constraints.get(SECTOR_ID); + if (sectorLimiter != null) { + Iterator it = sources.iterator(); + while (it.hasNext()) { + if (!sectorLimiter.evaluate(it.next())) { + it.remove(); + } + } + } + Collection parameters = getAllParameters(); + RequestConstraint peLimiter = constraints.get(PHYSICALELEMENT); + if (peLimiter != null) { + Iterator it = parameters.iterator(); + while (it.hasNext()) { + if (!peLimiter.evaluate(it.next())) { + it.remove(); + } + } + } + Collection levels = Collections.singleton(level); + try { + List result = walkTree(null, sources, + parameters, levels, true, true, null); + return result; + } catch (InterruptedException e) { + statusHandler.handle(Priority.PROBLEM, e.getLocalizedMessage(), e); + return Collections.emptyList(); + } + } + +} diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteRequestableData.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteRequestableData.java new file mode 100644 index 0000000000..bf1754d39d --- /dev/null +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteRequestableData.java @@ -0,0 +1,214 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.viz.satellite.inventory; + +import java.awt.Point; +import java.awt.Rectangle; +import java.util.Map; + +import javax.measure.unit.Unit; + +import org.geotools.coverage.grid.GridEnvelope2D; +import org.geotools.coverage.grid.GridGeometry2D; +import org.geotools.geometry.Envelope2D; +import org.opengis.coverage.grid.GridEnvelope; +import org.opengis.referencing.FactoryException; +import org.opengis.referencing.crs.CoordinateReferenceSystem; +import org.opengis.referencing.operation.TransformException; + +import com.raytheon.uf.common.dataplugin.level.Level; +import com.raytheon.uf.common.dataplugin.satellite.SatelliteRecord; +import com.raytheon.uf.common.datastorage.DataStoreFactory; +import com.raytheon.uf.common.datastorage.Request; +import com.raytheon.uf.common.datastorage.records.IDataRecord; +import com.raytheon.uf.common.geospatial.interpolation.GridDownscaler; +import com.raytheon.uf.common.geospatial.interpolation.GridReprojection; +import com.raytheon.uf.common.geospatial.interpolation.NearestNeighborInterpolation; +import com.raytheon.uf.common.geospatial.interpolation.PrecomputedGridReprojection; +import com.raytheon.uf.common.geospatial.util.SubGridGeometryCalculator; +import com.raytheon.uf.common.inventory.data.AbstractRequestableData; +import com.raytheon.uf.common.inventory.exception.DataCubeException; +import com.raytheon.uf.common.numeric.buffer.BufferWrapper; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.viz.datacube.CubeUtil; +import com.raytheon.viz.satellite.tileset.SatDataRetriever; + +/** + * Object capable of requesting Satellite data for base or derived displays. Can + * also reproject into different coverages + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Apr 09, 2014  2947     bsteffen    Initial creation
+ * 
+ * 
+ * + * @author mschenke + * @version 1.0 + */ + +public class SatelliteRequestableData extends AbstractRequestableData { + + private final SatelliteRecord record; + + public SatelliteRequestableData(SatelliteRecord record, Level level) { + this.record = record; + this.dataTime = record.getDataTime(); + this.level = level; + this.parameter = record.getPhysicalElement(); + this.parameterName = record.getPhysicalElement(); + this.source = record.getSectorID(); + this.space = new ComparableSatMapCoverage(record.getCoverage()); + } + + public SatelliteRecord getRecord() { + return record; + } + + @Override + public Object getDataValue(Object arg) throws DataCubeException { + if (arg instanceof GridGeometry2D) { + GridGeometry2D requestGeom = (GridGeometry2D) arg; + GridGeometry2D recordGeom = record.getGridGeometry(); + validateCRSMatch(requestGeom, recordGeom); + /* Figure out what level is needed */ + Envelope2D requestEnv = requestGeom.getEnvelope2D(); + GridEnvelope2D requestRange = requestGeom.getGridRange2D(); + double requestDx = requestEnv.width / requestRange.width; + double requestDy = requestEnv.height / requestRange.height; + Envelope2D recordEnv = recordGeom.getEnvelope2D(); + Rectangle[] levels = GridDownscaler.getDownscaleSizes(recordGeom); + int bestLevel = 0; + for (int level = levels.length - 1; level >= 0; level -= 1) { + double levelDx = recordEnv.width / levels[level].width; + double levelDy = recordEnv.height / levels[level].height; + if (levelDx <= requestDx || levelDy <= requestDy) { + bestLevel = Math.max(0, level); + break; + } + } + /* figure out what area of the level is needed. */ + GridGeometry2D levelGeom = new GridGeometry2D( + (GridEnvelope) new GridEnvelope2D(levels[bestLevel]), + recordEnv); + Request request; + SubGridGeometryCalculator subGrid; + try { + subGrid = new SubGridGeometryCalculator(requestEnv, levelGeom); + } catch (TransformException e) { + throw new DataCubeException(e); + } + if (subGrid.isEmpty()) { + /* The SpaceTimeMatcher should prevent this from ever happening */ + throw new DataCubeException( + "Request Area does not intersect data area."); + } else if (subGrid.isFull()) { + request = Request.ALL; + } else { + request = Request.buildSlab(subGrid.getGridRangeLow(true), + subGrid.getGridRangeHigh(false)); + } + String dataset = DataStoreFactory.createDataSetName(null, + SatelliteRecord.SAT_DATASET_NAME, bestLevel); + IDataRecord dataRecord = CubeUtil.retrieveData(record, + record.getPluginName(), request, dataset); + unit = SatDataRetriever.getDataUnit( + SatDataRetriever.getRecordUnit(record), dataRecord); + /* Reproject the data to match the request. */ + GridGeometry2D subGeom = subGrid.getSubGridGeometry2D(); + BufferWrapper source = BufferWrapper.wrapArray( + dataRecord.getDataObject(), subGeom.getGridRange2D().width, + subGeom.getGridRange2D().height); + BufferWrapper dest = BufferWrapper.create( + source.getPrimitiveType(), requestRange.width, + requestRange.height); + try { + GridReprojection reproj = PrecomputedGridReprojection + .getReprojection(subGeom, requestGeom); + reproj.reprojectedGrid(new NearestNeighborInterpolation(), + source, dest); + } catch (TransformException e) { + throw new DataCubeException(e); + } catch (FactoryException e) { + throw new DataCubeException(e); + } + Map attrs = dataRecord.getDataAttributes(); + dataRecord = DataStoreFactory.createStorageRecord( + dataRecord.getName(), dataRecord.getGroup(), + dest.getArray(), 2, new long[] { requestRange.width, + requestRange.height }); + dataRecord.setFillValue(0); + if (attrs != null) { + Number fill = (Number) attrs + .get(SatelliteRecord.SAT_FILL_VALUE); + + if (fill != null) { + dataRecord.setFillValue(fill); + } + } + return dataRecord; + } else { + return CubeUtil.retrieveData(record, record.getPluginName(), + Request.ALL, SatelliteRecord.SAT_DATASET_NAME); + } + } + + private static void validateCRSMatch(GridGeometry2D requestGeom, + GridGeometry2D recordGeom) throws DataCubeException { + CoordinateReferenceSystem requestCRS = requestGeom + .getCoordinateReferenceSystem(); + CoordinateReferenceSystem recordCRS = recordGeom + .getCoordinateReferenceSystem(); + + if (!requestCRS.equals(recordCRS)) { + /* The SpaceTimeMatcher should prevent this from ever happening */ + throw new DataCubeException("Incompatible CRSs\n" + + requestCRS.toWKT() + "\n" + recordCRS.toWKT()); + } + } + + @Override + public Unit getUnit() { + if (this.unit == null) { + /* + * Normally a data request occurs before anything needs the unit so + * this should never happen. + */ + try { + IDataRecord dataRecord = CubeUtil.retrieveData(record, + record.getPluginName(), + Request.buildPointRequest(new Point(0, 0)), + SatelliteRecord.SAT_DATASET_NAME); + unit = SatDataRetriever.getDataUnit( + SatDataRetriever.getRecordUnit(record), dataRecord); + } catch (DataCubeException e) { + UFStatus.getHandler(getClass()).error("Cannot find data unit.", + e); + + } + } + return super.getUnit(); + } + +} diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteRequestableLevelNode.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteRequestableLevelNode.java new file mode 100644 index 0000000000..4aec556449 --- /dev/null +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteRequestableLevelNode.java @@ -0,0 +1,173 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.viz.satellite.inventory; + +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Set; + +import com.raytheon.uf.common.dataplugin.PluginDataObject; +import com.raytheon.uf.common.dataplugin.satellite.SatMapCoverage; +import com.raytheon.uf.common.dataplugin.satellite.SatelliteRecord; +import com.raytheon.uf.common.dataquery.requests.DbQueryRequest; +import com.raytheon.uf.common.dataquery.requests.RequestConstraint; +import com.raytheon.uf.common.dataquery.requests.RequestConstraint.ConstraintType; +import com.raytheon.uf.common.dataquery.responses.DbQueryResponse; +import com.raytheon.uf.common.derivparam.tree.AbstractBaseDataNode; +import com.raytheon.uf.common.inventory.TimeAndSpace; +import com.raytheon.uf.common.inventory.data.AbstractRequestableData; +import com.raytheon.uf.common.inventory.exception.DataCubeException; +import com.raytheon.uf.common.time.DataTime; + +/** + * + * Satellite Requestable level node + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Apr 09, 2014  2947     bsteffen    Initial creation
+ * 
+ * 
+ * + * @author bsteffen + * @version 1.0 + */ +public class SatelliteRequestableLevelNode extends AbstractBaseDataNode { + + private final SatelliteCoverageCache coverages; + + private final Map requestConstraints; + + public SatelliteRequestableLevelNode(SatelliteCoverageCache coverages, + Map requestConstraints) { + this.coverages = coverages; + this.requestConstraints = requestConstraints; + } + + + public Map getRequestConstraintMap() { + return requestConstraints; + } + + protected DbQueryRequest getBaseRequest( + Map originalConstraints) { + Map constraints = new HashMap( + originalConstraints); + constraints.putAll(requestConstraints); + constraints.remove(SatelliteDataCubeAdapter.DERIVED); + DbQueryRequest request = new DbQueryRequest(); + request.setEntityClass(SatelliteRecord.class); + request.setDistinct(true); + request.setConstraints(constraints); + return request; + } + + @Override + public DbQueryRequest getAvailabilityRequest( + Map originalConstraints) { + DbQueryRequest request = getBaseRequest(originalConstraints); + request.addRequestField(PluginDataObject.DATATIME_ID); + request.addRequestField(SatelliteInventory.GID); + return request; + } + + @Override + public DbQueryRequest getDataRequest( + Map originalConstraints, + Set availability) { + DbQueryRequest request = getBaseRequest(originalConstraints); + RequestConstraint timeRc = new RequestConstraint(); + timeRc.setConstraintType(ConstraintType.IN); + for (TimeAndSpace time : availability) { + timeRc.addToConstraintValueList(time.getTime().toString()); + } + request.addConstraint(PluginDataObject.DATATIME_ID, timeRc); + return request; + } + + @Override + public Set getAvailability( + Map originalConstraints, Object response) + throws DataCubeException { + Set result = new HashSet(); + DbQueryResponse dbresponse = (DbQueryResponse) response; + for (Map map : dbresponse.getResults()) { + DataTime time = (DataTime) map.get(PluginDataObject.DATATIME_ID); + int gid = ((Number) map.get(SatelliteInventory.GID)).intValue(); + SatMapCoverage coverage = coverages.get(gid); + result.add(new TimeAndSpace(time, new ComparableSatMapCoverage( + coverage))); + } + return result; + } + + + @Override + public Set getData( + Map orignalConstraints, + Set availability, Object response) + throws DataCubeException { + DbQueryResponse queryResponse = (DbQueryResponse) response; + List> results = queryResponse.getResults(); + Set data = new HashSet( + results.size()); + SatelliteRecord[] records = queryResponse + .getEntityObjects(SatelliteRecord.class); + for (SatelliteRecord record : records) { + data.add(new SatelliteRequestableData(record, getLevel())); + } + return data; + } + + @Override + public int hashCode() { + final int prime = 31; + int result = super.hashCode(); + result = prime + * result + + ((requestConstraints == null) ? 0 : requestConstraints + .hashCode()); + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (!super.equals(obj)) + return false; + if (getClass() != obj.getClass()) + return false; + SatelliteRequestableLevelNode other = (SatelliteRequestableLevelNode) obj; + if (requestConstraints == null) { + if (other.requestConstraints != null) + return false; + } else if (!requestConstraints.equals(other.requestConstraints)) + return false; + return true; + } + +} diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteUnitRegistrar.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteUnitRegistrar.java new file mode 100644 index 0000000000..e1a6287ec2 --- /dev/null +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteUnitRegistrar.java @@ -0,0 +1,49 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.viz.satellite.inventory; + +import com.raytheon.uf.common.dataplugin.satellite.units.SatelliteUnits; +import com.raytheon.viz.core.units.IUnitRegistrar; + +/** + * Register the units used by satellite as part of cave startup. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Apr 15, 2014  2947     bsteffen    Initial creation
+ * 
+ * 
+ * + * @author bsteffen + * @version 1.0 + */ +public class SatelliteUnitRegistrar implements IUnitRegistrar { + + @Override + public void register() { + SatelliteUnits.register(); + } + + +} diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatBestResResourceData.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatBestResResourceData.java index 270bec1fd0..15ee46a043 100644 --- a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatBestResResourceData.java +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatBestResResourceData.java @@ -49,7 +49,7 @@ import com.raytheon.uf.viz.core.rsc.AbstractVizResource; import com.raytheon.uf.viz.core.rsc.LoadProperties; import com.raytheon.uf.viz.core.rsc.ProgressiveDisclosureProperties; import com.raytheon.uf.viz.core.rsc.ResourceList; -import com.raytheon.viz.satellite.SatelliteDataCubeAdapter; +import com.raytheon.viz.satellite.inventory.SatelliteDataCubeAdapter; import com.vividsolutions.jts.geom.Coordinate; import com.vividsolutions.jts.geom.Geometry; import com.vividsolutions.jts.geom.GeometryFactory; diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResource.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResource.java index 66e2de9a71..c4eec82abf 100644 --- a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResource.java +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResource.java @@ -66,8 +66,8 @@ import com.raytheon.uf.viz.core.rsc.AbstractPluginDataObjectResource; import com.raytheon.uf.viz.core.rsc.LoadProperties; import com.raytheon.uf.viz.core.rsc.capabilities.AbstractCapability; import com.raytheon.uf.viz.core.rsc.capabilities.ColorMapCapability; -import com.raytheon.uf.common.derivparam.library.DerivedParameterRequest; import com.raytheon.viz.satellite.SatelliteConstants; +import com.raytheon.viz.satellite.inventory.DerivedSatelliteRecord; import com.raytheon.viz.satellite.tileset.SatDataRetriever; import com.raytheon.viz.satellite.tileset.SatTileSetRenderable; import com.vividsolutions.jts.geom.Coordinate; @@ -97,6 +97,8 @@ import com.vividsolutions.jts.geom.Coordinate; * interrogation * Nov 20, 2013 2492 bsteffen Always get min/max values from style * rules. + * Apr 09, 2014 2947 bsteffen Improve flexibility of sat derived + * parameters. * * * @@ -283,14 +285,7 @@ public class SatResource extends } SingleLevel level = new SingleLevel(Level.LevelType.SURFACE); - String physicalElement = null; - DerivedParameterRequest request = (DerivedParameterRequest) record - .getMessageData(); - if (request == null) { - physicalElement = record.getPhysicalElement(); - } else { - physicalElement = request.getParameterAbbreviation(); - } + String physicalElement = record.getPhysicalElement(); // Grab the sampleRange from the preferences ParamLevelMatchCriteria match = new ParamLevelMatchCriteria(); @@ -459,17 +454,13 @@ public class SatResource extends return String.format("%.1f%s", measuredValue, unitString); } - private String getLegend(PluginDataObject record) { - String productName = null; - DerivedParameterRequest request = (DerivedParameterRequest) record - .getMessageData(); - if (request == null) { - productName = ((SatelliteRecord) record).getPhysicalElement(); - } else { - productName = request.getParameterAbbreviation(); + private String getLegend(SatelliteRecord record) { + String productName = record.getPhysicalElement(); + if (record instanceof DerivedSatelliteRecord) { + productName = ((DerivedSatelliteRecord) record).getName(); } return SatelliteConstants.getLegend(productName, - ((SatelliteRecord) record).getCreatingEntity()); + record.getCreatingEntity()); } public List getImages(IGraphicsTarget target, diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/tileset/SatDataRetriever.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/tileset/SatDataRetriever.java index 161c5e62d0..3b6d20dd7e 100644 --- a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/tileset/SatDataRetriever.java +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/tileset/SatDataRetriever.java @@ -22,6 +22,7 @@ package com.raytheon.viz.satellite.tileset; import java.awt.Rectangle; import java.nio.Buffer; import java.nio.ByteBuffer; +import java.nio.FloatBuffer; import java.nio.ShortBuffer; import java.text.ParseException; import java.text.ParsePosition; @@ -32,23 +33,22 @@ import javax.measure.unit.UnitFormat; import com.raytheon.uf.common.colormap.image.ColorMapData; import com.raytheon.uf.common.colormap.image.ColorMapData.ColorMapDataType; -import com.raytheon.uf.common.inventory.exception.DataCubeException; import com.raytheon.uf.common.dataplugin.satellite.SatelliteRecord; -import com.raytheon.uf.common.dataplugin.satellite.units.counts.DerivedWVPixel; import com.raytheon.uf.common.dataplugin.satellite.units.generic.GenericPixel; import com.raytheon.uf.common.dataplugin.satellite.units.goes.PolarPrecipWaterPixel; import com.raytheon.uf.common.dataplugin.satellite.units.water.BlendedTPWPixel; import com.raytheon.uf.common.datastorage.DataStoreFactory; import com.raytheon.uf.common.datastorage.Request; import com.raytheon.uf.common.datastorage.records.ByteDataRecord; +import com.raytheon.uf.common.datastorage.records.FloatDataRecord; import com.raytheon.uf.common.datastorage.records.IDataRecord; import com.raytheon.uf.common.datastorage.records.ShortDataRecord; +import com.raytheon.uf.common.inventory.exception.DataCubeException; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.viz.core.data.IColorMapDataRetrievalCallback; import com.raytheon.uf.viz.datacube.DataCubeContainer; -import com.raytheon.uf.common.derivparam.library.DerivedParameterRequest; import com.raytheon.viz.satellite.SatelliteConstants; /** @@ -59,11 +59,13 @@ import com.raytheon.viz.satellite.SatelliteConstants; * * SOFTWARE HISTORY * - * Date Ticket# Engineer Description - * ------------ ---------- ----------- -------------------------- - * Jun 20, 2013 2122 mschenke Initial creation - * Nov 13, 2013 2492 mschenke Added extraction of scale/offset from - * data record attributes for unit + * Date Ticket# Engineer Description + * ------------- -------- ----------- -------------------------- + * Jun 20, 2013 2122 mschenke Initial creation + * Nov 13, 2013 2492 mschenke Added extraction of scale/offset from + * data record attributes for unit + * Apr 09, 2014 2947 bsteffen Improve flexibility of sat derived + * parameters. * * * @@ -112,6 +114,8 @@ public class SatDataRetriever implements IColorMapDataRetrievalCallback { data = ByteBuffer.wrap((byte[]) record.getDataObject()); } else if (record instanceof ShortDataRecord) { data = ShortBuffer.wrap((short[]) record.getDataObject()); + } else if (record instanceof FloatDataRecord) { + data = FloatBuffer.wrap((float[]) record.getDataObject()); } Unit recordUnit = getRecordUnit(this.record); signed = recordUnit instanceof GenericPixel; @@ -148,14 +152,8 @@ public class SatDataRetriever implements IColorMapDataRetrievalCallback { public static Unit getRecordUnit(SatelliteRecord record) { Unit recordUnit = null; String physicalElement = record.getPhysicalElement(); - DerivedParameterRequest request = (DerivedParameterRequest) record - .getMessageData(); - if (request != null) { - physicalElement = request.getParameterAbbreviation(); - } - if (record.getUnits() != null && record.getUnits().isEmpty() == false - && request == null) { + if (record.getUnits() != null && record.getUnits().isEmpty() == false) { try { recordUnit = UnitFormat.getUCUMInstance().parseProductUnit( record.getUnits(), new ParsePosition(0)); @@ -165,12 +163,6 @@ public class SatDataRetriever implements IColorMapDataRetrievalCallback { "Unable to parse satellite units: " + record.getUnits(), e); } - } else if (request != null) { - if (physicalElement.equals("satDivWVIR")) { - recordUnit = new DerivedWVPixel(); - } else { - recordUnit = new GenericPixel(); - } } if (physicalElement.equals(SatelliteConstants.PRECIP)) { @@ -193,7 +185,7 @@ public class SatDataRetriever implements IColorMapDataRetrievalCallback { * @param dataRecord * @return */ - private static Unit getDataUnit(Unit recordUnit, + public static Unit getDataUnit(Unit recordUnit, IDataRecord dataRecord) { Unit units = recordUnit != null ? recordUnit : Unit.ONE; Map attrs = dataRecord.getDataAttributes(); diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/src/com/raytheon/uf/common/dataplugin/satellite/units/SatelliteUnits.java b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/src/com/raytheon/uf/common/dataplugin/satellite/units/SatelliteUnits.java index 07bc09ed35..4d0d7d8ef3 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/src/com/raytheon/uf/common/dataplugin/satellite/units/SatelliteUnits.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/src/com/raytheon/uf/common/dataplugin/satellite/units/SatelliteUnits.java @@ -28,6 +28,7 @@ import javax.measure.unit.SI; import javax.measure.unit.Unit; import javax.measure.unit.UnitFormat; +import com.raytheon.uf.common.dataplugin.satellite.units.counts.DerivedWVPixel; import com.raytheon.uf.common.dataplugin.satellite.units.generic.GenericPixel; import com.raytheon.uf.common.dataplugin.satellite.units.goes.PercentOfNormalTPWPixel; import com.raytheon.uf.common.dataplugin.satellite.units.goes.PolarPrecipWaterPixel; @@ -45,12 +46,14 @@ import com.raytheon.uf.common.dataplugin.satellite.units.water.RainfallRatePixel * *
  * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Sep 4, 2007             njensen     Initial creation
- * Mar 23, 2009     2086   jsanchez    Updated RainfallRatePixel to be velocity.
- *                                     Added PolarPrecipWaterPixel.
- * Jun 20, 2013     2122   mschenke    Added alias for degrees celsius to "C"
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Sep 04, 2007           njensen     Initial creation
+ * Mar 23, 2009  2086     jsanchez    Updated RainfallRatePixel to be velocity.
+ *                                    Added PolarPrecipWaterPixel.
+ * Jun 20, 2013  2122     mschenke    Added alias for degrees celsius to "C"
+ * Apr 15, 2014  2947     bsteffen    Register units with both formats.
+ * 
  * 
  * 
* @@ -84,35 +87,35 @@ public class SatelliteUnits { public static final Unit GENERIC_PIXEL = new GenericPixel(); + public static final Unit DERIVED_WV = new DerivedWVPixel(); + public static void register() { - UnitFormat.getUCUMInstance().alias(SI.KELVIN, "kelvin"); - UnitFormat.getUCUMInstance().alias(SI.CELSIUS, "C"); - UnitFormat.getUCUMInstance().label(SatelliteUnits.IR_PIXEL, "IRPixel"); - UnitFormat.getUCUMInstance().label(SatelliteUnits.PRECIP_PIXEL, - "PrecipPixel"); - UnitFormat.getUCUMInstance().label(SatelliteUnits.RAINFALL_RATE_PIXEL, - "RainfallRatePixel"); - UnitFormat.getUCUMInstance().label( - SatelliteUnits.SOUNDER_CLOUD_AMOUNT_PIXEL, + register(UnitFormat.getUCUMInstance()); + register(UnitFormat.getInstance()); + + } + + public static void register(UnitFormat format) { + format.alias(SI.KELVIN, "kelvin"); + format.alias(SI.CELSIUS, "C"); + format.label(SatelliteUnits.IR_PIXEL, "IRPixel"); + format.label(SatelliteUnits.PRECIP_PIXEL, "PrecipPixel"); + format.label(SatelliteUnits.RAINFALL_RATE_PIXEL, "RainfallRatePixel"); + format.label(SatelliteUnits.SOUNDER_CLOUD_AMOUNT_PIXEL, "SounderCloudAmountPixel"); - UnitFormat.getUCUMInstance().label( - SatelliteUnits.SOUNDER_CLOUD_HEIGHT_PIXEL, + format.label(SatelliteUnits.SOUNDER_CLOUD_HEIGHT_PIXEL, "SounderCloudTopHeightPixel"); - UnitFormat.getUCUMInstance().label( - SatelliteUnits.SOUNDER_LIFTED_INDEX_PIXEL, + format.label(SatelliteUnits.SOUNDER_LIFTED_INDEX_PIXEL, "SounderLiftedIndexPixel"); - UnitFormat.getUCUMInstance().label( - SatelliteUnits.SOUNDER_PRECIP_WATER_PIXEL, + format.label(SatelliteUnits.SOUNDER_PRECIP_WATER_PIXEL, "SounderPrecipWaterPixel"); - UnitFormat.getUCUMInstance().label( - SatelliteUnits.POLAR_PRECIP_WATER_PIXEL, + format.label(SatelliteUnits.POLAR_PRECIP_WATER_PIXEL, "PolarPrecipWaterPixel"); - UnitFormat.getUCUMInstance().label( - SatelliteUnits.SOUNDER_SKIN_TEMP_PIXEL, "SounderSkinTempPixel"); - UnitFormat.getUCUMInstance().label(SatelliteUnits.GENERIC_PIXEL, - "GenericPixel"); - UnitFormat.getUCUMInstance().label(SatelliteUnits.PERCENT_PIXEL, - "PercentOfNormalTPWPixel"); + format.label(SatelliteUnits.SOUNDER_SKIN_TEMP_PIXEL, + "SounderSkinTempPixel"); + format.label(SatelliteUnits.GENERIC_PIXEL, "GenericPixel"); + format.label(SatelliteUnits.PERCENT_PIXEL, "PercentOfNormalTPWPixel"); + format.label(SatelliteUnits.DERIVED_WV, "DerivedWV"); } } diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/src/com/raytheon/uf/common/dataplugin/satellite/units/goes/PercentOfNormalTPWPixel.java b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/src/com/raytheon/uf/common/dataplugin/satellite/units/goes/PercentOfNormalTPWPixel.java index 756d5d899d..feb3948edd 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/src/com/raytheon/uf/common/dataplugin/satellite/units/goes/PercentOfNormalTPWPixel.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/src/com/raytheon/uf/common/dataplugin/satellite/units/goes/PercentOfNormalTPWPixel.java @@ -25,19 +25,19 @@ import javax.measure.unit.Unit; import org.apache.commons.lang.builder.HashCodeBuilder; -import com.raytheon.uf.common.dataplugin.satellite.units.generic.GenericPixel; import com.raytheon.uf.common.dataplugin.satellite.units.goes.convert.PixelToPercentConverter; /** - * TODO Add Description + * A unit for the percent of normal total precipitable water pixels. * *
  * 
  * SOFTWARE HISTORY
  * 
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * May 12, 2010            jsanchez     Initial creation
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * May 12, 2010           jsanchez    Initial creation
+ * Apr 15, 2014  2947     bsteffen    Fix equals.
  * 
  * 
* @@ -50,7 +50,7 @@ public class PercentOfNormalTPWPixel extends Unit { @Override public boolean equals(Object anObject) { - return (anObject instanceof GenericPixel); + return (anObject instanceof PercentOfNormalTPWPixel); } @Override diff --git a/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/poesDif11u3_7uIR.xml b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/poesDif11u3_7uIR.xml similarity index 82% rename from edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/poesDif11u3_7uIR.xml rename to edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/poesDif11u3_7uIR.xml index fe5430b7c2..63d336de85 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/poesDif11u3_7uIR.xml +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/poesDif11u3_7uIR.xml @@ -18,9 +18,9 @@ See_the_AWIPS_II_Master_Rights_File_("Master_Rights_File.pdf")_for further_licensing_information. --> - + - - + + diff --git a/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/satDif11u12uIR.xml b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/satDif11u12uIR.xml similarity index 80% rename from edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/satDif11u12uIR.xml rename to edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/satDif11u12uIR.xml index f200245d78..e2607addb8 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/satDif11u12uIR.xml +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/satDif11u12uIR.xml @@ -18,9 +18,9 @@ See_the_AWIPS_II_Master_Rights_File_("Master_Rights_File.pdf")_for further_licensing_information. --> - + - - + + diff --git a/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/satDif11u13uIR.xml b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/satDif11u13uIR.xml similarity index 79% rename from edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/satDif11u13uIR.xml rename to edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/satDif11u13uIR.xml index cefc67320c..f31c3ef789 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/satDif11u13uIR.xml +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/satDif11u13uIR.xml @@ -18,9 +18,9 @@ See_the_AWIPS_II_Master_Rights_File_("Master_Rights_File.pdf")_for further_licensing_information. --> - + - - + + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/satDif11u3_9uIR.xml b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/satDif11u3_9uIR.xml similarity index 79% rename from edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/satDif11u3_9uIR.xml rename to edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/satDif11u3_9uIR.xml index e5c254bf89..4ae657a5fd 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/satDif11u3_9uIR.xml +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/satDif11u3_9uIR.xml @@ -18,9 +18,9 @@ See_the_AWIPS_II_Master_Rights_File_("Master_Rights_File.pdf")_for further_licensing_information. --> - + - - + + diff --git a/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/satDivWVIR.xml b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/satDivWVIR.xml similarity index 80% rename from edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/satDivWVIR.xml rename to edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/satDivWVIR.xml index 02131c35f1..7f9d5c9c1c 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/satDivWVIR.xml +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/definitions/satDivWVIR.xml @@ -18,9 +18,9 @@ See_the_AWIPS_II_Master_Rights_File_("Master_Rights_File.pdf")_for further_licensing_information. --> - + - - + + diff --git a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/satDif11u3_9uIR.py b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/functions/satDif11u3_9uIR.py similarity index 100% rename from edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/satDif11u3_9uIR.py rename to edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/functions/satDif11u3_9uIR.py diff --git a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/satDifference.py b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/functions/satDifference.py similarity index 100% rename from edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/satDifference.py rename to edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/functions/satDifference.py diff --git a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/satDivWVIR.py b/edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/functions/satDivWVIR.py similarity index 100% rename from edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/satDivWVIR.py rename to edexOsgi/com.raytheon.uf.common.dataplugin.satellite/utility/common_static/base/derivedParameters/functions/satDivWVIR.py diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/PluginDataObject.java b/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/PluginDataObject.java index 6d624ee83b..be6d7d5a72 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/PluginDataObject.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/PluginDataObject.java @@ -104,6 +104,8 @@ import com.raytheon.uf.common.time.DataTime; * PluginDataObject. * May 16, 2013 1869 bsteffen Rewrite dataURI property mappings. * Aug 30, 2013 2298 rjpeter Make getPluginName abstract + * Apr 15, 2014 1869 bsteffen Remove unused transient record field. + * * * */ @@ -173,9 +175,6 @@ public abstract class PluginDataObject extends PersistableDataObject implements @Transient private transient int uriIndex = 2; - @Transient - private Object record = null; - /** * Default Constructor */ @@ -271,14 +270,6 @@ public abstract class PluginDataObject extends PersistableDataObject implements } } - public Object getRecord() { - return record; - } - - public void setRecord(Object record) { - this.record = record; - } - /** * TODO: Rework non-PointDataContainer plots and remove * diff --git a/ncep/gov.noaa.nws.ncep.viz.rsc.satellite/src/gov/noaa/nws/ncep/viz/rsc/satellite/area/McIdasAreaProviderFactory.java b/ncep/gov.noaa.nws.ncep.viz.rsc.satellite/src/gov/noaa/nws/ncep/viz/rsc/satellite/area/McIdasAreaProviderFactory.java index a294de8723..a1e7c55f14 100644 --- a/ncep/gov.noaa.nws.ncep.viz.rsc.satellite/src/gov/noaa/nws/ncep/viz/rsc/satellite/area/McIdasAreaProviderFactory.java +++ b/ncep/gov.noaa.nws.ncep.viz.rsc.satellite/src/gov/noaa/nws/ncep/viz/rsc/satellite/area/McIdasAreaProviderFactory.java @@ -30,7 +30,6 @@ import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.uf.viz.core.requests.ThriftClient; import com.raytheon.uf.viz.core.rsc.AbstractRequestableResourceData; import com.raytheon.uf.viz.core.rsc.ResourceType; -import com.raytheon.viz.satellite.SatelliteDataCubeAdapter; import com.vividsolutions.jts.geom.Polygon; import gov.noaa.nws.ncep.common.dataplugin.mcidas.McidasMapCoverage; From 33fc376f33ef2f9ea18f12b66584f444c85f699f Mon Sep 17 00:00:00 2001 From: Lee Venable Date: Wed, 16 Apr 2014 15:39:34 -0500 Subject: [PATCH 041/188] Issue #3037 - Add dispose check in runAsync call. Change-Id: I13c7475f8c56f677f3dbdfab8d6000061db86f9f Former-commit-id: c511ef6d5566f0e1d9ae3d5ea886abbf1159d41a --- .../com/raytheon/viz/ui/dialogs/ImagingDialog.java | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/ImagingDialog.java b/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/ImagingDialog.java index 0614933e6c..9268d210d4 100644 --- a/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/ImagingDialog.java +++ b/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/ImagingDialog.java @@ -90,6 +90,7 @@ import com.raytheon.viz.ui.editor.IMultiPaneEditor; * Jan 15, 2014 2313 bsteffen Disable color map selection when * ColorMapCapability is not present. * Apr 08, 2014 2905 bsteffen Add option to interpolate colors. + * Apr 16, 2014 3037 lvenable Add dispose check in runAsync call. * * * @@ -812,7 +813,8 @@ public class ImagingDialog extends CaveSWTDialog implements contrastText.setText(contrastScale.getSelection() + "%"); - interpolateImageCheckbox.setSelection(imgCap.isInterpolationState()); + interpolateImageCheckbox + .setSelection(imgCap.isInterpolationState()); } else { topColorMapButton.setText("Top image is not displayed."); topColormapComp.getCMapButton().setText("Not Selected"); @@ -936,7 +938,8 @@ public class ImagingDialog extends CaveSWTDialog implements ((GridData) alphaLabel.getLayoutData()).exclude = true; } - interpolateImageCheckbox.setSelection(imgCap.isInterpolationState()); + interpolateImageCheckbox + .setSelection(imgCap.isInterpolationState()); } else { brightnessText.setVisible(false); contrastText.setVisible(false); @@ -967,6 +970,11 @@ public class ImagingDialog extends CaveSWTDialog implements VizApp.runAsync(new Runnable() { @Override public void run() { + // If the dialog has been disposed then return. + if (isDisposed()) { + return; + } + refreshComponents(); } }); From ab2488b2db5370220f6f27d4466be94fb296f77d Mon Sep 17 00:00:00 2001 From: Brad Gonzales Date: Wed, 16 Apr 2014 10:00:47 -0500 Subject: [PATCH 042/188] Issue #3001 Created com.raytheon.uf.common.dataplugin.ccfp. Moved CcfpLocation and CcfpRecord to that project. Updated feature and manifest references. Amend: Updates from peer review. Change-Id: I5606bbf3ba1dc3d5ad7bdcf3341c57436f9485b3 Former-commit-id: b80a3b8d1c90b7fb8720171f16529edc81bc30a8 --- .../META-INF/MANIFEST.MF | 8 +- .../com/raytheon/uf/viz/ccfp/Activator.java | 81 ------------------- .../uf/viz/ccfp/rsc/CcfpResource.java | 2 +- .../uf/viz/ccfp/rsc/CcfpResourceData.java | 2 +- .../feature.xml | 14 ++-- .../META-INF/MANIFEST.MF | 3 +- .../viz/aviation/monitor/CcfpData.java | 2 +- .../viz/aviation/monitor/MonitorDataUtil.java | 2 +- .../META-INF/MANIFEST.MF | 6 +- .../res/spring/ccfp-common.xml | 2 +- .../edex/plugin/ccfp/CcfpDecoder.java | 12 ++- .../edex/plugin/ccfp/CcfpSeparator.java | 11 +-- .../.classpath | 7 ++ .../.project | 28 +++++++ .../META-INF/MANIFEST.MF | 15 ++++ .../build.properties | 4 + .../common/dataplugin}/ccfp/CcfpLocation.java | 4 +- .../common/dataplugin}/ccfp/CcfpRecord.java | 4 +- .../feature.xml | 7 ++ .../com.raytheon.uf.edex.plugin.ccfp/.project | 28 +++++++ 20 files changed, 132 insertions(+), 110 deletions(-) delete mode 100644 cave/com.raytheon.uf.viz.ccfp/src/com/raytheon/uf/viz/ccfp/Activator.java create mode 100644 edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/.classpath create mode 100644 edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/.project create mode 100644 edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/META-INF/MANIFEST.MF create mode 100644 edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/build.properties rename edexOsgi/{com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin => com.raytheon.uf.common.dataplugin.ccfp/src/com/raytheon/uf/common/dataplugin}/ccfp/CcfpLocation.java (93%) rename edexOsgi/{com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin => com.raytheon.uf.common.dataplugin.ccfp/src/com/raytheon/uf/common/dataplugin}/ccfp/CcfpRecord.java (97%) create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.ccfp/.project diff --git a/cave/com.raytheon.uf.viz.ccfp/META-INF/MANIFEST.MF b/cave/com.raytheon.uf.viz.ccfp/META-INF/MANIFEST.MF index 6bf533f3e4..2af972442a 100644 --- a/cave/com.raytheon.uf.viz.ccfp/META-INF/MANIFEST.MF +++ b/cave/com.raytheon.uf.viz.ccfp/META-INF/MANIFEST.MF @@ -2,13 +2,12 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Ccfp Plug-in Bundle-SymbolicName: com.raytheon.uf.viz.ccfp;singleton:=true -Bundle-Version: 1.12.1174.qualifier -Bundle-Activator: com.raytheon.uf.viz.ccfp.Activator +Bundle-Version: 1.14.0 Bundle-Vendor: RAYTHEON -Eclipse-RegisterBuddy: com.raytheon.viz.core, com.raytheon.uf.viz.core Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Import-Package: com.raytheon.edex.plugin.ccfp, com.raytheon.uf.common.dataplugin, + com.raytheon.uf.common.dataplugin.ccfp, com.raytheon.uf.common.geospatial, com.raytheon.uf.common.status, com.raytheon.uf.common.time, @@ -28,5 +27,4 @@ Import-Package: com.raytheon.edex.plugin.ccfp, Bundle-ActivationPolicy: lazy Require-Bundle: com.raytheon.uf.viz.core, org.geotools;bundle-version="2.5.2" -Export-Package: com.raytheon.uf.viz.ccfp, - com.raytheon.uf.viz.ccfp.rsc +Export-Package: com.raytheon.uf.viz.ccfp.rsc diff --git a/cave/com.raytheon.uf.viz.ccfp/src/com/raytheon/uf/viz/ccfp/Activator.java b/cave/com.raytheon.uf.viz.ccfp/src/com/raytheon/uf/viz/ccfp/Activator.java deleted file mode 100644 index 8f47cab41b..0000000000 --- a/cave/com.raytheon.uf.viz.ccfp/src/com/raytheon/uf/viz/ccfp/Activator.java +++ /dev/null @@ -1,81 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ -package com.raytheon.uf.viz.ccfp; - -import org.eclipse.ui.plugin.AbstractUIPlugin; -import org.osgi.framework.BundleContext; - -/** - * The activator class controls the plug-in life cycle - * - *
- * 
- * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Sep 22, 2009 3072       bsteffen     Initial creation
- * 
- * 
- * - * @author bsteffen - * @version 1.0 - */ -public class Activator extends AbstractUIPlugin { - - // The plug-in ID - public static final String PLUGIN_ID = "com.raytheon.uf.viz.ccfp"; - - // The shared instance - private static Activator plugin; - - /** - * The constructor - */ - public Activator() { - } - - /* - * (non-Javadoc) - * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext) - */ - public void start(BundleContext context) throws Exception { - super.start(context); - plugin = this; - } - - /* - * (non-Javadoc) - * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext) - */ - public void stop(BundleContext context) throws Exception { - plugin = null; - super.stop(context); - } - - /** - * Returns the shared instance - * - * @return the shared instance - */ - public static Activator getDefault() { - return plugin; - } - -} diff --git a/cave/com.raytheon.uf.viz.ccfp/src/com/raytheon/uf/viz/ccfp/rsc/CcfpResource.java b/cave/com.raytheon.uf.viz.ccfp/src/com/raytheon/uf/viz/ccfp/rsc/CcfpResource.java index d662d39013..249fc5af0b 100644 --- a/cave/com.raytheon.uf.viz.ccfp/src/com/raytheon/uf/viz/ccfp/rsc/CcfpResource.java +++ b/cave/com.raytheon.uf.viz.ccfp/src/com/raytheon/uf/viz/ccfp/rsc/CcfpResource.java @@ -32,8 +32,8 @@ import org.eclipse.swt.graphics.RGB; import org.eclipse.swt.graphics.Rectangle; import org.opengis.referencing.crs.CoordinateReferenceSystem; -import com.raytheon.edex.plugin.ccfp.CcfpRecord; import com.raytheon.uf.common.dataplugin.PluginDataObject; +import com.raytheon.uf.common.dataplugin.ccfp.CcfpRecord; import com.raytheon.uf.common.geospatial.ReferencedCoordinate; import com.raytheon.uf.common.time.DataTime; import com.raytheon.uf.viz.core.IExtent; diff --git a/cave/com.raytheon.uf.viz.ccfp/src/com/raytheon/uf/viz/ccfp/rsc/CcfpResourceData.java b/cave/com.raytheon.uf.viz.ccfp/src/com/raytheon/uf/viz/ccfp/rsc/CcfpResourceData.java index ae946ce57f..d6342872e3 100644 --- a/cave/com.raytheon.uf.viz.ccfp/src/com/raytheon/uf/viz/ccfp/rsc/CcfpResourceData.java +++ b/cave/com.raytheon.uf.viz.ccfp/src/com/raytheon/uf/viz/ccfp/rsc/CcfpResourceData.java @@ -25,8 +25,8 @@ import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlAttribute; -import com.raytheon.edex.plugin.ccfp.CcfpRecord; import com.raytheon.uf.common.dataplugin.PluginDataObject; +import com.raytheon.uf.common.dataplugin.ccfp.CcfpRecord; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; diff --git a/cave/com.raytheon.uf.viz.dataplugins.feature/feature.xml b/cave/com.raytheon.uf.viz.dataplugins.feature/feature.xml index af78b441fb..fca6b25c20 100644 --- a/cave/com.raytheon.uf.viz.dataplugins.feature/feature.xml +++ b/cave/com.raytheon.uf.viz.dataplugins.feature/feature.xml @@ -100,6 +100,13 @@ version="0.0.0" unpack="false"/> + + - - - + diff --git a/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpDecoder.java b/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpDecoder.java index 7dd70eccd7..90c920752d 100644 --- a/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpDecoder.java +++ b/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpDecoder.java @@ -29,6 +29,10 @@ import com.raytheon.edex.exception.DecoderException; import com.raytheon.edex.plugin.AbstractDecoder; import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.common.dataplugin.PluginException; +import com.raytheon.uf.common.dataplugin.ccfp.CcfpLocation; +import com.raytheon.uf.common.dataplugin.ccfp.CcfpRecord; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.time.DataTime; import com.raytheon.uf.common.time.TimeRange; import com.raytheon.uf.edex.decodertools.time.TimeTools; @@ -49,6 +53,7 @@ import com.vividsolutions.jts.io.WKTReader; * Sep 21, 2009 3072 bsteffen Fixed Decoding of Line Records * Jan 02, 2013 DCS 135 tk handle coverage value Line records * Aug 30, 2013 2298 rjpeter Make getPluginName abstract + * Apr 16, 2014 3001 bgonzale Use UfStatus for logging. * * * @@ -60,6 +65,9 @@ public class CcfpDecoder extends AbstractDecoder { private static final String PLUGIN_NAME = "ccfp"; + private static final IUFStatusHandler theLogger = UFStatus + .getHandler(CcfpDecoder.class); + /** Match the product returned from separator */ private static final String PARSE_STRING = "[A-Z]{4}[0-9]{1,2} [A-Z]{4} [0-9]{6}(?: [A-Z]{3})?\n" + "CFP[\\p{Alnum} ]{3}\n" // awips header @@ -226,7 +234,7 @@ public class CcfpDecoder extends AbstractDecoder { } } catch (Exception e) { record = null; - logger.error("Unable to decode CCFP", e); + theLogger.error("Unable to decode CCFP", e); } data = EMPTY_PDO; if (record != null) { @@ -235,7 +243,7 @@ public class CcfpDecoder extends AbstractDecoder { record.setInsertTime(baseTime); data = new PluginDataObject[] { record }; } catch (PluginException e) { - logger.error("Error constructing datauri", e); + theLogger.error("Error constructing datauri", e); } } return data; diff --git a/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpSeparator.java b/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpSeparator.java index 5ba540904a..37326fa041 100644 --- a/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpSeparator.java +++ b/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpSeparator.java @@ -27,11 +27,10 @@ import java.util.NoSuchElementException; import java.util.regex.Matcher; import java.util.regex.Pattern; -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; - import com.raytheon.edex.esb.Headers; import com.raytheon.edex.plugin.AbstractRecordSeparator; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.util.StringUtil; /** @@ -44,8 +43,9 @@ import com.raytheon.uf.common.util.StringUtil; * ------------ ---------- ----------- -------------------------- * 03/03/2007 908 bwoodle initial creation * 12/03/2008 chammack Camel refactor - * 09/16/2009 3027 njensen Static patterns + * 09/16/2009 3027 njensen Static patterns * 01/02/2013 DCS 135 tk use \\r* for testing end of line + * 04/16/2014 3001 bgonzale Use UfStatus for logging. * * * @@ -55,7 +55,8 @@ import com.raytheon.uf.common.util.StringUtil; public class CcfpSeparator extends AbstractRecordSeparator { - private final Log theLogger = LogFactory.getLog(getClass()); + private static final IUFStatusHandler theLogger = UFStatus + .getHandler(CcfpSeparator.class); /** Regex used for separating multi-record files */ private static final Pattern DATASET = Pattern diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/.classpath b/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/.classpath new file mode 100644 index 0000000000..cd7b12125f --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/.classpath @@ -0,0 +1,7 @@ + + + + + + + diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/.project b/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/.project new file mode 100644 index 0000000000..fafcd57fd3 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/.project @@ -0,0 +1,28 @@ + + + com.raytheon.uf.common.dataplugin.ccfp + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.pde.ManifestBuilder + + + + + org.eclipse.pde.SchemaBuilder + + + + + + org.eclipse.pde.PluginNature + org.eclipse.jdt.core.javanature + + diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/META-INF/MANIFEST.MF new file mode 100644 index 0000000000..2ddf9956a1 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/META-INF/MANIFEST.MF @@ -0,0 +1,15 @@ +Manifest-Version: 1.0 +Bundle-ManifestVersion: 2 +Bundle-Name: CCFP common Plug-in +Bundle-SymbolicName: com.raytheon.uf.common.dataplugin.ccfp +Bundle-Version: 1.14.0 +Eclipse-RegisterBuddy: com.raytheon.uf.common.serialization +Bundle-Vendor: RAYTHEON +Bundle-RequiredExecutionEnvironment: JavaSE-1.6 +Export-Package: com.raytheon.uf.common.dataplugin.ccfp +Require-Bundle: javax.persistence;bundle-version="1.0.0", + org.hibernate;bundle-version="3.5.6", + com.raytheon.uf.common.geospatial;bundle-version="1.14.0", + com.raytheon.uf.common.serialization;bundle-version="1.12.1174" +Import-Package: com.raytheon.uf.common.dataplugin, + com.raytheon.uf.common.dataplugin.annotations diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/build.properties b/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/build.properties new file mode 100644 index 0000000000..34d2e4d2da --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/build.properties @@ -0,0 +1,4 @@ +source.. = src/ +output.. = bin/ +bin.includes = META-INF/,\ + . diff --git a/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpLocation.java b/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/src/com/raytheon/uf/common/dataplugin/ccfp/CcfpLocation.java similarity index 93% rename from edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpLocation.java rename to edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/src/com/raytheon/uf/common/dataplugin/ccfp/CcfpLocation.java index b1976a1eaf..23cb187ee0 100644 --- a/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpLocation.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/src/com/raytheon/uf/common/dataplugin/ccfp/CcfpLocation.java @@ -18,7 +18,7 @@ * further licensing information. **/ -package com.raytheon.edex.plugin.ccfp; +package com.raytheon.uf.common.dataplugin.ccfp; import javax.persistence.Column; import javax.persistence.Embeddable; @@ -46,6 +46,8 @@ import com.vividsolutions.jts.geom.Geometry; * Jul 16, 2013 2181 bsteffen Convert geometry types to use hibernate- * spatial * Nov 01, 2013 2361 njensen Remove XML annotations + * Apr 15, 2014 3001 bgonzale Refactored to common package, + * com.raytheon.uf.common.dataplugin.ccfp. * * * diff --git a/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpRecord.java b/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/src/com/raytheon/uf/common/dataplugin/ccfp/CcfpRecord.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpRecord.java rename to edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/src/com/raytheon/uf/common/dataplugin/ccfp/CcfpRecord.java index 45025c7581..730548c9fb 100644 --- a/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpRecord.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/src/com/raytheon/uf/common/dataplugin/ccfp/CcfpRecord.java @@ -18,7 +18,7 @@ * further licensing information. **/ -package com.raytheon.edex.plugin.ccfp; +package com.raytheon.uf.common.dataplugin.ccfp; import javax.persistence.Access; import javax.persistence.AccessType; @@ -56,6 +56,8 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; * PluginDataObject. * Aug 30, 2013 2298 rjpeter Make getPluginName abstract * Nov 01, 2013 2361 njensen Remove XML annotations + * Apr 15, 2014 3001 bgonzale Refactored to common package, + * com.raytheon.uf.common.dataplugin.ccfp. * * * diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml b/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml index 48b22fbeb5..6de1612be3 100644 --- a/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml +++ b/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml @@ -38,6 +38,13 @@ version="0.0.0" unpack="false"/> + + + + com.raytheon.uf.edex.plugin.ccfp + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.pde.ManifestBuilder + + + + + org.eclipse.pde.SchemaBuilder + + + + + + org.eclipse.pde.PluginNature + org.eclipse.jdt.core.javanature + + From 8ce590c31c8685499ae267636540da3e00a2871f Mon Sep 17 00:00:00 2001 From: Roger Ferrel Date: Tue, 15 Apr 2014 12:12:34 -0500 Subject: [PATCH 043/188] Issue #3023 Configurable available disk thresholds and unit test fixes Change-Id: Ia179baab388a9f9faf62e84e4a3338a7af3464b0 Former-commit-id: ce00327d4cd248efb65fd8b6e823d93c81c9a902 --- cave/com.raytheon.uf.viz.archive/plugin.xml | 8 ++ .../uf/viz/archive/ui/AbstractArchiveDlg.java | 16 ++- .../viz/archive/ui/ArchiveRetentionDlg.java | 13 +-- .../uf/viz/archive/ui/CaseCreation.java | 79 +++++++++++++++ .../uf/viz/archive/ui/CaseCreationDlg.java | 60 +++++++++++- .../viz/archive/ui/CaseCreationManager.java | 98 +++++++++++++++++++ .../com/raytheon/uf/common/util/SizeUtil.java | 12 ++- .../base/archiver/gui/CaseCreation.xml | 30 ++++++ .../archive/ArchiveConfigManagerTest.java | 21 ++-- 9 files changed, 308 insertions(+), 29 deletions(-) create mode 100644 cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreation.java create mode 100644 cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationManager.java create mode 100644 edexOsgi/com.raytheon.uf.edex.archive/utility/common_static/base/archiver/gui/CaseCreation.xml diff --git a/cave/com.raytheon.uf.viz.archive/plugin.xml b/cave/com.raytheon.uf.viz.archive/plugin.xml index 7e1d124169..bf7a596350 100644 --- a/cave/com.raytheon.uf.viz.archive/plugin.xml +++ b/cave/com.raytheon.uf.viz.archive/plugin.xml @@ -30,6 +30,14 @@ recursive="false" extensionFilter=".xml"> + + diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/AbstractArchiveDlg.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/AbstractArchiveDlg.java index b17a977ee4..7cb9486838 100644 --- a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/AbstractArchiveDlg.java +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/AbstractArchiveDlg.java @@ -78,6 +78,7 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * Nov 14, 2013 2549 rferrel Get category data moved off the UI thread. * Dec 11, 2013 2624 rferrel No longer clear table prior to populating. * Apr 15, 2014 3034 lvenable Added dispose checks in runAsync calls. + * Apr 10, 2014 3023 rferrel Added setTotalSelectedSize method. * * * @@ -577,15 +578,22 @@ public abstract class AbstractArchiveDlg extends CaveSWTDialog implements } } + setTotalSelectedSize(totalSize); + setTotalSelectedItems(totalSelected); + } + + /** + * + * @param selectedTotalSize + */ + protected void setTotalSelectedSize(long selectedTotalSize) { String sizeMsg = null; - if (totalSize == DisplayData.UNKNOWN_SIZE) { + if (selectedTotalSize == DisplayData.UNKNOWN_SIZE) { sizeMsg = DisplayData.UNKNOWN_SIZE_LABEL; } else { - sizeMsg = SizeUtil.prettyByteSize(totalSize); + sizeMsg = SizeUtil.prettyByteSize(selectedTotalSize); } - setTotalSizeText(sizeMsg); - setTotalSelectedItems(totalSelected); } /** diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveRetentionDlg.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveRetentionDlg.java index 6072a5e10c..04662713eb 100644 --- a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveRetentionDlg.java +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveRetentionDlg.java @@ -56,6 +56,7 @@ import com.raytheon.uf.common.time.util.TimeUtil; * Aug 26, 2013 #2225 rferrel Make dialog perspective independent. * Oct 01, 2013 #2147 rferrel Change getEnd() to pick up files with future time stamps. * Oct 07, 2013 #2438 rferrel Properly save and load retention times. + * Apr 14, 2014 #3023 rferrel Code clean up. * * * @@ -70,12 +71,6 @@ public class ArchiveRetentionDlg extends AbstractArchiveDlg { /** Current Archive/Category selection's extended retention hours. */ private RetentionHours extRetention; - /** Displays the total number of selected items for all tables. */ - private Label totalSelectedItems; - - /** Displays the total size of selected items. */ - private Label totalSizeLbl; - /** Flag to indicate when retention hours are modified. */ private boolean retentionHoursAreModified = false; @@ -293,9 +288,6 @@ public class ArchiveRetentionDlg extends AbstractArchiveDlg { */ @Override protected void setTotalSizeText(String sizeStringText) { - if (totalSizeLbl != null && !totalSizeLbl.isDisposed()) { - totalSizeLbl.setText(sizeStringText); - } } /* @@ -307,9 +299,6 @@ public class ArchiveRetentionDlg extends AbstractArchiveDlg { */ @Override protected void setTotalSelectedItems(int totalSize) { - if (totalSelectedItems != null && !totalSelectedItems.isDisposed()) { - totalSelectedItems.setText("" + totalSize); - } } /* diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreation.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreation.java new file mode 100644 index 0000000000..631ae0500d --- /dev/null +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreation.java @@ -0,0 +1,79 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.viz.archive.ui; + +import javax.xml.bind.annotation.XmlAccessType; +import javax.xml.bind.annotation.XmlAccessorType; +import javax.xml.bind.annotation.XmlElement; +import javax.xml.bind.annotation.XmlRootElement; + +/** + * Archive case creation dialog's configuration options. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 11, 2014 3023       rferrel     Initial creation
+ * 
+ * 
+ * + * @author rferrel + * @version 1.0 + */ + +@XmlRootElement(name = "CaseCreation") +@XmlAccessorType(XmlAccessType.NONE) +public class CaseCreation { + @XmlElement(name = "CautionThreshold") + private float cautionThreshold; + + @XmlElement(name = "DangerThreshold") + private float dangerThreshold; + + @XmlElement(name = "FatalThreshold") + private float fatalThreshold; + + public float getCautionThreshold() { + return cautionThreshold; + } + + public void setCautionThreshold(float cautionThreshold) { + this.cautionThreshold = cautionThreshold; + } + + public float getDangerThreshold() { + return dangerThreshold; + } + + public void setDangerThreshold(float dangerThreshold) { + this.dangerThreshold = dangerThreshold; + } + + public float getFatalThreshold() { + return fatalThreshold; + } + + public void setFatalThreshold(float fatalThreshold) { + this.fatalThreshold = fatalThreshold; + } +} diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationDlg.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationDlg.java index 2f7ccf2f82..06f445f4a0 100644 --- a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationDlg.java +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationDlg.java @@ -71,6 +71,7 @@ import com.raytheon.viz.ui.dialogs.ICloseCallback; * Jul 24, 2013 #2221 rferrel Changes for select configuration. * Aug 06, 2013 #2222 rferrel Changes to display all selected data. * Aug 26, 2013 #2225 rferrel Make perspective independent and no longer modal. + * Apr 11, 2014 #3023 rferrel Configurable Threshold options. * * * @@ -162,6 +163,9 @@ public class CaseCreationDlg extends AbstractArchiveDlg { /** Allow only single instance of dialog. */ private GenerateCaseDlg generateCaseDlg; + /** Manager for configurable values for the dialog. */ + private final CaseCreationManager ccManager; + /** * Constructor. * @@ -175,6 +179,7 @@ public class CaseCreationDlg extends AbstractArchiveDlg { this.type = Type.Case; this.setSelect = false; this.type = Type.Case; + this.ccManager = new CaseCreationManager(); } /* @@ -829,24 +834,33 @@ public class CaseCreationDlg extends AbstractArchiveDlg { if (isDisposed()) { return; } - File dir = (File) locationLbl.getData(); + Object o = locationLbl.getData(); + if (!(o instanceof File)) { + return; + } + File dir = (File) o; long totSpace = dir.getTotalSpace(); long freeSpace = dir.getUsableSpace(); + + o = uncompressSizeLbl.getData(); + if (o instanceof Long) { + freeSpace -= (Long) o; + } long percentFull = (long) Math.round(((totSpace - freeSpace) * 100.0) / totSpace); String state = null; Color bgColor = null; Color fgColor = null; Display display = shell.getDisplay(); - if (percentFull <= 84) { + if (freeSpace > ccManager.getCautionThreshold()) { state = "GOOD"; bgColor = display.getSystemColor(SWT.COLOR_GREEN); fgColor = display.getSystemColor(SWT.COLOR_BLACK); - } else if (percentFull <= 94) { + } else if (freeSpace > ccManager.getDangerThreshold()) { state = "CAUTION"; bgColor = display.getSystemColor(SWT.COLOR_YELLOW); fgColor = display.getSystemColor(SWT.COLOR_BLACK); - } else if (percentFull <= 97) { + } else if (freeSpace > ccManager.getFatalThreshold()) { state = "DANGER"; bgColor = display.getSystemColor(SWT.COLOR_RED); fgColor = display.getSystemColor(SWT.COLOR_BLACK); @@ -955,10 +969,46 @@ public class CaseCreationDlg extends AbstractArchiveDlg { return str; } + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.viz.archive.ui.AbstractArchiveDlg#setTotalSizeText(java + * .lang.String) + */ + @Override protected void setTotalSizeText(String text) { - uncompressSizeLbl.setText(text); + if (!uncompressSizeLbl.isDisposed()) { + uncompressSizeLbl.setText(text); + } } + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.viz.archive.ui.AbstractArchiveDlg#setTotalSelectedSize + * (long) + */ + @Override + protected void setTotalSelectedSize(long totalSize) { + super.setTotalSelectedSize(totalSize); + Long tSize = null; + if (totalSize > 0) { + tSize = new Long(totalSize); + } + uncompressSizeLbl.setData(tSize); + updateLocationState(); + } + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.viz.archive.ui.AbstractArchiveDlg#setTotalSelectedItems + * (int) + */ + @Override protected void setTotalSelectedItems(int totalSelected) { selectedItemsSize = totalSelected; totalSelectedItemsLbl.setText("" + totalSelected); diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationManager.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationManager.java new file mode 100644 index 0000000000..b35b646c84 --- /dev/null +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationManager.java @@ -0,0 +1,98 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.viz.archive.ui; + +import java.io.File; + +import javax.xml.bind.JAXB; + +import org.apache.commons.io.FileUtils; + +import com.raytheon.uf.common.localization.IPathManager; +import com.raytheon.uf.common.localization.PathManagerFactory; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.status.UFStatus.Priority; + +/** + * This class obtains the configurable options for the archive case creation + * dialog. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 11, 2014 3023       rferrel     Initial creation
+ * 
+ * 
+ * + * @author rferrel + * @version 1.0 + */ + +public class CaseCreationManager { + private static transient IUFStatusHandler statusHandler = UFStatus + .getHandler(CaseCreationManager.class); + + private CaseCreation caseCreation; + + public CaseCreationManager() { + initValues(); + } + + private void initValues() { + String path = "archiver" + IPathManager.SEPARATOR + "gui" + + IPathManager.SEPARATOR + "CaseCreation.xml"; + IPathManager pm = PathManagerFactory.getPathManager(); + File file = pm.getStaticFile(path); + try { + caseCreation = JAXB.unmarshal(file, CaseCreation.class); + } catch (RuntimeException e) { + statusHandler.handle(Priority.PROBLEM, e.getLocalizedMessage(), e); + caseCreation = new CaseCreation(); + } + + if (caseCreation.getCautionThreshold() <= 0.0) { + caseCreation.setCautionThreshold((float) 2.0); + } + + if (caseCreation.getDangerThreshold() <= 0.0) { + caseCreation.setDangerThreshold((float) 1.0); + } + + if (caseCreation.getFatalThreshold() <= 0.0) { + caseCreation.setFatalThreshold((float) 0.5); + } + } + + public long getCautionThreshold() { + return (long) (caseCreation.getCautionThreshold() * FileUtils.ONE_GB); + } + + public long getDangerThreshold() { + return (long) (caseCreation.getDangerThreshold() * FileUtils.ONE_GB); + } + + public long getFatalThreshold() { + return (long) (caseCreation.getFatalThreshold() * FileUtils.ONE_GB); + } +} diff --git a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SizeUtil.java b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SizeUtil.java index cdb9e9591d..e5ee17286a 100644 --- a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SizeUtil.java +++ b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SizeUtil.java @@ -30,6 +30,7 @@ package com.raytheon.uf.common.util; * ------------ ---------- ----------- -------------------------- * Jul 24, 2012 njensen Initial creation * Jun 12, 2013 2064 mpduff Add prettyKiloByteSize. + * Apr 10, 2014 3023 rferrel Properly handle negative numbers. * * * @@ -54,14 +55,21 @@ public class SizeUtil { * @return the pretty String representation of the byte size */ public static String prettyByteSize(long numberOfBytes) { - float n = numberOfBytes; + StringBuilder sb = new StringBuilder(); + float n; + if (numberOfBytes < 0) { + sb.append("-"); + n = -numberOfBytes; + } else { + n = numberOfBytes; + } + int reps = 0; while (n > BYTES_PER && reps < REP_PREFIX.length - 1) { reps++; n /= BYTES_PER; } int tenth = ((int) (n * 10)) % 10; - StringBuilder sb = new StringBuilder(); sb.append((int) n).append(".").append(tenth); sb.append(REP_PREFIX[reps]); return sb.toString(); diff --git a/edexOsgi/com.raytheon.uf.edex.archive/utility/common_static/base/archiver/gui/CaseCreation.xml b/edexOsgi/com.raytheon.uf.edex.archive/utility/common_static/base/archiver/gui/CaseCreation.xml new file mode 100644 index 0000000000..8616b89db0 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.archive/utility/common_static/base/archiver/gui/CaseCreation.xml @@ -0,0 +1,30 @@ + + + + + + 2.0 + 1.0 + 0.5 + diff --git a/tests/unit/com/raytheon/uf/common/archive/ArchiveConfigManagerTest.java b/tests/unit/com/raytheon/uf/common/archive/ArchiveConfigManagerTest.java index 8df168ed93..cb69ee496d 100644 --- a/tests/unit/com/raytheon/uf/common/archive/ArchiveConfigManagerTest.java +++ b/tests/unit/com/raytheon/uf/common/archive/ArchiveConfigManagerTest.java @@ -51,6 +51,7 @@ import com.raytheon.uf.common.localization.PathManagerFactoryTest; import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.common.util.FileUtil; import com.raytheon.uf.common.util.TestUtil; +import com.raytheon.uf.edex.archive.purge.ArchivePurgeManager; /** * Test ArchiveConfigManager Archive Ingest Purge and Archive Creation. @@ -65,6 +66,8 @@ import com.raytheon.uf.common.util.TestUtil; * Added additional test data for file newer than purge * time but in directory that is older than purge time. * Aug 28, 2013 2299 rferrel purgeExpiredFromArchive now returns number of files purged. + * Apr 14, 2014 3023 rferrel Remove archive purge test no long works with implementation + * cluster locks. * * * @@ -158,10 +161,10 @@ public class ArchiveConfigManagerTest { "/sat/{0}{1}{2}/{3}/GOES-13/{7}{8}Z_SOUND-VIS_10km_EAST-CONUS-TIGE59_KNES_128453.satz.{4}{5}{6}{7}"); createTestFiles(satFormat_Raw, archiveRaw, SAT_CAT_NAME_RAW, true, archiveStart, archiveEnd); - MessageFormat satFormat_Processed = new MessageFormat( - "/satellite/East CONUS/Sounder Visible imagery/satellite-{4}-{5}-{6}-{7}.h5"); - createTestFiles(satFormat_Processed, archiveProcessed, "Satellite", - true, archiveStart, archiveEnd); + // MessageFormat satFormat_Processed = new MessageFormat( + // "/satellite/East CONUS/Sounder Visible imagery/satellite-{4}-{5}-{6}-{7}.h5"); + // createTestFiles(satFormat_Processed, archiveProcessed, "Satellite", + // true, archiveStart, archiveEnd); // **** acars **** MessageFormat acarsFormat_Raw = new MessageFormat( @@ -545,9 +548,15 @@ public class ArchiveConfigManagerTest { createFileNameListRemoveTestDir(filesFoundInArchive)); } - @Test + /* + * With the implementation of cluster task locking (to prevent database + * Archive, Archive purge and Archive case creation from interfering with + * each other) this unit test fails since unable to access the + * awips.cluster_task table to perform the locks. + */ + // @Test public void testArchiveManagerPurge() throws IOException { - ArchiveConfigManager manager = ArchiveConfigManager.getInstance(); + ArchivePurgeManager manager = ArchivePurgeManager.getInstance(); Collection filesFoundInPurge = new ArrayList(); int purgeCount = 0; From ae2275a0ee26a70a25542130eb88cea0c23fc2ea Mon Sep 17 00:00:00 2001 From: Slav Korolev Date: Thu, 17 Apr 2014 09:10:13 -0400 Subject: [PATCH 044/188] Issue #2942 - Updated throw exception. Former-commit-id: 1457190469ec62f7a7aa2fa8e62ee2012dd57c10 --- .../uf/edex/plugin/manualIngest/MessageGenerator.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.manualIngest/src/com/raytheon/uf/edex/plugin/manualIngest/MessageGenerator.java b/edexOsgi/com.raytheon.uf.edex.plugin.manualIngest/src/com/raytheon/uf/edex/plugin/manualIngest/MessageGenerator.java index 3d4f4e3353..fd3dd91937 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.manualIngest/src/com/raytheon/uf/edex/plugin/manualIngest/MessageGenerator.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.manualIngest/src/com/raytheon/uf/edex/plugin/manualIngest/MessageGenerator.java @@ -56,6 +56,8 @@ import com.raytheon.uf.edex.distribution.DistributionPatterns; * ------------ ---------- ----------- -------------------------- * Oct 28, 2009 brockwoo Initial creation * Sep 03, 2013 2327 rjpeter Added directory routing by plugin and date of product. + * Apr 17, 2014 2942 skorolev Updated throw exception in sendFileToIngest. + * * * * @author brockwoo @@ -285,6 +287,10 @@ public class MessageGenerator implements Processor { try { File archiveFile = copyFileToArchive(new File(inFile)); + if (archiveFile == null) { + throw new Exception("File " + inFile + + " has not been copied into archive."); + } EDEXUtil.getMessageProducer().sendAsync(route, archiveFile.getAbsolutePath()); } catch (Exception e) { From 0b9f8ce7f1e1f3f2fa206755cf310b273036702a Mon Sep 17 00:00:00 2001 From: Mike Duff Date: Wed, 16 Apr 2014 17:25:36 -0500 Subject: [PATCH 045/188] Issue #3025 - Fix incorrect sort algorithm. Change-Id: Ied1ec59a8703c1f7476793d3896a253ec6aa2707 Former-commit-id: 9c275288183b93ba5cac991dbbdf72bdf122ad0a --- .../ui/dialogs/gagetable/GageTableDlg.java | 42 ++++++++++--------- 1 file changed, 23 insertions(+), 19 deletions(-) diff --git a/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/dialogs/gagetable/GageTableDlg.java b/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/dialogs/gagetable/GageTableDlg.java index 479203af00..3d3b92078f 100644 --- a/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/dialogs/gagetable/GageTableDlg.java +++ b/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/dialogs/gagetable/GageTableDlg.java @@ -104,7 +104,8 @@ import com.raytheon.viz.mpe.ui.dialogs.gagetable.xml.GageTableSortType; * May 28, 2009 2476 mpduff Initial creation. * Mar 08, 2013 15725 snaples Updated to fix resort issues when editing value. * Jan 28, 2014 16994 snaples Updated populateGridCombo to get correct filename prefix for matching up selection. - * Feb 2, 2014 16201 snaples Added saved data flag support + * Feb 02, 2014 16201 snaples Added saved data flag support + * Apr 16, 2014 3025 mpduff Fix sort method. * * * @@ -488,8 +489,8 @@ public class GageTableDlg extends JFrame implements IEditTimeChangedListener { for (int i = 0; i < columnData.size(); i++) { if (columnData.get(i).isDataColumn()) { gridCombo.addItem(columnData.get(i).getName()); - if (selectedGrid - .equalsIgnoreCase(columnData.get(i).getProductDescriptor().getProductFilenamePrefix())) { + if (selectedGrid.equalsIgnoreCase(columnData.get(i) + .getProductDescriptor().getProductFilenamePrefix())) { gridComboSelection = gridSelectionIndex; } gridSelectionIndex++; @@ -1137,20 +1138,24 @@ public class GageTableDlg extends JFrame implements IEditTimeChangedListener { response = -1; } else { if (ascending) { - if (o1.toString().trim().equalsIgnoreCase("M")) { - response = -1; - } else if (o2.toString().trim().equalsIgnoreCase("M")) { - response = 1; - } else { - response = o1.compareTo(o2); + // Check for equality first + response = o1.compareTo(o2); + if (response != 0) { + if (o1.toString().trim().equalsIgnoreCase("M")) { + response = -1; + } else if (o2.toString().trim().equalsIgnoreCase("M")) { + response = 1; + } } } else { - if (o1.toString().trim().equalsIgnoreCase("M")) { - response = 1; - } else if (o2.toString().trim().equalsIgnoreCase("M")) { - response = -1; - } else { - response = o2.compareTo(o1); + // Check for equality first + response = o1.compareTo(o2); + if (response != 0) { + if (o1.toString().trim().equalsIgnoreCase("M")) { + response = 1; + } else if (o2.toString().trim().equalsIgnoreCase("M")) { + response = -1; + } } } } @@ -1316,12 +1321,11 @@ public class GageTableDlg extends JFrame implements IEditTimeChangedListener { dispose(); } - public void setDataChanged(boolean dataChanged) - { - this.dataChanged = dataChanged; + public void setDataChanged(boolean dataChanged) { + this.dataChanged = dataChanged; } - /** + /** * Set the sort order of the columns. * * @param settings From f4823976f3fd9add4695660190e88bdc5ef58d7a Mon Sep 17 00:00:00 2001 From: Ron Anderson Date: Thu, 17 Apr 2014 11:38:40 -0500 Subject: [PATCH 046/188] Issue #2664 Fix NullPointerException when no .prj file present Change-Id: I2716eca6b71d79657f19feadb931a23ee3e44f4d Former-commit-id: 66db062f94a5136902bac5cd5df8cbf30305a30a --- .../uf/viz/gisdatastore/rsc/DataStoreResource.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/DataStoreResource.java b/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/DataStoreResource.java index 4de7beccc6..c34365a018 100644 --- a/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/DataStoreResource.java +++ b/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/DataStoreResource.java @@ -119,6 +119,7 @@ import com.vividsolutions.jts.geom.Point; * Feb 18, 2014 #2819 randerso Removed unnecessary clones of geometries * Mar 11, 2014 #2718 randerso Changes for GeoTools 10.5 * Mar 25, 2014 #2664 randerso Added support for non-WGS84 shape files + * Apr 14, 2014 #2664 randerso Fix NullPointerException when no .prj file present * * * @@ -611,6 +612,13 @@ public class DataStoreResource extends schema = dataStore.getSchema(typeName); CoordinateReferenceSystem incomingCrs = schema .getGeometryDescriptor().getCoordinateReferenceSystem(); + if (incomingCrs == null) { + statusHandler.warn("No projection information found for " + + dataStore.getFeatureSource(typeName).getName() + .getURI() + + ", assuming WGS84 unprojected lat/lon."); + incomingCrs = MapUtil.getLatLonProjection(); + } incomingToLatLon = MapUtil.getTransformToLatLon(incomingCrs); latLonToIncoming = MapUtil.getTransformFromLatLon(incomingCrs); From c0df1b34bd5713ad90b06a3de45db56a08dc5bb7 Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Thu, 17 Apr 2014 15:07:11 -0500 Subject: [PATCH 047/188] Issue #2726: Remove CPG forwarding route Change-Id: Idf2238ddde88d2a88949c289302a73b8aaf752e9 Former-commit-id: 3b29088641ed4b857b3eca55bc873b151dd86146 --- .../res/spring/cpgsrv-spring.xml | 8 -------- .../uf/edex/cpgsrv/CompositeProductGenerator.java | 15 ++++++++------- 2 files changed, 8 insertions(+), 15 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.edex.cpgsrv/res/spring/cpgsrv-spring.xml b/edexOsgi/com.raytheon.uf.edex.cpgsrv/res/spring/cpgsrv-spring.xml index bcc6a25751..bff953f0f7 100644 --- a/edexOsgi/com.raytheon.uf.edex.cpgsrv/res/spring/cpgsrv-spring.xml +++ b/edexOsgi/com.raytheon.uf.edex.cpgsrv/res/spring/cpgsrv-spring.xml @@ -5,14 +5,6 @@ http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd"> - - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.cpgsrv/src/com/raytheon/uf/edex/cpgsrv/CompositeProductGenerator.java b/edexOsgi/com.raytheon.uf.edex.cpgsrv/src/com/raytheon/uf/edex/cpgsrv/CompositeProductGenerator.java index 481473320d..fe10fae847 100644 --- a/edexOsgi/com.raytheon.uf.edex.cpgsrv/src/com/raytheon/uf/edex/cpgsrv/CompositeProductGenerator.java +++ b/edexOsgi/com.raytheon.uf.edex.cpgsrv/src/com/raytheon/uf/edex/cpgsrv/CompositeProductGenerator.java @@ -61,7 +61,7 @@ import com.raytheon.uf.edex.database.plugin.PluginDao; * 02/05/2013 1580 mpduff EventBus refactor. * 02/12/2013 1615 bgonzale Changed ProcessEvent pluginName to dataType. * Feb 15, 2013 1638 mschenke Moved DataURINotificationMessage to uf.common.dataplugin - * + * Apr 17, 2014 2726 rjpeter Updated to send alerts directly to notification route. * * * @author dhladky @@ -380,7 +380,7 @@ public abstract class CompositeProductGenerator implements protected void persistRecords() { try { PluginDataObject[] pdos = getPluginDataObjects(); - if (pdos != null && getDao() != null && pdos.length > 0) { + if ((pdos != null) && (getDao() != null) && (pdos.length > 0)) { EDEXUtil.checkPersistenceTimes(pdos); getDao().persistRecords(pdos); } @@ -394,10 +394,10 @@ public abstract class CompositeProductGenerator implements */ protected void fireTopicUpdate() { try { - if (getPluginDataObjects() != null - && getPluginDataObjects().length > 0) { - EDEXUtil.getMessageProducer().sendAsync("cpgProcessAlerts", - getPluginDataObjects()); + if ((getPluginDataObjects() != null) + && (getPluginDataObjects().length > 0)) { + EDEXUtil.getMessageProducer().sendAsync( + "notificationAggregation", getPluginDataObjects()); } } catch (EdexException e) { e.printStackTrace(); @@ -437,7 +437,8 @@ public abstract class CompositeProductGenerator implements @Override public void log(URIGenerateMessage message) { - if (getPluginDataObjects() != null && getPluginDataObjects().length > 0) { + if ((getPluginDataObjects() != null) + && (getPluginDataObjects().length > 0)) { long curTime = System.currentTimeMillis(); ProcessEvent processEvent = new ProcessEvent(); From da8e9f644259b2622114b2b24be8bbce96a6bc99 Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Thu, 17 Apr 2014 15:24:08 -0500 Subject: [PATCH 048/188] Issue #2906 added wx_past to bufr decoder added aliases and bufr table mappings Former-commit-id: 4a2ed02cfb1e0f024c82a73711887ae1149d0f5e --- .../bufrobs/alias/synoptic_land-alias.xml | 2 - .../bufrobs/tables/synoptic_land-0_20_004.xml | 69 +++++++++++++++++++ .../bufrobs/tables/synoptic_land-0_20_005.xml | 69 +++++++++++++++++++ 3 files changed, 138 insertions(+), 2 deletions(-) create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/utility/edex_static/base/bufrobs/tables/synoptic_land-0_20_004.xml create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/utility/edex_static/base/bufrobs/tables/synoptic_land-0_20_005.xml diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/utility/edex_static/base/bufrobs/alias/synoptic_land-alias.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/utility/edex_static/base/bufrobs/alias/synoptic_land-alias.xml index 63c26267d2..95f58618b7 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/utility/edex_static/base/bufrobs/alias/synoptic_land-alias.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/utility/edex_static/base/bufrobs/alias/synoptic_land-alias.xml @@ -59,10 +59,8 @@ Present weather Present weather - Total precipitation/total water equivalent Total precipitation past 24 hours diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/utility/edex_static/base/bufrobs/tables/synoptic_land-0_20_004.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/utility/edex_static/base/bufrobs/tables/synoptic_land-0_20_004.xml new file mode 100644 index 0000000000..a0ac574aac --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/utility/edex_static/base/bufrobs/tables/synoptic_land-0_20_004.xml @@ -0,0 +1,69 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/utility/edex_static/base/bufrobs/tables/synoptic_land-0_20_005.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/utility/edex_static/base/bufrobs/tables/synoptic_land-0_20_005.xml new file mode 100644 index 0000000000..fc46acfe61 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/utility/edex_static/base/bufrobs/tables/synoptic_land-0_20_005.xml @@ -0,0 +1,69 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + From 1f6c21885dec492442049f3c8045515422aaaedc Mon Sep 17 00:00:00 2001 From: Roger Ferrel Date: Thu, 17 Apr 2014 16:38:57 -0500 Subject: [PATCH 049/188] Issue #3045 Code cleanup for CategoryConfig and ArchiveConfig, Former-commit-id: aa99ca1708590f17f498651e86fe0ef8ea61e1e0 --- .../common/archive/config/ArchiveConfig.java | 22 ++++-- .../common/archive/config/CategoryConfig.java | 52 +++++++++++--- .../archive/ArchiveConfigManagerTest.java | 71 ++++++++++--------- 3 files changed, 96 insertions(+), 49 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/ArchiveConfig.java b/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/ArchiveConfig.java index 8aec78e0e0..cb6012c197 100644 --- a/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/ArchiveConfig.java +++ b/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/ArchiveConfig.java @@ -57,6 +57,7 @@ import javax.xml.bind.annotation.XmlRootElement; * ------------ ---------- ----------- -------------------------- * May 1, 2013 1966 rferrel Initial creation * May 31, 2013 1965 bgonzale Added getCategory(categoryName) + * Apr 17, 2014 3045 rferrel Code cleanup to prevent null pointer. * * * @@ -91,7 +92,7 @@ public class ArchiveConfig implements Comparable { * for the archiver. */ @XmlElement(name = "category") - List categoryList; + List categoryList = new ArrayList(); /** * Constructor. @@ -157,7 +158,11 @@ public class ArchiveConfig implements Comparable { * @param retentionHours */ public void setRetentionHours(int retentionHours) { - this.retentionHours = retentionHours; + if (retentionHours > 0) { + this.retentionHours = retentionHours; + } else { + this.retentionHours = 1; + } } /** @@ -166,7 +171,10 @@ public class ArchiveConfig implements Comparable { * @return */ public List getCategoryList() { - return new ArrayList(categoryList); + List list = new ArrayList( + categoryList.size()); + list.addAll(categoryList); + return list; } /** @@ -188,15 +196,17 @@ public class ArchiveConfig implements Comparable { * @param categoryList */ public void setCategoryList(List categoryList) { - this.categoryList = categoryList; + this.categoryList.clear(); + if (categoryList != null) { + this.categoryList.addAll(categoryList); + } } /** * Check for required entries. */ public boolean isValid() { - return (name != null) && (rootDir != null) && (categoryList != null) - && (categoryList.size() > 0); + return (name != null) && (rootDir != null) && (categoryList.size() > 0); } /* diff --git a/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/CategoryConfig.java b/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/CategoryConfig.java index b22fadc77b..441b8eacf6 100644 --- a/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/CategoryConfig.java +++ b/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/CategoryConfig.java @@ -73,6 +73,7 @@ import javax.xml.bind.annotation.XmlRootElement; * May 1, 2013 1966 rferrel Initial creation * Aug 03, 2013 2224 rferrel Changes to include DataSet. * Jan 09, 2014 2603 rferrel Fix bug in setSelectedDisplayNames + * Apr 17, 2014 3045 rferrel Code cleanup to prevent null pointer. * * * @@ -97,7 +98,7 @@ public class CategoryConfig implements Comparable { private int retentionHours; @XmlElement(name = "dataSet") - private List dataSetList; + private List dataSetList = new ArrayList(); @XmlElement(name = "selectedDisplayName") private final Collection selectedDisplayNames = new TreeSet(); @@ -138,31 +139,66 @@ public class CategoryConfig implements Comparable { * Set the retention hours must be greater then zero. */ public void setRetentionHours(int retentionHours) { - this.retentionHours = retentionHours; + if (retentionHours > 0) { + this.retentionHours = retentionHours; + } else { + this.retentionHours = 1; + } } + /** + * + * @return dataSetList + */ public List getDataSetList() { - return new ArrayList(dataSetList); + List list = new ArrayList( + dataSetList.size()); + list.addAll(dataSetList); + return list; } + /** + * + * @param dataSetList + */ public void setDataSetList(List dataSetList) { - this.dataSetList = dataSetList; + this.dataSetList.clear(); + if (dataSetList != null) { + this.dataSetList.addAll(dataSetList); + } } + /** + * + * @return selectedDisplayNames + */ public Collection getSelectedDisplayNames() { return selectedDisplayNames; } - public void setSelectedDisplayNames( - Collection selectedDisplayNameList) { - selectedDisplayNames.clear(); - selectedDisplayNames.addAll(selectedDisplayNameList); + /** + * + * @param selectedDisplayNames + */ + public void setSelectedDisplayNames(Collection selectedDisplayNames) { + this.selectedDisplayNames.clear(); + if (selectedDisplayNames != null) { + this.selectedDisplayNames.addAll(selectedDisplayNames); + } } + /** + * + * @param displayName + */ public void addSelectedDisplayName(String displayName) { selectedDisplayNames.add(displayName); } + /** + * + * @param displayName + */ public void removeSelectedDisplayName(String displayName) { selectedDisplayNames.remove(displayName); } diff --git a/tests/unit/com/raytheon/uf/common/archive/ArchiveConfigManagerTest.java b/tests/unit/com/raytheon/uf/common/archive/ArchiveConfigManagerTest.java index cb69ee496d..504bb2c941 100644 --- a/tests/unit/com/raytheon/uf/common/archive/ArchiveConfigManagerTest.java +++ b/tests/unit/com/raytheon/uf/common/archive/ArchiveConfigManagerTest.java @@ -51,7 +51,6 @@ import com.raytheon.uf.common.localization.PathManagerFactoryTest; import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.common.util.FileUtil; import com.raytheon.uf.common.util.TestUtil; -import com.raytheon.uf.edex.archive.purge.ArchivePurgeManager; /** * Test ArchiveConfigManager Archive Ingest Purge and Archive Creation. @@ -68,6 +67,7 @@ import com.raytheon.uf.edex.archive.purge.ArchivePurgeManager; * Aug 28, 2013 2299 rferrel purgeExpiredFromArchive now returns number of files purged. * Apr 14, 2014 3023 rferrel Remove archive purge test no long works with implementation * cluster locks. + * Apr 17, 2014 3045 rferrel Commented out test so no longer have dependence ArchivPurgeManger. * * * @@ -555,39 +555,40 @@ public class ArchiveConfigManagerTest { * awips.cluster_task table to perform the locks. */ // @Test - public void testArchiveManagerPurge() throws IOException { - ArchivePurgeManager manager = ArchivePurgeManager.getInstance(); - Collection filesFoundInPurge = new ArrayList(); - int purgeCount = 0; - - for (ArchiveConfig a : manager.getArchives()) { - purgeCount += manager.purgeExpiredFromArchive(a); - } - - // assertEquals( - // - // "The expected number of purged files and number of purge files not the same", - // purgeCount, purgeFiles.size()); - - for (File file : allFiles) { - if (!file.exists()) { - filesFoundInPurge.add(file); - } - } - System.out.println("purgeCount: " + purgeCount + ", pureFiles.size:" - + purgeFiles.size() + ", filesFoundInPurge.size(): " - + filesFoundInPurge.size()); - - for (File file : purgeFiles) { - if (!filesFoundInPurge.contains(file)) { - System.out.println("not purged: " + file.getAbsolutePath()); - } - } - - assertEquals( - "The expected purge files and the files purged are not the same", - createFileNameListRemoveTestDir(purgeFiles), - createFileNameListRemoveTestDir(filesFoundInPurge)); - } + // public void testArchiveManagerPurge() throws IOException { + // ArchivePurgeManager manager = ArchivePurgeManager.getInstance(); + // Collection filesFoundInPurge = new ArrayList(); + // int purgeCount = 0; + // + // for (ArchiveConfig a : manager.getArchives()) { + // purgeCount += manager.purgeExpiredFromArchive(a); + // } + // + // // assertEquals( + // // + // // + // "The expected number of purged files and number of purge files not the same", + // // purgeCount, purgeFiles.size()); + // + // for (File file : allFiles) { + // if (!file.exists()) { + // filesFoundInPurge.add(file); + // } + // } + // System.out.println("purgeCount: " + purgeCount + ", pureFiles.size:" + // + purgeFiles.size() + ", filesFoundInPurge.size(): " + // + filesFoundInPurge.size()); + // + // for (File file : purgeFiles) { + // if (!filesFoundInPurge.contains(file)) { + // System.out.println("not purged: " + file.getAbsolutePath()); + // } + // } + // + // assertEquals( + // "The expected purge files and the files purged are not the same", + // createFileNameListRemoveTestDir(purgeFiles), + // createFileNameListRemoveTestDir(filesFoundInPurge)); + // } } From ed3d88c27a34506a1a9c2eea7bab565ff6d9e13a Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Wed, 16 Apr 2014 17:12:11 -0500 Subject: [PATCH 050/188] Issue #2928: Limit thriftsrv and textdbsrv streams. Change-Id: I5f59d3ac39f7e776f88d65f3d015862968c3e178 Former-commit-id: 96bf7347434344901965bd4510d14edb9bdcd62a --- .../uf/common/serialization/JAXBManager.java | 21 ++- .../serialization/SerializationUtil.java | 22 ++- .../META-INF/MANIFEST.MF | 5 +- .../com/raytheon/uf/common/util/SizeUtil.java | 7 +- .../util/stream/CountingInputStream.java | 175 ++++++++++++++++++ .../util/stream/CountingOutputStream.java | 133 +++++++++++++ .../util/stream/LimitingInputStream.java | 81 ++++++++ .../util/stream/LimitingOutputStream.java | 81 ++++++++ .../META-INF/MANIFEST.MF | 5 +- .../build.properties | 3 +- .../res/spring/auth-common.xml | 1 + .../resources/thriftService.properties | 4 + .../edex/auth/RemoteRequestRouteWrapper.java | 57 +++++- .../.settings/org.eclipse.jdt.core.prefs | 12 +- .../src/com/raytheon/uf/edex/esb/Main.java | 2 +- .../raytheon/uf/edex/esb/camel/Executor.java | 17 +- .../META-INF/MANIFEST.MF | 3 +- .../build.properties | 3 +- .../res/spring/textdbsrv-request.xml | 9 +- .../resources/textdbsrv.properties | 4 + .../uf/edex/textdbsrv/TextDBSrvWrapper.java | 152 +++++++++++++++ 21 files changed, 761 insertions(+), 36 deletions(-) create mode 100644 edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/CountingInputStream.java create mode 100644 edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/CountingOutputStream.java create mode 100644 edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/LimitingInputStream.java create mode 100644 edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/LimitingOutputStream.java create mode 100644 edexOsgi/com.raytheon.uf.edex.auth/resources/thriftService.properties create mode 100644 edexOsgi/com.raytheon.uf.edex.textdbsrv/resources/textdbsrv.properties create mode 100644 edexOsgi/com.raytheon.uf.edex.textdbsrv/src/com/raytheon/uf/edex/textdbsrv/TextDBSrvWrapper.java diff --git a/edexOsgi/com.raytheon.uf.common.serialization/src/com/raytheon/uf/common/serialization/JAXBManager.java b/edexOsgi/com.raytheon.uf.common.serialization/src/com/raytheon/uf/common/serialization/JAXBManager.java index 0fb26ad000..ff2f8fcc6b 100644 --- a/edexOsgi/com.raytheon.uf.common.serialization/src/com/raytheon/uf/common/serialization/JAXBManager.java +++ b/edexOsgi/com.raytheon.uf.common.serialization/src/com/raytheon/uf/common/serialization/JAXBManager.java @@ -57,6 +57,7 @@ import com.raytheon.uf.common.status.UFStatus.Priority; * Aug 18, 2013 #2097 dhladky Allowed extension by OGCJAXBManager * Sep 30, 2013 2361 njensen Refactored for cleanliness * Nov 14, 2013 2361 njensen Added lazy init option, improved unmarshal error message + * Apr 16, 2014 2928 rjpeter Updated marshalToStream to not close the stream. * * * @author chammack @@ -372,13 +373,22 @@ public class JAXBManager { */ public void marshalToXmlFile(Object obj, String filePath, boolean formattedOutput) throws SerializationException { + OutputStream os = null; try { - marshalToStream(obj, new FileOutputStream(new File(filePath)), - formattedOutput); + os = new FileOutputStream(new File(filePath)); + marshalToStream(obj, os, formattedOutput); } catch (SerializationException e) { throw e; } catch (Exception e) { throw new SerializationException(e); + } finally { + if (os != null) { + try { + os.close(); + } catch (IOException e) { + // ignore + } + } } } @@ -419,13 +429,6 @@ public class JAXBManager { if ((msh != null) && (marshallers.size() < QUEUE_SIZE)) { marshallers.add(msh); } - if (out != null) { - try { - out.close(); - } catch (IOException e) { - // ignore - } - } } } diff --git a/edexOsgi/com.raytheon.uf.common.serialization/src/com/raytheon/uf/common/serialization/SerializationUtil.java b/edexOsgi/com.raytheon.uf.common.serialization/src/com/raytheon/uf/common/serialization/SerializationUtil.java index 0dd8df7119..e0bf583d53 100644 --- a/edexOsgi/com.raytheon.uf.common.serialization/src/com/raytheon/uf/common/serialization/SerializationUtil.java +++ b/edexOsgi/com.raytheon.uf.common.serialization/src/com/raytheon/uf/common/serialization/SerializationUtil.java @@ -50,7 +50,7 @@ import com.raytheon.uf.common.util.ServiceLoaderUtil; * Aug 06, 2013 2228 njensen More efficient transformFromThrift(Class, byte[]) * Aug 13, 2013 2169 bkowal Unzip any gzipped data before applying thrift transformations * Oct 01, 2013 2163 njensen Updated calls to JAXBManager - * + * Apr 16, 2014 2928 rjpeter Added jaxbMarshalToStream. * * * @author chammack @@ -176,6 +176,26 @@ public final class SerializationUtil { } + /** + * Convert an instance of a class to an XML representation and write XML to + * a stream. Uses JAXB. + * + * @param obj + * Object to be marshaled + * @param filePath + * Path to the output file + * @throws SerializationException + */ + public static void jaxbMarshalToStream(Object obj, OutputStream os) + throws SerializationException { + try { + getJaxbManager().marshalToStream(obj, os); + } catch (JAXBException e) { + throw new SerializationException(e); + } + + } + /** * Instantiates an object from the XML representation in a File. Uses JAXB. * diff --git a/edexOsgi/com.raytheon.uf.common.util/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.util/META-INF/MANIFEST.MF index 76af75665b..d82760aedd 100644 --- a/edexOsgi/com.raytheon.uf.common.util/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.util/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Utility Plug-in Bundle-SymbolicName: com.raytheon.uf.common.util -Bundle-Version: 1.12.1174.qualifier +Bundle-Version: 1.14.0 Bundle-Vendor: RAYTHEON Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Require-Bundle: org.apache.commons.beanutils;bundle-version="1.8.3", @@ -18,4 +18,5 @@ Export-Package: com.raytheon.uf.common.util, com.raytheon.uf.common.util.header, com.raytheon.uf.common.util.mapping, com.raytheon.uf.common.util.registry, - com.raytheon.uf.common.util.session + com.raytheon.uf.common.util.session, + com.raytheon.uf.common.util.stream diff --git a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SizeUtil.java b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SizeUtil.java index e5ee17286a..76d84fc07d 100644 --- a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SizeUtil.java +++ b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/SizeUtil.java @@ -39,12 +39,15 @@ package com.raytheon.uf.common.util; */ public class SizeUtil { - private static final int BYTES_PER = 1024; private static final String[] REP_PREFIX = new String[] { "B", "kB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB" }; + public static final long BYTES_PER_KB = BYTES_PER; + + public static final long BYTES_PER_MB = BYTES_PER_KB * BYTES_PER; + /** * Transforms a number of bytes to a pretty string based on the total number * of bytes, e.g. B, kB, MB, or GB as fitting. For example: 1000 -> 1000B, @@ -65,7 +68,7 @@ public class SizeUtil { } int reps = 0; - while (n > BYTES_PER && reps < REP_PREFIX.length - 1) { + while ((n > BYTES_PER) && (reps < (REP_PREFIX.length - 1))) { reps++; n /= BYTES_PER; } diff --git a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/CountingInputStream.java b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/CountingInputStream.java new file mode 100644 index 0000000000..102cf06fcb --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/CountingInputStream.java @@ -0,0 +1,175 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.common.util.stream; + +import java.io.IOException; +import java.io.InputStream; + +/** + * Stream that counts the number of bytes that have been read. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 15, 2014 2928       rjpeter     Initial creation
+ * 
+ * 
+ * + * @author rjpeter + * @version 1.0 + */ +public class CountingInputStream extends InputStream { + /** + * Stream to get data from. + */ + protected final InputStream wrappedStream; + + /** + * Number of bytes that have been read. + */ + protected long bytesRead = 0; + + /** + * Wraps the passed {@code InputStream} counting the bytes that are read + * from it. + * + * @param inputStream + */ + public CountingInputStream(InputStream inputStream) { + this.wrappedStream = inputStream; + } + + /* + * (non-Javadoc) + * + * @see java.io.InputStream#read(byte[]) + */ + @Override + public int read(byte[] b) throws IOException { + return read(b, 0, b.length); + } + + /* + * (non-Javadoc) + * + * @see java.io.InputStream#read(byte[], int, int) + */ + @Override + public int read(byte[] b, int off, int len) throws IOException { + int rval = wrappedStream.read(b, off, len); + increaseBytesRead(rval); + return rval; + } + + /* + * (non-Javadoc) + * + * @see java.io.InputStream#skip(long) + */ + @Override + public long skip(long n) throws IOException { + return wrappedStream.skip(n); + } + + /* + * (non-Javadoc) + * + * @see java.io.InputStream#available() + */ + @Override + public int available() throws IOException { + return wrappedStream.available(); + } + + /** + * Closes the underlying stream. Nothing in this stream needs to be closed + * as long as the wrappedStream is closed. + */ + @Override + public void close() throws IOException { + wrappedStream.close(); + } + + /* + * (non-Javadoc) + * + * @see java.io.InputStream#mark(int) + */ + @Override + public synchronized void mark(int readlimit) { + wrappedStream.mark(readlimit); + } + + /* + * (non-Javadoc) + * + * @see java.io.InputStream#reset() + */ + @Override + public synchronized void reset() throws IOException { + wrappedStream.reset(); + } + + /* + * (non-Javadoc) + * + * @see java.io.InputStream#markSupported() + */ + @Override + public boolean markSupported() { + return wrappedStream.markSupported(); + } + + /* + * (non-Javadoc) + * + * @see java.io.InputStream#read() + */ + @Override + public int read() throws IOException { + int rval = wrappedStream.read(); + increaseBytesRead(1); + return rval; + } + + /** + * Method that updates the internal count of the number of bytes read. Also + * useful extension point for special handling based on amount of bytes + * read. + * + * @param bytesRead + * @throws IOException + */ + public void increaseBytesRead(int bytesRead) throws IOException { + this.bytesRead += bytesRead; + } + + /** + * Returns the bytes read so far. + * + * @return + */ + public long getBytesRead() { + return bytesRead; + } +} diff --git a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/CountingOutputStream.java b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/CountingOutputStream.java new file mode 100644 index 0000000000..e7e6a69320 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/CountingOutputStream.java @@ -0,0 +1,133 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.common.util.stream; + +import java.io.IOException; +import java.io.OutputStream; + +/** + * Stream that counts the number of bytes that have been written. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 15, 2014 2928       rjpeter     Initial creation
+ * 
+ * 
+ * + * @author rjpeter + * @version 1.0 + */ +public class CountingOutputStream extends OutputStream { + /** + * Stream to write data to. + */ + protected final OutputStream wrappedStream; + + /** + * Number of bytes that have been written. + */ + protected long bytesWritten = 0; + + /** + * Wraps the passed {@code OutputStream} counting the bytes that are written + * to it. + * + * @param outputStream + */ + public CountingOutputStream(OutputStream outputStream) { + this.wrappedStream = outputStream; + } + + /* + * (non-Javadoc) + * + * @see java.io.OutputStream#write(byte[]) + */ + @Override + public void write(byte[] b) throws IOException { + this.write(b, 0, b.length); + } + + /* + * (non-Javadoc) + * + * @see java.io.OutputStream#write(byte[], int, int) + */ + @Override + public void write(byte[] b, int off, int len) throws IOException { + wrappedStream.write(b, off, len); + increaseBytesWritten(len); + } + + /* + * (non-Javadoc) + * + * @see java.io.OutputStream#flush() + */ + @Override + public void flush() throws IOException { + wrappedStream.flush(); + } + + /** + * Closes the underlying stream. Nothing in this stream needs to be closed + * as long as the wrappedStream is closed. + */ + @Override + public void close() throws IOException { + wrappedStream.close(); + } + + /* + * (non-Javadoc) + * + * @see java.io.OutputStream#write(int) + */ + @Override + public void write(int b) throws IOException { + wrappedStream.write(b); + increaseBytesWritten(1); + } + + /** + * Method that updates the internal count of the number of bytes written. + * Also useful extension point for special handling based on amount of bytes + * written. + * + * @param bytesRead + * @throws IOException + */ + public void increaseBytesWritten(int bytesWritten) throws IOException { + this.bytesWritten += bytesWritten; + } + + /** + * Returns the bytes written so far. + * + * @return + */ + public long getBytesWritten() { + return bytesWritten; + } +} diff --git a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/LimitingInputStream.java b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/LimitingInputStream.java new file mode 100644 index 0000000000..7d54a9c80b --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/LimitingInputStream.java @@ -0,0 +1,81 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.common.util.stream; + +import java.io.IOException; +import java.io.InputStream; + +import com.raytheon.uf.common.util.SizeUtil; + +/** + * Stream that limits the number of bytes that can be read. If limit is reached + * an IOException is thrown. This does not preclude more bytes being read from + * the stream. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 15, 2014 2928       rjpeter     Initial creation
+ * 
+ * 
+ * + * @author rjpeter + * @version 1.0 + */ +public class LimitingInputStream extends CountingInputStream { + /** + * Maximum number of bytes that can be read from the wrapped stream before + * errors are thrown on read. + */ + protected final long maxBytes; + + /** + * Wraps the given {@code InputStream} and will throw IOException once the + * specified number of bytes have been read from the stream. + * + * @param inputStream + * @param maxBytes + */ + public LimitingInputStream(InputStream inputStream, long maxBytes) { + super(inputStream); + this.maxBytes = maxBytes; + } + + /** + * Tracks number of bytes read from wrapped stream. An IOException will be + * thrown if number of bytes read exceeds {@code maxBytes}. + * + * @param bytesRead + * @throws IOException + */ + @Override + public void increaseBytesRead(int bytesRead) throws IOException { + super.increaseBytesRead(bytesRead); + long curBytes = getBytesRead(); + if (curBytes > maxBytes) { + throw new IOException("Maximum number of bytes [" + + SizeUtil.prettyByteSize(maxBytes) + + "] has been exceeded by stream"); + } + } +} diff --git a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/LimitingOutputStream.java b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/LimitingOutputStream.java new file mode 100644 index 0000000000..68a29d84e3 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/stream/LimitingOutputStream.java @@ -0,0 +1,81 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.common.util.stream; + +import java.io.IOException; +import java.io.OutputStream; + +import com.raytheon.uf.common.util.SizeUtil; + +/** + * Stream that limits the number of bytes that can be written. If limit is + * reached an IOException is thrown. This does not preclude more bytes from + * being written to the stream. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 15, 2014 2928       rjpeter     Initial creation
+ * 
+ * 
+ * + * @author rjpeter + * @version 1.0 + */ +public class LimitingOutputStream extends CountingOutputStream { + /** + * Maximum number of bytes that can be written to the wrapped stream before + * errors are thrown on write. + */ + protected final long maxBytes; + + /** + * Wraps the given {@code OutputStream} and will throw IOException once the + * specified number of bytes have been written to the stream. + * + * @param inputStream + * @param maxBytes + */ + public LimitingOutputStream(OutputStream outputStream, long maxBytes) { + super(outputStream); + this.maxBytes = maxBytes; + } + + /** + * Tracks number of bytes written to wrapped stream. An IOException will be + * thrown if number of bytes written exceeds {@code maxBytes}. + * + * @param bytesWritten + * @throws IOException + */ + @Override + public void increaseBytesWritten(int bytesWritten) throws IOException { + super.increaseBytesWritten(bytesWritten); + long curBytes = getBytesWritten(); + if (curBytes > maxBytes) { + throw new IOException("Maximum number of bytes [" + + SizeUtil.prettyByteSize(maxBytes) + + "] has been exceeded by stream"); + } + } +} diff --git a/edexOsgi/com.raytheon.uf.edex.auth/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.auth/META-INF/MANIFEST.MF index f3cf512e01..d69c756259 100644 --- a/edexOsgi/com.raytheon.uf.edex.auth/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.auth/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Auth Plug-in Bundle-SymbolicName: com.raytheon.uf.edex.auth -Bundle-Version: 1.12.1174.qualifier +Bundle-Version: 1.14.0 Bundle-Vendor: RAYTHEON Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Require-Bundle: com.raytheon.uf.common.serialization;bundle-version="1.11.31", @@ -10,7 +10,8 @@ Require-Bundle: com.raytheon.uf.common.serialization;bundle-version="1.11.31", com.raytheon.uf.common.auth;bundle-version="1.0.0", com.raytheon.edex.common;bundle-version="1.11.31", com.raytheon.uf.common.status;bundle-version="1.11.31", - com.raytheon.uf.common.comm;bundle-version="1.12.1174" + com.raytheon.uf.common.comm;bundle-version="1.12.1174", + com.raytheon.uf.common.util Export-Package: com.raytheon.uf.edex.auth, com.raytheon.uf.edex.auth.authentication, com.raytheon.uf.edex.auth.req, diff --git a/edexOsgi/com.raytheon.uf.edex.auth/build.properties b/edexOsgi/com.raytheon.uf.edex.auth/build.properties index 5791d48d5f..ad8d78badb 100644 --- a/edexOsgi/com.raytheon.uf.edex.auth/build.properties +++ b/edexOsgi/com.raytheon.uf.edex.auth/build.properties @@ -2,4 +2,5 @@ source.. = src/ output.. = bin/ bin.includes = META-INF/,\ .,\ - res/ + res/,\ + resources/ diff --git a/edexOsgi/com.raytheon.uf.edex.auth/res/spring/auth-common.xml b/edexOsgi/com.raytheon.uf.edex.auth/res/spring/auth-common.xml index 4edb120166..5a3cc392ae 100644 --- a/edexOsgi/com.raytheon.uf.edex.auth/res/spring/auth-common.xml +++ b/edexOsgi/com.raytheon.uf.edex.auth/res/spring/auth-common.xml @@ -9,6 +9,7 @@ + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.auth/resources/thriftService.properties b/edexOsgi/com.raytheon.uf.edex.auth/resources/thriftService.properties new file mode 100644 index 0000000000..f60a52b7d8 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.auth/resources/thriftService.properties @@ -0,0 +1,4 @@ +# byte limit for input and output streams to the thrift service. +# After specified number of bytes, the stream is rejected to +# prevent jvm OutOfMemory as the client is doing something wrong. +thriftService.byteLimitInMB=100 \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.auth/src/com/raytheon/uf/edex/auth/RemoteRequestRouteWrapper.java b/edexOsgi/com.raytheon.uf.edex.auth/src/com/raytheon/uf/edex/auth/RemoteRequestRouteWrapper.java index 8b9ef16e7d..660e331284 100644 --- a/edexOsgi/com.raytheon.uf.edex.auth/src/com/raytheon/uf/edex/auth/RemoteRequestRouteWrapper.java +++ b/edexOsgi/com.raytheon.uf.edex.auth/src/com/raytheon/uf/edex/auth/RemoteRequestRouteWrapper.java @@ -19,7 +19,10 @@ **/ package com.raytheon.uf.edex.auth; +import java.io.ByteArrayOutputStream; +import java.io.IOException; import java.io.InputStream; +import java.io.OutputStream; import com.raytheon.uf.common.auth.AuthException; import com.raytheon.uf.common.auth.resp.AuthServerErrorResponse; @@ -31,7 +34,10 @@ import com.raytheon.uf.common.serialization.comm.RequestWrapper; import com.raytheon.uf.common.serialization.comm.response.ServerErrorResponse; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.util.ByteArrayOutputStreamPool; import com.raytheon.uf.common.util.SizeUtil; +import com.raytheon.uf.common.util.stream.LimitingInputStream; +import com.raytheon.uf.common.util.stream.LimitingOutputStream; /** * Wrapper for camel route so Serialization exceptions can be caught and @@ -48,6 +54,7 @@ import com.raytheon.uf.common.util.SizeUtil; * reduce garbage objected generated by * camel doing the auto conversion. * Feb 06, 2014 2672 bsteffen Return error when Stream is not consumed. + * Apr 15, 2014 2928 rjpeter Limit data streams read in and written out. * * * @author mschenke @@ -55,20 +62,31 @@ import com.raytheon.uf.common.util.SizeUtil; */ public class RemoteRequestRouteWrapper { - private static final IUFStatusHandler thriftSrvLogger = UFStatus .getNamedHandler("ThriftSrvRequestLogger"); private RemoteRequestServer server; + private int byteLimitInMB; + public byte[] executeThrift(InputStream data) { + /* + * This stream does not need to be closed, Camel will handle closing of + * data + */ + InputStream inputStream = null; + OutputStream outStream = null; + try { long startTime = System.currentTimeMillis(); + inputStream = new LimitingInputStream(data, byteLimitInMB + * SizeUtil.BYTES_PER_MB); Object obj = SerializationUtil.transformFromThrift(Object.class, - data); - int remaining = data.available(); + inputStream); + + int remaining = inputStream.available(); if (remaining == 1) { - int tail = data.read(); + int tail = inputStream.read(); /* * When http proxies are being used there is a single null * character at the end of the message, no need to panic. @@ -89,7 +107,14 @@ public class RemoteRequestRouteWrapper { request = (IServerRequest) obj; } Object rvalObj = server.handleThriftRequest(request); - byte[] rval = SerializationUtil.transformToThrift(rvalObj); + + ByteArrayOutputStream baos = ByteArrayOutputStreamPool + .getInstance().getStream(); + outStream = new LimitingOutputStream(baos, byteLimitInMB + * SizeUtil.BYTES_PER_MB); + + SerializationUtil.transformToThriftUsingStream(rvalObj, outStream); + byte[] rval = baos.toByteArray(); long endTime = System.currentTimeMillis(); StringBuilder sb = new StringBuilder(300); sb.append("Handled ").append(obj.toString()).append(" in ") @@ -119,6 +144,21 @@ public class RemoteRequestRouteWrapper { "Failed to serialize throwable to client", e); return new byte[] {}; } + } finally { + if (inputStream != null) { + try { + inputStream.close(); + } catch (IOException e) { + // ignore + } + } + if (outStream != null) { + try { + outStream.close(); + } catch (IOException e) { + // ignore + } + } } } @@ -130,4 +170,11 @@ public class RemoteRequestRouteWrapper { this.server = server; } + public int getByteLimitInMB() { + return byteLimitInMB; + } + + public void setByteLimitInMB(int byteLimitInMB) { + this.byteLimitInMB = byteLimitInMB; + } } diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/.settings/org.eclipse.jdt.core.prefs b/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/.settings/org.eclipse.jdt.core.prefs index 53584022bd..7341ab1683 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/.settings/org.eclipse.jdt.core.prefs +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/.settings/org.eclipse.jdt.core.prefs @@ -1,7 +1,11 @@ -#Thu Mar 26 10:32:57 CDT 2009 eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 -org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve +org.eclipse.jdt.core.compiler.compliance=1.7 +org.eclipse.jdt.core.compiler.debug.lineNumber=generate +org.eclipse.jdt.core.compiler.debug.localVariable=generate +org.eclipse.jdt.core.compiler.debug.sourceFile=generate org.eclipse.jdt.core.compiler.problem.assertIdentifier=error org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.6 +org.eclipse.jdt.core.compiler.source=1.7 diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/src/com/raytheon/uf/edex/esb/Main.java b/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/src/com/raytheon/uf/edex/esb/Main.java index 02fbcd6644..03208ee50e 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/src/com/raytheon/uf/edex/esb/Main.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel.launcher/src/com/raytheon/uf/edex/esb/Main.java @@ -161,7 +161,7 @@ public class Main { m.invoke(null, new Object[0]); } System.exit(0); - } catch (ClassNotFoundException e) { + } catch (ClassNotFoundException | LinkageError e) { logger.error("Could not load class", e); if (cl != null) { StringBuilder msg = new StringBuilder(1000); diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/Executor.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/Executor.java index 4b6fb4a58a..1931ab7d5b 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/Executor.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/Executor.java @@ -28,6 +28,7 @@ import java.util.Iterator; import java.util.List; import java.util.Properties; import java.util.concurrent.CountDownLatch; +import java.util.concurrent.atomic.AtomicBoolean; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -75,6 +76,10 @@ public class Executor { public static void start() throws Exception { final long t0 = System.currentTimeMillis(); + Thread.currentThread().setName("EDEXMain"); + System.setProperty("System.status", "Starting"); + final AtomicBoolean shutdownContexts = new AtomicBoolean(false); + Runtime.getRuntime().addShutdownHook(new Thread() { @Override public void run() { @@ -87,7 +92,12 @@ public class Executor { .append("\n* EDEX ESB is shutting down *") .append("\n**************************************************"); logger.info(msg.toString()); - ctxMgr.stopContexts(); + if (shutdownContexts.get()) { + ctxMgr.stopContexts(); + } else { + logger.info("Contexts never started, skipping context shutdown"); + } + long t2 = System.currentTimeMillis(); msg.setLength(0); msg.append("\n**************************************************"); @@ -102,9 +112,6 @@ public class Executor { } }); - Thread.currentThread().setName("EDEXMain"); - System.setProperty("System.status", "Starting"); - List xmlFiles = new ArrayList(); List propertiesFiles = new ArrayList(); @@ -166,6 +173,8 @@ public class Executor { ContextManager ctxMgr = (ContextManager) context .getBean("contextManager"); + shutdownContexts.set(true); + // start final routes ctxMgr.startContexts(); diff --git a/edexOsgi/com.raytheon.uf.edex.textdbsrv/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.textdbsrv/META-INF/MANIFEST.MF index eb903b71cf..2e269620fc 100644 --- a/edexOsgi/com.raytheon.uf.edex.textdbsrv/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.textdbsrv/META-INF/MANIFEST.MF @@ -10,7 +10,8 @@ Require-Bundle: com.raytheon.edex.common, org.apache.commons.lang, com.raytheon.uf.edex.decodertools;bundle-version="1.0.0", com.raytheon.uf.common.dataplugin.text, - com.raytheon.uf.common.site;bundle-version="1.12.1152" + com.raytheon.uf.common.site;bundle-version="1.12.1152", + com.raytheon.uf.common.status Export-Package: com.raytheon.uf.edex.services, com.raytheon.uf.edex.services.textdbimpl, com.raytheon.uf.edex.services.textdbsrv diff --git a/edexOsgi/com.raytheon.uf.edex.textdbsrv/build.properties b/edexOsgi/com.raytheon.uf.edex.textdbsrv/build.properties index 5791d48d5f..0aa3712428 100644 --- a/edexOsgi/com.raytheon.uf.edex.textdbsrv/build.properties +++ b/edexOsgi/com.raytheon.uf.edex.textdbsrv/build.properties @@ -2,4 +2,5 @@ source.. = src/ output.. = bin/ bin.includes = META-INF/,\ .,\ - res/ + res/,\ + resources/ \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.textdbsrv/res/spring/textdbsrv-request.xml b/edexOsgi/com.raytheon.uf.edex.textdbsrv/res/spring/textdbsrv-request.xml index 73917fc0e1..4608bb9051 100644 --- a/edexOsgi/com.raytheon.uf.edex.textdbsrv/res/spring/textdbsrv-request.xml +++ b/edexOsgi/com.raytheon.uf.edex.textdbsrv/res/spring/textdbsrv-request.xml @@ -3,6 +3,11 @@ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd"> + + + + + - - - + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.textdbsrv/resources/textdbsrv.properties b/edexOsgi/com.raytheon.uf.edex.textdbsrv/resources/textdbsrv.properties new file mode 100644 index 0000000000..7b3f8ff207 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.textdbsrv/resources/textdbsrv.properties @@ -0,0 +1,4 @@ +# byte limit for input and output streams to the textdb srv. +# After specified number of bytes, the stream is rejected to +# prevent jvm OutOfMemory as the client is doing something wrong. +textdbsrv.byteLimitInMB=10 \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.textdbsrv/src/com/raytheon/uf/edex/textdbsrv/TextDBSrvWrapper.java b/edexOsgi/com.raytheon.uf.edex.textdbsrv/src/com/raytheon/uf/edex/textdbsrv/TextDBSrvWrapper.java new file mode 100644 index 0000000000..1a1a68fd07 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.textdbsrv/src/com/raytheon/uf/edex/textdbsrv/TextDBSrvWrapper.java @@ -0,0 +1,152 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + */ +package com.raytheon.uf.edex.textdbsrv; + +import java.io.ByteArrayOutputStream; +import java.io.IOException; +import java.io.InputStream; +import java.io.OutputStream; + +import com.raytheon.uf.common.message.Message; +import com.raytheon.uf.common.serialization.SerializationUtil; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.util.ByteArrayOutputStreamPool; +import com.raytheon.uf.common.util.SizeUtil; +import com.raytheon.uf.common.util.stream.LimitingInputStream; +import com.raytheon.uf.common.util.stream.LimitingOutputStream; +import com.raytheon.uf.edex.services.TextDBSrv; +import com.raytheon.uf.edex.services.textdbimpl.CommandExecutor; + +/** + * Thin wrapper around TextDBSrv to handle marshalling/unmarshalling and + * limiting of the byte stream. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 15, 2014 2928       rjpeter     Initial creation.
+ * 
+ * 
+ * + * @author rjpeter + * @version 1.0 + */ +public class TextDBSrvWrapper { + private final IUFStatusHandler statusHandler = UFStatus + .getHandler(TextDBSrvWrapper.class); + + /** + * The limit of bytes that we are able to read in without erroring off. + */ + private long byteLimitInMB; + + /** + * TextDbSrv implementation to use. + */ + private TextDBSrv textdbSrv; + + /** + * Unmarshalls the input stream as xml data and sends to textdbsrv for + * processing. + * + * @param is + * @return + */ + public byte[] executeTextDBMessage(InputStream xmlDataStream) { + /* + * This stream does not need to be closed, Camel will handle closing of + * data + */ + InputStream inputStream = null; + Message rval; + + try { + inputStream = new LimitingInputStream(xmlDataStream, byteLimitInMB + * SizeUtil.BYTES_PER_MB); + Message message = SerializationUtil.jaxbUnmarshalFromInputStream( + Message.class, inputStream); + rval = textdbSrv.processMessage(message); + } catch (Throwable e) { + statusHandler + .error("Error occured processing textDbSrv message", e); + rval = CommandExecutor + .createErrorMessage("Error occurred during processing: " + + e.getLocalizedMessage()); + } finally { + if (inputStream != null) { + try { + inputStream.close(); + } catch (IOException e) { + // ignore + } + } + } + + OutputStream outStream = null; + int tries = 0; + + while (tries < 2) { + try { + ByteArrayOutputStream baos = ByteArrayOutputStreamPool + .getInstance().getStream(); + outStream = new LimitingOutputStream(baos, byteLimitInMB + * SizeUtil.BYTES_PER_MB); + SerializationUtil.jaxbMarshalToStream(rval, outStream); + return baos.toByteArray(); + } catch (Exception e) { + statusHandler.error("Error occured marshalling response", e); + tries++; + rval = CommandExecutor + .createErrorMessage("Error occurred during processing: " + + e.getLocalizedMessage()); + } finally { + if (outStream != null) { + try { + outStream.close(); + } catch (IOException e) { + // ignore + } + } + } + } + + return null; + } + + public long getByteLimitInMB() { + return byteLimitInMB; + } + + public void setByteLimitInMB(long byteLimitInMB) { + this.byteLimitInMB = byteLimitInMB; + } + + public TextDBSrv getTextdbSrv() { + return textdbSrv; + } + + public void setTextdbSrv(TextDBSrv textdbSrv) { + this.textdbSrv = textdbSrv; + } +} From 33c3a71df1fee5434db92f96265738549f993b7e Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Fri, 18 Apr 2014 12:48:39 -0500 Subject: [PATCH 051/188] Issue #2726: Add endpoint tracking to MessageProducer Change-Id: I2368b112dd008dba6d699642b0b25abec781927d Former-commit-id: 7ceffcc229824730e54c34a38cf178a2282cd920 --- .../uf/edex/esb/camel/MessageProducer.java | 64 +++++++++++++++---- .../esb/camel/context/ContextManager.java | 5 +- 2 files changed, 54 insertions(+), 15 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/MessageProducer.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/MessageProducer.java index b0a1e9f366..352e92970c 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/MessageProducer.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/MessageProducer.java @@ -31,6 +31,7 @@ import javax.naming.ConfigurationException; import org.apache.camel.AsyncCallback; import org.apache.camel.AsyncProcessor; import org.apache.camel.CamelContext; +import org.apache.camel.Endpoint; import org.apache.camel.Exchange; import org.apache.camel.ExchangePattern; import org.apache.camel.Processor; @@ -43,6 +44,7 @@ import com.raytheon.uf.common.message.IMessage; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.util.Pair; +import com.raytheon.uf.common.util.collections.BoundedMap; import com.raytheon.uf.edex.core.EDEXUtil; import com.raytheon.uf.edex.core.EdexException; import com.raytheon.uf.edex.core.IMessageProducer; @@ -59,7 +61,8 @@ import com.raytheon.uf.edex.esb.camel.context.ContextManager; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Nov 14, 2008 njensen Initial creation. - * Mar 27, 2014 2726 rjpeter Modified for graceful shutdown changes. + * Mar 27, 2014 2726 rjpeter Modified for graceful shutdown changes, + * added tracking of endpoints by context. * * * @author njensen @@ -79,6 +82,8 @@ public class MessageProducer implements IMessageProducer, InterceptStrategy { private final ConcurrentMap contextProducerMap = new ConcurrentHashMap(); + private final ConcurrentMap> contextUriEndpointMap = new ConcurrentHashMap>(); + /** * List of messages waiting to be sent. */ @@ -151,14 +156,16 @@ public class MessageProducer implements IMessageProducer, InterceptStrategy { } try { - ProducerTemplate template = getProducerTemplateForUri(uri); + Pair ctxAndTemplate = getProducerTemplateAndEndpointForUri(uri); Map headers = getHeaders(message); + ProducerTemplate template = ctxAndTemplate.getFirst(); + Endpoint ep = ctxAndTemplate.getSecond(); if (headers != null) { - template.sendBodyAndHeaders(uri, ExchangePattern.InOnly, + template.sendBodyAndHeaders(ep, ExchangePattern.InOnly, message, headers); } else { - template.sendBody(uri, ExchangePattern.InOnly, message); + template.sendBody(ep, ExchangePattern.InOnly, message); } } catch (Exception e) { throw new EdexException("Error sending asynchronous message: " @@ -184,14 +191,16 @@ public class MessageProducer implements IMessageProducer, InterceptStrategy { String uri = getContextData().getEndpointUriForRouteId(endpoint); try { - ProducerTemplate template = getProducerTemplateForUri(uri); + Pair ctxAndTemplate = getProducerTemplateAndEndpointForUri(uri); Map headers = getHeaders(message); + ProducerTemplate template = ctxAndTemplate.getFirst(); + Endpoint ep = ctxAndTemplate.getSecond(); if (headers != null) { - return template.sendBodyAndHeaders(uri, ExchangePattern.OutIn, + return template.sendBodyAndHeaders(ep, ExchangePattern.OutIn, message, headers); } else { - return template.sendBody(uri, ExchangePattern.OutIn, message); + return template.sendBody(ep, ExchangePattern.OutIn, message); } } catch (Exception e) { throw new EdexException("Error sending synchronous message: " @@ -226,14 +235,14 @@ public class MessageProducer implements IMessageProducer, InterceptStrategy { /** * Returns the a producer template for the CamelContext this thread is - * currently a part of. If thread is not part of a context, will use context - * of the uri. If the uri is not registered in this jvm, will use the first - * context available. + * currently a part of and the endpoint for the URI. If thread is not part + * of a context, will use context of the uri. If the uri is not registered + * in this jvm, will use the first context available. * * @return */ - protected ProducerTemplate getProducerTemplateForUri(String uri) - throws ConfigurationException, EdexException { + protected Pair getProducerTemplateAndEndpointForUri( + String uri) throws ConfigurationException, EdexException { CamelContext ctx = currentThreadContext.get(); if (ctx == null) { @@ -273,7 +282,36 @@ public class MessageProducer implements IMessageProducer, InterceptStrategy { tmp = prev; } } - return tmp; + + /* + * Caching endpoint for the uri ourselves. Camel considers various + * endpoints non singleton. So for things like jms-topic, a new + * endpoint is created everytime a message is sent to the URI + * instead of reusing one that was already created. This is in part + * due to the lack of tracking per route. We are ok with caching per + * context as we don't operate on routes individually only contexts + * as a whole. + */ + Map endpointMap = contextUriEndpointMap.get(ctx); + if (endpointMap == null) { + endpointMap = new BoundedMap(100); + Map prev = contextUriEndpointMap.putIfAbsent( + ctx, endpointMap); + if (prev != null) { + endpointMap = prev; + } + } + + Endpoint ep = null; + synchronized (endpointMap) { + ep = endpointMap.get(uri); + if (ep == null) { + ep = ctx.getEndpoint(uri); + endpointMap.put(uri, ep); + } + } + + return new Pair(tmp, ep); } throw new ConfigurationException( diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java index 325d76314e..231a546fda 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java @@ -140,7 +140,7 @@ public class ContextManager implements ApplicationContextAware, * Last time dependency mapping was generated. Used to periodically * regenerate the dependency mappings. */ - private final long lastDependencyTime = 0; + private long lastDependencyTime = 0; public static ContextManager getInstance() { return instance; @@ -219,7 +219,8 @@ public class ContextManager implements ApplicationContextAware, synchronized (this) { long millis = System.currentTimeMillis(); if ((dependencyMapping == null) - || (millis > (lastDependencyTime + TimeUtil.MILLIS_PER_MINUTE))) { + || (millis > (lastDependencyTime + (3 * TimeUtil.MILLIS_PER_MINUTE)))) { + lastDependencyTime = millis; dependencyMapping = new ContextDependencyMapping( getContextData(), suppressExceptions); } From 07dd1a19946dcc0fcbd55a15bad4e067c51e2e14 Mon Sep 17 00:00:00 2001 From: Mike Duff Date: Fri, 18 Apr 2014 13:30:08 -0500 Subject: [PATCH 052/188] Issue #2907 - Fix plugin FQN Change-Id: I56e0001602c05218c881fbee9dc6ca32f9a1c092 Former-commit-id: cc21ff4025a5ea63f6bf211cb6aa49af8193db43 --- .../res/spring/redbook-common.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.redbook/res/spring/redbook-common.xml b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/res/spring/redbook-common.xml index d46d088fc1..dc854e7ed8 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.redbook/res/spring/redbook-common.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/res/spring/redbook-common.xml @@ -8,7 +8,7 @@ - + From 1a43f04b16f73d094332b46fe0f4cd1d83144ff7 Mon Sep 17 00:00:00 2001 From: Brad Gonzales Date: Thu, 17 Apr 2014 08:28:40 -0500 Subject: [PATCH 053/188] Issue #3001 Renamed com.raytheon.edex.plugin.ccfp to com.raytheon.uf.edex.plugin.ccfp. Amend: Updates from peer review. Change-Id: Ib5719f711234005e021bc4d8dec899289d8b447b Former-commit-id: 9374912aeb3e3a642d34a0aec75bcda7c707bcf9 --- .../META-INF/MANIFEST.MF | 10 ++----- .../META-INF/MANIFEST.MF | 2 +- .../com.raytheon.edex.plugin.ccfp/.project | 28 ------------------- .../build.xml | 6 ++-- .../feature.xml | 2 +- .../.classpath | 0 .../.settings/org.eclipse.jdt.core.prefs | 0 .../META-INF/MANIFEST.MF | 6 ++-- .../build.properties | 0 .../com.raytheon.edex.plugin.ccfp.ecl | 0 .../res/spring/ccfp-common.xml | 2 +- .../res/spring/ccfp-ingest.xml | 4 +-- .../uf}/edex/plugin/ccfp/CcfpDecoder.java | 2 +- .../uf}/edex/plugin/ccfp/CcfpSeparator.java | 2 +- .../base/purge/ccfpPurgeRules.xml | 0 .../edex_static/base/distribution/ccfp.xml | 0 .../com.raytheon.uf.docs.datauri/.classpath | 2 +- 17 files changed, 17 insertions(+), 49 deletions(-) delete mode 100644 edexOsgi/com.raytheon.edex.plugin.ccfp/.project rename edexOsgi/{com.raytheon.edex.plugin.ccfp => com.raytheon.uf.edex.plugin.ccfp}/.classpath (100%) rename edexOsgi/{com.raytheon.edex.plugin.ccfp => com.raytheon.uf.edex.plugin.ccfp}/.settings/org.eclipse.jdt.core.prefs (100%) rename edexOsgi/{com.raytheon.edex.plugin.ccfp => com.raytheon.uf.edex.plugin.ccfp}/META-INF/MANIFEST.MF (78%) rename edexOsgi/{com.raytheon.edex.plugin.ccfp => com.raytheon.uf.edex.plugin.ccfp}/build.properties (100%) rename edexOsgi/{com.raytheon.edex.plugin.ccfp => com.raytheon.uf.edex.plugin.ccfp}/com.raytheon.edex.plugin.ccfp.ecl (100%) rename edexOsgi/{com.raytheon.edex.plugin.ccfp => com.raytheon.uf.edex.plugin.ccfp}/res/spring/ccfp-common.xml (89%) rename edexOsgi/{com.raytheon.edex.plugin.ccfp => com.raytheon.uf.edex.plugin.ccfp}/res/spring/ccfp-ingest.xml (91%) rename edexOsgi/{com.raytheon.edex.plugin.ccfp/src/com/raytheon => com.raytheon.uf.edex.plugin.ccfp/src/com/raytheon/uf}/edex/plugin/ccfp/CcfpDecoder.java (99%) rename edexOsgi/{com.raytheon.edex.plugin.ccfp/src/com/raytheon => com.raytheon.uf.edex.plugin.ccfp/src/com/raytheon/uf}/edex/plugin/ccfp/CcfpSeparator.java (99%) rename edexOsgi/{com.raytheon.edex.plugin.ccfp => com.raytheon.uf.edex.plugin.ccfp}/utility/common_static/base/purge/ccfpPurgeRules.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.ccfp => com.raytheon.uf.edex.plugin.ccfp}/utility/edex_static/base/distribution/ccfp.xml (100%) diff --git a/cave/com.raytheon.uf.viz.ccfp/META-INF/MANIFEST.MF b/cave/com.raytheon.uf.viz.ccfp/META-INF/MANIFEST.MF index 2af972442a..fdcfff3df6 100644 --- a/cave/com.raytheon.uf.viz.ccfp/META-INF/MANIFEST.MF +++ b/cave/com.raytheon.uf.viz.ccfp/META-INF/MANIFEST.MF @@ -4,9 +4,10 @@ Bundle-Name: Ccfp Plug-in Bundle-SymbolicName: com.raytheon.uf.viz.ccfp;singleton:=true Bundle-Version: 1.14.0 Bundle-Vendor: RAYTHEON +Require-Bundle: com.raytheon.uf.viz.core Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -Import-Package: com.raytheon.edex.plugin.ccfp, - com.raytheon.uf.common.dataplugin, +Bundle-ActivationPolicy: lazy +Import-Package: com.raytheon.uf.common.dataplugin, com.raytheon.uf.common.dataplugin.ccfp, com.raytheon.uf.common.geospatial, com.raytheon.uf.common.status, @@ -17,14 +18,9 @@ Import-Package: com.raytheon.edex.plugin.ccfp, com.raytheon.uf.viz.core.map, com.raytheon.uf.viz.core.rsc, com.raytheon.uf.viz.core.rsc.capabilities, - com.raytheon.uf.viz.core.status, com.vividsolutions.jts.geom, - org.eclipse.core.runtime, org.eclipse.swt.graphics, org.eclipse.ui.plugin, org.opengis.referencing.crs, org.osgi.framework -Bundle-ActivationPolicy: lazy -Require-Bundle: com.raytheon.uf.viz.core, - org.geotools;bundle-version="2.5.2" Export-Package: com.raytheon.uf.viz.ccfp.rsc diff --git a/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF b/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF index 45f4fd3c8c..ca8042a3a5 100644 --- a/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF +++ b/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF @@ -12,7 +12,7 @@ Require-Bundle: org.eclipse.ui, com.raytheon.viz.alerts, com.raytheon.viz.texteditor, org.geotools, - com.raytheon.edex.plugin.ccfp, + com.raytheon.uf.common.dataplugin.ccfp, com.raytheon.uf.common.pointdata;bundle-version="1.11.7", com.raytheon.uf.common.serialization, com.raytheon.edex.plugin.taf;bundle-version="1.12.1174", diff --git a/edexOsgi/com.raytheon.edex.plugin.ccfp/.project b/edexOsgi/com.raytheon.edex.plugin.ccfp/.project deleted file mode 100644 index e82c70ee1c..0000000000 --- a/edexOsgi/com.raytheon.edex.plugin.ccfp/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - com.raytheon.edex.plugin.ccfp - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - - diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/build.xml index de824ef366..29e01809e2 100644 --- a/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/build.xml +++ b/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/build.xml @@ -66,7 +66,7 @@ - + @@ -314,7 +314,7 @@ - + - + diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml b/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml index 6de1612be3..62015e6f02 100644 --- a/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml +++ b/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml @@ -137,7 +137,7 @@ unpack="false"/> - +
diff --git a/edexOsgi/com.raytheon.edex.plugin.ccfp/res/spring/ccfp-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/res/spring/ccfp-ingest.xml similarity index 91% rename from edexOsgi/com.raytheon.edex.plugin.ccfp/res/spring/ccfp-ingest.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.ccfp/res/spring/ccfp-ingest.xml index 15f6adeddc..5f674367e9 100644 --- a/edexOsgi/com.raytheon.edex.plugin.ccfp/res/spring/ccfp-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/res/spring/ccfp-ingest.xml @@ -3,8 +3,8 @@ xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd"> - - + + diff --git a/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpDecoder.java b/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/src/com/raytheon/uf/edex/plugin/ccfp/CcfpDecoder.java similarity index 99% rename from edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpDecoder.java rename to edexOsgi/com.raytheon.uf.edex.plugin.ccfp/src/com/raytheon/uf/edex/plugin/ccfp/CcfpDecoder.java index 90c920752d..87d3c2dc05 100644 --- a/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpDecoder.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/src/com/raytheon/uf/edex/plugin/ccfp/CcfpDecoder.java @@ -18,7 +18,7 @@ * further licensing information. **/ -package com.raytheon.edex.plugin.ccfp; +package com.raytheon.uf.edex.plugin.ccfp; import java.util.Calendar; import java.util.regex.Matcher; diff --git a/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpSeparator.java b/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/src/com/raytheon/uf/edex/plugin/ccfp/CcfpSeparator.java similarity index 99% rename from edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpSeparator.java rename to edexOsgi/com.raytheon.uf.edex.plugin.ccfp/src/com/raytheon/uf/edex/plugin/ccfp/CcfpSeparator.java index 37326fa041..33ba4ceddb 100644 --- a/edexOsgi/com.raytheon.edex.plugin.ccfp/src/com/raytheon/edex/plugin/ccfp/CcfpSeparator.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/src/com/raytheon/uf/edex/plugin/ccfp/CcfpSeparator.java @@ -18,7 +18,7 @@ * further licensing information. **/ -package com.raytheon.edex.plugin.ccfp; +package com.raytheon.uf.edex.plugin.ccfp; import java.util.ArrayList; import java.util.Iterator; diff --git a/edexOsgi/com.raytheon.edex.plugin.ccfp/utility/common_static/base/purge/ccfpPurgeRules.xml b/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/utility/common_static/base/purge/ccfpPurgeRules.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.ccfp/utility/common_static/base/purge/ccfpPurgeRules.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.ccfp/utility/common_static/base/purge/ccfpPurgeRules.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.ccfp/utility/edex_static/base/distribution/ccfp.xml b/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/utility/edex_static/base/distribution/ccfp.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.ccfp/utility/edex_static/base/distribution/ccfp.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.ccfp/utility/edex_static/base/distribution/ccfp.xml diff --git a/javaUtilities/com.raytheon.uf.docs.datauri/.classpath b/javaUtilities/com.raytheon.uf.docs.datauri/.classpath index a721ea282d..8aebf994a3 100644 --- a/javaUtilities/com.raytheon.uf.docs.datauri/.classpath +++ b/javaUtilities/com.raytheon.uf.docs.datauri/.classpath @@ -6,7 +6,7 @@ - + From 76c5bb67a550393947fa46c9d0f4c9163f51bbd6 Mon Sep 17 00:00:00 2001 From: Ron Anderson Date: Fri, 18 Apr 2014 10:31:16 -0500 Subject: [PATCH 054/188] Issue #3030 Avoid GeoTools Resampler2D infinite recursion. Change-Id: Ie2dc0a66e8f15648b1a76a0d54efb36795223345 Former-commit-id: 123ddd451854e93063f518b0ece746b1109df9d1 --- .../viz/grid/data/ImportRequestableData.java | 99 ++++++++++++++----- .../raytheon/viz/grid/util/CoverageUtils.java | 93 ----------------- .../raytheon/viz/grid/util/RemappedImage.java | 75 -------------- 3 files changed, 73 insertions(+), 194 deletions(-) delete mode 100644 cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/util/RemappedImage.java diff --git a/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/data/ImportRequestableData.java b/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/data/ImportRequestableData.java index a9b36d9315..292d90b86d 100644 --- a/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/data/ImportRequestableData.java +++ b/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/data/ImportRequestableData.java @@ -19,21 +19,28 @@ **/ package com.raytheon.viz.grid.data; +import java.nio.FloatBuffer; import java.util.Arrays; import java.util.List; -import javax.media.jai.Interpolation; +import org.geotools.coverage.grid.GridGeometry2D; -import com.raytheon.uf.common.inventory.data.AbstractRequestableData; -import com.raytheon.uf.common.inventory.data.AliasRequestableData; -import com.raytheon.uf.common.inventory.exception.DataCubeException; import com.raytheon.uf.common.datastorage.Request; import com.raytheon.uf.common.datastorage.records.FloatDataRecord; import com.raytheon.uf.common.datastorage.records.IDataRecord; +import com.raytheon.uf.common.geospatial.data.GeographicDataSource; +import com.raytheon.uf.common.geospatial.interpolation.BicubicInterpolation; +import com.raytheon.uf.common.geospatial.interpolation.GridReprojection; +import com.raytheon.uf.common.geospatial.interpolation.Interpolation; +import com.raytheon.uf.common.geospatial.interpolation.PrecomputedGridReprojection; import com.raytheon.uf.common.gridcoverage.GridCoverage; +import com.raytheon.uf.common.inventory.data.AbstractRequestableData; +import com.raytheon.uf.common.inventory.data.AliasRequestableData; +import com.raytheon.uf.common.inventory.exception.DataCubeException; +import com.raytheon.uf.common.numeric.buffer.FloatBufferWrapper; +import com.raytheon.uf.common.numeric.source.DataSource; import com.raytheon.uf.common.time.DataTime; import com.raytheon.uf.viz.core.exception.VizException; -import com.raytheon.viz.grid.util.CoverageUtils; import com.raytheon.viz.grid.util.SliceUtil; /** @@ -69,6 +76,7 @@ public class ImportRequestableData extends AliasRequestableData { this.dataTime = dataTime; } + @Override public Object getDataValue(Object arg) throws DataCubeException { Request req = Request.ALL; if (arg instanceof Request) { @@ -87,26 +95,26 @@ public class ImportRequestableData extends AliasRequestableData { float w2 = (millis2 - dataTime.getValidTime().getTimeInMillis()) / w1; w1 = 1 - w2; - if (rval instanceof FloatDataRecord - && interp2 instanceof FloatDataRecord) { + if ((rval instanceof FloatDataRecord) + && (interp2 instanceof FloatDataRecord)) { // multiply in place so rval will hold correct value after // calculation interpolate(((FloatDataRecord) rval).getFloatData(), ((FloatDataRecord) interp2).getFloatData(), w2, w1); - } else if (rval instanceof FloatDataRecord[] - && interp2 instanceof FloatDataRecord) { + } else if ((rval instanceof FloatDataRecord[]) + && (interp2 instanceof FloatDataRecord)) { FloatDataRecord[] recs = (FloatDataRecord[]) rval; FloatDataRecord[] recs2 = (FloatDataRecord[]) interp2; - for (int i = 0; i < recs.length && i < recs2.length; i++) { + for (int i = 0; (i < recs.length) && (i < recs2.length); i++) { interpolate(recs[i].getFloatData(), recs2[i].getFloatData(), w2, w1); } } else if (rval instanceof IDataRecord[]) { IDataRecord[] recs = (IDataRecord[]) rval; IDataRecord[] recs2 = (IDataRecord[]) interp2; - for (int i = 0; i < recs.length && i < recs2.length; i++) { - if (recs[i] instanceof FloatDataRecord - && recs2[i] instanceof FloatDataRecord) { + for (int i = 0; (i < recs.length) && (i < recs2.length); i++) { + if ((recs[i] instanceof FloatDataRecord) + && (recs2[i] instanceof FloatDataRecord)) { interpolate(((FloatDataRecord) recs[i]).getFloatData(), ((FloatDataRecord) recs2[i]).getFloatData(), w2, w1); @@ -115,32 +123,27 @@ public class ImportRequestableData extends AliasRequestableData { } } - CoverageUtils covUtil = CoverageUtils.getInstance(); GridCoverage sourceGrid = (GridCoverage) sourceRecord.getSpace(); GridCoverage destGrid = (GridCoverage) getSpace(); - Interpolation interpolation = Interpolation - .getInstance(Interpolation.INTERP_BICUBIC); + Interpolation interpolation = new BicubicInterpolation(); try { if (rval instanceof FloatDataRecord) { - FloatDataRecord fdr = covUtil.remapGrid(sourceGrid, destGrid, - (FloatDataRecord) rval, interpolation) - .getFloatDataRecord(); + FloatDataRecord fdr = remapGrid(sourceGrid, destGrid, + (FloatDataRecord) rval, interpolation); rval = SliceUtil.slice(fdr, req); } else if (rval instanceof FloatDataRecord[]) { FloatDataRecord[] recs = (FloatDataRecord[]) rval; for (int i = 0; i < recs.length; i++) { - FloatDataRecord fdr = covUtil.remapGrid(sourceGrid, - destGrid, recs[i], interpolation) - .getFloatDataRecord(); + FloatDataRecord fdr = remapGrid(sourceGrid, destGrid, + recs[i], interpolation); recs[i] = SliceUtil.slice(fdr, req); } } else if (rval instanceof IDataRecord[]) { IDataRecord[] recs = (IDataRecord[]) rval; for (int i = 0; i < recs.length; i++) { if (recs[i] instanceof FloatDataRecord) { - FloatDataRecord fdr = covUtil.remapGrid(sourceGrid, - destGrid, (FloatDataRecord) recs[i], - interpolation).getFloatDataRecord(); + FloatDataRecord fdr = remapGrid(sourceGrid, destGrid, + (FloatDataRecord) recs[i], interpolation); recs[i] = SliceUtil.slice(fdr, req); } } @@ -152,6 +155,50 @@ public class ImportRequestableData extends AliasRequestableData { return rval; } + /** + * remap gridded data to a new grid coverage + * + * @param sourceGrid + * source grid coverage + * @param destGrid + * destination grid coverage + * @param fdr + * source float data record + * @param interpolation + * interpolation algorithm + * @return destination float data record + * @throws VizException + */ + protected FloatDataRecord remapGrid(GridCoverage sourceGrid, + GridCoverage destGrid, FloatDataRecord fdr, + Interpolation interpolation) throws VizException { + + try { + GridGeometry2D sourceGeometry = sourceGrid.getGridGeometry(); + GridGeometry2D destGeometry = destGrid.getGridGeometry(); + + GridReprojection interp = PrecomputedGridReprojection + .getReprojection(sourceGeometry, destGeometry); + + DataSource source = new GeographicDataSource(FloatBuffer.wrap(fdr + .getFloatData()), sourceGeometry); + + FloatBufferWrapper dest = new FloatBufferWrapper( + destGeometry.getGridRange2D()); + + interp.reprojectedGrid(interpolation, source, dest); + + FloatDataRecord rval = new FloatDataRecord(fdr.getName(), + fdr.getGroup(), dest.getArray(), + destGeometry.getDimension(), new long[] { dest.getNx(), + dest.getNy() }); + + return rval; + } catch (Exception e) { + throw new VizException(e.getLocalizedMessage(), e); + } + } + /** * Performs the following calc in place at arr1: arr1 = arr1 * val1 + arr2 * * val2 @@ -165,7 +212,7 @@ public class ImportRequestableData extends AliasRequestableData { float val2) { if (arr1.length == arr2.length) { for (int i = 0; i < arr1.length; i++) { - arr1[i] = arr1[i] * val1 + arr2[i] * val2; + arr1[i] = (arr1[i] * val1) + (arr2[i] * val2); } } else { // world implodes diff --git a/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/util/CoverageUtils.java b/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/util/CoverageUtils.java index 6bc8201216..883dddfe2c 100644 --- a/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/util/CoverageUtils.java +++ b/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/util/CoverageUtils.java @@ -183,99 +183,6 @@ public class CoverageUtils implements IAlertObserver { } } - public RemappedImage remapGrid(GridCoverage sourceGrid, - GridCoverage destinationGrid, FloatDataRecord inputData, - Interpolation interpolation) throws VizException { - if (sourceGrid.getId().equals(destinationGrid.getId())) { - // we don't need to remap anything. the grids are the same - return new RemappedImage(inputData); - } - - long[] sizes = inputData.getSizes(); - GridCoverage2D inputGC = null; - - if (sizes.length == 2) { - // Map the data into an array - GridCoverageFactory factory = new GridCoverageFactory(); - Envelope inputEnvelope = sourceGrid.getGridGeometry().getEnvelope(); - float[][] dataPoints = new float[(int) sizes[1]][(int) sizes[0]]; - float[] dataVals = inputData.getFloatData(); - int index = 0; - - for (int y = 0; y < sizes[1]; y++) { - for (int x = 0; x < sizes[0]; x++) { - dataPoints[y][x] = dataVals[index++]; - // Switch -999999 to NaN? - if (dataPoints[y][x] == -999999) { - dataPoints[y][x] = Float.NaN; - } - } - } - - inputGC = factory.create("in", dataPoints, inputEnvelope); - } else { - throw new VizException( - "Failed to reproject coverage. FloatData not a 2d array: " - + Arrays.toString(sizes)); - } - - Raster remappedImage = null; - - GridCoverage2D croppedGrid; - - /* - * Check the CRSs to see if they are the same. If they are, then - * reprojection is not necessary, only resampling - */ - if (sourceGrid.getCrsWKT().equals(destinationGrid.getCrsWKT()) - && sourceGrid.getGeometry().getEnvelope() - .equals(destinationGrid.getGeometry().getEnvelope())) { - - float scaleX = (float) ((float) destinationGrid.getNx() / (float) sourceGrid - .getNx()); - float scaleY = (float) ((float) destinationGrid.getNy() / (float) sourceGrid - .getNy()); - - PlanarImage image = scaleGrid(inputGC.getRenderedImage(), scaleX, - scaleY); - remappedImage = image.getData(); - - } else { - GridGeometry2D destGeom = destinationGrid.getGridGeometry(); - // Construct the source grid coverage object - croppedGrid = CoverageUtils.getInstance().cropGrid(inputGC, - destGeom, interpolation); - RenderedImage renderedImage = croppedGrid.getRenderedImage(); - try { - MapUtil.jaiMlibWarpPolynomialTableOpImageWorkAround(renderedImage); - } catch (Exception e) { - throw new VizException( - "Unable to successfully apply JAI workaround!", e); - } - remappedImage = renderedImage.getData(); - } - // Remap the the output data into a Grid2DFloat object - float[] floatData = null; - int ny = destinationGrid.getNy(); - int nx = destinationGrid.getNx(); - floatData = remappedImage.getPixels(remappedImage.getMinX(), - remappedImage.getMinY(), nx, ny, floatData); - - int size = floatData.length; - for (int i = 0; i < size; i++) { - if (Float.isNaN(floatData[i])) { - floatData[i] = -999999; - } - } - - inputData.setFloatData(floatData); - inputData.setSizes(new long[] { nx, ny }); - inputData.setDimension(2); - JAI.getDefaultInstance().getTileCache().flush(); - - return new RemappedImage(inputData, destinationGrid.getGridGeometry()); - } - /** * Resamples the grid to a new resolution using scale values * diff --git a/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/util/RemappedImage.java b/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/util/RemappedImage.java deleted file mode 100644 index ecf355cab6..0000000000 --- a/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/util/RemappedImage.java +++ /dev/null @@ -1,75 +0,0 @@ -package com.raytheon.viz.grid.util; - -import org.geotools.coverage.grid.GridGeometry2D; - -import com.raytheon.uf.common.datastorage.records.FloatDataRecord; - -/** - * Remapped image data and geometry - * - *
- * 
- * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Jun 17, 2010            rgeorge     Initial creation
- * 
- * 
- * - * @author rgeorge - * @version 1.0 - */ -public class RemappedImage { - - private FloatDataRecord floatDataRecord; - - private GridGeometry2D gridGeometry; - - /** - * @param floatDataRecord - */ - public RemappedImage(FloatDataRecord floatDataRecord) { - this.floatDataRecord = floatDataRecord; - } - - /** - * @param inputData - * @param gridGeometry - */ - public RemappedImage(FloatDataRecord floatDataRecord, - GridGeometry2D gridGeometry) { - this.floatDataRecord = floatDataRecord; - this.gridGeometry = gridGeometry; - } - - /** - * @return the floatDataRecord - */ - public FloatDataRecord getFloatDataRecord() { - return floatDataRecord; - } - - /** - * @param floatDataRecord - * the floatDataRecord to set - */ - public void setFloatDataRecord(FloatDataRecord floatDataRecord) { - this.floatDataRecord = floatDataRecord; - } - - /** - * @return the gridGeometry - */ - public GridGeometry2D getGridGeometry() { - return gridGeometry; - } - - /** - * @param gridGeometry - * the gridGeometry to set - */ - public void setGridGeometry(GridGeometry2D gridGeometry) { - this.gridGeometry = gridGeometry; - } - -} From ead90bc794e9aa4b9d925de61aed608782b675fd Mon Sep 17 00:00:00 2001 From: Mike Duff Date: Fri, 18 Apr 2014 15:29:21 -0500 Subject: [PATCH 055/188] Issue #2955 - Made chat invitation dialogs non-modal Change-Id: Ib7294e8149996715b6a247a1e04335dc1a0c7023 Former-commit-id: bb61e3c39d5dabf7e698726f0a093d8cf4f7088a --- .../uf/viz/collaboration/ui/InviteDialog.java | 36 +++++++++---------- 1 file changed, 17 insertions(+), 19 deletions(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/InviteDialog.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/InviteDialog.java index 617e800935..0dd8aacd47 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/InviteDialog.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/InviteDialog.java @@ -67,6 +67,7 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialogBase; * Feb 13, 2014 2751 bclement better types for roomid and inviter * Mar 06, 2014 2848 bclement moved join logic to separate method * Mar 27, 2014 2632 mpduff Set the OK button as the default button. + * Apr 18, 2014 2955 mpduff Make dialog non-modal. * * * @@ -105,18 +106,11 @@ public class InviteDialog extends CaveSWTDialogBase { * * @param parentShell * Parent shell. - * @param title - * Title for the dialog. - * @param labelStr - * Test to put in the label for the message text control. - * @param messageStr - * Message to be displayed. - * @param iconStyle - * Icon style to be displayed. + * @param event + * The invitation event */ public InviteDialog(Shell parentShell, IVenueInvitationEvent event) { - super(parentShell, SWT.DIALOG_TRIM | SWT.APPLICATION_MODAL - | SWT.PRIMARY_MODAL | SWT.SYSTEM_MODAL, CAVE.NONE); + super(parentShell, SWT.DIALOG_TRIM, CAVE.NONE); setText("Session Invitation"); IUser inviter = event.getInviter(); VenueId room = event.getRoomId(); @@ -151,7 +145,7 @@ public class InviteDialog extends CaveSWTDialogBase { @Override protected void initializeComponents(Shell shell) { mainComp = new Composite(shell, SWT.NONE); - GridLayout gl = new GridLayout(2, false); + GridLayout gl = new GridLayout(1, false); gl.marginHeight = 0; gl.marginWidth = 0; gl.horizontalSpacing = 0; @@ -233,10 +227,10 @@ public class InviteDialog extends CaveSWTDialogBase { font = new Font(Display.getCurrent(), fontData[0]); } if (heading) { - gd = new GridData(SWT.LEFT, SWT.NONE, false, false); + gd = new GridData(SWT.LEFT, SWT.CENTER, false, false); label.setFont(font); } else { - gd = new GridData(SWT.LEFT, SWT.NONE, true, true); + gd = new GridData(SWT.LEFT, SWT.CENTER, true, true); gd.widthHint = 300; } label.setLayoutData(gd); @@ -250,16 +244,15 @@ public class InviteDialog extends CaveSWTDialogBase { Composite actionButtonComp = new Composite(mainComp, SWT.NONE); actionButtonComp.setLayout(new GridLayout(2, false)); GridData gd = new GridData(SWT.FILL, SWT.DEFAULT, true, false); - gd.horizontalSpan = 2; actionButtonComp.setLayoutData(gd); int btnWidth = 80; gd = new GridData(SWT.RIGHT, SWT.DEFAULT, true, false); gd.widthHint = btnWidth; - Button okBtn = new Button(actionButtonComp, SWT.PUSH); - okBtn.setText("Join"); - okBtn.setLayoutData(gd); - okBtn.addSelectionListener(new SelectionAdapter() { + Button joinBtn = new Button(actionButtonComp, SWT.PUSH); + joinBtn.setText("Join"); + joinBtn.setLayoutData(gd); + joinBtn.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent se) { String handle = handleText.getText().trim(); @@ -294,7 +287,7 @@ public class InviteDialog extends CaveSWTDialogBase { } }); - this.getShell().setDefaultButton(okBtn); + this.getShell().setDefaultButton(joinBtn); } /** @@ -340,6 +333,11 @@ public class InviteDialog extends CaveSWTDialogBase { } } + /** + * Get the IVenueSession being used. + * + * @return the IVenueSession + */ public IVenueSession getSession() { return session; } From b288bd46de02bfff3abac15841381cd7a12f979e Mon Sep 17 00:00:00 2001 From: Mike Duff Date: Mon, 21 Apr 2014 09:38:07 -0500 Subject: [PATCH 056/188] Issue #3000 - Split bufrmos plugin into common and edex. Change-Id: Id3142b8746cfb28966e7378a522e4db775dfcf37 Former-commit-id: 3fd04e796b7c409c67c06517265648e576852352 --- .../feature.xml | 14 +++---- .../META-INF/MANIFEST.MF | 3 +- .../.classpath | 7 ++++ .../.project | 28 +++++++++++++ .../.settings/org.eclipse.jdt.core.prefs | 7 ++++ .../META-INF/MANIFEST.MF | 16 +++++++ .../build.properties | 4 ++ .../bufrmos/common/BufrMosAvnData.java | 2 +- .../bufrmos/common/BufrMosData.java | 2 +- .../bufrmos/common/BufrMosDataLocation.java | 2 +- .../bufrmos/common/BufrMosEtaData.java | 2 +- .../bufrmos/common/BufrMosGfsData.java | 2 +- .../bufrmos/common/BufrMosHpcData.java | 2 +- .../bufrmos/common/BufrMosLampData.java | 2 +- .../bufrmos/common/BufrMosMrfData.java | 2 +- .../bufrmos/common/BufrMosNgmData.java | 2 +- .../feature.xml | 8 +++- .../.classpath | 0 .../.project | 28 +++++++++++++ .../.settings/org.eclipse.jdt.core.prefs | 0 .../META-INF/MANIFEST.MF | 10 ++--- .../build.properties | 0 .../com.raytheon.edex.plugin.bufrmos.ecl | 0 .../res/bufrtables/AVNBufrTableB | 0 .../res/bufrtables/AVNBufrTableD | 0 .../res/bufrtables/ETABufrTableB | 0 .../res/bufrtables/ETABufrTableD | 0 .../res/bufrtables/GFSBufrTableB | 0 .../res/bufrtables/GFSBufrTableD | 0 .../res/bufrtables/HPCBufrTableB | 0 .../res/bufrtables/HPCBufrTableD | 0 .../res/bufrtables/LAMPBufrTableB | 0 .../res/bufrtables/LAMPBufrTableD | 0 .../res/bufrtables/MRFBufrTableB | 0 .../res/bufrtables/MRFBufrTableD | 0 .../bufrtables/MnemonicDescriptorMapping.txt | 0 .../res/bufrtables/NGMBufrTableB | 0 .../res/bufrtables/NGMBufrTableD | 0 .../res/bufrtables/mosFilenames.properties | 0 .../res/pointdata/bufrmosAVN.xml | 0 .../res/pointdata/bufrmosETA.xml | 0 .../res/pointdata/bufrmosGFS.xml | 0 .../res/pointdata/bufrmosHPC.xml | 0 .../res/pointdata/bufrmosLAMP.xml | 0 .../res/pointdata/bufrmosMRF.xml | 0 .../res/pointdata/bufrmosNGM.xml | 0 .../res/pointdata/bufrmosdb.xml | 0 .../res/spring/bufrmos-common-dataaccess.xml | 0 .../res/spring/bufrmos-common.xml | 42 +++++++++---------- .../res/spring/bufrmos-ingest.xml | 2 +- .../edex/plugin/bufrmos/BufrMosDecoder.java | 6 +-- .../edex/plugin/bufrmos/BufrMosSeparator.java | 6 +-- .../plugin/bufrmos/MOSPointDataState.java | 2 +- .../edex/plugin/bufrmos/dao/BufrMOSDao.java | 20 ++++----- .../bufrmos/dao/BufrMosLocationDao.java | 4 +- .../bufrmos/decoder/BUFRMOSStaticData.java | 4 +- .../bufrmos/decoder/BufrMOSDataAdapter.java | 26 ++++++------ .../bufrmos/decoder/BufrMOSElement.java | 2 +- .../bufrmos/decoder/BufrMosLocationCache.java | 6 +-- .../decoder/MOSDescriptorDelegate.java | 16 +++---- .../base/purge/bufrmosAVNPurgeRules.xml | 0 .../base/purge/bufrmosETAPurgeRules.xml | 0 .../base/purge/bufrmosGFSPurgeRules.xml | 0 .../base/purge/bufrmosHPCPurgeRules.xml | 0 .../base/purge/bufrmosLAMPPurgeRules.xml | 0 .../base/purge/bufrmosMRFPurgeRules.xml | 0 .../base/purge/bufrmosNGMPurgeRules.xml | 0 .../edex_static/base/distribution/bufrmos.xml | 0 68 files changed, 187 insertions(+), 92 deletions(-) create mode 100644 edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/.classpath create mode 100644 edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/.project create mode 100644 edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/.settings/org.eclipse.jdt.core.prefs create mode 100644 edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/META-INF/MANIFEST.MF create mode 100644 edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/build.properties rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin => com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin}/bufrmos/common/BufrMosAvnData.java (98%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin => com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin}/bufrmos/common/BufrMosData.java (98%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin => com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin}/bufrmos/common/BufrMosDataLocation.java (98%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin => com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin}/bufrmos/common/BufrMosEtaData.java (97%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin => com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin}/bufrmos/common/BufrMosGfsData.java (97%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin => com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin}/bufrmos/common/BufrMosHpcData.java (98%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin => com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin}/bufrmos/common/BufrMosLampData.java (97%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin => com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin}/bufrmos/common/BufrMosMrfData.java (97%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin => com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin}/bufrmos/common/BufrMosNgmData.java (97%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/.classpath (100%) create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/.project rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/.settings/org.eclipse.jdt.core.prefs (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/META-INF/MANIFEST.MF (73%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/build.properties (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/com.raytheon.edex.plugin.bufrmos.ecl (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/AVNBufrTableB (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/AVNBufrTableD (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/ETABufrTableB (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/ETABufrTableD (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/GFSBufrTableB (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/GFSBufrTableD (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/HPCBufrTableB (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/HPCBufrTableD (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/LAMPBufrTableB (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/LAMPBufrTableD (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/MRFBufrTableB (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/MRFBufrTableD (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/MnemonicDescriptorMapping.txt (100%) mode change 100755 => 100644 rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/NGMBufrTableB (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/NGMBufrTableD (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/bufrtables/mosFilenames.properties (100%) mode change 100755 => 100644 rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/pointdata/bufrmosAVN.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/pointdata/bufrmosETA.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/pointdata/bufrmosGFS.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/pointdata/bufrmosHPC.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/pointdata/bufrmosLAMP.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/pointdata/bufrmosMRF.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/pointdata/bufrmosNGM.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/pointdata/bufrmosdb.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/spring/bufrmos-common-dataaccess.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/spring/bufrmos-common.xml (56%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/res/spring/bufrmos-ingest.xml (94%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon => com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf}/edex/plugin/bufrmos/BufrMosDecoder.java (95%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon => com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf}/edex/plugin/bufrmos/BufrMosSeparator.java (97%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon => com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf}/edex/plugin/bufrmos/MOSPointDataState.java (98%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon => com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf}/edex/plugin/bufrmos/dao/BufrMOSDao.java (86%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon => com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf}/edex/plugin/bufrmos/dao/BufrMosLocationDao.java (94%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon => com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf}/edex/plugin/bufrmos/decoder/BUFRMOSStaticData.java (99%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon => com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf}/edex/plugin/bufrmos/decoder/BufrMOSDataAdapter.java (92%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon => com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf}/edex/plugin/bufrmos/decoder/BufrMOSElement.java (98%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon => com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf}/edex/plugin/bufrmos/decoder/BufrMosLocationCache.java (93%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos/src/com/raytheon => com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf}/edex/plugin/bufrmos/decoder/MOSDescriptorDelegate.java (85%) mode change 100755 => 100644 rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/utility/common_static/base/purge/bufrmosAVNPurgeRules.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/utility/common_static/base/purge/bufrmosETAPurgeRules.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/utility/common_static/base/purge/bufrmosGFSPurgeRules.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/utility/common_static/base/purge/bufrmosHPCPurgeRules.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/utility/common_static/base/purge/bufrmosLAMPPurgeRules.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/utility/common_static/base/purge/bufrmosMRFPurgeRules.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/utility/common_static/base/purge/bufrmosNGMPurgeRules.xml (100%) rename edexOsgi/{com.raytheon.edex.plugin.bufrmos => com.raytheon.uf.edex.plugin.bufrmos}/utility/edex_static/base/distribution/bufrmos.xml (100%) diff --git a/cave/com.raytheon.uf.viz.dataplugins.feature/feature.xml b/cave/com.raytheon.uf.viz.dataplugins.feature/feature.xml index fca6b25c20..0154d0341b 100644 --- a/cave/com.raytheon.uf.viz.dataplugins.feature/feature.xml +++ b/cave/com.raytheon.uf.viz.dataplugins.feature/feature.xml @@ -198,13 +198,6 @@ version="0.0.0" unpack="false"/> - - + + diff --git a/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF b/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF index ca8042a3a5..92382c4c99 100644 --- a/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF +++ b/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF @@ -41,8 +41,7 @@ Export-Package: com.raytheon.viz.aviation, com.raytheon.viz.aviation.utility, com.raytheon.viz.aviation.xml Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -Import-Package: com.raytheon.edex.plugin.bufrmos.common, - com.raytheon.uf.common.dataplugin.acarssounding, +Import-Package: com.raytheon.uf.common.dataplugin.acarssounding, com.raytheon.uf.common.dataplugin.ccfp, com.raytheon.uf.common.dataplugin.gfe.point, com.raytheon.uf.common.dataplugin.gfe.request, diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/.classpath b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/.classpath new file mode 100644 index 0000000000..ad32c83a78 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/.classpath @@ -0,0 +1,7 @@ + + + + + + + diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/.project b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/.project new file mode 100644 index 0000000000..1e0794ab9d --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/.project @@ -0,0 +1,28 @@ + + + com.raytheon.uf.common.dataplugin.bufrmos + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.pde.ManifestBuilder + + + + + org.eclipse.pde.SchemaBuilder + + + + + + org.eclipse.pde.PluginNature + org.eclipse.jdt.core.javanature + + diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/.settings/org.eclipse.jdt.core.prefs b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 0000000000..c537b63063 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,7 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 +org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.source=1.6 diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/META-INF/MANIFEST.MF new file mode 100644 index 0000000000..a1f2ab3d49 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/META-INF/MANIFEST.MF @@ -0,0 +1,16 @@ +Manifest-Version: 1.0 +Bundle-ManifestVersion: 2 +Bundle-Name: Bufrmos +Bundle-SymbolicName: com.raytheon.uf.common.dataplugin.bufrmos +Bundle-Version: 1.14.0.qualifier +Bundle-Activator: com.raytheon.uf.common.dataplugin.bufrmos.Activator +Bundle-Vendor: RAYTHEON +Require-Bundle: org.eclipse.core.runtime, + org.hibernate;bundle-version="3.5.6", + javax.persistence;bundle-version="1.0.0", + com.raytheon.uf.common.dataplugin;bundle-version="1.12.1174", + com.raytheon.uf.common.serialization;bundle-version="1.12.1174", + com.raytheon.uf.common.pointdata;bundle-version="1.13.0" +Bundle-RequiredExecutionEnvironment: JavaSE-1.6 +Bundle-ActivationPolicy: lazy +Export-Package: com.raytheon.uf.common.dataplugin.bufrmos.common diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/build.properties b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/build.properties new file mode 100644 index 0000000000..34d2e4d2da --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/build.properties @@ -0,0 +1,4 @@ +source.. = src/ +output.. = bin/ +bin.includes = META-INF/,\ + . diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosAvnData.java b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosAvnData.java similarity index 98% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosAvnData.java rename to edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosAvnData.java index 5f75b2fce3..4c1d6897f3 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosAvnData.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosAvnData.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.common; +package com.raytheon.uf.common.dataplugin.bufrmos.common; import javax.persistence.Access; import javax.persistence.AccessType; diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosData.java b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosData.java similarity index 98% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosData.java rename to edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosData.java index 8fde8b7356..aab751eb9f 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosData.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosData.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.common; +package com.raytheon.uf.common.dataplugin.bufrmos.common; import javax.persistence.CascadeType; import javax.persistence.Embedded; diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosDataLocation.java b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosDataLocation.java similarity index 98% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosDataLocation.java rename to edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosDataLocation.java index 1dbb1b5bcf..9c3a0f9cbc 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosDataLocation.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosDataLocation.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.common; +package com.raytheon.uf.common.dataplugin.bufrmos.common; import javax.persistence.Column; import javax.persistence.Entity; diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosEtaData.java b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosEtaData.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosEtaData.java rename to edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosEtaData.java index f6c018ae02..444d812fd0 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosEtaData.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosEtaData.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.common; +package com.raytheon.uf.common.dataplugin.bufrmos.common; import javax.persistence.Access; import javax.persistence.AccessType; diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosGfsData.java b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosGfsData.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosGfsData.java rename to edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosGfsData.java index a7cc5e9b65..6169b279fb 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosGfsData.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosGfsData.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.common; +package com.raytheon.uf.common.dataplugin.bufrmos.common; import javax.persistence.Access; import javax.persistence.AccessType; diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosHpcData.java b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosHpcData.java similarity index 98% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosHpcData.java rename to edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosHpcData.java index 078926c80a..d488ba2163 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosHpcData.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosHpcData.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.common; +package com.raytheon.uf.common.dataplugin.bufrmos.common; import javax.persistence.Access; import javax.persistence.AccessType; diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosLampData.java b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosLampData.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosLampData.java rename to edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosLampData.java index c813aec30a..5ee4132e6e 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosLampData.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosLampData.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.common; +package com.raytheon.uf.common.dataplugin.bufrmos.common; import javax.persistence.Access; import javax.persistence.AccessType; diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosMrfData.java b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosMrfData.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosMrfData.java rename to edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosMrfData.java index aa7694743c..bfdbed4d18 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosMrfData.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosMrfData.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.common; +package com.raytheon.uf.common.dataplugin.bufrmos.common; import javax.persistence.Access; import javax.persistence.AccessType; diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosNgmData.java b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosNgmData.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosNgmData.java rename to edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosNgmData.java index c437682ff4..aaddd2ce4d 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/common/BufrMosNgmData.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/src/com/raytheon/uf/common/dataplugin/bufrmos/common/BufrMosNgmData.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.common; +package com.raytheon.uf.common.dataplugin.bufrmos.common; import javax.persistence.Access; import javax.persistence.AccessType; diff --git a/edexOsgi/com.raytheon.uf.edex.bufr.feature/feature.xml b/edexOsgi/com.raytheon.uf.edex.bufr.feature/feature.xml index a6aeecf588..94154bd099 100644 --- a/edexOsgi/com.raytheon.uf.edex.bufr.feature/feature.xml +++ b/edexOsgi/com.raytheon.uf.edex.bufr.feature/feature.xml @@ -74,7 +74,7 @@ unpack="false"/> + + diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/.classpath b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/.classpath similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/.classpath rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/.classpath diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/.project b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/.project new file mode 100644 index 0000000000..82f093a942 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/.project @@ -0,0 +1,28 @@ + + + com.raytheon.uf.edex.plugin.bufrmos + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.pde.ManifestBuilder + + + + + org.eclipse.pde.SchemaBuilder + + + + + + org.eclipse.pde.PluginNature + org.eclipse.jdt.core.javanature + + diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/.settings/org.eclipse.jdt.core.prefs b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/.settings/org.eclipse.jdt.core.prefs similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/.settings/org.eclipse.jdt.core.prefs rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/.settings/org.eclipse.jdt.core.prefs diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/META-INF/MANIFEST.MF similarity index 73% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/META-INF/MANIFEST.MF rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/META-INF/MANIFEST.MF index 6f37159a96..8809ec3b24 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/META-INF/MANIFEST.MF @@ -1,12 +1,11 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Bufrmos Plug-in -Bundle-SymbolicName: com.raytheon.edex.plugin.bufrmos -Bundle-Version: 1.12.1174.qualifier +Bundle-SymbolicName: com.raytheon.uf.edex.plugin.bufrmos +Bundle-Version: 1.14.0.qualifier Eclipse-RegisterBuddy: com.raytheon.uf.common.serialization Bundle-Vendor: RAYTHEON -Export-Package: com.raytheon.edex.plugin.bufrmos, - com.raytheon.edex.plugin.bufrmos.common +Export-Package: com.raytheon.uf.edex.plugin.bufrmos Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Require-Bundle: com.raytheon.uf.common.dataplugin;bundle-version="1.12.1174", com.raytheon.uf.common.datastorage;bundle-version="1.12.1174", @@ -15,7 +14,8 @@ Require-Bundle: com.raytheon.uf.common.dataplugin;bundle-version="1.12.1174", com.raytheon.uf.edex.core;bundle-version="1.12.1174", com.raytheon.uf.edex.database;bundle-version="1.0.0", com.raytheon.uf.edex.pointdata;bundle-version="1.12.1174", - com.raytheon.uf.edex.decodertools;bundle-version="1.12.1174" + com.raytheon.uf.edex.decodertools;bundle-version="1.12.1174", + com.raytheon.uf.common.dataplugin.bufrmos;bundle-version="1.0.0" Import-Package: com.raytheon.edex.esb, com.raytheon.edex.exception, com.raytheon.edex.plugin, diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/build.properties b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/build.properties similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/build.properties rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/build.properties diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/com.raytheon.edex.plugin.bufrmos.ecl b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/com.raytheon.edex.plugin.bufrmos.ecl similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/com.raytheon.edex.plugin.bufrmos.ecl rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/com.raytheon.edex.plugin.bufrmos.ecl diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/AVNBufrTableB b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/AVNBufrTableB similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/AVNBufrTableB rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/AVNBufrTableB diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/AVNBufrTableD b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/AVNBufrTableD similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/AVNBufrTableD rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/AVNBufrTableD diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/ETABufrTableB b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/ETABufrTableB similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/ETABufrTableB rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/ETABufrTableB diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/ETABufrTableD b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/ETABufrTableD similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/ETABufrTableD rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/ETABufrTableD diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/GFSBufrTableB b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/GFSBufrTableB similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/GFSBufrTableB rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/GFSBufrTableB diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/GFSBufrTableD b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/GFSBufrTableD similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/GFSBufrTableD rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/GFSBufrTableD diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/HPCBufrTableB b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/HPCBufrTableB similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/HPCBufrTableB rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/HPCBufrTableB diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/HPCBufrTableD b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/HPCBufrTableD similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/HPCBufrTableD rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/HPCBufrTableD diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/LAMPBufrTableB b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/LAMPBufrTableB similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/LAMPBufrTableB rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/LAMPBufrTableB diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/LAMPBufrTableD b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/LAMPBufrTableD similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/LAMPBufrTableD rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/LAMPBufrTableD diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/MRFBufrTableB b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/MRFBufrTableB similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/MRFBufrTableB rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/MRFBufrTableB diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/MRFBufrTableD b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/MRFBufrTableD similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/MRFBufrTableD rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/MRFBufrTableD diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/MnemonicDescriptorMapping.txt b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/MnemonicDescriptorMapping.txt old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/MnemonicDescriptorMapping.txt rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/MnemonicDescriptorMapping.txt diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/NGMBufrTableB b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/NGMBufrTableB similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/NGMBufrTableB rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/NGMBufrTableB diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/NGMBufrTableD b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/NGMBufrTableD similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/NGMBufrTableD rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/NGMBufrTableD diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/mosFilenames.properties b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/mosFilenames.properties old mode 100755 new mode 100644 similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/bufrtables/mosFilenames.properties rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/bufrtables/mosFilenames.properties diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosAVN.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosAVN.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosAVN.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosAVN.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosETA.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosETA.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosETA.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosETA.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosGFS.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosGFS.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosGFS.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosGFS.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosHPC.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosHPC.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosHPC.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosHPC.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosLAMP.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosLAMP.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosLAMP.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosLAMP.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosMRF.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosMRF.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosMRF.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosMRF.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosNGM.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosNGM.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosNGM.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosNGM.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosdb.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosdb.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/pointdata/bufrmosdb.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/pointdata/bufrmosdb.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/spring/bufrmos-common-dataaccess.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/spring/bufrmos-common-dataaccess.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/spring/bufrmos-common-dataaccess.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/spring/bufrmos-common-dataaccess.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/spring/bufrmos-common.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/spring/bufrmos-common.xml similarity index 56% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/spring/bufrmos-common.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/spring/bufrmos-common.xml index 4d99090d40..86215648c7 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/spring/bufrmos-common.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/spring/bufrmos-common.xml @@ -4,9 +4,9 @@ - - - + + + @@ -16,9 +16,9 @@ - - - + + + @@ -28,9 +28,9 @@ - - - + + + @@ -40,9 +40,9 @@ - - - + + + @@ -52,9 +52,9 @@ - - - + + + @@ -64,9 +64,9 @@ - - - + + + @@ -76,9 +76,9 @@ - - - + + + diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/spring/bufrmos-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/spring/bufrmos-ingest.xml similarity index 94% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/res/spring/bufrmos-ingest.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/spring/bufrmos-ingest.xml index 85e5c62b3a..bd8b9ce1a1 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/res/spring/bufrmos-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/res/spring/bufrmos-ingest.xml @@ -3,7 +3,7 @@ xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd"> - + diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/BufrMosDecoder.java b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/BufrMosDecoder.java similarity index 95% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/BufrMosDecoder.java rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/BufrMosDecoder.java index e6963d3f55..a42e3cb7dc 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/BufrMosDecoder.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/BufrMosDecoder.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos; +package com.raytheon.uf.edex.plugin.bufrmos; import java.util.ArrayList; import java.util.Date; @@ -29,9 +29,9 @@ import org.apache.commons.logging.LogFactory; import com.raytheon.edex.esb.Headers; import com.raytheon.edex.exception.DecoderException; import com.raytheon.edex.plugin.AbstractDecoder; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosData; -import com.raytheon.edex.plugin.bufrmos.decoder.BufrMOSDataAdapter; import com.raytheon.uf.common.dataplugin.PluginDataObject; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosData; +import com.raytheon.uf.edex.plugin.bufrmos.decoder.BufrMOSDataAdapter; /** * Decoder strategy for BUFR Model Output Statistics data. Most common usage is diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/BufrMosSeparator.java b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/BufrMosSeparator.java similarity index 97% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/BufrMosSeparator.java rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/BufrMosSeparator.java index c158afc1a5..ec061044ca 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/BufrMosSeparator.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/BufrMosSeparator.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos; +package com.raytheon.uf.edex.plugin.bufrmos; import java.util.ArrayList; import java.util.List; @@ -27,14 +27,14 @@ import org.apache.commons.logging.LogFactory; import com.raytheon.edex.esb.Headers; import com.raytheon.edex.plugin.AbstractRecordSeparator; -import com.raytheon.edex.plugin.bufrmos.decoder.BUFRMOSStaticData; -import com.raytheon.edex.plugin.bufrmos.decoder.MOSDescriptorDelegate; import com.raytheon.uf.edex.decodertools.bufr.BUFRDataDocument; import com.raytheon.uf.edex.decodertools.bufr.BUFRDocument; import com.raytheon.uf.edex.decodertools.bufr.BUFRFile; import com.raytheon.uf.edex.decodertools.bufr.descriptors.IDescriptorFactorySelector; import com.raytheon.uf.edex.decodertools.bufr.packets.BUFRSublistPacket; import com.raytheon.uf.edex.decodertools.bufr.packets.IBUFRDataPacket; +import com.raytheon.uf.edex.plugin.bufrmos.decoder.BUFRMOSStaticData; +import com.raytheon.uf.edex.plugin.bufrmos.decoder.MOSDescriptorDelegate; import com.raytheon.uf.edex.wmo.message.WMOHeader; /** diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/MOSPointDataState.java b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/MOSPointDataState.java similarity index 98% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/MOSPointDataState.java rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/MOSPointDataState.java index 75bece537e..8ef85298ea 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/MOSPointDataState.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/MOSPointDataState.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos; +package com.raytheon.uf.edex.plugin.bufrmos; import java.util.HashMap; import java.util.Map; diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/dao/BufrMOSDao.java b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/dao/BufrMOSDao.java similarity index 86% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/dao/BufrMOSDao.java rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/dao/BufrMOSDao.java index fef4a645a6..1241282ffb 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/dao/BufrMOSDao.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/dao/BufrMOSDao.java @@ -17,23 +17,23 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.dao; +package com.raytheon.uf.edex.plugin.bufrmos.dao; import java.io.InputStream; import java.util.List; import javax.xml.bind.JAXBException; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosAvnData; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosData; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosData.MOSType; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosEtaData; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosGfsData; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosHpcData; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosLampData; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosMrfData; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosNgmData; import com.raytheon.uf.common.dataplugin.PluginException; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosAvnData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosEtaData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosGfsData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosHpcData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosLampData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosMrfData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosNgmData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosData.MOSType; import com.raytheon.uf.common.dataplugin.persist.IPersistable; import com.raytheon.uf.common.datastorage.IDataStore; import com.raytheon.uf.common.status.IUFStatusHandler; diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/dao/BufrMosLocationDao.java b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/dao/BufrMosLocationDao.java similarity index 94% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/dao/BufrMosLocationDao.java rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/dao/BufrMosLocationDao.java index 54e700bf3a..f74cf7c95b 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/dao/BufrMosLocationDao.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/dao/BufrMosLocationDao.java @@ -18,9 +18,9 @@ * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.dao; +package com.raytheon.uf.edex.plugin.bufrmos.dao; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosDataLocation; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosDataLocation; import com.raytheon.uf.edex.database.DataAccessLayerException; import com.raytheon.uf.edex.database.dao.CoreDao; import com.raytheon.uf.edex.database.dao.DaoConfig; diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/BUFRMOSStaticData.java b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/BUFRMOSStaticData.java similarity index 99% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/BUFRMOSStaticData.java rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/BUFRMOSStaticData.java index d088cbed49..6fb15c5f72 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/BUFRMOSStaticData.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/BUFRMOSStaticData.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.decoder; +package com.raytheon.uf.edex.plugin.bufrmos.decoder; import java.io.BufferedReader; import java.io.IOException; @@ -33,7 +33,7 @@ import java.util.Properties; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; -import com.raytheon.edex.plugin.bufrmos.BufrMosSeparator; +import com.raytheon.uf.edex.plugin.bufrmos.BufrMosSeparator; import com.raytheon.uf.edex.wmo.message.WMOHeader; /** diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/BufrMOSDataAdapter.java b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/BufrMOSDataAdapter.java similarity index 92% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/BufrMOSDataAdapter.java rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/BufrMOSDataAdapter.java index 1cc6386a9c..dcad46bf22 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/BufrMOSDataAdapter.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/BufrMOSDataAdapter.java @@ -17,24 +17,22 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.decoder; +package com.raytheon.uf.edex.plugin.bufrmos.decoder; import java.util.Calendar; import java.util.Iterator; import java.util.List; -import com.raytheon.edex.plugin.bufrmos.BufrMosSeparator; -import com.raytheon.edex.plugin.bufrmos.MOSPointDataState; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosAvnData; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosData; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosData.MOSType; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosDataLocation; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosEtaData; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosGfsData; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosHpcData; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosLampData; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosMrfData; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosNgmData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosAvnData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosDataLocation; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosEtaData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosGfsData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosHpcData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosLampData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosMrfData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosNgmData; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosData.MOSType; import com.raytheon.uf.common.pointdata.PointDataContainer; import com.raytheon.uf.common.pointdata.PointDataView; import com.raytheon.uf.common.time.DataTime; @@ -46,6 +44,8 @@ import com.raytheon.uf.edex.decodertools.bufr.packets.BUFRNumericPacket; import com.raytheon.uf.edex.decodertools.bufr.packets.IBUFRDataPacket; import com.raytheon.uf.edex.decodertools.core.IDecoderConstants; import com.raytheon.uf.edex.decodertools.time.TimeTools; +import com.raytheon.uf.edex.plugin.bufrmos.BufrMosSeparator; +import com.raytheon.uf.edex.plugin.bufrmos.MOSPointDataState; /** * This class creates a completed Model Output Statistics (MOS) entry from a diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/BufrMOSElement.java b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/BufrMOSElement.java similarity index 98% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/BufrMOSElement.java rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/BufrMOSElement.java index f3734f91d6..9e6eb86d17 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/BufrMOSElement.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/BufrMOSElement.java @@ -17,7 +17,7 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.decoder; +package com.raytheon.uf.edex.plugin.bufrmos.decoder; import com.raytheon.uf.edex.decodertools.bufr.descriptors.BUFRDescriptor; diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/BufrMosLocationCache.java b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/BufrMosLocationCache.java similarity index 93% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/BufrMosLocationCache.java rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/BufrMosLocationCache.java index 5c70f066cb..899be1d363 100644 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/BufrMosLocationCache.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/BufrMosLocationCache.java @@ -17,15 +17,15 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.decoder; +package com.raytheon.uf.edex.plugin.bufrmos.decoder; import java.lang.ref.WeakReference; import java.util.Map; import java.util.WeakHashMap; -import com.raytheon.edex.plugin.bufrmos.common.BufrMosDataLocation; -import com.raytheon.edex.plugin.bufrmos.dao.BufrMosLocationDao; +import com.raytheon.uf.common.dataplugin.bufrmos.common.BufrMosDataLocation; import com.raytheon.uf.edex.database.DataAccessLayerException; +import com.raytheon.uf.edex.plugin.bufrmos.dao.BufrMosLocationDao; /** * TODO Add Description diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/MOSDescriptorDelegate.java b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/MOSDescriptorDelegate.java old mode 100755 new mode 100644 similarity index 85% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/MOSDescriptorDelegate.java rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/MOSDescriptorDelegate.java index 393784197e..77daeff607 --- a/edexOsgi/com.raytheon.edex.plugin.bufrmos/src/com/raytheon/edex/plugin/bufrmos/decoder/MOSDescriptorDelegate.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/src/com/raytheon/uf/edex/plugin/bufrmos/decoder/MOSDescriptorDelegate.java @@ -17,15 +17,15 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.edex.plugin.bufrmos.decoder; +package com.raytheon.uf.edex.plugin.bufrmos.decoder; -import static com.raytheon.edex.plugin.bufrmos.decoder.BUFRMOSStaticData.MODEL_AVN; -import static com.raytheon.edex.plugin.bufrmos.decoder.BUFRMOSStaticData.MODEL_ETA; -import static com.raytheon.edex.plugin.bufrmos.decoder.BUFRMOSStaticData.MODEL_GFS; -import static com.raytheon.edex.plugin.bufrmos.decoder.BUFRMOSStaticData.MODEL_HPC; -import static com.raytheon.edex.plugin.bufrmos.decoder.BUFRMOSStaticData.MODEL_LAMP; -import static com.raytheon.edex.plugin.bufrmos.decoder.BUFRMOSStaticData.MODEL_MRF; -import static com.raytheon.edex.plugin.bufrmos.decoder.BUFRMOSStaticData.MODEL_NGM; +import static com.raytheon.uf.edex.plugin.bufrmos.decoder.BUFRMOSStaticData.MODEL_AVN; +import static com.raytheon.uf.edex.plugin.bufrmos.decoder.BUFRMOSStaticData.MODEL_ETA; +import static com.raytheon.uf.edex.plugin.bufrmos.decoder.BUFRMOSStaticData.MODEL_GFS; +import static com.raytheon.uf.edex.plugin.bufrmos.decoder.BUFRMOSStaticData.MODEL_HPC; +import static com.raytheon.uf.edex.plugin.bufrmos.decoder.BUFRMOSStaticData.MODEL_LAMP; +import static com.raytheon.uf.edex.plugin.bufrmos.decoder.BUFRMOSStaticData.MODEL_MRF; +import static com.raytheon.uf.edex.plugin.bufrmos.decoder.BUFRMOSStaticData.MODEL_NGM; import java.util.HashMap; import java.util.Map; diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosAVNPurgeRules.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosAVNPurgeRules.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosAVNPurgeRules.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosAVNPurgeRules.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosETAPurgeRules.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosETAPurgeRules.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosETAPurgeRules.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosETAPurgeRules.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosGFSPurgeRules.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosGFSPurgeRules.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosGFSPurgeRules.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosGFSPurgeRules.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosHPCPurgeRules.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosHPCPurgeRules.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosHPCPurgeRules.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosHPCPurgeRules.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosLAMPPurgeRules.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosLAMPPurgeRules.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosLAMPPurgeRules.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosLAMPPurgeRules.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosMRFPurgeRules.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosMRFPurgeRules.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosMRFPurgeRules.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosMRFPurgeRules.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosNGMPurgeRules.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosNGMPurgeRules.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosNGMPurgeRules.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/common_static/base/purge/bufrmosNGMPurgeRules.xml diff --git a/edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/edex_static/base/distribution/bufrmos.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/edex_static/base/distribution/bufrmos.xml similarity index 100% rename from edexOsgi/com.raytheon.edex.plugin.bufrmos/utility/edex_static/base/distribution/bufrmos.xml rename to edexOsgi/com.raytheon.uf.edex.plugin.bufrmos/utility/edex_static/base/distribution/bufrmos.xml From 23a71c7f13b8adc409ac06c7c6f452b9f816cb18 Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Fri, 18 Apr 2014 16:39:45 -0500 Subject: [PATCH 057/188] Issue #2681: Update stats aggregate to work in discrete time chunks. Change-Id: I999c6676d5b2464eb8f5467b5155f842c365798e Former-commit-id: 1d18f8f5b3fb1986f197c27b765dabec84343dac --- .../uf/edex/stats/AggregateManager.java | 75 +++++++++++++------ .../raytheon/uf/edex/stats/dao/StatsDao.java | 35 +++++++-- 2 files changed, 82 insertions(+), 28 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.edex.stats/src/com/raytheon/uf/edex/stats/AggregateManager.java b/edexOsgi/com.raytheon.uf.edex.stats/src/com/raytheon/uf/edex/stats/AggregateManager.java index 5536df811d..cc72935dfe 100644 --- a/edexOsgi/com.raytheon.uf.edex.stats/src/com/raytheon/uf/edex/stats/AggregateManager.java +++ b/edexOsgi/com.raytheon.uf.edex.stats/src/com/raytheon/uf/edex/stats/AggregateManager.java @@ -78,6 +78,7 @@ import com.raytheon.uf.edex.stats.util.ConfigLoader; * Mar 27, 2013 1802 bphillip Made jaxb manager static and changed visibility of a method * May 22, 2013 1917 rjpeter Added ability to save raw and aggregate stats, to reclaimSpace every scan call, * and to not pretty print xml grouping information. + * Apr 18, 2014 2681 rjpeter Updated scan to process in distinct chunks of time. * * * @author jsanchez @@ -243,35 +244,65 @@ public class AggregateManager { String type = entry.getKey(); StatisticsEventConfig event = entry.getValue(); List records = null; + Calendar minTime = statsRecordDao.retrieveMinTime(type); - do { - // retrieve stats in blocks of 1000 - records = statsRecordDao.retrieveRecords(timeToProcess, type, - 2000); + if ((minTime != null) && minTime.before(timeToProcess)) { + /* + * process in minute chunks to avoid overwhelming the database + * and having consistent results if stats is down for a period + * of time. + */ + Calendar maxTime = (Calendar) minTime.clone(); + maxTime.add(Calendar.MINUTE, 1); - if (!CollectionUtil.isNullOrEmpty(records)) { - // sort events into time buckets - Map> timeMap = sort( - event, records); + // not checking before since we want before or equal to + while (!maxTime.after(timeToProcess) && maxTime.after(minTime)) { + records = statsRecordDao.retrieveRecords(type, minTime, + maxTime); - for (Map.Entry> timeMapEntry : timeMap - .entrySet()) { - aggregate(event, timeMapEntry.getKey(), - timeMapEntry.getValue()); - } + if (!CollectionUtil.isNullOrEmpty(records)) { + // sort events into time buckets + Map> timeMap = sort( + event, records); - try { - statsRecordDao.deleteAll(records); - } catch (Exception e) { - statusHandler.error("Error deleting stat records", e); - } + for (Map.Entry> timeMapEntry : timeMap + .entrySet()) { + aggregate(event, timeMapEntry.getKey(), + timeMapEntry.getValue()); + } - count += records.size(); - if (event.getRawOfflineRetentionDays() >= 0) { - offline.writeStatsToDisk(event, timeMap); + try { + statsRecordDao.deleteAll(records); + } catch (Exception e) { + statusHandler.error("Error deleting stat records", + e); + } + + count += records.size(); + if (event.getRawOfflineRetentionDays() >= 0) { + offline.writeStatsToDisk(event, timeMap); + } + + // increment to next interval + minTime.add(Calendar.MINUTE, 1); + maxTime.add(Calendar.MINUTE, 1); + } else { + maxTime.add(Calendar.MINUTE, 1); + + // check if at end of interval + if (maxTime.before(timeToProcess)) { + // no records found in interval, find next interval + minTime = statsRecordDao.retrieveMinTime(type); + if (minTime == null) { + break; + } + + maxTime.setTimeInMillis(minTime.getTimeInMillis()); + maxTime.add(Calendar.MINUTE, 1); + } } } - } while (!CollectionUtil.isNullOrEmpty(records)); + } } statsRecordDao.reclaimSpace(); diff --git a/edexOsgi/com.raytheon.uf.edex.stats/src/com/raytheon/uf/edex/stats/dao/StatsDao.java b/edexOsgi/com.raytheon.uf.edex.stats/src/com/raytheon/uf/edex/stats/dao/StatsDao.java index 0093675017..6965d305eb 100644 --- a/edexOsgi/com.raytheon.uf.edex.stats/src/com/raytheon/uf/edex/stats/dao/StatsDao.java +++ b/edexOsgi/com.raytheon.uf.edex.stats/src/com/raytheon/uf/edex/stats/dao/StatsDao.java @@ -42,6 +42,7 @@ import com.raytheon.uf.edex.database.dao.SessionManagedDao; * Aug 21, 2012 jsanchez Initial creation * Mar 18, 2013 1082 bphillip Modified to extend sessionmanagedDao and use spring injection * May 22, 2013 1917 rjpeter Added reclaimSpace. + * Apr 18, 2014 2681 rjpeter Added retrieveMinTime. * * * @author jsanchez @@ -56,7 +57,29 @@ public class StatsDao extends SessionManagedDao { } /** - * Retrieves stat records that has a date before the limit. + * Retrieves the earliest time in the stats table for a given data type. + * + * @param eventType + * @return + * @throws DataAccessLayerException + */ + public Calendar retrieveMinTime(String eventType) + throws DataAccessLayerException { + String hql = "select min(rec.date) from StatsRecord rec where rec.eventType = :eventType"; + List results = this + .executeHQLQuery(hql, "eventType", eventType); + if ((results != null) && !results.isEmpty()) { + Object time = results.get(0); + if (time != null) { + return (Calendar) time; + } + } + + return null; + } + + /** + * Retrieves stat records that has a date in the time range. * * @param limit * @param eventType @@ -66,11 +89,11 @@ public class StatsDao extends SessionManagedDao { * size 0 will be returned. * @throws DataAccessLayerException */ - public List retrieveRecords(Calendar limit, String eventType, - int maxResults) throws DataAccessLayerException { - String hql = "from StatsRecord rec where rec.eventType = :eventType and rec.date < :date order by rec.date asc"; - return this.query(hql, maxResults, "eventType", eventType, "date", - limit); + public List retrieveRecords(String eventType, + Calendar minTime, Calendar maxTime) throws DataAccessLayerException { + String hql = "from StatsRecord rec where rec.eventType = :eventType and rec.date >= :minDate and rec.date < :maxDate order by rec.date asc"; + return this.query(hql, "eventType", eventType, "minDate", minTime, + "maxDate", maxTime); } @Override From 3fb2835dd3627e950d0829b25e73bf9ddde8da80 Mon Sep 17 00:00:00 2001 From: Brad Gonzales Date: Mon, 21 Apr 2014 10:22:44 -0500 Subject: [PATCH 058/188] Issue #3001 Changed ccfp-common.xml to used common. Fixed version in com.raytheon.viz.aviation/META-INF/MANIFEST.MF. Change-Id: I118afa785fff93251950f0f10e72979174de35cb Former-commit-id: cd85b148b6b267779d1fe8b510f14f63c45db77a --- cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF | 2 +- .../com.raytheon.uf.edex.plugin.ccfp/res/spring/ccfp-common.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF b/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF index 92382c4c99..a555b1bdeb 100644 --- a/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF +++ b/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Aviation Plug-in Bundle-SymbolicName: com.raytheon.viz.aviation;singleton:=true -Bundle-Version: 1.12.1174.qualifier +Bundle-Version: 1.14.0 Bundle-Activator: com.raytheon.viz.aviation.activator.Activator Bundle-Vendor: Raytheon Require-Bundle: org.eclipse.ui, diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/res/spring/ccfp-common.xml b/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/res/spring/ccfp-common.xml index 8293eabc68..e6558f9d9b 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/res/spring/ccfp-common.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/res/spring/ccfp-common.xml @@ -5,7 +5,7 @@ - + From 59241fed1d80978d08e8fa2318cfb0ba2ed75197 Mon Sep 17 00:00:00 2001 From: Mike Duff Date: Mon, 21 Apr 2014 10:55:43 -0500 Subject: [PATCH 059/188] Issue #2891 - Fix refresh of Utilization Graph Change-Id: Ib5fb5cb5a367459ab306dc223ab11172310d6cd8 Former-commit-id: acb92afe49544fc0a1d9f5b08c7ec2d2e8016c16 --- .../datadelivery/bandwidth/ui/BandwidthCanvasComp.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/bandwidth/ui/BandwidthCanvasComp.java b/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/bandwidth/ui/BandwidthCanvasComp.java index bfc4c317db..56119d6c18 100644 --- a/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/bandwidth/ui/BandwidthCanvasComp.java +++ b/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/bandwidth/ui/BandwidthCanvasComp.java @@ -105,7 +105,8 @@ import com.raytheon.uf.viz.datadelivery.utils.DataDeliveryUtils; * Dec 17, 2013 2633 mpduff Fix redraw problems.. * Jan 09, 2014 2633 mpduff On resize keep graph at bottom so data are always visible. * Jan 29, 2014 2722 mpduff Changed how graph data are requested. - * Mar 24, 2014 #2951 lvenable Added dispose checks for SWT widgets. + * Mar 24, 2014 2951 lvenable Added dispose checks for SWT widgets. + * Apr 21, 2014 2891 mpduff Add Y Label canvas to redraw on refresh. * * * @author lvenable @@ -1521,10 +1522,11 @@ public class BandwidthCanvasComp extends Composite implements IDialogClosed, redrawImage(CanvasImages.GRAPH); redrawImage(CanvasImages.X_LABEL); redrawImage(CanvasImages.UTILIZATION_GRAPH); + redrawImage(CanvasImages.Y_LABEL); canvasMap.get(CanvasImages.GRAPH).redraw(); canvasMap.get(CanvasImages.X_LABEL).redraw(); - canvasMap.get(CanvasImages.UTILIZATION_GRAPH); - + canvasMap.get(CanvasImages.UTILIZATION_GRAPH).redraw(); + canvasMap.get(CanvasImages.Y_LABEL).redraw(); } }); From 2253938ed5143b612856638cd970c4ba118f7f54 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Mon, 21 Apr 2014 09:42:31 -0500 Subject: [PATCH 060/188] Issue #2984 remove unnecessary dependencies on edex Change-Id: Iad6ebd93d0ec6cd3823042f8ef2653dac963c746 Former-commit-id: 39d1f72292414d008c0899dac616e76c8c0f2512 --- .../META-INF/MANIFEST.MF | 3 +- .../META-INF/MANIFEST.MF | 4 +- .../raytheon/uf/viz/profiler/Activator.java | 87 ------------------- .../META-INF/MANIFEST.MF | 6 +- .../META-INF/MANIFEST.MF | 4 +- .../META-INF/MANIFEST.MF | 3 +- .../META-INF/MANIFEST.MF | 7 +- .../META-INF/MANIFEST.MF | 4 +- .../META-INF/MANIFEST.MF | 6 +- .../META-INF/MANIFEST.MF | 6 +- .../META-INF/MANIFEST.MF | 14 +-- 11 files changed, 27 insertions(+), 117 deletions(-) delete mode 100644 cave/com.raytheon.uf.viz.profiler/src/com/raytheon/uf/viz/profiler/Activator.java diff --git a/cave/com.raytheon.uf.viz.monitor/META-INF/MANIFEST.MF b/cave/com.raytheon.uf.viz.monitor/META-INF/MANIFEST.MF index 5105c66534..37cd2c8833 100644 --- a/cave/com.raytheon.uf.viz.monitor/META-INF/MANIFEST.MF +++ b/cave/com.raytheon.uf.viz.monitor/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: Monitor Plug-in Bundle-SymbolicName: com.raytheon.uf.viz.monitor;singleton:=true Eclipse-RegisterBuddy: com.raytheon.viz.core, com.raytheon.uf.viz.core, com.raytheon.viz.ui, com.raytheon.uf.common.serialization -Bundle-Version: 1.12.1174.qualifier +Bundle-Version: 1.14.0.qualifier Bundle-Activator: com.raytheon.uf.viz.monitor.Activator Bundle-Vendor: RAYTHEON Require-Bundle: org.eclipse.ui, @@ -13,7 +13,6 @@ Require-Bundle: org.eclipse.ui, com.raytheon.viz.ui;bundle-version="1.10.13", org.geotools;bundle-version="2.4.0", com.raytheon.viz.alerts;bundle-version="1.10.13", - com.raytheon.uf.edex.decodertools;bundle-version="1.0.0", com.raytheon.uf.common.monitor;bundle-version="1.11.17", org.apache.commons.lang;bundle-version="2.3.0", com.raytheon.uf.common.wxmath diff --git a/cave/com.raytheon.uf.viz.profiler/META-INF/MANIFEST.MF b/cave/com.raytheon.uf.viz.profiler/META-INF/MANIFEST.MF index 678076a3c4..e6b3331257 100644 --- a/cave/com.raytheon.uf.viz.profiler/META-INF/MANIFEST.MF +++ b/cave/com.raytheon.uf.viz.profiler/META-INF/MANIFEST.MF @@ -3,12 +3,10 @@ Bundle-ManifestVersion: 2 Bundle-Name: Profiler Plug-in Bundle-SymbolicName: com.raytheon.uf.viz.profiler;singleton:=true Eclipse-RegisterBuddy: com.raytheon.viz.core, com.raytheon.uf.viz.core, com.raytheon.viz.ui, com.raytheon.uf.common.serialization -Bundle-Version: 1.12.1174.qualifier -Bundle-Activator: com.raytheon.uf.viz.profiler.Activator +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: RAYTHEON Require-Bundle: com.raytheon.uf.common.pointdata;bundle-version="1.11.9", com.raytheon.viz.pointdata;bundle-version="1.11.4", - com.raytheon.uf.edex.decodertools;bundle-version="1.11.9", com.raytheon.viz.core;bundle-version="1.11.4", com.raytheon.viz.core.graphing;bundle-version="1.11.4", org.eclipse.ui, diff --git a/cave/com.raytheon.uf.viz.profiler/src/com/raytheon/uf/viz/profiler/Activator.java b/cave/com.raytheon.uf.viz.profiler/src/com/raytheon/uf/viz/profiler/Activator.java deleted file mode 100644 index 89e0f294b7..0000000000 --- a/cave/com.raytheon.uf.viz.profiler/src/com/raytheon/uf/viz/profiler/Activator.java +++ /dev/null @@ -1,87 +0,0 @@ -package com.raytheon.uf.viz.profiler; -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ - -import org.eclipse.jface.resource.ImageDescriptor; -import org.eclipse.ui.plugin.AbstractUIPlugin; -import org.osgi.framework.BundleContext; - -/** - * The activator class controls the plug-in life cycle - */ -public class Activator extends AbstractUIPlugin { - - // The plug-in ID - public static final String PLUGIN_ID = "com.raytheon.uf.viz.qpf"; - - // The shared instance - private static Activator plugin; - - /** - * The constructor - */ - public Activator() { - } - - /* - * (non-Javadoc) - * - * @see - * org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext - * ) - */ - public void start(BundleContext context) throws Exception { - super.start(context); - plugin = this; - } - - /* - * (non-Javadoc) - * - * @see - * org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext - * ) - */ - public void stop(BundleContext context) throws Exception { - plugin = null; - super.stop(context); - } - - /** - * Returns the shared instance - * - * @return the shared instance - */ - public static Activator getDefault() { - return plugin; - } - - /** - * Returns an image descriptor for the image file at the given plug-in - * relative path - * - * @param path - * the path - * @return the image descriptor - */ - public static ImageDescriptor getImageDescriptor(String path) { - return imageDescriptorFromPlugin(PLUGIN_ID, path); - } -} diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/META-INF/MANIFEST.MF index 718de7c53a..dd537b6ce7 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Gfe Common Plug-in Bundle-SymbolicName: com.raytheon.uf.common.dataplugin.gfe -Bundle-Version: 1.12.1174.qualifier +Bundle-Version: 1.14.0.qualifier Eclipse-RegisterBuddy: com.raytheon.uf.common.serialization Eclipse-BuddyPolicy: ext Bundle-Vendor: RAYTHEON @@ -43,9 +43,7 @@ Export-Package: com.raytheon.uf.common.dataplugin.gfe, com.raytheon.uf.common.dataplugin.gfe.util, com.raytheon.uf.common.dataplugin.gfe.weather, com.raytheon.uf.common.dataplugin.gfe.weatherelement -Import-Package: com.raytheon.edex.exception, - com.raytheon.edex.util, - com.raytheon.uf.common.activetable, +Import-Package: com.raytheon.uf.common.activetable, com.raytheon.uf.common.dataplugin, com.raytheon.uf.common.dataplugin.annotations, com.raytheon.uf.common.dataplugin.persist, diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.ldadhydro/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.dataplugin.ldadhydro/META-INF/MANIFEST.MF index 6dac136c48..6a1c4a5c4c 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.ldadhydro/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.ldadhydro/META-INF/MANIFEST.MF @@ -2,10 +2,10 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Ldadhydro Bundle-SymbolicName: com.raytheon.uf.common.dataplugin.ldadhydro -Bundle-Version: 1.0.0.qualifier +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: RAYTHEON Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -Eclipse-RegisterBuddy: com.raytheon.edex.common, com.raytheon.uf.common.serialization +Eclipse-RegisterBuddy: com.raytheon.uf.common.serialization Import-Package: com.raytheon.uf.common.dataplugin, com.raytheon.uf.common.dataplugin.annotations, com.raytheon.uf.common.dataplugin.persist, diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.madis/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.dataplugin.madis/META-INF/MANIFEST.MF index fbd2829be3..3f884ff841 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.madis/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.madis/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Madis Bundle-SymbolicName: com.raytheon.uf.common.dataplugin.madis -Bundle-Version: 1.0.0.qualifier +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: RAYTHEON Export-Package: com.raytheon.uf.common.dataplugin.madis Require-Bundle: javax.persistence;bundle-version="1.0.0", @@ -11,7 +11,6 @@ Require-Bundle: javax.persistence;bundle-version="1.0.0", com.raytheon.uf.common.pointdata;bundle-version="1.12.1174", com.raytheon.uf.common.serialization;bundle-version="1.12.1174", javax.measure;bundle-version="1.0.0", - com.raytheon.edex.common;bundle-version="1.12.1174", com.raytheon.uf.common.status;bundle-version="1.12.1174" Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Bundle-ActivationPolicy: lazy diff --git a/edexOsgi/com.raytheon.uf.common.hydro/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.hydro/META-INF/MANIFEST.MF index 8465cd91b8..2a68b96a92 100644 --- a/edexOsgi/com.raytheon.uf.common.hydro/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.hydro/META-INF/MANIFEST.MF @@ -2,12 +2,13 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Hydrocommon Plug-in Bundle-SymbolicName: com.raytheon.uf.common.hydro -Bundle-Version: 1.12.1174.qualifier +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: RAYTHEON Require-Bundle: org.geotools;bundle-version="2.5.2", com.raytheon.uf.common.geospatial;bundle-version="1.11.9", - com.raytheon.edex.common;bundle-version="1.11.9", - com.raytheon.uf.common.dataaccess + com.raytheon.uf.common.dataaccess, + com.raytheon.uf.common.serialization, + com.raytheon.uf.common.util;bundle-version="1.14.0" Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Bundle-ActivationPolicy: lazy Export-Package: com.raytheon.uf.common.hydro.service, diff --git a/edexOsgi/com.raytheon.uf.common.monitor.cpg/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.monitor.cpg/META-INF/MANIFEST.MF index 188a36db67..aa05ee5b3f 100644 --- a/edexOsgi/com.raytheon.uf.common.monitor.cpg/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.monitor.cpg/META-INF/MANIFEST.MF @@ -2,8 +2,8 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Cpg Plug-in Bundle-SymbolicName: com.raytheon.uf.common.monitor.cpg -Bundle-Version: 1.12.1174.qualifier -Eclipse-RegisterBuddy: com.raytheon.edex.common, com.raytheon.uf.common.serialization +Bundle-Version: 1.14.0.qualifier +Eclipse-RegisterBuddy: com.raytheon.uf.common.serialization Bundle-Vendor: RAYTHEON Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Bundle-ActivationPolicy: lazy diff --git a/edexOsgi/com.raytheon.uf.common.mpe/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.mpe/META-INF/MANIFEST.MF index db158e5b93..c181cf4ba4 100644 --- a/edexOsgi/com.raytheon.uf.common.mpe/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.mpe/META-INF/MANIFEST.MF @@ -4,12 +4,12 @@ Bundle-Name: Mpe Plug-in Bundle-SymbolicName: com.raytheon.uf.common.mpe Bundle-Version: 1.14.0.qualifier Bundle-Vendor: RAYTHEON -Require-Bundle: com.raytheon.edex.common, - org.geotools, +Require-Bundle: org.geotools, org.apache.commons.lang, javax.persistence;bundle-version="1.0.0", javax.measure;bundle-version="1.0.0", - com.raytheon.uf.common.serialization.comm + com.raytheon.uf.common.serialization.comm, + com.raytheon.uf.common.serialization Bundle-ActivationPolicy: lazy Export-Package: com.raytheon.uf.common.mpe.constants, com.raytheon.uf.common.mpe.fieldgen, diff --git a/edexOsgi/com.raytheon.uf.common.registry.schemas.ebxml/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.registry.schemas.ebxml/META-INF/MANIFEST.MF index 399a674add..1fd1c3f5a5 100644 --- a/edexOsgi/com.raytheon.uf.common.registry.schemas.ebxml/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.registry.schemas.ebxml/META-INF/MANIFEST.MF @@ -2,18 +2,18 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Ebxml Bundle-SymbolicName: com.raytheon.uf.common.registry.schemas.ebxml -Bundle-Version: 1.0.0.qualifier +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: RAYTHEON Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Require-Bundle: javax.persistence;bundle-version="1.0.0", org.hibernate;bundle-version="1.0.0", com.raytheon.uf.common.serialization;bundle-version="1.12.1174", com.raytheon.uf.common.dataplugin;bundle-version="1.12.1174", - com.raytheon.uf.edex.database;bundle-version="1.0.0", org.apache.commons.cxf;bundle-version="1.0.0", com.raytheon.uf.common.status;bundle-version="1.12.1174", com.raytheon.uf.common.util;bundle-version="1.12.1174", - org.reflections;bundle-version="0.9.9" + org.reflections;bundle-version="0.9.9", + org.springframework;bundle-version="3.1.4" Export-Package: com.raytheon.uf.common.registry, com.raytheon.uf.common.registry.schemas.ebxml.util, com.raytheon.uf.common.registry.schemas.ebxml.util.annotations, diff --git a/edexOsgi/com.raytheon.uf.common.tafqueue/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.tafqueue/META-INF/MANIFEST.MF index 1ada5a101a..eac67c2e03 100644 --- a/edexOsgi/com.raytheon.uf.common.tafqueue/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.tafqueue/META-INF/MANIFEST.MF @@ -2,15 +2,17 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Tafqueue Bundle-SymbolicName: com.raytheon.uf.common.tafqueue -Bundle-Version: 1.0.0.qualifier +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: RAYTHEON Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -Require-Bundle: com.raytheon.edex.common;bundle-version="1.12.1174", - com.raytheon.uf.common.serialization.comm;bundle-version="1.12.1174", +Require-Bundle: com.raytheon.uf.common.serialization.comm, javax.persistence;bundle-version="1.0.0", org.apache.commons.lang;bundle-version="2.3.0", - com.raytheon.uf.common.status;bundle-version="1.12.1174", - com.raytheon.uf.common.auth;bundle-version="1.12.1174" + com.raytheon.uf.common.status, + com.raytheon.uf.common.auth, + com.raytheon.uf.common.serialization, + org.hibernate;bundle-version="3.5.6" Export-Package: com.raytheon.uf.common.tafqueue -Import-Package: com.raytheon.uf.common.localization, +Import-Package: com.raytheon.uf.common.dataplugin.persist, + com.raytheon.uf.common.localization, org.apache.commons.configuration From 043d9c8b8de82edfa02826a812bd40c2a5f7ad87 Mon Sep 17 00:00:00 2001 From: Ben Steffensmeier Date: Fri, 18 Apr 2014 15:58:43 -0500 Subject: [PATCH 061/188] Issue #2947 Improve support for Satellite combined products. Former-commit-id: 891422a7d324514d5ee82d3d195e923c27fc58ef --- .../uf/viz/truecolor/rsc/ChannelInfo.java | 24 ++++++++------ .../truecolor/rsc/TrueColorResourceGroup.java | 18 ++++++++--- .../ext/mosaic/GLMosaicImageExtension.java | 3 +- .../satellite/rsc/SatBestResResourceData.java | 25 +++++++++------ .../satellite/rsc/SatBlendedResourceData.java | 32 +++++++++++++------ .../viz/satellite/rsc/SatResource.java | 11 ++++--- 6 files changed, 73 insertions(+), 40 deletions(-) diff --git a/cave/com.raytheon.uf.viz.truecolor/src/com/raytheon/uf/viz/truecolor/rsc/ChannelInfo.java b/cave/com.raytheon.uf.viz.truecolor/src/com/raytheon/uf/viz/truecolor/rsc/ChannelInfo.java index fe297e7e0d..373da39d85 100644 --- a/cave/com.raytheon.uf.viz.truecolor/src/com/raytheon/uf/viz/truecolor/rsc/ChannelInfo.java +++ b/cave/com.raytheon.uf.viz.truecolor/src/com/raytheon/uf/viz/truecolor/rsc/ChannelInfo.java @@ -37,9 +37,11 @@ import com.raytheon.uf.viz.truecolor.extension.ITrueColorImagingExtension.Channe * * SOFTWARE HISTORY * - * Date Ticket# Engineer Description - * ------------ ---------- ----------- -------------------------- - * Aug 20, 2012 mschenke Initial creation + * Date Ticket# Engineer Description + * ------------- -------- ----------- -------------------------- + * Aug 20, 2012 mschenke Initial creation + * Apr 18, 2014 2947 bsteffen Support unitless data. + * * * * @@ -117,20 +119,22 @@ public class ChannelInfo { * the unit to set */ public void setUnit(Unit unit) { - this.unit = unit; + if (unit == null) { + this.unit = Unit.ONE; + } else { + this.unit = unit; + } } @XmlElement(name = "unit") public void setUnitString(String unit) { if (unit != null) { - this.unit = UnitFormat.getUCUMInstance().parseObject(unit, - new ParsePosition(0)); + setUnit(UnitFormat.getUCUMInstance().parseObject(unit, + new ParsePosition(0))); } else { - this.unit = null; - } - if (this.unit == null) { - this.unit = Unit.ONE; + setUnit(null); } + } public String getUnitString() { diff --git a/cave/com.raytheon.uf.viz.truecolor/src/com/raytheon/uf/viz/truecolor/rsc/TrueColorResourceGroup.java b/cave/com.raytheon.uf.viz.truecolor/src/com/raytheon/uf/viz/truecolor/rsc/TrueColorResourceGroup.java index b2d41c3caa..be4dbb84eb 100644 --- a/cave/com.raytheon.uf.viz.truecolor/src/com/raytheon/uf/viz/truecolor/rsc/TrueColorResourceGroup.java +++ b/cave/com.raytheon.uf.viz.truecolor/src/com/raytheon/uf/viz/truecolor/rsc/TrueColorResourceGroup.java @@ -24,6 +24,8 @@ import java.util.HashMap; import java.util.IdentityHashMap; import java.util.Map; +import javax.measure.converter.UnitConverter; + import org.eclipse.swt.graphics.Rectangle; import org.opengis.referencing.crs.CoordinateReferenceSystem; @@ -63,9 +65,10 @@ import com.vividsolutions.jts.geom.Coordinate; * * SOFTWARE HISTORY * - * Date Ticket# Engineer Description - * ------------ ---------- ----------- -------------------------- - * Aug 6, 2012 mschenke Initial creation + * Date Ticket# Engineer Description + * ------------- -------- ----------- -------------------------- + * Aug 06, 2012 mschenke Initial creation + * Apr 18, 2014 2947 bsteffen Support unitless data. * * * @@ -422,11 +425,16 @@ public class TrueColorResourceGroup extends } else if (object instanceof ColorMapCapability) { ColorMapParameters params = ((ColorMapCapability) object) .getColorMapParameters(); + UnitConverter toDisplay = params + .getColorMapToDisplayConverter(); + if (toDisplay == null) { + toDisplay = UnitConverter.IDENTITY; + } ChannelInfo ci = channelInfoMap.get(params); if (ci != null) { - ci.setRangeMin(params.getDataToDisplayConverter().convert( + ci.setRangeMin(toDisplay.convert( params.getColorMapMin())); - ci.setRangeMax(params.getDataToDisplayConverter().convert( + ci.setRangeMax(toDisplay.convert( params.getColorMapMax())); ci.setUnit(params.getDisplayUnit()); } diff --git a/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/ext/mosaic/GLMosaicImageExtension.java b/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/ext/mosaic/GLMosaicImageExtension.java index c6ce3e9258..9590bd5a5d 100644 --- a/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/ext/mosaic/GLMosaicImageExtension.java +++ b/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/ext/mosaic/GLMosaicImageExtension.java @@ -58,6 +58,7 @@ import com.raytheon.viz.core.gl.images.GLOffscreenColormappedImage; * Nov 20, 2013 2492 bsteffen Mosaic in image units. * Apr 08, 2014 2950 bsteffen Always use float for maximum precision * offscreen so interpolation works. + * Apr 18, 2014 2947 bsteffen Fix mosaicing of datamapped images. * * * @@ -144,7 +145,7 @@ public abstract class GLMosaicImageExtension extends GLColormappedImageExtension.setupDataMapping(gl, (AbstractGLColormappedImage) image, - writeToImage.getDataUnit(), 2, 3); + writeToImage.getDataUnit(), GL.GL_TEXTURE2, GL.GL_TEXTURE3); return image; } // Fall through here, no actual rendering will occur diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatBestResResourceData.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatBestResResourceData.java index 15ee46a043..98b6a37f3c 100644 --- a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatBestResResourceData.java +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatBestResResourceData.java @@ -69,6 +69,7 @@ import com.vividsolutions.jts.geom.Polygon; * Nov 06, 2012 15157 D. Friedman Allow configured inclusion percentage * Oct 10, 2013 2104 mschenke Fixed broken percentage calculation * Mar 11, 2014 2896 bsteffen Limit the number of divisions. + * Apr 18, 2014 2947 bsteffen limit divisions more for pretiled data. * * * @@ -298,7 +299,7 @@ public class SatBestResResourceData extends AbstractRequestableResourceData { } private double getInclusionPercentage(IDescriptor descriptor, - ResourcePair rp, Polygon extent) throws VizException { + ResourcePair rp, Polygon extent) { Double totalPercentage = Double.NaN; GeneralGridGeometry targetGeometry = descriptor.getGridGeometry(); try { @@ -313,10 +314,14 @@ public class SatBestResResourceData extends AbstractRequestableResourceData { request.setDistinct(true); DbQueryResponse response = (DbQueryResponse) ThriftClient .sendRequest(request); + IGridGeometryProvider[] coverages = response.getFieldObjects( + "coverage", IGridGeometryProvider.class); + int maxDivisions = 1024; + if (coverages.length > 0) { + maxDivisions = Math.max(16, maxDivisions / coverages.length); + } Geometry area = null; - for (Map result : response.getResults()) { - IGridGeometryProvider provider = (IGridGeometryProvider) result - .get("coverage"); + for (IGridGeometryProvider provider : coverages) { GridGeometry2D gridGeometry = provider.getGridGeometry(); double envWidth = gridGeometry.getEnvelope().getSpan(0); @@ -326,14 +331,14 @@ public class SatBestResResourceData extends AbstractRequestableResourceData { int xDiv = (int) (envWidth / 100); int yDiv = (int) (envHeight / 100); - if (xDiv * yDiv > 1024 * 1024) { - /* Don't wasste too much time/memory, preserve aspect ratio. */ + if ((long) xDiv * (long) yDiv > maxDivisions * maxDivisions) { + /* Don't waste too much time/memory, preserve aspect ratio. */ if (xDiv > yDiv) { - yDiv = 1024 * yDiv / xDiv; - xDiv = 1024; + yDiv = maxDivisions * yDiv / xDiv; + xDiv = maxDivisions; } else { - xDiv = 1024 * xDiv / yDiv; - yDiv = 1024; + xDiv = maxDivisions * xDiv / yDiv; + yDiv = maxDivisions; } } Geometry intersection = EnvelopeIntersection diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatBlendedResourceData.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatBlendedResourceData.java index 4485d0bb6c..e811b02621 100644 --- a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatBlendedResourceData.java +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatBlendedResourceData.java @@ -58,18 +58,26 @@ import com.raytheon.uf.viz.core.rsc.ResourceList; import com.raytheon.uf.viz.datacube.DataCubeContainer; /** - * TODO Add Description + * Resource which displays multiple Satellite resources simultaneously. It is + * designed for displaying multiple, potentially overlapping regions such as + * the GOES East/West CONUS displays. This resource takes advantage of the + * mosaicing capability to render all teh satellite products into a single + * composite so that alpha changes are consistent for overlapping areas. * *
  * 
  * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Feb 19, 2009            jsanchez     Initial creation
- * Mar 10, 2009        800 jsanchez     Returned a single display name at a time.
- * Mar 20, 2009            jsanchez     Constructed resource with highest frequency first.
- * Apr 29, 2009       2295 jsanchez     Removed the size parameter in getFrequencyIndex().
- * Jun 17, 2009       2493 jsanchez     Displayed both times in CONUS scale.
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Feb 19, 2009           jsanchez    Initial creation
+ * Mar 10, 2009  800      jsanchez    Returned a single display name at a time.
+ * Mar 20, 2009           jsanchez    Constructed resource with highest
+ *                                    frequency first.
+ * Apr 29, 2009  2295     jsanchez    Removed the size parameter in
+ *                                    getFrequencyIndex().
+ * Jun 17, 2009  2493     jsanchez    Displayed both times in CONUS scale.
+ * Apr 18, 2014  2947     bsteffen    Allow resources being blended to omit
+ *                                    load properties.
  * 
  * 
* @@ -147,8 +155,12 @@ public class SatBlendedResourceData extends AbstractRequestableResourceData if (rp.getResource() != null) { rp.setResourceData(rp.getResource().getResourceData()); } - rp.getLoadProperties().overrideCapabilities( - loadProperties.getCapabilities()); + LoadProperties props = rp.getLoadProperties(); + if (props == null) { + props = new LoadProperties(); + rp.setLoadProperties(props); + } + props.overrideCapabilities(loadProperties.getCapabilities()); boolean success = true; try { success = rp.instantiateResource(descriptor, false); diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResource.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResource.java index c4eec82abf..55204a29b3 100644 --- a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResource.java +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResource.java @@ -41,7 +41,6 @@ import com.raytheon.uf.common.colormap.prefs.DataMappingPreferences; import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.common.dataplugin.satellite.SatMapCoverage; import com.raytheon.uf.common.dataplugin.satellite.SatelliteRecord; -import com.raytheon.uf.common.dataplugin.satellite.units.SatelliteUnits; import com.raytheon.uf.common.geospatial.IGridGeometryProvider; import com.raytheon.uf.common.geospatial.ReferencedCoordinate; import com.raytheon.uf.common.style.ParamLevelMatchCriteria; @@ -60,12 +59,14 @@ import com.raytheon.uf.viz.core.IGraphicsTarget; import com.raytheon.uf.viz.core.drawables.ColorMapLoader; import com.raytheon.uf.viz.core.drawables.IRenderable; import com.raytheon.uf.viz.core.drawables.PaintProperties; +import com.raytheon.uf.viz.core.drawables.ext.IImagingExtension.ImageProvider; import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.uf.viz.core.map.IMapDescriptor; import com.raytheon.uf.viz.core.rsc.AbstractPluginDataObjectResource; import com.raytheon.uf.viz.core.rsc.LoadProperties; import com.raytheon.uf.viz.core.rsc.capabilities.AbstractCapability; import com.raytheon.uf.viz.core.rsc.capabilities.ColorMapCapability; +import com.raytheon.uf.viz.core.rsc.capabilities.ImagingCapability; import com.raytheon.viz.satellite.SatelliteConstants; import com.raytheon.viz.satellite.inventory.DerivedSatelliteRecord; import com.raytheon.viz.satellite.tileset.SatDataRetriever; @@ -98,7 +99,7 @@ import com.vividsolutions.jts.geom.Coordinate; * Nov 20, 2013 2492 bsteffen Always get min/max values from style * rules. * Apr 09, 2014 2947 bsteffen Improve flexibility of sat derived - * parameters. + * parameters, implement ImageProvider * * * @@ -106,7 +107,8 @@ import com.vividsolutions.jts.geom.Coordinate; * @version 1 */ public class SatResource extends - AbstractPluginDataObjectResource { + AbstractPluginDataObjectResource + implements ImageProvider { /** String id to look for satellite-provided data values */ public static final String SATELLITE_DATA_INTERROGATE_ID = "satelliteDataValue"; @@ -268,7 +270,7 @@ public class SatResource extends private void initializeFirstFrame(SatelliteRecord record) throws VizException { - SatelliteUnits.register(); + getCapability(ImagingCapability.class).setProvider(this); ColorMapParameters colorMapParameters = null; IColorMap colorMap = null; String cmName = null; @@ -463,6 +465,7 @@ public class SatResource extends record.getCreatingEntity()); } + @Override public List getImages(IGraphicsTarget target, PaintProperties paintProps) throws VizException { SatRenderable renderable = (SatRenderable) getOrCreateRenderable(paintProps From 811f05f164d77349954e1dcdfa3679b5de6acf12 Mon Sep 17 00:00:00 2001 From: Ron Anderson Date: Mon, 21 Apr 2014 13:03:50 -0500 Subject: [PATCH 062/188] Issue #2998 Fixed null pointer in AttributeViewer. Improved sizing of displayAttributes. Change-Id: I40b3dc486a713f6ba6ce6f5075ffce1eb6555f93 Former-commit-id: 0fac12a4f17de189a88e6dd4415f6364afc4f459 --- .../gisdatastore/rsc/DataStoreResource.java | 52 ++++++++++++------- .../uf/viz/gisdatastore/rsc/ReloadJob.java | 7 +++ .../viz/gisdatastore/ui/AttributeViewer.java | 8 ++- 3 files changed, 42 insertions(+), 25 deletions(-) diff --git a/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/DataStoreResource.java b/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/DataStoreResource.java index c34365a018..87ee8cc4f7 100644 --- a/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/DataStoreResource.java +++ b/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/DataStoreResource.java @@ -26,6 +26,7 @@ import java.util.Collections; import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.Set; import org.eclipse.core.runtime.ListenerList; import org.eclipse.jface.preference.IPreferenceStore; @@ -120,6 +121,7 @@ import com.vividsolutions.jts.geom.Point; * Mar 11, 2014 #2718 randerso Changes for GeoTools 10.5 * Mar 25, 2014 #2664 randerso Added support for non-WGS84 shape files * Apr 14, 2014 #2664 randerso Fix NullPointerException when no .prj file present + * Apr 21, 2014 #2998 randerso Stored types of attributes to be used in the AttributeViewer * * * @@ -452,11 +454,11 @@ public class DataStoreResource extends */ private TimeRange timeRange; - private String[] attributeNames; + private Map> attrTypeMap; private Object[][] attributes; - private Map displayAttributes; + protected Map displayAttributes; protected IWireframeShape outlineShape; @@ -578,11 +580,11 @@ public class DataStoreResource extends loadDataStore(); - getCapability(LabelableCapability.class).setAvailableLabelFields( - this.attributeNames); + String[] names = this.getAttributeNames(); + getCapability(LabelableCapability.class).setAvailableLabelFields(names); getCapability(ShadeableCapability.class).setAvailableShadingFields( - this.attributeNames); + names); IPreferenceStore prefs = Activator.getDefault().getPreferenceStore(); if (this.timeRange != null) { @@ -625,26 +627,22 @@ public class DataStoreResource extends List attrDesc = schema .getAttributeDescriptors(); - // TODO: Should ID be in attributes and if so do we need a more - // unique attribute name if (attrDesc == null) { - attributeNames = new String[] { ID_ATTRIBUTE_NAME }; + attrTypeMap = new HashMap>(1); + attrTypeMap.put(ID_ATTRIBUTE_NAME, Integer.class); } else { - List names = new ArrayList(attrDesc.size()); - names.add(ID_ATTRIBUTE_NAME); + attrTypeMap = new HashMap>(attrDesc.size(), + 1.0f); + attrTypeMap.put(ID_ATTRIBUTE_NAME, Integer.class); for (AttributeDescriptor at : attrDesc) { Class atType = at.getType().getBinding(); if (!Geometry.class.isAssignableFrom(atType)) { - names.add(at.getLocalName()); + attrTypeMap.put(at.getLocalName(), atType); } } - attributeNames = names.toArray(new String[names.size()]); } - displayAttributes = new HashMap( - (int) Math.ceil(attributeNames.length / 0.75f), 0.75f); - timer.stop(); perfLog.logDuration("loadDataStore", timer.getElapsedTime()); } catch (Exception e) { @@ -694,7 +692,9 @@ public class DataStoreResource extends featureCollection = featureSource.getFeatures(query); int size = featureCollection.size(); - attributes = new Object[size][attributeNames.length]; + Set attributeNames = attrTypeMap.keySet(); + attributes = new Object[size][attributeNames.size()]; + featureIterator = featureCollection.features(); int i = 0; while (featureIterator.hasNext()) { @@ -708,9 +708,10 @@ public class DataStoreResource extends incomingToLatLon)); attributes[index][0] = id; - for (int j = 1; j < attributeNames.length; j++) { - Object attr = f.getAttribute(attributeNames[j]); - attributes[index][j] = attr; + int j = 1; + for (String attrName : attributeNames) { + Object attr = f.getAttribute(attrName); + attributes[index][j++] = attr; } } } catch (Exception e) { @@ -1266,7 +1267,18 @@ public class DataStoreResource extends * @return the attribute names */ public String[] getAttributeNames() { - return attributeNames; + return attrTypeMap.keySet().toArray(new String[attrTypeMap.size()]); + } + + /** + * Get Java type of an attribute + * + * @param attributeName + * name of the desired attribute + * @return the type + */ + public Class getAttributeType(String attributeName) { + return attrTypeMap.get(attributeName); } /** diff --git a/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/ReloadJob.java b/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/ReloadJob.java index 697f839864..6948a7b57e 100644 --- a/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/ReloadJob.java +++ b/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/ReloadJob.java @@ -59,6 +59,7 @@ import com.vividsolutions.jts.geom.Point; * Feb 18, 2014 #2819 randerso Removed unnecessary clones of geometries * Mar 11, 2014 #2718 randerso Changes for GeoTools 10.5 * Mar 25, 2014 #2664 randerso Added support for non-WGS84 shape files + * Apr 21, 2014 #2998 randerso Make a better stab at sizing displayAttributes correctly * * * @@ -289,6 +290,12 @@ class ReloadJob extends Job { featureCollection = featureSource.getFeatures(query); featureIterator = featureCollection.features(); + if (req.rsc.displayAttributes == null) { + req.rsc.displayAttributes = new HashMap( + (int) Math.ceil(featureCollection.size() / 0.75f), + 0.75f); + } + // TODO: do we need to implement the GeometryCache/gidMap // stuff like in DbMapResource? diff --git a/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/ui/AttributeViewer.java b/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/ui/AttributeViewer.java index d177871fd8..cd96e03f91 100644 --- a/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/ui/AttributeViewer.java +++ b/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/ui/AttributeViewer.java @@ -83,6 +83,8 @@ import com.raytheon.viz.ui.dialogs.ICloseCallback; * Mar 21, 2013 1638 mschenke Created Pair class internal so no dependencies on GFE * Jul 24, 2013 #1908 randerso Added support for updating attributes when resource cropped. * Code cleanup + * Apr 21, 2014 #2998 randerso Changed to use attribute type (not type of attribute value + * which may be null) to determine alignment of column. * * * @@ -326,7 +328,6 @@ public class AttributeViewer extends CaveJFACEDialog implements RemoveListener, Table table = viewer.getTable(); table.setHeaderVisible(true); - // table.setLinesVisible(true); table.setSortDirection(SWT.UP); comparator = new ColumnComparator(); ArrayList> sortOrder = new ArrayList>( @@ -341,16 +342,13 @@ public class AttributeViewer extends CaveJFACEDialog implements RemoveListener, for (String attrName : names) { int index = i++; int alignment = SWT.LEFT; - if (this.attributes[0][index] instanceof Integer) { + if (Number.class.isAssignableFrom(rsc.getAttributeType(attrName))) { alignment = SWT.RIGHT; } TableViewerColumn tvc = new TableViewerColumn(viewer, alignment, index); final TableColumn column = tvc.getColumn(); column.setText(attrName); - // column.addSelectionListener(new - // ColumnSelectionAdapter(tableViewer, - // index)); column.pack(); int extent = column.getWidth(); for (Object[] atts : this.attributes) { From 6c47c780389a9108a6ccb6a04cd859dc166a1b62 Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Mon, 21 Apr 2014 12:22:16 -0500 Subject: [PATCH 063/188] Issue #2822 fixed check for topic subscription before leader transfer now only checks if the bare ID (no resource) is subscribed to topic added method to check for same ID using multiple handles Former-commit-id: 09d7a1113a6254d8f01cf42d863e9365aac23cc7 --- .../session/SharedDisplaySession.java | 59 ++++++++++++------- .../comm/provider/session/VenueSession.java | 20 +++++++ 2 files changed, 57 insertions(+), 22 deletions(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java index 72af6271ba..5435e5b37d 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java @@ -23,9 +23,7 @@ import java.net.URI; import java.util.Collection; import java.util.HashSet; import java.util.List; -import java.util.Map; import java.util.Set; -import java.util.concurrent.ConcurrentHashMap; import org.apache.http.client.methods.HttpDelete; import org.jivesoftware.smack.XMPPConnection; @@ -99,6 +97,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; * ensure that subscription is setup before joining room * Mar 31, 2014 2899 mpduff Improve error messages. * Apr 15, 2014 2822 bclement added check for other participants being subscribed to topic + * Apr 21, 2014 2822 bclement removed use of resources in topicSubscribers, added skipCache * * * @@ -120,7 +119,7 @@ public class SharedDisplaySession extends VenueSession implements private LeafNode topic; - private final Map topicSubscribers = new ConcurrentHashMap(); + private final Set topicSubscribers = new HashSet(); private XMPPConnection conn; @@ -631,30 +630,35 @@ public class SharedDisplaySession extends VenueSession implements } /** + * may return false positives if skipCache is set to false, won't return a + * false negative + * * @param user - * @return true if user has a subscription to the session topic + * @param skipCache + * if true, a list of current subscribers is always retrieved + * from the server + * @return return false if user doesn't have a subscription to the session + * topic * @throws XMPPException */ - private boolean isSubscribedToTopic(UserId user) + private boolean isSubscribedToTopic(UserId user, boolean skipCache) throws XMPPException { - Boolean rval = topicSubscribers.get(user); - if (rval == null) { - synchronized (topicSubscribers) { + boolean rval; + synchronized (topicSubscribers) { + rval = topicSubscribers.contains(user.getNormalizedId()); + if (skipCache || !rval) { + topicSubscribers.clear(); List subs = PubSubOperations.getAllSubscriptions( conn, topic); for (Subscription sub : subs) { - topicSubscribers.put(IDConverter.convertFrom(sub.getJid()), - true); + /* + * we can't use the resource from the subscription here + * because the room user won't always have a resource + */ + UserId subber = IDConverter.convertFrom(sub.getJid()); + topicSubscribers.add(subber.getNormalizedId()); } - } - rval = topicSubscribers.get(user); - if (rval == null) { - /* - * userid object hash includes resource, cache as a client that - * doesn't use topic - */ - topicSubscribers.put(user, false); - rval = false; + rval = topicSubscribers.contains(user.getNormalizedId()); } } return rval; @@ -673,6 +677,16 @@ public class SharedDisplaySession extends VenueSession implements throw new CollaborationException( "Unable to grant ownership because new leader's actual userid is not known"); } + /* + * leadership transfer must be sync'd between room ownership and topic + * ownership. If a user is in the room under multiple handles, we can't + * know for sure that this handle is associated with the same client + * that understands leadership and is subscribed to the pubsub topic + */ + if (hasMultipleHandles(actualId)) { + throw new CollaborationException( + "Unable to grant ownership because new leader is in the room under multiple handles"); + } final String newLeaderId = actualId.getNormalizedId(); @@ -683,9 +697,10 @@ public class SharedDisplaySession extends VenueSession implements try { /* * make sure that the new leader is not just in the room, but also - * subscribed to the pubsub topic + * subscribed to the pubsub topic. Skip cache to handle participants + * who may have switched clients since that last time we cached */ - if (!isSubscribedToTopic(actualId)) { + if (!isSubscribedToTopic(actualId, true)) { throw new CollaborationException( "Unable to grant ownership because new leader is not subscribed to session topic"); } @@ -774,7 +789,7 @@ public class SharedDisplaySession extends VenueSession implements boolean rval = false; if (actualId != null) { try { - rval = isSubscribedToTopic(actualId); + rval = isSubscribedToTopic(actualId, false); } catch (XMPPException e) { log.error("Error checking if user is a shared display client", e); diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java index 6320d6e1bb..063232ae32 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java @@ -108,6 +108,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; * handle is now set in constructor * Apr 11, 2014 2903 bclement made constructor public b/c connection code moved packages * Apr 16, 2014 3020 bclement added check for invited rooms in roomExistsOnServer() + * Apr 21, 2014 2822 bclement added hasMultipleHandles() * * * @@ -939,6 +940,25 @@ public class VenueSession extends BaseSession implements IVenueSession { return rval; } + /** + * the return value is only accurate if the actual userIDs of all + * participants can be seen by this client + * + * @param user + * @return true if the user is in the room under multiple handles + */ + protected boolean hasMultipleHandles(UserId user) { + int count = 0; + IVenue v = getVenue(); + for (VenueParticipant p : v.getParticipants()) { + UserId other = v.getParticipantUserid(p); + if (other != null && user.isSameUser(other)) { + count += 1; + } + } + return count > 1; + } + /* * (non-Javadoc) * From 3c45a24efb4c18d76c528dafecb80e373ac7a397 Mon Sep 17 00:00:00 2001 From: Lee Venable Date: Mon, 21 Apr 2014 13:42:07 -0500 Subject: [PATCH 064/188] Issue #3041 - added dispose check to runAsync call and cleaned up code. Change-Id: I50e6ce1a214a884221fbc256a133e57e579862da Former-commit-id: ed2fc05f61861efe6c70b8fc73ad10d27bb73c12 --- .../ui/action/PutHomeCursorAction.java | 5 +- .../ui/dialog/PutHomeCursorDialog.java | 509 ++++++++++-------- 2 files changed, 282 insertions(+), 232 deletions(-) diff --git a/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/ui/action/PutHomeCursorAction.java b/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/ui/action/PutHomeCursorAction.java index a66b481886..1e90d16e64 100644 --- a/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/ui/action/PutHomeCursorAction.java +++ b/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/ui/action/PutHomeCursorAction.java @@ -38,6 +38,7 @@ import com.raytheon.viz.awipstools.ui.layer.HomeToolLayer; * Date Ticket# Engineer Description * ------------- -------- ----------- -------------------------- * Sep 03, 2013 2310 bsteffen Rewritten to extend HomeToolAction. + * Apr 21, 2014 3041 lvenable Added dispose check. * * * @@ -50,12 +51,10 @@ public class PutHomeCursorAction extends HomeToolAction { @Override public Object execute(ExecutionEvent arg0) throws ExecutionException { - if (putHomeCursorDialog == null - || putHomeCursorDialog.getShell() == null) { + if (putHomeCursorDialog == null || putHomeCursorDialog.isDisposed()) { Shell shell = PlatformUI.getWorkbench().getActiveWorkbenchWindow() .getShell(); putHomeCursorDialog = new PutHomeCursorDialog(shell); - putHomeCursorDialog.setBlockOnOpen(false); putHomeCursorDialog.open(); } diff --git a/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/ui/dialog/PutHomeCursorDialog.java b/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/ui/dialog/PutHomeCursorDialog.java index 6039479507..85cdbd9d1d 100644 --- a/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/ui/dialog/PutHomeCursorDialog.java +++ b/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/ui/dialog/PutHomeCursorDialog.java @@ -19,6 +19,38 @@ **/ package com.raytheon.viz.awipstools.ui.dialog; +import java.util.List; + +import org.eclipse.jface.dialogs.MessageDialog; +import org.eclipse.swt.SWT; +import org.eclipse.swt.events.SelectionAdapter; +import org.eclipse.swt.events.SelectionEvent; +import org.eclipse.swt.layout.GridData; +import org.eclipse.swt.layout.GridLayout; +import org.eclipse.swt.widgets.Button; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Group; +import org.eclipse.swt.widgets.Label; +import org.eclipse.swt.widgets.Layout; +import org.eclipse.swt.widgets.Shell; +import org.eclipse.swt.widgets.Text; + +import com.raytheon.uf.common.pointdata.spatial.ObStation; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.status.UFStatus.Priority; +import com.raytheon.uf.viz.core.VizApp; +import com.raytheon.uf.viz.core.catalog.DirectDbQuery; +import com.raytheon.uf.viz.points.IPointChangedListener; +import com.raytheon.uf.viz.points.PointsDataManager; +import com.raytheon.viz.ui.dialogs.CaveSWTDialog; +import com.vividsolutions.jts.geom.Coordinate; +import com.vividsolutions.jts.geom.Geometry; +import com.vividsolutions.jts.geom.GeometryFactory; +import com.vividsolutions.jts.io.ParseException; +import com.vividsolutions.jts.io.WKBReader; +import com.vividsolutions.jts.io.WKTWriter; + /** * Creates the Put Cursor Home Dialog. * @@ -26,7 +58,7 @@ package com.raytheon.viz.awipstools.ui.dialog; * SOFTWARE HISTORY * Date Ticket# Engineer Description * ------------- -------- ----------- -------------------------- - * Dec 05, 2007 Eric Babin Initial Creation + * Dec 05, 2007 Eric Babin Initial Creation * Dec 10, 2007 598 Eric Babin Added city, state query. * Dec 20, 2007 656 Eric Babin Updated to refresh location after * clicking GO. @@ -42,315 +74,317 @@ package com.raytheon.viz.awipstools.ui.dialog; * and the query by city, state. * Sep 03, 2013 2310 bsteffen Extend IPointChangedListener instead of * IResourceDataChanged. - * + * Apr 21, 2014 3041 lvenable Added dispose check to runAsync call and cleaned up + * code. Wrote ticket #3047 for common_obs_spatial + * for the city/state issues. + * * * * @author ebabin * @version 1.0 */ - -// TODO: the code that performs the queries will need to be cleaned up once we have -// time to cleanup, complete the common_obs_spatial table -import java.util.List; - -import org.eclipse.jface.dialogs.MessageDialog; -import org.eclipse.swt.SWT; -import org.eclipse.swt.events.DisposeEvent; -import org.eclipse.swt.events.DisposeListener; -import org.eclipse.swt.events.SelectionAdapter; -import org.eclipse.swt.events.SelectionEvent; -import org.eclipse.swt.graphics.Point; -import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.GridLayout; -import org.eclipse.swt.layout.RowLayout; -import org.eclipse.swt.widgets.Button; -import org.eclipse.swt.widgets.Composite; -import org.eclipse.swt.widgets.Control; -import org.eclipse.swt.widgets.Event; -import org.eclipse.swt.widgets.Group; -import org.eclipse.swt.widgets.Label; -import org.eclipse.swt.widgets.Listener; -import org.eclipse.swt.widgets.Shell; -import org.eclipse.swt.widgets.Text; - -import com.raytheon.uf.common.pointdata.spatial.ObStation; -import com.raytheon.uf.common.status.IUFStatusHandler; -import com.raytheon.uf.common.status.UFStatus; -import com.raytheon.uf.common.status.UFStatus.Priority; -import com.raytheon.uf.viz.core.VizApp; -import com.raytheon.uf.viz.core.catalog.DirectDbQuery; -import com.raytheon.uf.viz.points.IPointChangedListener; -import com.raytheon.uf.viz.points.PointsDataManager; -import com.raytheon.viz.ui.dialogs.CaveJFACEDialog; -import com.vividsolutions.jts.geom.Coordinate; -import com.vividsolutions.jts.geom.Geometry; -import com.vividsolutions.jts.geom.GeometryFactory; -import com.vividsolutions.jts.io.ParseException; -import com.vividsolutions.jts.io.WKBReader; -import com.vividsolutions.jts.io.WKTWriter; - -public class PutHomeCursorDialog extends CaveJFACEDialog implements +public class PutHomeCursorDialog extends CaveSWTDialog implements IPointChangedListener { - private static final transient IUFStatusHandler statusHandler = UFStatus + private final transient IUFStatusHandler statusHandler = UFStatus .getHandler(PutHomeCursorDialog.class); - private static final String DIST_QRY_FMT = "SELECT icao, name, state FROM common_obs_spatial " + private final String DIST_QRY_FMT = "SELECT icao, name, state FROM common_obs_spatial " + "WHERE ST_DWithin(the_geom, ST_GeomFromText('%s'), %4.1f) AND" + " catalogtype = %d ORDER BY ST_Distance(the_geom, ST_GeomFromText('%1$s'))"; - private static final String ICAO_QRY_FMT = "SELECT AsBinary(the_geom) FROM common_obs_spatial " + private final String ICAO_QRY_FMT = "SELECT AsBinary(the_geom) FROM common_obs_spatial " + "WHERE catalogtype = %d and icao = '%s'"; - private static final String CITY_QRY_FMT = "SELECT AsBinary(the_geom) FROM common_obs_spatial " + private final String CITY_QRY_FMT = "SELECT AsBinary(the_geom) FROM common_obs_spatial " + "WHERE catalogtype = %d AND name = '%s' AND state = '%s'"; - private static final String CITY_DB_QRY_FMT = "SELECT AsBinary(the_geom) FROM mapdata.city " + private final String CITY_DB_QRY_FMT = "SELECT AsBinary(the_geom) FROM mapdata.city " + "WHERE name = '%s' AND st = '%s'"; - private static final String AIRPORT_DB_QRY_FMT = "SELECT AsBinary(the_geom) FROM mapdata.airport " + private final String AIRPORT_DB_QRY_FMT = "SELECT AsBinary(the_geom) FROM mapdata.airport " + "WHERE city = '%s' AND state = '%s'"; - private Composite top = null; - + /** Station radio button. */ private Button stationRadio; + /** City radio button. */ private Button cityRadio; + /** Lat/Lon radio button. */ private Button latLonRadio; + /** Station label. */ + private Label stationLabel; + + /** Station text field. */ private Text stationTextField; + /** City label. */ + private Label citylabel; + + /** City text field. */ private Text cityTextField; + /** State label. */ + private Label stateLabel; + + /** State text field. */ private Text stateTextField; + /** Latitude label. */ + private Label latLabel; + + /** Latitude text field */ private Text latTextField; + /** Longitude label. */ + private Label lonLabel; + + /** Longitude text field. */ private Text lonTextField; - private Button goButton, closeButton; + /** Go button. */ + private Button goBtn; - public PutHomeCursorDialog(Shell shell) { - super(shell); - this.setBlockOnOpen(false); - this.setShellStyle(SWT.TITLE | SWT.MODELESS | SWT.CLOSE); - } - - /* - * (non-Javadoc) - * - * @see - * org.eclipse.jface.dialogs.Dialog#createDialogArea(org.eclipse.swt.widgets - * .Composite) - */ - @Override - public Control createDialogArea(Composite parent) { - top = (Composite) super.createDialogArea(parent); - // Create the main layout for the shell. - GridLayout gridLayout = new GridLayout(1, true); - - top.setLayout(gridLayout); - - // Initialize all of the menus, controls, and layouts - initializeComponents(); - - return top; - } + /** Close button. */ + private Button closeBtn; /** - * Initializes the components. + * Constructor. + * + * @param shell + * Parent shell. */ - private void initializeComponents() { - createSelectionChoices(); - createStationChoice(); - createCityChoice(); - createLatLonChoice(); + public PutHomeCursorDialog(Shell shell) { + super(shell, SWT.DIALOG_TRIM, CAVE.DO_NOT_BLOCK); + + setText("Put Home Cursor"); + PointsDataManager.getInstance().addHomeChangedListener(this); + } + + @Override + protected Layout constructShellLayout() { + GridLayout gridLayout = new GridLayout(1, false); + return gridLayout; + } + + @Override + protected Object constructShellLayoutData() { + // TODO Auto-generated method stub + return super.constructShellLayoutData(); + } + + @Override + protected void initializeComponents(Shell shell) { + + Group locSelectionGroup = new Group(shell, SWT.NONE); + + GridData gridData = new GridData(SWT.FILL, SWT.DEFAULT, true, false); + locSelectionGroup.setLayoutData(gridData); + locSelectionGroup.setText("Location selection via:"); + + GridLayout rowLayout = new GridLayout(1, false); + locSelectionGroup.setLayout(rowLayout); + + createSelectionChoices(locSelectionGroup); + + Composite controlsComp = new Composite(locSelectionGroup, SWT.NONE); + controlsComp.setLayout(new GridLayout(2, false)); + controlsComp.setLayoutData(new GridData(SWT.FILL, SWT.DEFAULT, true, + false)); + + createStationChoice(controlsComp); + createCityChoice(controlsComp); + createLatLonChoice(controlsComp); + + createActionButtons(); + try { updateStationInfo(PointsDataManager.getInstance().getHome()); } catch (Exception e) { } - // @TODO Not currently no data for city, state. So disabled for now. - stationRadio.setSelection(true); - cityTextField.setEnabled(false); - stateTextField.setEnabled(false); - latTextField.setEnabled(false); - lonTextField.setEnabled(false); - stationTextField.setEnabled(true); + + enableDisableControls(); + } + + @Override + protected void disposed() { + PointsDataManager.getInstance().removeHomeChangedListener( + PutHomeCursorDialog.this); } /** * Creates the selection composite. + * + * @param selectionGroup + * Group container. */ - private void createSelectionChoices() { - Group selectionGroup = new Group(top, SWT.NONE | SWT.FILL); + private void createSelectionChoices(Group selectionGroup) { - GridData gridData = new GridData(); - gridData.horizontalAlignment = GridData.FILL; - gridData.grabExcessHorizontalSpace = true; - selectionGroup.setLayoutData(gridData); + /* + * Composite for the location radio buttons. + */ + Composite locationComp = new Composite(selectionGroup, SWT.BORDER); + locationComp.setLayout(new GridLayout(3, true)); - RowLayout rowLayout = new RowLayout(); - rowLayout.type = SWT.VERTICAL; - selectionGroup.setLayout(rowLayout); - - Label label = new Label(selectionGroup, SWT.NONE | SWT.CENTER); - label.setText("Location selection via:"); - - Composite locationComp = new Composite(selectionGroup, SWT.None); - locationComp.setLayout(new RowLayout()); + /* + * Station radio button selection + */ stationRadio = new Button(locationComp, SWT.RADIO); + stationRadio.setText("Station"); + stationRadio.setSelection(true); stationRadio.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent event) { - cityTextField.setEnabled(false); - stateTextField.setEnabled(false); - latTextField.setEnabled(false); - lonTextField.setEnabled(false); - stationTextField.setEnabled(true); + if (stationRadio.getSelection() == false) { + return; + } + enableDisableControls(); } }); - stationRadio.setText("Station"); + /* + * City radio button selection + */ cityRadio = new Button(locationComp, SWT.RADIO); cityRadio.setText("City/State"); cityRadio.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent event) { - cityTextField.setEnabled(true); - stateTextField.setEnabled(true); - latTextField.setEnabled(false); - lonTextField.setEnabled(false); - stationTextField.setEnabled(false); + if (cityRadio.getSelection() == false) { + return; + } + enableDisableControls(); } }); + /* + * Lat/Lon radio button selection + */ latLonRadio = new Button(locationComp, SWT.RADIO); + latLonRadio.setText("Lat/Lon"); latLonRadio.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent event) { - cityTextField.setEnabled(false); - stateTextField.setEnabled(false); - latTextField.setEnabled(true); - lonTextField.setEnabled(true); - stationTextField.setEnabled(false); + if (latLonRadio.getSelection() == false) { + return; + } + enableDisableControls(); } }); - - latLonRadio.setText("Lat/Lon"); } /** - * Creates station choice composite. + * Creates station choice controls. + * + * @param controlsComp + * Composite containing the controls. */ - private void createStationChoice() { - Group comp = new Group(top, SWT.None); - GridData gridData = new GridData(); - gridData.horizontalAlignment = GridData.FILL; + private void createStationChoice(Composite controlsComp) { - comp.setLayoutData(gridData); - comp.setLayout(new GridLayout(3, true)); - Label label = new Label(comp, SWT.NONE); - label.setText("Station:"); - stationTextField = new Text(comp, SWT.BORDER); - GridData data = new GridData(GridData.HORIZONTAL_ALIGN_FILL - | GridData.GRAB_HORIZONTAL); - data.horizontalSpan = 2; + stationLabel = new Label(controlsComp, SWT.NONE); + stationLabel.setText("Station:"); + + stationTextField = new Text(controlsComp, SWT.BORDER); + GridData data = new GridData(SWT.FILL, SWT.DEFAULT, true, false); stationTextField.setLayoutData(data); + + // Add a separator line. + addSeparator(controlsComp); } /** - * Creates city choice composite. + * Creates city choice controls. + * + * @param controlsComp + * Composite containing the controls. */ - private void createCityChoice() { - Group comp = new Group(top, SWT.None); - GridData gridData = new GridData(); - gridData.horizontalAlignment = GridData.FILL; - gridData.grabExcessHorizontalSpace = true; - comp.setLayoutData(gridData); - comp.setLayout(new GridLayout(3, true)); + private void createCityChoice(Composite controlsComp) { - Label citylabel = new Label(comp, SWT.NONE); + citylabel = new Label(controlsComp, SWT.NONE); citylabel.setText("City:"); - cityTextField = new Text(comp, SWT.BORDER); - GridData data = new GridData(GridData.HORIZONTAL_ALIGN_FILL - | GridData.GRAB_HORIZONTAL); - data.horizontalSpan = 2; - cityTextField.setLayoutData(data); - Label stateLabel = new Label(comp, SWT.NONE); + cityTextField = new Text(controlsComp, SWT.BORDER); + GridData gd = new GridData(SWT.FILL, SWT.DEFAULT, true, false); + cityTextField.setLayoutData(gd); + + stateLabel = new Label(controlsComp, SWT.NONE); stateLabel.setText("State:"); stateLabel.setToolTipText("Two Letter Abbreviation"); - stateTextField = new Text(comp, SWT.BORDER); + gd = new GridData(50, SWT.DEFAULT); + stateTextField = new Text(controlsComp, SWT.BORDER); stateTextField.setTextLimit(2); + stateTextField.setLayoutData(gd); - stateTextField.setEnabled(false); - cityTextField.setEnabled(false); + // Add a separator line. + addSeparator(controlsComp); } /** - * Creates lat/lon choice composite. + * Creates lat/lon choice controls. + * + * @param controlsComp + * Composite containing the controls. */ - private void createLatLonChoice() { - Group comp = new Group(top, SWT.None); - GridData gridData = new GridData(); - gridData.horizontalAlignment = GridData.FILL; - gridData.grabExcessHorizontalSpace = true; - comp.setLayoutData(gridData); - comp.setLayout(new GridLayout(2, true)); - Label latLabel = new Label(comp, SWT.NONE); + private void createLatLonChoice(Composite controlsComp) { + + latLabel = new Label(controlsComp, SWT.NONE); latLabel.setText("Latitude:"); - latTextField = new Text(comp, SWT.BORDER); + + GridData gd = new GridData(SWT.FILL, SWT.DEFAULT, true, false); + latTextField = new Text(controlsComp, SWT.BORDER); latTextField.setLayoutData(new GridData(80, SWT.DEFAULT)); - Label longLabel = new Label(comp, SWT.NONE); - longLabel.setText("Longitude:"); - lonTextField = new Text(comp, SWT.BORDER); + latTextField.setLayoutData(gd); + + lonLabel = new Label(controlsComp, SWT.NONE); + lonLabel.setText("Longitude:"); + + gd = new GridData(SWT.FILL, SWT.DEFAULT, true, false); + lonTextField = new Text(controlsComp, SWT.BORDER); lonTextField.setLayoutData(new GridData(80, SWT.DEFAULT)); + lonTextField.setLayoutData(gd); + Coordinate point = PointsDataManager.getInstance().getHome(); lonTextField.setText(String.valueOf(point.x)); latTextField.setText(String.valueOf(point.y)); - } - /* - * (non-Javadoc) - * - * @see - * org.eclipse.jface.window.Window#configureShell(org.eclipse.swt.widgets - * .Shell) - */ - @Override - protected void configureShell(Shell shell) { - super.configureShell(shell); - PointsDataManager.getInstance().addHomeChangedListener(this); - shell.addDisposeListener(new DisposeListener() { - - @Override - public void widgetDisposed(DisposeEvent e) { - PointsDataManager.getInstance().removeHomeChangedListener( - PutHomeCursorDialog.this); - } - }); - shell.setText("Put Home Cursor"); - - } - - /* - * (non-Javadoc) - * - * @see org.eclipse.jface.dialogs.Dialog#getInitialSize() - */ - @Override - protected Point getInitialSize() { - return new Point(300, 360); + // Add a separator line. + addSeparator(controlsComp); } /** - * Exits the dialog. + * Add a line separator to the given composite. + * + * @param parentComp + * Parent composite. */ - private void exitDialog() { - PointsDataManager.getInstance().removeHomeChangedListener(this); - this.close(); + private void addSeparator(Composite parentComp) { + GridLayout gl = (GridLayout) parentComp.getLayout(); + + GridData gd = new GridData(SWT.FILL, SWT.DEFAULT, true, false); + gd.horizontalSpan = gl.numColumns; + Label sepLbl = new Label(parentComp, SWT.SEPARATOR | SWT.HORIZONTAL); + sepLbl.setLayoutData(gd); + } + + /** + * Enable or disable controls based on the radio button states. + */ + private void enableDisableControls() { + stationLabel.setEnabled(stationRadio.getSelection()); + stationTextField.setEnabled(stationRadio.getSelection()); + + citylabel.setEnabled(cityRadio.getSelection()); + cityTextField.setEnabled(cityRadio.getSelection()); + stateLabel.setEnabled(cityRadio.getSelection()); + stateTextField.setEnabled(cityRadio.getSelection()); + + latLabel.setEnabled(latLonRadio.getSelection()); + latTextField.setEnabled(latLonRadio.getSelection()); + lonLabel.setEnabled(latLonRadio.getSelection()); + lonTextField.setEnabled(latLonRadio.getSelection()); } /** @@ -364,8 +398,7 @@ public class PutHomeCursorDialog extends CaveJFACEDialog implements .trim(); Coordinate c = runStationQuery(station); if (c == null) { - MessageDialog.openError(getParentShell(), - "Put Home Cursor Error", + MessageDialog.openError(shell, "Put Home Cursor Error", "Could not find that Metar station"); stationTextField.setFocus(); } else { @@ -373,22 +406,19 @@ public class PutHomeCursorDialog extends CaveJFACEDialog implements stationTextField.setText(station); } } else { - MessageDialog.openError(getParentShell(), - "Put Home Cursor Error", + MessageDialog.openError(shell, "Put Home Cursor Error", "The input for the Station is empty. Please correct."); stationTextField.setFocus(); } } else if (cityRadio.getSelection()) { if (cityTextField.getText().isEmpty()) { - MessageDialog.openError(getParentShell(), - "Put Home Cursor Error", + MessageDialog.openError(shell, "Put Home Cursor Error", "The input for the City is empty. Please correct."); cityTextField.setFocus(); return; } if (stateTextField.getText().length() != 2) { - MessageDialog.openError(getParentShell(), - "Put Home Cursor Error", + MessageDialog.openError(shell, "Put Home Cursor Error", "The input for the State is invalid. Please correct."); stateTextField.setFocus(); return; @@ -397,8 +427,8 @@ public class PutHomeCursorDialog extends CaveJFACEDialog implements String state = stateTextField.getText().toUpperCase().trim(); Coordinate c = runCityQuery(city, state); if (c == null) { - MessageDialog.openError(getParentShell(), - "Put Home Cursor Error", "Could not find that city"); + MessageDialog.openError(shell, "Put Home Cursor Error", + "Could not find that city"); cityTextField.setFocus(); } else { PointsDataManager.getInstance().setHome(c); @@ -411,7 +441,7 @@ public class PutHomeCursorDialog extends CaveJFACEDialog implements c.x = Float.parseFloat(lonTextField.getText()); } catch (NumberFormatException nfe) { MessageDialog - .openError(getParentShell(), "Put Home Cursor Error", + .openError(shell, "Put Home Cursor Error", "The input for the Longitude not a number. Please correct."); lonTextField.setFocus(); return; @@ -437,23 +467,42 @@ public class PutHomeCursorDialog extends CaveJFACEDialog implements } } - @Override - protected void createButtonsForButtonBar(Composite parent) { + /** + * Create the action buttons at the bottom of the dialog. + */ + private void createActionButtons() { + Composite buttonComp = new Composite(shell, SWT.NONE); + GridLayout gl = new GridLayout(2, true); + GridData gd = new GridData(SWT.FILL, SWT.DEFAULT, true, false); + buttonComp.setLayout(gl); + buttonComp.setLayoutData(gd); + + int buttonWidth = 75; + // override, so can add calculate as default button. - goButton = createButton(parent, SWT.OK, "Go", true); - closeButton = createButton(parent, SWT.CLOSE, "Close", false); - goButton.addListener(SWT.Selection, new Listener() { - public void handleEvent(Event event) { + gd = new GridData(SWT.RIGHT, SWT.DEFAULT, true, false); + gd.widthHint = buttonWidth; + goBtn = new Button(buttonComp, SWT.PUSH); + goBtn.setText("Go"); + goBtn.setLayoutData(gd); + goBtn.addSelectionListener(new SelectionAdapter() { + @Override + public void widgetSelected(SelectionEvent e) { updateStation(); } }); - closeButton.addListener(SWT.Selection, new Listener() { - public void handleEvent(Event event) { - exitDialog(); + + gd = new GridData(SWT.LEFT, SWT.DEFAULT, true, false); + gd.widthHint = buttonWidth; + closeBtn = new Button(buttonComp, SWT.PUSH); + closeBtn.setText("Close"); + closeBtn.setLayoutData(gd); + closeBtn.addSelectionListener(new SelectionAdapter() { + @Override + public void widgetSelected(SelectionEvent e) { + close(); } - }); - } /** @@ -585,9 +634,12 @@ public class PutHomeCursorDialog extends CaveJFACEDialog implements @Override public void pointChanged() { VizApp.runAsync(new Runnable() { - @Override public void run() { + if (isDisposed()) { + return; + } + Coordinate point = PointsDataManager.getInstance().getHome(); lonTextField.setText(String.valueOf(point.x)); latTextField.setText(String.valueOf(point.y)); @@ -597,5 +649,4 @@ public class PutHomeCursorDialog extends CaveJFACEDialog implements }); } - } From c23e741c6567cc1a7cc7a2015b11c38e63249f1c Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Mon, 21 Apr 2014 13:53:48 -0500 Subject: [PATCH 065/188] Issue #2726: Fix context tracker for MessageProducer Change-Id: Id5ba1f100d99909ef0918fb7482bbdc7540aff8e Former-commit-id: b41584617a29a555a30aa8a0e4e5e7969ed4bfc2 --- .../uf/edex/esb/camel/MessageProducer.java | 12 +++++- .../ModelSoundingPersistenceManager.java | 38 ++++++++++--------- 2 files changed, 32 insertions(+), 18 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/MessageProducer.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/MessageProducer.java index 352e92970c..5f19ae9099 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/MessageProducer.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/MessageProducer.java @@ -375,8 +375,14 @@ public class MessageProducer implements IMessageProducer, InterceptStrategy { * track the thread this context is using for proper dependency * management. */ + CamelContext prev = MessageProducer.this.currentThreadContext + .get(); MessageProducer.this.currentThreadContext.set(context); - target.process(exchange); + try { + target.process(exchange); + } finally { + MessageProducer.this.currentThreadContext.set(prev); + } } @Override @@ -385,12 +391,16 @@ public class MessageProducer implements IMessageProducer, InterceptStrategy { * track the thread this context is using for proper dependency * management. */ + CamelContext prev = MessageProducer.this.currentThreadContext + .get(); MessageProducer.this.currentThreadContext.set(context); try { target.process(exchange); } catch (Throwable e) { exchange.setException(e); + } finally { + MessageProducer.this.currentThreadContext.set(prev); } callback.done(true); return true; diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingPersistenceManager.java b/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingPersistenceManager.java index 0528cd33c4..d9a3fb6e27 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingPersistenceManager.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingPersistenceManager.java @@ -43,7 +43,7 @@ import com.raytheon.uf.edex.core.IContextStateProcessor; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Jul 17, 2013 2161 bkowal Initial creation. - * Mar 11, 2014 2726 rjpeter Graceful shutdown. + * Mar 11, 2014 2726 rjpeter Graceful shutdown, don't forward empty pdo lists. * * * @author bkowal @@ -99,14 +99,16 @@ public class ModelSoundingPersistenceManager implements IContextStateProcessor { if (container != null) { List pdoList = container.getPdos(); - PluginDataObject[] pdos = pdoList - .toArray(new PluginDataObject[pdoList.size()]); - try { - EDEXUtil.getMessageProducer().sendSync( - "modelSoundingPersistIndexAlert", pdos); - } catch (EdexException e) { - logger.error("Failed to persist " + pdos.length - + " PluginDataObject(s)!", e); + if ((pdoList != null) && !pdoList.isEmpty()) { + PluginDataObject[] pdos = pdoList + .toArray(new PluginDataObject[pdoList.size()]); + try { + EDEXUtil.getMessageProducer().sendSync( + "modelSoundingPersistIndexAlert", pdos); + } catch (EdexException e) { + logger.error("Failed to persist " + pdos.length + + " PluginDataObject(s)!", e); + } } } } catch (Throwable e) { @@ -125,14 +127,16 @@ public class ModelSoundingPersistenceManager implements IContextStateProcessor { protected void storeContainer(ModelSoundingStorageContainer container) { List pdoList = container.getPdos(); - PluginDataObject[] pdos = pdoList.toArray(new PluginDataObject[pdoList - .size()]); - try { - EDEXUtil.getMessageProducer().sendSync( - "modelSoundingPersistIndexAlert", pdos); - } catch (EdexException e) { - logger.error("Failed to persist " + pdos.length - + " PluginDataObject(s)!", e); + if ((pdoList != null) && !pdoList.isEmpty()) { + PluginDataObject[] pdos = pdoList + .toArray(new PluginDataObject[pdoList.size()]); + try { + EDEXUtil.getMessageProducer().sendSync( + "modelSoundingPersistIndexAlert", pdos); + } catch (EdexException e) { + logger.error("Failed to persist " + pdos.length + + " PluginDataObject(s)!", e); + } } } From 665246d72ed5b8965e69eb24504e16bae6c6e57c Mon Sep 17 00:00:00 2001 From: Ron Anderson Date: Thu, 17 Apr 2014 15:42:27 -0500 Subject: [PATCH 066/188] Issue #2997 Fix Geostationary projection to work with GeoTools 10.5 Change-Id: Id9f3dc3af07548039509e4121cafd2e02a01453c Former-commit-id: 2b67417e6128e3cd4cafa5c8f2ac23c10be2b300 --- .../core/maps/rsc/AbstractDbMapResource.java | 75 +++- .../viz/core/maps/rsc/DbMapQueryFactory.java | 7 +- .../uf/viz/core/maps/rsc/DbMapResource.java | 90 +++-- .../viz/core/maps/rsc/DbPointMapResource.java | 72 ++-- .../viz/core/maps/rsc/DefaultDbMapQuery.java | 11 +- .../core/drawables/AbstractDescriptor.java | 36 +- .../cave/cache/map/CacheDbMapQuery.java | 22 +- .../viz/core/rsc/jts/JTSCompiler.java | 10 +- .../maps/dataaccess/util/MapsQueryUtil.java | 82 ++++- .../geospatial/GeometryTransformer.java | 344 ++++++++++++++++++ .../common/geospatial/ReferencedGeometry.java | 5 +- 11 files changed, 604 insertions(+), 150 deletions(-) create mode 100644 edexOsgi/com.raytheon.uf.common.geospatial/src/com/raytheon/uf/common/geospatial/GeometryTransformer.java diff --git a/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/AbstractDbMapResource.java b/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/AbstractDbMapResource.java index 1439070318..04f938c1eb 100644 --- a/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/AbstractDbMapResource.java +++ b/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/AbstractDbMapResource.java @@ -21,8 +21,15 @@ package com.raytheon.uf.viz.core.maps.rsc; import java.util.List; +import org.geotools.geometry.jts.CoordinateSequenceTransformer; +import org.geotools.geometry.jts.DefaultCoordinateSequenceTransformer; +import org.geotools.geometry.jts.ReferencedEnvelope; import org.opengis.referencing.crs.CoordinateReferenceSystem; +import org.opengis.referencing.operation.MathTransform; +import com.raytheon.uf.common.geospatial.GeometryTransformer; +import com.raytheon.uf.common.geospatial.MapUtil; +import com.raytheon.uf.common.geospatial.util.EnvelopeIntersection; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; @@ -37,9 +44,11 @@ import com.raytheon.uf.viz.core.rsc.LoadProperties; import com.raytheon.uf.viz.core.rsc.capabilities.LabelableCapability; import com.raytheon.uf.viz.core.rsc.capabilities.MagnificationCapability; import com.vividsolutions.jts.geom.Envelope; +import com.vividsolutions.jts.geom.Geometry; +import com.vividsolutions.jts.geom.impl.PackedCoordinateSequenceFactory; /** - * TODO Add Description + * Base class for database map resources * *
  * 
@@ -47,7 +56,8 @@ import com.vividsolutions.jts.geom.Envelope;
  * 
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
- * Aug 10, 2011            randerso     Initial creation
+ * Aug 10, 2011            randerso    Initial creation
+ * Apr 17, 2014  #2997     randerso    Moved buildBoundingGeometry up from DbMapResource
  * 
  * 
* @@ -63,6 +73,13 @@ public abstract class AbstractDbMapResource 16 start to cause noticeable drop outs + // in the map geometry. + protected static final double SPEED_UP = 8; + protected IFont font; protected PixelExtent lastExtent; @@ -206,4 +223,58 @@ public abstract class AbstractDbMapResource * @@ -35,6 +35,7 @@ import com.vividsolutions.jts.geom.Envelope; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Dec 9, 2011 bsteffen Initial creation + * Apr 9, 2014 #2997 randerso Added queryWithinGeometry * * * @@ -45,7 +46,7 @@ import com.vividsolutions.jts.geom.Envelope; public class DbMapQueryFactory { public interface DbMapQuery { - public QueryResult queryWithinEnvelope(Envelope env, + public QueryResult queryWithinGeometry(Geometry geom, List columns, List additionalConstraints) throws VizException; diff --git a/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/DbMapResource.java b/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/DbMapResource.java index 1ae17abade..5c8e0bb32a 100644 --- a/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/DbMapResource.java +++ b/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/DbMapResource.java @@ -41,11 +41,9 @@ import org.eclipse.core.runtime.Status; import org.eclipse.core.runtime.jobs.Job; import org.eclipse.swt.graphics.RGB; import org.eclipse.swt.graphics.Rectangle; -import org.geotools.geometry.jts.ReferencedEnvelope; import org.opengis.referencing.crs.CoordinateReferenceSystem; import com.raytheon.uf.common.dataquery.db.QueryResult; -import com.raytheon.uf.common.geospatial.MapUtil; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; @@ -74,7 +72,6 @@ import com.raytheon.uf.viz.core.rsc.capabilities.ShadeableCapability; import com.raytheon.viz.core.rsc.jts.JTSCompiler; import com.raytheon.viz.core.rsc.jts.JTSCompiler.PointStyle; import com.raytheon.viz.core.spatial.GeometryCache; -import com.vividsolutions.jts.geom.Envelope; import com.vividsolutions.jts.geom.Geometry; import com.vividsolutions.jts.geom.Point; import com.vividsolutions.jts.geom.TopologyException; @@ -85,7 +82,7 @@ import com.vividsolutions.jts.io.WKBReader; * *
  * 
- * SOFTWARE HISTORY
+ * SOFTWARE HISTORY 
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
  * Feb 19, 2009            randerso    Initial creation
@@ -95,6 +92,7 @@ import com.vividsolutions.jts.io.WKBReader;
  * Nov 06, 2013 2361       njensen     Prepopulate fields in initInternal
  *                                     instead of constructor for speed
  * Feb 18, 2014 2819       randerso    Removed unnecessary clones of geometries
+ * Apr 09, 2014 2997       randerso    Replaced buildEnvelope with buildBoundingGeometry
  * 
  * 
* @@ -171,18 +169,18 @@ public class DbMapResource extends String shadingField; - Envelope envelope; + Geometry boundingGeom; Map colorMap; Request(IGraphicsTarget target, IMapDescriptor descriptor, - DbMapResource rsc, Envelope envelope, String geomField, + DbMapResource rsc, Geometry boundingGeom, String geomField, String labelField, String shadingField, Map colorMap) { this.target = target; this.descriptor = descriptor; this.rsc = rsc; - this.envelope = envelope; + this.boundingGeom = boundingGeom; this.geomField = geomField; this.labelField = labelField; this.shadingField = shadingField; @@ -217,10 +215,10 @@ public class DbMapResource extends public Throwable cause; - public Envelope query; + public String table; - private Result(Envelope query) { - this.query = query; + private Result(String table) { + this.table = table; failed = true; } } @@ -238,13 +236,13 @@ public class DbMapResource extends } public void request(IGraphicsTarget target, IMapDescriptor descriptor, - DbMapResource rsc, Envelope query, String geomField, + DbMapResource rsc, Geometry boundingGeom, String geomField, String labelField, String shadingField, Map colorMap) { if (requestQueue.size() == QUEUE_LIMIT) { requestQueue.poll(); } - requestQueue.add(new Request(target, descriptor, rsc, query, + requestQueue.add(new Request(target, descriptor, rsc, boundingGeom, geomField, labelField, shadingField, colorMap)); this.cancel(); @@ -265,7 +263,7 @@ public class DbMapResource extends protected IStatus run(IProgressMonitor monitor) { Request req = requestQueue.poll(); while (req != null) { - Result result = new Result(req.envelope); + Result result = new Result(resourceData.getTable()); try { String table = resourceData.getTable(); if (canceled) { @@ -302,7 +300,7 @@ public class DbMapResource extends QueryResult mappedResult = DbMapQueryFactory.getMapQuery( resourceData.getTable(), getGeomField(lev[lev.length - 1])) - .queryWithinEnvelope(req.envelope, fields, + .queryWithinGeometry(req.boundingGeom, fields, constraints); Map gidMap = new HashMap( mappedResult.getResultCount() * 2); @@ -363,11 +361,13 @@ public class DbMapResource extends byte[] wkb = (byte[]) obj; g = wkbReader.read(wkb); } else { - statusHandler.handle(Priority.ERROR, + statusHandler.handle( + Priority.ERROR, "Expected byte[] received " + obj.getClass().getName() + ": " + obj.toString() - + "\n query=\"" + req.envelope + + "\n table=\"" + + resourceData.getTable() + "\""); } gidMap.put(gid, g); @@ -580,19 +580,6 @@ public class DbMapResource extends getLabelFields().toArray(new String[0])); } - private Envelope buildEnvelope(PixelExtent extent) throws VizException { - Envelope env = null; - try { - Envelope e = descriptor.pixelToWorld(extent, descriptor.getCRS()); - ReferencedEnvelope ref = new ReferencedEnvelope(e, - descriptor.getCRS()); - env = ref.transform(MapUtil.LATLON_PROJECTION, true); - } catch (Exception e) { - throw new VizException("Error transforming extent", e); - } - return env; - } - protected String getGeomField(double simpLev) { DecimalFormat df = new DecimalFormat("0.######"); String suffix = "_" @@ -623,20 +610,27 @@ public class DbMapResource extends PaintProperties paintProps) throws VizException { PixelExtent screenExtent = (PixelExtent) paintProps.getView() .getExtent(); + Rectangle canvasBounds = paintProps.getCanvasBounds(); + int screenWidth = canvasBounds.width; + double worldToScreenRatio = screenExtent.getWidth() / screenWidth; + + int displayWidth = (int) (descriptor.getMapWidth() * paintProps + .getZoomLevel()); + double kmPerPixel = (displayWidth / screenWidth) / 1000.0; // compute an estimate of degrees per pixel double yc = screenExtent.getCenter()[1]; - double x1 = screenExtent.getMinX(); - double x2 = screenExtent.getMaxX(); + double x1 = screenExtent.getCenter()[0]; + double x2 = x1 + 1; double[] c1 = descriptor.pixelToWorld(new double[] { x1, yc }); double[] c2 = descriptor.pixelToWorld(new double[] { x2, yc }); - Rectangle canvasBounds = paintProps.getCanvasBounds(); - int screenWidth = canvasBounds.width; - double dppX = Math.abs(c2[0] - c1[0]) / screenWidth; - // System.out.println("c1:" + Arrays.toString(c1) + " c2:" - // + Arrays.toString(c2) + " dpp:" + dppX); + double dppX = (Math.abs(c2[0] - c1[0]) * screenExtent.getWidth()) + / screenWidth; double simpLev = getSimpLev(dppX); + // System.out.println("c1:" + Arrays.toString(c1) + "\nc2:" + // + Arrays.toString(c2) + "\ndpp:" + dppX + "\nsimpLev:" + // + simpLev); String labelField = getCapability(LabelableCapability.class) .getLabelField(); @@ -655,8 +649,10 @@ public class DbMapResource extends clipToProjExtent(screenExtent).getEnvelope())) { if (!paintProps.isZooming()) { PixelExtent expandedExtent = getExpandedExtent(screenExtent); - Envelope query = buildEnvelope(expandedExtent); - queryJob.request(aTarget, descriptor, this, query, + Geometry boundingGeom = buildBoundingGeometry(expandedExtent, + worldToScreenRatio, kmPerPixel); + + queryJob.request(aTarget, descriptor, this, boundingGeom, getGeomField(simpLev), labelField, shadingField, colorMap); lastExtent = expandedExtent; @@ -670,8 +666,9 @@ public class DbMapResource extends if (result != null) { if (result.failed) { lastExtent = null; // force to re-query when re-enabled - throw new VizException("Error processing map query request: " - + result.query, result.cause); + throw new VizException( + "Error processing map query request for: " + + result.table, result.cause); } if (outlineShape != null) { outlineShape.dispose(); @@ -716,14 +713,11 @@ public class DbMapResource extends (float) (10 * labelMagnification), null); font.setSmoothing(false); } - double screenToWorldRatio = paintProps.getView().getExtent() - .getWidth() - / paintProps.getCanvasBounds().width; double offsetX = getCapability(LabelableCapability.class) - .getxOffset() * screenToWorldRatio; + .getxOffset() * worldToScreenRatio; double offsetY = getCapability(LabelableCapability.class) - .getyOffset() * screenToWorldRatio; + .getyOffset() * worldToScreenRatio; RGB color = getCapability(ColorableCapability.class).getColor(); IExtent extent = paintProps.getView().getExtent(); List strings = new ArrayList( @@ -737,7 +731,7 @@ public class DbMapResource extends .getDensity(); double minScreenDistance = Double.MAX_VALUE; if (density > 0) { - minScreenDistance = (screenToWorldRatio * BASE_DENSITY_MULT) + minScreenDistance = (worldToScreenRatio * BASE_DENSITY_MULT) / density; } @@ -763,10 +757,10 @@ public class DbMapResource extends IExtent strExtent = new PixelExtent( node.location[0], node.location[0] - + (node.rect.getWidth() * screenToWorldRatio), + + (node.rect.getWidth() * worldToScreenRatio), node.location[1], node.location[1] - + ((node.rect.getHeight() - node.rect.getY()) * screenToWorldRatio)); + + ((node.rect.getHeight() - node.rect.getY()) * worldToScreenRatio)); if ((lastLabel != null) && lastLabel.equals(node.label)) { // check intersection of extents diff --git a/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/DbPointMapResource.java b/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/DbPointMapResource.java index 9c8344e807..42cf1e7615 100644 --- a/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/DbPointMapResource.java +++ b/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/DbPointMapResource.java @@ -31,10 +31,9 @@ import org.eclipse.core.runtime.IStatus; import org.eclipse.core.runtime.Status; import org.eclipse.core.runtime.jobs.Job; import org.eclipse.swt.graphics.RGB; -import org.geotools.geometry.jts.ReferencedEnvelope; +import org.eclipse.swt.graphics.Rectangle; import com.raytheon.uf.common.dataquery.db.QueryResult; -import com.raytheon.uf.common.geospatial.MapUtil; import com.raytheon.uf.common.geospatial.ReferencedCoordinate; import com.raytheon.uf.common.pointdata.vadriver.VA_Advanced; import com.raytheon.uf.common.status.IUFStatusHandler; @@ -58,7 +57,6 @@ import com.raytheon.uf.viz.core.rsc.capabilities.LabelableCapability; import com.raytheon.uf.viz.core.rsc.capabilities.MagnificationCapability; import com.raytheon.uf.viz.core.rsc.capabilities.PointCapability; import com.vividsolutions.jts.geom.Coordinate; -import com.vividsolutions.jts.geom.Envelope; import com.vividsolutions.jts.geom.Geometry; import com.vividsolutions.jts.geom.Point; import com.vividsolutions.jts.io.WKBReader; @@ -71,7 +69,8 @@ import com.vividsolutions.jts.io.WKBReader; * SOFTWARE HISTORY * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Mar 19, 2009 randerso Initial creation + * Mar 19, 2009 randerso Initial creation + * Apr 09, 2014 2997 randerso Replaced buildEnvelope with buildBoundingGeometry * * * @@ -163,15 +162,15 @@ public class DbPointMapResource extends String goodnessField; - Envelope env; + Geometry boundingGeometry; public Request(DbPointMapResource rsc, String labelField, - String goodnessField, Envelope env) { + String goodnessField, Geometry boundingGeometry) { super(); this.rsc = rsc; this.labelField = labelField; this.goodnessField = goodnessField; - this.env = env; + this.boundingGeometry = boundingGeometry; } } @@ -202,12 +201,12 @@ public class DbPointMapResource extends } public void request(IGraphicsTarget target, DbPointMapResource rsc, - Envelope envelope, String labelField, String goodnessField) { + Geometry boundingGeom, String labelField, String goodnessField) { if (requestQueue.size() == QUEUE_LIMIT) { requestQueue.poll(); } requestQueue.add(new Request(rsc, labelField, goodnessField, - envelope)); + boundingGeom)); this.cancel(); this.schedule(); @@ -234,8 +233,8 @@ public class DbPointMapResource extends if (req.labelField != null) { columns.add(req.labelField); } - if (req.goodnessField != null - && req.goodnessField != req.labelField) { + if ((req.goodnessField != null) + && (req.goodnessField != req.labelField)) { columns.add(req.goodnessField); } if (resourceData.getColumns() != null) { @@ -258,8 +257,8 @@ public class DbPointMapResource extends QueryResult results = DbMapQueryFactory.getMapQuery( resourceData.getTable(), - resourceData.getGeomField()).queryWithinEnvelope( - req.env, columns, constraints); + resourceData.getGeomField()).queryWithinGeometry( + req.boundingGeometry, columns, constraints); long t1 = System.currentTimeMillis(); System.out.println("Maps DB query took: " + (t1 - t0) @@ -285,15 +284,14 @@ public class DbPointMapResource extends statusHandler.handle(Priority.ERROR, "Expected byte[] received " + geomObj.getClass().getName() - + ": " + geomObj.toString() - + "\n query=\"" + req.env + "\""); + + ": " + geomObj.toString()); } if (g != null) { String label = ""; - if (req.labelField != null - && results.getRowColumnValue(c, - req.labelField) != null) { + if ((req.labelField != null) + && (results.getRowColumnValue(c, + req.labelField) != null)) { Object r = results.getRowColumnValue(c, req.labelField); if (r instanceof BigDecimal) { @@ -395,36 +393,18 @@ public class DbPointMapResource extends queryJob = new MapQueryJob(); } - private void requestData(IGraphicsTarget target, PixelExtent extent) - throws VizException { - - Envelope env = null; - try { - Envelope e = descriptor.pixelToWorld(extent, descriptor.getCRS()); - ReferencedEnvelope ref = new ReferencedEnvelope(e, - descriptor.getCRS()); - env = ref.transform(MapUtil.LATLON_PROJECTION, true); - } catch (Exception e) { - throw new VizException("Error transforming extent", e); - } - - // add the label field - String labelField = getCapability(LabelableCapability.class) - .getLabelField(); - - queryJob.request(target, this, env, labelField, - resourceData.getGoodnessField()); - } - @Override protected void paintInternal(IGraphicsTarget aTarget, PaintProperties paintProps) throws VizException { PixelExtent screenExtent = (PixelExtent) paintProps.getView() .getExtent(); + Rectangle canvasBounds = paintProps.getCanvasBounds(); + int screenWidth = canvasBounds.width; + double worldToScreenRatio = screenExtent.getWidth() / screenWidth; int displayWidth = (int) (descriptor.getMapWidth() * paintProps .getZoomLevel()); - double kmPerPixel = (displayWidth / paintProps.getCanvasBounds().width) / 1000.0; + double kmPerPixel = (displayWidth / screenWidth) / 1000.0; double magnification = getCapability(MagnificationCapability.class) .getMagnification(); @@ -437,12 +417,16 @@ public class DbPointMapResource extends .getLabelField(); boolean isLabeled = labelField != null; if ((isLabeled && !labelField.equals(lastLabelField)) - || lastExtent == null + || (lastExtent == null) || !lastExtent.getEnvelope().contains( clipToProjExtent(screenExtent).getEnvelope())) { if (!paintProps.isZooming()) { PixelExtent expandedExtent = getExpandedExtent(screenExtent); - requestData(aTarget, expandedExtent); + Geometry boundingGeom = buildBoundingGeometry(expandedExtent, + worldToScreenRatio, kmPerPixel); + + queryJob.request(aTarget, this, boundingGeom, labelField, + resourceData.getGoodnessField()); lastExtent = expandedExtent; lastLabelField = labelField; } @@ -497,9 +481,9 @@ public class DbPointMapResource extends try { if (node.getDistance() > threshold) { Coordinate c = node.screenLoc; - if (c != null && screenExtent.contains(c.x, c.y)) { + if ((c != null) && screenExtent.contains(c.x, c.y)) { points.add(new double[] { c.x, c.y, 0.0 }); - if (isLabeled && magnification != 0) { + if (isLabeled && (magnification != 0)) { DrawableString str = new DrawableString( node.label, color); str.setCoordinates(c.x + offsetX, c.y + offsetY); diff --git a/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/DefaultDbMapQuery.java b/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/DefaultDbMapQuery.java index 606bbbc5ba..9daccc9632 100644 --- a/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/DefaultDbMapQuery.java +++ b/cave/com.raytheon.uf.viz.core.maps/src/com/raytheon/uf/viz/core/maps/rsc/DefaultDbMapQuery.java @@ -28,10 +28,10 @@ import com.raytheon.uf.viz.core.catalog.DirectDbQuery; import com.raytheon.uf.viz.core.catalog.DirectDbQuery.QueryLanguage; import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.uf.viz.core.maps.rsc.DbMapQueryFactory.DbMapQuery; -import com.vividsolutions.jts.geom.Envelope; +import com.vividsolutions.jts.geom.Geometry; /** - * TODO Add Description + * Default implementation of DbMapQuery * *
  * 
@@ -42,6 +42,7 @@ import com.vividsolutions.jts.geom.Envelope;
  * Dec 9, 2011             bsteffen    Initial creation
  * Sep 18, 2012      #1019 randerso    cleaned up geometry type query
  * Jan 30, 2013      #1551 bkowal      Refactored
+ * Apr  9, 2014      #2997 randerso    Added queryWithinGeometry
  * 
  * 
* @@ -63,14 +64,14 @@ public class DefaultDbMapQuery implements DbMapQuery { } @Override - public QueryResult queryWithinEnvelope(Envelope env, List columns, + public QueryResult queryWithinGeometry(Geometry geom, List columns, List additionalConstraints) throws VizException { /* * Build the query using the common method. */ - final String query = MapsQueryUtil.assembleMapsTableQuery(env, columns, - additionalConstraints, this.table, this.geomField); + final String query = MapsQueryUtil.assembleMapsTableQuery(geom, + columns, additionalConstraints, this.table, this.geomField); return DirectDbQuery.executeMappedQuery(query.toString(), MAPS, QueryLanguage.SQL); diff --git a/cave/com.raytheon.uf.viz.core/src/com/raytheon/uf/viz/core/drawables/AbstractDescriptor.java b/cave/com.raytheon.uf.viz.core/src/com/raytheon/uf/viz/core/drawables/AbstractDescriptor.java index 5d51ceffaf..a8a4407432 100644 --- a/cave/com.raytheon.uf.viz.core/src/com/raytheon/uf/viz/core/drawables/AbstractDescriptor.java +++ b/cave/com.raytheon.uf.viz.core/src/com/raytheon/uf/viz/core/drawables/AbstractDescriptor.java @@ -78,6 +78,8 @@ import com.raytheon.uf.viz.core.time.TimeMatchingJob; * frames * Jul 03, 2013 2154 bsteffen Ensure all resource groups get * removed from the time matcher. + * Apr 09, 2014 2997 randerso Stopped printing stack trace for + * otherwise ignored exception * * * @author chammack @@ -182,8 +184,8 @@ public abstract class AbstractDescriptor extends ResourceGroup implements postRemoveListener(rp.getResource()); TimeMatchingJob.scheduleTimeMatch(AbstractDescriptor.this); - if (renderableDisplay != null - && renderableDisplay.getContainer() != null) { + if ((renderableDisplay != null) + && (renderableDisplay.getContainer() != null)) { IDisplayPaneContainer container = renderableDisplay .getContainer(); for (IDisplayPane pane : container.getDisplayPanes()) { @@ -198,7 +200,7 @@ public abstract class AbstractDescriptor extends ResourceGroup implements } protected void postAddListener(ResourcePair rp) { - if (rp.getResource() != null && getTimeMatcher() != null) { + if ((rp.getResource() != null) && (getTimeMatcher() != null)) { // We need to run time matching immediately beacuse order // constructed is important for time matching so we must do it now // instead of scheduling since another resource could be added by @@ -251,8 +253,7 @@ public abstract class AbstractDescriptor extends ResourceGroup implements } ResourceList rl = null; if (resource instanceof IResourceGroup) { - rl = ((IResourceGroup) resource) - .getResourceList(); + rl = ((IResourceGroup) resource).getResourceList(); } else if (resource.getResourceData() instanceof IResourceGroup) { rl = ((IResourceGroup) resource.getResourceData()) .getResourceList(); @@ -364,7 +365,8 @@ public abstract class AbstractDescriptor extends ResourceGroup implements int frameIndex = info.frameIndex; DataTime[] frames = info.frameTimes; if (frameCount <= getNumberOfFrames()) { - if (frames != null && frameIndex >= 0 && frames.length > frameIndex) { + if ((frames != null) && (frameIndex >= 0) + && (frames.length > frameIndex)) { restoredTime = frames[frameIndex]; } limitedNumberOfFrames = frameCount; @@ -379,7 +381,8 @@ public abstract class AbstractDescriptor extends ResourceGroup implements int frameIndex = info.frameIndex; DataTime[] frames = info.frameTimes; if (limitedNumberOfFrames <= getNumberOfFrames()) { - if (frames != null && frameIndex >= 0 && frames.length > frameIndex) { + if ((frames != null) && (frameIndex >= 0) + && (frames.length > frameIndex)) { restoredTime = frames[frameIndex]; } limitedNumberOfFrames = Integer.MAX_VALUE; @@ -517,7 +520,8 @@ public abstract class AbstractDescriptor extends ResourceGroup implements @Override public void setRenderableDisplay(IRenderableDisplay display) { - if (this.renderableDisplay == null || display.getDescriptor() == this) { + if ((this.renderableDisplay == null) + || (display.getDescriptor() == this)) { this.renderableDisplay = display; } } @@ -565,11 +569,11 @@ public abstract class AbstractDescriptor extends ResourceGroup implements String error = null; DataTime[] times = info.frameTimes; int idx = info.frameIndex; - if (times == null && idx >= 0) { + if ((times == null) && (idx >= 0)) { error = "Index should be less than zero when there are no frame times."; - } else if (times != null && idx >= times.length) { + } else if ((times != null) && (idx >= times.length)) { error = "Index must be less than the number of frames."; - } else if (idx < 0 && times != null && times.length > 0) { + } else if ((idx < 0) && (times != null) && (times.length > 0)) { error = "Index must be positive when frames are provided"; } if (times != null) { @@ -612,8 +616,8 @@ public abstract class AbstractDescriptor extends ResourceGroup implements FramesInfo oldInfo = new FramesInfo(oldTimes, oldIdx); oldTime = oldInfo.getCurrentFrame(); currTime = currInfo.getCurrentFrame(); - if ((oldTime != null && oldTime.equals(currTime) == false) - || (currTime != null && currTime.equals(oldTime) == false)) { + if (((oldTime != null) && (oldTime.equals(currTime) == false)) + || ((currTime != null) && (currTime.equals(oldTime) == false))) { frameChanged = true; } } @@ -629,7 +633,7 @@ public abstract class AbstractDescriptor extends ResourceGroup implements int idx = frameIndex; if (frames != null) { frames = Arrays.copyOf(frames, frames.length); - if (idx < 0 || idx >= frames.length) { + if ((idx < 0) || (idx >= frames.length)) { // This only happens for 4-panels with shared time managers. idx = frames.length - 1; } @@ -727,7 +731,7 @@ public abstract class AbstractDescriptor extends ResourceGroup implements */ @Override public final CoordinateReferenceSystem getCRS() { - if (gridGeometry != null && gridGeometry.getEnvelope() != null) { + if ((gridGeometry != null) && (gridGeometry.getEnvelope() != null)) { return gridGeometry.getEnvelope().getCoordinateReferenceSystem(); } else { return null; @@ -779,7 +783,7 @@ public abstract class AbstractDescriptor extends ResourceGroup implements try { pixelToWorld.transform(wpixel, 0, output, 0, 1); } catch (TransformException e) { - e.printStackTrace(); + // e.printStackTrace(); return null; } } else { diff --git a/cave/com.raytheon.uf.viz.thinclient.cave/src/com/raytheon/uf/viz/thinclient/cave/cache/map/CacheDbMapQuery.java b/cave/com.raytheon.uf.viz.thinclient.cave/src/com/raytheon/uf/viz/thinclient/cave/cache/map/CacheDbMapQuery.java index 81bb0414c3..e2f84b41dd 100644 --- a/cave/com.raytheon.uf.viz.thinclient.cave/src/com/raytheon/uf/viz/thinclient/cave/cache/map/CacheDbMapQuery.java +++ b/cave/com.raytheon.uf.viz.thinclient.cave/src/com/raytheon/uf/viz/thinclient/cave/cache/map/CacheDbMapQuery.java @@ -39,7 +39,7 @@ import com.vividsolutions.jts.io.ParseException; import com.vividsolutions.jts.io.WKBReader; /** - * TODO Add Description + * DbMapQuery implementation using client side cache * *
  * 
@@ -48,6 +48,7 @@ import com.vividsolutions.jts.io.WKBReader;
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
  * Dec 9, 2011            bsteffen     Initial creation
+ * Apr 9, 2014   #2997    randerso     Added queryWithinGeometry
  * 
  * 
* @@ -102,8 +103,7 @@ public class CacheDbMapQuery extends DefaultDbMapQuery { } } - @Override - public QueryResult queryWithinEnvelope(Envelope env, List columns, + private QueryResult queryWithinEnvelope(Envelope env, List columns, List additionalConstraints) throws VizException { fillCache(geomField, columns); List items = tree.query(env); @@ -116,7 +116,7 @@ public class CacheDbMapQuery extends DefaultDbMapQuery { List rows = new ArrayList(); for (int i = 0; i < items.size(); i++) { int rowNumber = (Integer) items.get(i); - if (validGIDs != null + if ((validGIDs != null) && !validGIDs.contains(data.getRowColumnValue(rowNumber, GID))) { continue; @@ -135,6 +135,20 @@ public class CacheDbMapQuery extends DefaultDbMapQuery { return new QueryResult(columnNames, rows.toArray(new QueryResultRow[0])); } + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.viz.core.maps.rsc.DefaultDbMapQuery#queryWithinGeometry + * (com.vividsolutions.jts.geom.Geometry, java.util.List, java.util.List) + */ + @Override + public QueryResult queryWithinGeometry(Geometry geom, List columns, + List additionalConstraints) throws VizException { + return queryWithinEnvelope(geom.getEnvelopeInternal(), columns, + additionalConstraints); + } + private List getIndices(String constraint) throws VizException { synchronized (constraint2indices) { List indices = constraint2indices.get(constraint); diff --git a/cave/com.raytheon.viz.core/src/com/raytheon/viz/core/rsc/jts/JTSCompiler.java b/cave/com.raytheon.viz.core/src/com/raytheon/viz/core/rsc/jts/JTSCompiler.java index 7d8090bc2c..2afde2c49e 100644 --- a/cave/com.raytheon.viz.core/src/com/raytheon/viz/core/rsc/jts/JTSCompiler.java +++ b/cave/com.raytheon.viz.core/src/com/raytheon/viz/core/rsc/jts/JTSCompiler.java @@ -21,7 +21,6 @@ package com.raytheon.viz.core.rsc.jts; import org.eclipse.swt.graphics.RGB; import org.opengis.referencing.FactoryException; -import org.opengis.referencing.operation.TransformException; import com.raytheon.uf.common.geospatial.ReferencedGeometry; import com.raytheon.uf.common.geospatial.util.WorldWrapCorrector; @@ -54,6 +53,7 @@ import com.vividsolutions.jts.geom.prep.PreparedGeometryFactory; * ------------ ---------- ----------- -------------------------- * Oct 24, 2006 chammack Initial Creation. * Feb 14, 2014 2804 mschenke Rewrote to move clipping from GLWireframeShape2D to here + * Apr 21, 2014 2997 randerso Improved error handling in handle(ReferencedGeometry, JTSGeometryData) * * * @@ -354,7 +354,7 @@ public class JTSCompiler { boolean clipped) throws VizException { if (geom instanceof GeometryCollection) { handleGeometryCollection((GeometryCollection) geom, data, clipped); - } else if (clipped == false && data.isClipping()) { + } else if ((clipped == false) && data.isClipping()) { geom = complexClip(geom, data.getClippingArea()); if (geom.isEmpty() == false) { disposition(geom, data, true); @@ -469,14 +469,14 @@ public class JTSCompiler { */ public void handle(ReferencedGeometry geom, JTSGeometryData data) throws VizException { - if (corrector != null && corrector.needsCorrecting() + if ((corrector != null) && corrector.needsCorrecting() && data.isWorldWrapCorrect()) { try { geom = new ReferencedGeometry( corrector.correct(geom.asLatLon())); } catch (FactoryException e) { throw new VizException("Error creating transform to Lat/Lon", e); - } catch (TransformException e) { + } catch (Exception e) { throw new VizException( "Error transforming geometry into Lat/Lon", e); } @@ -487,7 +487,7 @@ public class JTSCompiler { } catch (FactoryException e) { throw new VizException( "Error creating transform to descriptor pixel space", e); - } catch (TransformException e) { + } catch (Exception e) { throw new VizException( "Error transforming geometry into descriptor pixel space", e); diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.maps/src/com/raytheon/uf/common/dataplugin/maps/dataaccess/util/MapsQueryUtil.java b/edexOsgi/com.raytheon.uf.common.dataplugin.maps/src/com/raytheon/uf/common/dataplugin/maps/dataaccess/util/MapsQueryUtil.java index d87351dffb..8fbc3e18fd 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.maps/src/com/raytheon/uf/common/dataplugin/maps/dataaccess/util/MapsQueryUtil.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.maps/src/com/raytheon/uf/common/dataplugin/maps/dataaccess/util/MapsQueryUtil.java @@ -19,11 +19,11 @@ **/ package com.raytheon.uf.common.dataplugin.maps.dataaccess.util; -import java.util.ArrayList; import java.util.Iterator; import java.util.List; import com.vividsolutions.jts.geom.Envelope; +import com.vividsolutions.jts.geom.Geometry; /** * A utility to construct a query that will be used to retrieve information from @@ -35,7 +35,8 @@ import com.vividsolutions.jts.geom.Envelope; * * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Jan 28, 2013 bkowal Initial creation + * Jan 28, 2013 bkowal Initial creation + * Apr 09, 2014 #2997 randerso Added support to query against a Geometry * * * @@ -45,12 +46,47 @@ import com.vividsolutions.jts.geom.Envelope; public class MapsQueryUtil { + /** + * PostGIS Spatial Reference ID (EPSG code) for WGS84. + */ + private static final int WGS84_SRID = 4326; + /** * */ private MapsQueryUtil() { } + /** + * Builds a query that can be used to query the maps table based on the + * provided information. + * + * @param boundingGeom + * used to limit the selected information to a certain + * geographical area + * @param columns + * the list of columns that will be included in the SELECT + * statement + * @param additionalConstraints + * the list of constraints that will become part of the AND + * statement + * @param table + * the table to select data from + * @param geomField + * the name of the geometry field of interest + * @return the query + */ + public static String assembleMapsTableQuery(Geometry boundingGeom, + List columns, List additionalConstraints, + String table, String geomField) { + + String geospatialConstraint = "ST_Intersects(the_geom, ST_GeometryFromText('" + + boundingGeom.toText() + "', " + WGS84_SRID + "))"; + + return assembleMapsTableQuery(geospatialConstraint, columns, + additionalConstraints, table, geomField); + } + /** * Builds a query that can be used to query the maps table based on the * provided information. @@ -73,24 +109,20 @@ public class MapsQueryUtil { public static String assembleMapsTableQuery(Envelope env, List columns, List additionalConstraints, String table, String geomField) { - // add the geospatial constraint - if (env != null) { - // copy before modifying - if (additionalConstraints == null) { - additionalConstraints = new ArrayList(); - } else { - additionalConstraints = new ArrayList( - additionalConstraints); - } - // geospatial constraint will be first - additionalConstraints.add(0, String.format( - "%s && ST_SetSrid('BOX3D(%f %f, %f %f)'::box3d,4326)", - geomField, env.getMinX(), env.getMinY(), env.getMaxX(), - env.getMaxY())); - } + String geospatialConstraint = String.format( + "%s && ST_SetSrid('BOX3D(%f %f, %f %f)'::box3d," + WGS84_SRID + + ")", geomField, env.getMinX(), env.getMinY(), + env.getMaxX(), env.getMaxY()); + return assembleMapsTableQuery(geospatialConstraint, columns, + additionalConstraints, table, geomField); + } + + private static String assembleMapsTableQuery(String geospatialConstraint, + List columns, List additionalConstraints, + String table, String geomField) { StringBuilder query = new StringBuilder("SELECT "); - if (columns != null && !columns.isEmpty()) { + if ((columns != null) && !columns.isEmpty()) { Iterator iter = columns.iterator(); query.append(iter.next()); while (iter.hasNext()) { @@ -102,9 +134,19 @@ public class MapsQueryUtil { query.append(" FROM "); query.append(table); - // add any additional constraints - if (additionalConstraints != null && !additionalConstraints.isEmpty()) { + // add the geospatial constraint + if (geospatialConstraint != null) { query.append(" WHERE "); + query.append(geospatialConstraint); + } + + // add any additional constraints + if ((additionalConstraints != null) && !additionalConstraints.isEmpty()) { + if (geospatialConstraint == null) { + query.append(" WHERE "); + } else { + query.append(" AND "); + } Iterator iter = additionalConstraints.iterator(); query.append(iter.next()); while (iter.hasNext()) { diff --git a/edexOsgi/com.raytheon.uf.common.geospatial/src/com/raytheon/uf/common/geospatial/GeometryTransformer.java b/edexOsgi/com.raytheon.uf.common.geospatial/src/com/raytheon/uf/common/geospatial/GeometryTransformer.java new file mode 100644 index 0000000000..16e1383dcf --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.geospatial/src/com/raytheon/uf/common/geospatial/GeometryTransformer.java @@ -0,0 +1,344 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.common.geospatial; + +import java.util.ArrayList; +import java.util.List; + +import org.geotools.geometry.jts.CoordinateSequenceTransformer; +import org.geotools.geometry.jts.DefaultCoordinateSequenceTransformer; +import org.opengis.referencing.crs.CoordinateReferenceSystem; +import org.opengis.referencing.operation.MathTransform; +import org.opengis.referencing.operation.TransformException; + +import com.vividsolutions.jts.geom.CoordinateSequence; +import com.vividsolutions.jts.geom.CoordinateSequenceFactory; +import com.vividsolutions.jts.geom.Geometry; +import com.vividsolutions.jts.geom.GeometryCollection; +import com.vividsolutions.jts.geom.GeometryFactory; +import com.vividsolutions.jts.geom.LineString; +import com.vividsolutions.jts.geom.LinearRing; +import com.vividsolutions.jts.geom.MultiLineString; +import com.vividsolutions.jts.geom.MultiPoint; +import com.vividsolutions.jts.geom.MultiPolygon; +import com.vividsolutions.jts.geom.Point; +import com.vividsolutions.jts.geom.Polygon; + +/** + * Replacement for GeoTools GeometryCoordinateSequenceTransformer that can + * handle conversion of polygons containing NaNs. + * + * Had to copy the entire class and modify it since it was not written to be + * subclassed. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 16, 2014 #2997      randerso    Initial creation
+ * 
+ * 
+ * + * @author randerso + * @version 1.0 + */ + +public class GeometryTransformer { + + private MathTransform transform = null; + + private CoordinateReferenceSystem crs; + + private CoordinateSequenceTransformer inputCSTransformer = null; + + private CoordinateSequenceTransformer csTransformer = null; + + private GeometryFactory currGeometryFactory = null; + + /** + * Creates a transformer which uses the {@link CoordinateSequenceFactory} of + * the source geometries. + */ + public GeometryTransformer() { + // the csTransformer is initialized from the first geometry + // and the supplied transform + } + + /** + * Creates a transformer which uses a client-specified + * {@link CoordinateSequenceTransformer}. + *

+ * WARNING: The CoordinateSequenceTransformer must use the same + * {@link CoordinateSequenceFactory} as the output GeometryFactory, so that + * geometries are constructed consistently. + * + * @param transformer + */ + public GeometryTransformer(CoordinateSequenceTransformer transformer) { + inputCSTransformer = transformer; + csTransformer = transformer; + } + + /** + * Sets the math transform to be used for transformation + * + * @param transform + */ + public void setMathTransform(MathTransform transform) { + this.transform = transform; + } + + /** + * Sets the target coordinate reference system. + *

+ * This value is used to set the coordinate reference system of geometries + * after they have been transformed. + *

+ * + * @param crs + * The target coordinate reference system. + */ + public void setCoordinateReferenceSystem(CoordinateReferenceSystem crs) { + this.crs = crs; + } + + /** + * Initializes the internal CoordinateSequenceTransformer if not specified + * explicitly. + * + * @param gf + * the factory to use + */ + private void init(GeometryFactory gf) { + // don't init if csTransformer already exists + if (inputCSTransformer != null) { + return; + } + // don't reinit if gf is the same (the usual case) + if (currGeometryFactory == gf) { + return; + } + + currGeometryFactory = gf; + CoordinateSequenceFactory csf = gf.getCoordinateSequenceFactory(); + csTransformer = new DefaultCoordinateSequenceTransformer(csf); + } + + /** + * Applies the transform to the provided geometry, creating a new + * transformed geometry. + * + * @param g + * the geometry to transform + * @return a new transformed geometry + * @throws TransformException + */ + public Geometry transform(Geometry g) throws TransformException { + GeometryFactory factory = g.getFactory(); + Geometry transformed = null; + + // lazily init csTransformer using geometry's CSFactory + init(factory); + + if (g instanceof Point) { + transformed = transformPoint((Point) g, factory); + } else if (g instanceof MultiPoint) { + MultiPoint mp = (MultiPoint) g; + Point[] points = new Point[mp.getNumGeometries()]; + + for (int i = 0; i < points.length; i++) { + points[i] = transformPoint((Point) mp.getGeometryN(i), factory); + } + + transformed = factory.createMultiPoint(points); + } else if (g instanceof LineString) { + transformed = transformLineString((LineString) g, factory); + } else if (g instanceof MultiLineString) { + MultiLineString mls = (MultiLineString) g; + LineString[] lines = new LineString[mls.getNumGeometries()]; + + for (int i = 0; i < lines.length; i++) { + lines[i] = transformLineString( + (LineString) mls.getGeometryN(i), factory); + } + + transformed = factory.createMultiLineString(lines); + } else if (g instanceof Polygon) { + transformed = transformPolygon((Polygon) g, factory); + } else if (g instanceof MultiPolygon) { + // changed from original GeoTools implementation + // to handle transformPolygon possibly returning LineStrings instead for polygons + MultiPolygon mp = (MultiPolygon) g; + int n = mp.getNumGeometries(); + List polygons = new ArrayList(n); + + for (int i = 0; i < n; i++) { + polygons.add(transformPolygon((Polygon) mp.getGeometryN(i), + factory)); + } + + transformed = factory.buildGeometry(polygons); + } else if (g instanceof GeometryCollection) { + GeometryCollection gc = (GeometryCollection) g; + Geometry[] geoms = new Geometry[gc.getNumGeometries()]; + + for (int i = 0; i < geoms.length; i++) { + geoms[i] = transform(gc.getGeometryN(i)); + } + + transformed = factory.createGeometryCollection(geoms); + } else { + throw new IllegalArgumentException("Unsupported geometry type " + + g.getClass()); + } + + // copy over user data + // do a special check for coordinate reference system + transformed.setUserData(g.getUserData()); + + if ((g.getUserData() == null) + || (g.getUserData() instanceof CoordinateReferenceSystem)) { + // set the new one to be the target crs + if (crs != null) { + transformed.setUserData(crs); + } + } + + return transformed; + } + + /** + * + * @param ls + * @param gf + * @return transformed lineString + * @throws TransformException + */ + public LineString transformLineString(LineString ls, GeometryFactory gf) + throws TransformException { + + // if required, init csTransformer using geometry's CSFactory + init(gf); + + CoordinateSequence cs = projectCoordinateSequence(ls + .getCoordinateSequence()); + LineString transformed = null; + + // changed from original GeoTools implementation + // to check if CoordinateSequence is closed and return LineString if not + if (isClosed(cs)) { + transformed = gf.createLinearRing(cs); + } else { + transformed = gf.createLineString(cs); + } + + transformed.setUserData(ls.getUserData()); + return transformed; + } + + // changed from original GeoTools implementation + // added function to check if CoordinateSequence + // is closed and contains enough points to be a + // LinearRing + private boolean isClosed(CoordinateSequence cs) { + if (cs.size() < 4) { + return false; + } + return cs.getCoordinate(0).equals2D(cs.getCoordinate(cs.size() - 1)); + } + + /** + * @param point + * @param gf + * @return transformed point + * + * @throws TransformException + */ + public Point transformPoint(Point point, GeometryFactory gf) + throws TransformException { + + // if required, init csTransformer using geometry's CSFactory + init(gf); + + CoordinateSequence cs = projectCoordinateSequence(point + .getCoordinateSequence()); + Point transformed = gf.createPoint(cs); + transformed.setUserData(point.getUserData()); + return transformed; + } + + /** + * @param cs + * a CoordinateSequence + * @return + * + * @throws TransformException + */ + private CoordinateSequence projectCoordinateSequence(CoordinateSequence cs) + throws TransformException { + return csTransformer.transform(cs, transform); + } + + /** + * @param polygon + * @param gf + * @return transformed Polygon or MultiLineString if Polygon no longer + * closes + * @throws TransformException + */ + public Geometry transformPolygon(Polygon polygon, GeometryFactory gf) + throws TransformException { + // changed from original GeoTools implementation + // to return LineStrings if polygon no longer closed due to NaNs + // returned by projection transformation (point outside valid range for projection) + LineString[] lineStrings = new LineString[polygon.getNumInteriorRing() + 1]; + + lineStrings[0] = transformLineString(polygon.getExteriorRing(), gf); + + for (int i = 1; i < lineStrings.length; i++) { + lineStrings[i] = transformLineString( + polygon.getInteriorRingN(i - 1), gf); + } + + boolean closed = true; + for (LineString ls : lineStrings) { + if (!ls.isClosed()) { + closed = false; + break; + } + } + + Geometry transformed; + if (closed) { + LinearRing[] interiors = new LinearRing[lineStrings.length - 1]; + for (int i = 0; i < interiors.length; i++) { + interiors[i] = (LinearRing) lineStrings[i + 1]; + } + transformed = gf.createPolygon((LinearRing) lineStrings[0], + interiors); + } else { + transformed = gf.createMultiLineString(lineStrings); + } + transformed.setUserData(polygon.getUserData()); + return transformed; + } +} diff --git a/edexOsgi/com.raytheon.uf.common.geospatial/src/com/raytheon/uf/common/geospatial/ReferencedGeometry.java b/edexOsgi/com.raytheon.uf.common.geospatial/src/com/raytheon/uf/common/geospatial/ReferencedGeometry.java index b8cf76d9dd..34088055bb 100644 --- a/edexOsgi/com.raytheon.uf.common.geospatial/src/com/raytheon/uf/common/geospatial/ReferencedGeometry.java +++ b/edexOsgi/com.raytheon.uf.common.geospatial/src/com/raytheon/uf/common/geospatial/ReferencedGeometry.java @@ -22,7 +22,6 @@ package com.raytheon.uf.common.geospatial; import org.geotools.coverage.grid.GeneralGridGeometry; import org.geotools.geometry.jts.CoordinateSequenceTransformer; import org.geotools.geometry.jts.DefaultCoordinateSequenceTransformer; -import org.geotools.geometry.jts.GeometryCoordinateSequenceTransformer; import org.opengis.referencing.operation.MathTransform; import org.opengis.referencing.operation.TransformException; @@ -39,6 +38,7 @@ import com.vividsolutions.jts.geom.impl.PackedCoordinateSequenceFactory; * ------------ ---------- ----------- -------------------------- * Dec 29, 2008 chammack Initial creation * Feb 18, 2014 #2819 randerso Made transform non-destructive + * Apr 16, 2014 #2997 randerso Changed to use our GeometryTransformer * * * @@ -100,8 +100,7 @@ public class ReferencedGeometry extends ReferencedObject { protected Geometry transform(MathTransform mt) throws TransformException { CoordinateSequenceTransformer t1 = new DefaultCoordinateSequenceTransformer( PackedCoordinateSequenceFactory.DOUBLE_FACTORY); - final GeometryCoordinateSequenceTransformer transformer = new GeometryCoordinateSequenceTransformer( - t1); + final GeometryTransformer transformer = new GeometryTransformer(t1); transformer.setMathTransform(mt); return transformer.transform(this.internalObject); From 5bc1f147c9efd9df2b925d5e733a63c9befd1720 Mon Sep 17 00:00:00 2001 From: Dave Hladky Date: Mon, 21 Apr 2014 15:08:30 -0500 Subject: [PATCH 067/188] Issue #2887 Previously missed check for start/end of sub (isExpired()). Change-Id: I9a720b8db129ff7b82547531240d055499a57cfe Former-commit-id: 9af92514064e0c994be6d285f66f17c922e9d428 --- .../uf/common/datadelivery/registry/Subscription.java | 8 ++++++++ .../datadelivery/bandwidth/util/BandwidthDaoUtil.java | 8 +++++++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/Subscription.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/Subscription.java index 04df1eca63..533463d2cb 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/Subscription.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/Subscription.java @@ -50,6 +50,7 @@ import com.raytheon.uf.common.datadelivery.registry.Utils.SubscriptionStatus; * Jan 24, 2013 2709 bgonzale Added method inActivePeriodWindow. * Feb 05, 2014 2677 mpduff Add subscription state getter/setter. * Apr 02, 2014 2810 dhladky Priority sorting of subscriptions. + * Apr 21, 2014 2887 dhladky Added shouldScheduleForTime() to interface. * * * @@ -730,4 +731,11 @@ public interface Subscription extends Compar * @return This subscrition's state */ SubscriptionState getSubscriptionState(); + + /** + * Check against activePeriod and Start/End of subscription + * @param checkCal + * @return + */ + boolean shouldScheduleForTime(Calendar checkCal); } \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/util/BandwidthDaoUtil.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/util/BandwidthDaoUtil.java index ad879e6701..dbaf01baeb 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/util/BandwidthDaoUtil.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/util/BandwidthDaoUtil.java @@ -84,6 +84,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalStatus; * active period. * Jan 29, 2014 2636 mpduff Scheduling refactor. * Feb 11, 2014 2636 mpduff Change how retrieval times are calculated. + * Apr 21, 2014 2887 dhladky Missed start/end in previous call, needs shouldScheduleForTime(); * * * @author djohnson @@ -229,8 +230,13 @@ public class BandwidthDaoUtil { * Fine grain check by hour and minute, for * subscription(start/end), activePeriod(start/end) */ + + // TODO: IMPORTANT NOTE: WHEN 14.2.1 MERGES IN. THIS NEEDS + // TO CHECK AGAINST THE OFFSET BASE REFTIME, THE BASE REFTIME + // WILL BE WHAT IS ADDED IF THE CHECK IS TRUE. DO NOT BLINDLY + // MERGE 14.2.1's CODE OVER THIS. if (!subscription - .inActivePeriodWindow(retrievalTime)) { + .shouldScheduleForTime(retrievalTime)) { // don't schedule this retrieval time, // outside subscription window continue; From ed99abbb9d82f8ea562270dfe65f5caaa2b02d62 Mon Sep 17 00:00:00 2001 From: Ron Anderson Date: Mon, 21 Apr 2014 17:26:29 -0500 Subject: [PATCH 068/188] Issue #2998 Fix regression made in earlier check in. Change-Id: Ic7c915fef09b3398e2946d8e7688e5d2997acc71 Former-commit-id: 8c48d369b3b6af0222b541ccfa9230495d4cb0f9 --- .../gisdatastore/rsc/DataStoreResource.java | 23 +++++++++++-------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/DataStoreResource.java b/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/DataStoreResource.java index 87ee8cc4f7..62e9c8bc6d 100644 --- a/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/DataStoreResource.java +++ b/cave/com.raytheon.uf.viz.gisdatastore/src/com/raytheon/uf/viz/gisdatastore/rsc/DataStoreResource.java @@ -23,7 +23,7 @@ import java.awt.geom.Rectangle2D; import java.io.IOException; import java.util.ArrayList; import java.util.Collections; -import java.util.HashMap; +import java.util.LinkedHashMap; import java.util.List; import java.util.Map; import java.util.Set; @@ -454,7 +454,9 @@ public class DataStoreResource extends */ private TimeRange timeRange; - private Map> attrTypeMap; + // Intentionally declaring as a LinkedHashMap + // to ensure insertion order is preserved. + private LinkedHashMap> attrTypeMap; private Object[][] attributes; @@ -628,12 +630,12 @@ public class DataStoreResource extends .getAttributeDescriptors(); if (attrDesc == null) { - attrTypeMap = new HashMap>(1); + attrTypeMap = new LinkedHashMap>(1); attrTypeMap.put(ID_ATTRIBUTE_NAME, Integer.class); } else { - attrTypeMap = new HashMap>(attrDesc.size(), - 1.0f); + attrTypeMap = new LinkedHashMap>( + attrDesc.size(), 1.0f); attrTypeMap.put(ID_ATTRIBUTE_NAME, Integer.class); for (AttributeDescriptor at : attrDesc) { Class atType = at.getType().getBinding(); @@ -707,11 +709,14 @@ public class DataStoreResource extends da.setCentroid((Point) JTS.transform(g.getCentroid(), incomingToLatLon)); - attributes[index][0] = id; - int j = 1; + int j = 0; for (String attrName : attributeNames) { - Object attr = f.getAttribute(attrName); - attributes[index][j++] = attr; + if (attrName.equals(ID_ATTRIBUTE_NAME)) { + attributes[index][j++] = id; + } else { + Object attr = f.getAttribute(attrName); + attributes[index][j++] = attr; + } } } } catch (Exception e) { From a37a2afe18e66e5ba1a5ba513eda32f1ec938cfc Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Mon, 21 Apr 2014 13:20:19 -0500 Subject: [PATCH 069/188] Issue #2060 dropping grid dataURI column Change-Id: I8b8ba3f2ec71e15aa3c40e7eab42525dbf09157e Former-commit-id: 1aab87d9572089a09351ebdfb8fbcef884866feb --- .../FlashFloodGuidanceDataManager.java | 46 ++++------ deltaScripts/14.3.1/dropGridDataURI.sh | 41 +++++++++ .../EnsembleGridAssembler.java | 11 +-- .../uf/common/dataplugin/ffmp/FFMPUtils.java | 8 +- .../dataplugin/grid/GridInfoRecord.java | 6 +- .../uf/common/dataplugin/grid/GridRecord.java | 14 +-- .../database/plugin/DataURIDatabaseUtil.java | 87 +++++++++++++++++++ .../util/RetrievalGeneratorUtilities.java | 38 ++------ .../grid/staticdata/StaticDataGenerator.java | 17 ++-- .../uf/edex/ohd/pproc/ArealQpeGenSrv.java | 32 +++---- .../com/raytheon/uf/edex/ohd/pproc/GAFF.java | 17 ++-- .../raytheon/uf/edex/ohd/pproc/GAFFDB.java | 19 ++-- 12 files changed, 201 insertions(+), 135 deletions(-) create mode 100644 deltaScripts/14.3.1/dropGridDataURI.sh create mode 100644 edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/DataURIDatabaseUtil.java diff --git a/cave/com.raytheon.viz.hydro/src/com/raytheon/viz/hydro/flashfloodguidance/FlashFloodGuidanceDataManager.java b/cave/com.raytheon.viz.hydro/src/com/raytheon/viz/hydro/flashfloodguidance/FlashFloodGuidanceDataManager.java index 96db3484ed..e5c9a1a6d9 100644 --- a/cave/com.raytheon.viz.hydro/src/com/raytheon/viz/hydro/flashfloodguidance/FlashFloodGuidanceDataManager.java +++ b/cave/com.raytheon.viz.hydro/src/com/raytheon/viz/hydro/flashfloodguidance/FlashFloodGuidanceDataManager.java @@ -19,7 +19,6 @@ **/ package com.raytheon.viz.hydro.flashfloodguidance; -import java.io.FileNotFoundException; import java.text.SimpleDateFormat; import java.util.Date; import java.util.HashMap; @@ -27,12 +26,10 @@ import java.util.List; import java.util.Map; import java.util.TimeZone; -import com.raytheon.uf.common.dataplugin.PluginException; import com.raytheon.uf.common.dataplugin.grid.GridConstants; import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataquery.requests.RequestConstraint; import com.raytheon.uf.common.dataquery.requests.RequestConstraint.ConstraintType; -import com.raytheon.uf.common.datastorage.StorageException; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; @@ -51,6 +48,7 @@ import com.raytheon.viz.hydrocommon.HydroConstants; * ------------ ---------- ----------- -------------------------- * 03Sept2008 #1507 dhladky Initial Creation. * 12Oct2009 2256 mpduff Added additional data query capability. + * Apr 21, 2014 2060 njensen Remove dependency on grid dataURI column * * * @@ -59,13 +57,12 @@ import com.raytheon.viz.hydrocommon.HydroConstants; */ public class FlashFloodGuidanceDataManager { - private static final transient IUFStatusHandler statusHandler = UFStatus.getHandler(FlashFloodGuidanceDataManager.class); + private static final transient IUFStatusHandler statusHandler = UFStatus + .getHandler(FlashFloodGuidanceDataManager.class); + /** Instance of this class */ private static FlashFloodGuidanceDataManager instance = null; - private static final String LINESEGS_QUERY = "select hrap_row, hrap_beg_col, " - + "hrap_end_col, area from linesegs"; - /** RFC Site name to RFC lookup map */ public static Map RFCMAP = new HashMap(); @@ -136,8 +133,6 @@ public class FlashFloodGuidanceDataManager { query.addColumn(GridConstants.DATASET_ID); query.addColumn(GridConstants.PARAMETER_ABBREVIATION); query.addColumn("dataTime.refTime"); - query.addColumn("dataURI"); - query.addColumn("id"); query.addConstraint(GridConstants.DATASET_ID, new RequestConstraint( "FFG%", ConstraintType.LIKE)); query.addConstraint(GridConstants.SECONDARY_ID, "Version0"); @@ -174,8 +169,7 @@ public class FlashFloodGuidanceDataManager { return null; } - public GridRecord getGridRecord(String uri) throws PluginException, - FileNotFoundException, StorageException { + public GridRecord getGridRecord(String uri) { StringBuilder query = new StringBuilder(); query.append("from " + com.raytheon.uf.common.dataplugin.grid.GridRecord.class @@ -197,8 +191,9 @@ public class FlashFloodGuidanceDataManager { List rs = null; try { - rs = DirectDbQuery.executeQuery("select area_id, interior_lat, interior_lon from geoArea " + where, - HydroConstants.IHFS, QueryLanguage.SQL); + rs = DirectDbQuery.executeQuery( + "select area_id, interior_lat, interior_lon from geoArea " + + where, HydroConstants.IHFS, QueryLanguage.SQL); } catch (VizException e) { statusHandler.handle(Priority.PROBLEM, "FFG Query" + " Error querying GeoArea table"); @@ -207,7 +202,8 @@ public class FlashFloodGuidanceDataManager { return rs; } - public List getContingencyValue(String areaId, int duration, Date refTime) { + public List getContingencyValue(String areaId, int duration, + Date refTime) { List rs = null; SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); sdf.setTimeZone(TimeZone.getTimeZone("GMT")); @@ -227,14 +223,14 @@ public class FlashFloodGuidanceDataManager { dur = 2001; } - String where = " where pe = 'PP' and ts = 'CF' and " + - "validtime >= '" + date + "' and lid = '" + areaId + "' " + - "and dur = " + dur + " order by validtime desc;"; + String where = " where pe = 'PP' and ts = 'CF' and " + "validtime >= '" + + date + "' and lid = '" + areaId + "' " + "and dur = " + dur + + " order by validtime desc;"; try { - rs = DirectDbQuery.executeQuery("select lid, validtime, value from " + - "contingencyvalue " + where, - HydroConstants.IHFS, QueryLanguage.SQL); + rs = DirectDbQuery.executeQuery( + "select lid, validtime, value from " + "contingencyvalue " + + where, HydroConstants.IHFS, QueryLanguage.SQL); } catch (VizException e) { statusHandler.handle(Priority.PROBLEM, "FFG Query" + " Error querying ContingencyValue table"); @@ -246,15 +242,11 @@ public class FlashFloodGuidanceDataManager { public List getContingencyValue(String boundaryType) { List rs = null; - - String where = " where pe='PP' and ts='CF' and lid in (select area_id from " + - "GeoArea where boundary_type = '" + boundaryType.toUpperCase() + - "') order by validtime desc, dur asc"; String sql = "select distinct(validtime), dur from contingencyvalue"; - + try { - rs = DirectDbQuery.executeQuery(sql, - HydroConstants.IHFS, QueryLanguage.SQL); + rs = DirectDbQuery.executeQuery(sql, HydroConstants.IHFS, + QueryLanguage.SQL); } catch (VizException e) { statusHandler.handle(Priority.PROBLEM, "FFG Query" + " Error querying ContingencyValue table"); diff --git a/deltaScripts/14.3.1/dropGridDataURI.sh b/deltaScripts/14.3.1/dropGridDataURI.sh new file mode 100644 index 0000000000..9b979efefc --- /dev/null +++ b/deltaScripts/14.3.1/dropGridDataURI.sh @@ -0,0 +1,41 @@ +#!/bin/bash +# DR #2060 - this update script will drop the dataURI column from the grid table + +PSQL="/awips2/psql/bin/psql" + +# drops the datauri constraint and column if they exist +function dropDatauri { + echo "INFO: Dropping DataURI column from grid" + ${PSQL} -U awips -d metadata -c "ALTER TABLE grid DROP CONSTRAINT IF EXISTS grid_datauri_key;" + ${PSQL} -U awips -d metadata -c "ALTER TABLE grid DROP COLUMN IF EXISTS datauri;" + if [ $? -ne 0 ]; then + echo "ERROR: Failed to drop dataURI column for grid" + echo "FATAL: The update has failed." + exit 1 + fi +} + + +# takes three args: table, constraint name, unique columns +# will first drop the constraint if it exists and then adds it back, this is +# fairly inefficient if it does exist but operationally it won't exist and for +# testing this allows the script to be run easily as a noop. +function dropAndAddConstraint { + ${PSQL} -U awips -d metadata -c "ALTER TABLE $1 DROP CONSTRAINT IF EXISTS $2;" + ${PSQL} -U awips -d metadata -c "ALTER TABLE $1 ADD CONSTRAINT $2 UNIQUE $3;" + if [ $? -ne 0 ]; then + echo "ERROR: Failed to add new unique constraint for $1" + echo "FATAL: The update has failed." + exit 1 + fi + ${PSQL} -U awips -d metadata -c "VACUUM FULL ANALYZE $1" +} + +echo "INFO: Dropping dataURI columns." + +dropDatauri +dropAndAddConstraint grid grid_reftime_forecasttime_rangestart_rangeend_info_id "(refTime, forecastTime, rangestart, rangeend, info_id)" +dropAndAddConstraint grid_info grid_info_datasetid_secondaryid_ensembleid_location_id_parameter_abbreviation_level_id "(datasetid, secondaryid, ensembleid, location_id, parameter_abbreviation, level_id)" + + +echo "INFO: grid dataURI column dropped successfully" diff --git a/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/decoderpostprocessors/EnsembleGridAssembler.java b/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/decoderpostprocessors/EnsembleGridAssembler.java index 761a8076e0..49e2ddab4b 100644 --- a/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/decoderpostprocessors/EnsembleGridAssembler.java +++ b/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/decoderpostprocessors/EnsembleGridAssembler.java @@ -58,8 +58,8 @@ import com.raytheon.uf.edex.core.EDEXUtil; import com.raytheon.uf.edex.database.cluster.ClusterLockUtils; import com.raytheon.uf.edex.database.cluster.ClusterLockUtils.LockState; import com.raytheon.uf.edex.database.cluster.ClusterTask; +import com.raytheon.uf.edex.database.plugin.DataURIDatabaseUtil; import com.raytheon.uf.edex.database.plugin.PluginFactory; -import com.raytheon.uf.edex.database.query.DatabaseQuery; import com.raytheon.uf.edex.plugin.grid.dao.GridDao; /** @@ -81,6 +81,7 @@ import com.raytheon.uf.edex.plugin.grid.dao.GridDao; * Oct 15, 2013 2473 bsteffen Remove deprecated method calls. * Nov 19, 2013 2478 rjpeter Make update process update database also. * Dec 06, 2013 2170 rjpeter Update to pass PluginDataObject[] to notification. + * Apr 21, 2014 2060 njensen Remove dependency on grid dataURI column * * * @author bphillip @@ -214,15 +215,11 @@ public class EnsembleGridAssembler implements IDecoderPostProcessor { */ private void processGrid(GridRecord record, CompositeModel thinned) throws Exception { - GridDao dao = (GridDao) PluginFactory.getInstance().getPluginDao( GridConstants.GRID); GridRecord assembledRecord = createAssembledRecord(record, thinned); - DatabaseQuery query = new DatabaseQuery(GridRecord.class); - query.addReturnedField("dataURI"); - query.addQueryParam("dataURI", assembledRecord.getDataURI()); - List result = dao.queryByCriteria(query); - if (result.isEmpty()) { + boolean exists = DataURIDatabaseUtil.existingDataURI(assembledRecord); + if (!exists) { persistNewRecord(record, assembledRecord, thinned, dao); } else { updateExistingRecord(record, assembledRecord, thinned, dao); diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.ffmp/src/com/raytheon/uf/common/dataplugin/ffmp/FFMPUtils.java b/edexOsgi/com.raytheon.uf.common.dataplugin.ffmp/src/com/raytheon/uf/common/dataplugin/ffmp/FFMPUtils.java index 87bda5ae9e..fb97ca7471 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.ffmp/src/com/raytheon/uf/common/dataplugin/ffmp/FFMPUtils.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.ffmp/src/com/raytheon/uf/common/dataplugin/ffmp/FFMPUtils.java @@ -85,6 +85,7 @@ import com.vividsolutions.jts.io.WKTWriter; * 03/01/13 DR 13228 G. Zhang Add state for VGB query and related code * 03/18/13 1817 D. Hladky Fixed issue with BOX where only 1 HUC was showing up. * 08/20/13 2250 mnash Fixed incorrect return types for database queries. + * Apr 21, 2014 2060 njensen Remove dependency on grid dataURI column * * * @author dhladky @@ -943,10 +944,8 @@ public class FFMPUtils { */ public static String getFFGDataURI(String rfc, String parameter, String plugin) { - DbQueryRequest request = new DbQueryRequest(); request.setEntityClass(GridRecord.class.getName()); - request.addRequestField("dataURI"); request.addConstraint(GridConstants.PARAMETER_ABBREVIATION, new RequestConstraint(parameter)); request.addConstraint(GridConstants.DATASET_ID, new RequestConstraint( @@ -955,10 +954,7 @@ public class FFMPUtils { try { DbQueryResponse response = (DbQueryResponse) RequestRouter .route(request); - - for (Map map : response.getResults()) { - return (String) map.get("dataURI"); - } + return response.getEntityObjects(GridRecord.class)[0].getDataURI(); } catch (Exception e) { e.printStackTrace(); } diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridInfoRecord.java b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridInfoRecord.java index e59cf4c844..7a40edd823 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridInfoRecord.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridInfoRecord.java @@ -28,6 +28,7 @@ import javax.persistence.ManyToOne; import javax.persistence.PrimaryKeyJoinColumn; import javax.persistence.SequenceGenerator; import javax.persistence.Table; +import javax.persistence.UniqueConstraint; import com.raytheon.uf.common.dataplugin.annotations.DataURI; import com.raytheon.uf.common.dataplugin.level.Level; @@ -53,6 +54,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; * May 21, 2012 bsteffen Initial creation * Nov 25, 2013 2574 bsteffen Add converter to location dataURI * annotation. + * Apr 15, 2014 2060 njensen Added unique constraint annotation * * * @@ -60,7 +62,9 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; * @version 1.0 */ @Entity -@Table(name = "grid_info") +@Table(name = "grid_info", uniqueConstraints = { @UniqueConstraint(columnNames = { + "datasetid", "secondaryid", "ensembleid", "location_id", + "parameter_abbreviation", "level_id" }) }) @SequenceGenerator(name = "GRIDINFO_GENERATOR", sequenceName = "gridinfo_seq", allocationSize = 1) @DynamicSerialize public class GridInfoRecord extends PersistableDataObject { diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridRecord.java b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridRecord.java index 5e37c83a82..eed4f41d18 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridRecord.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridRecord.java @@ -22,9 +22,6 @@ package com.raytheon.uf.common.dataplugin.grid; import java.util.HashMap; import java.util.Map; -import javax.persistence.Access; -import javax.persistence.AccessType; -import javax.persistence.Column; import javax.persistence.Entity; import javax.persistence.ManyToOne; import javax.persistence.PrimaryKeyJoinColumn; @@ -68,6 +65,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; * PluginDataObject. * Aug 30, 2013 2298 rjpeter Make getPluginName abstract * Dec 16, 2013 2574 bsteffen Remove getDecoderGettable. + * Apr 15, 2014 2060 njensen Remove dataURI column * * * @@ -76,7 +74,8 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; */ @Entity @SequenceGenerator(initialValue = 1, name = PluginDataObject.ID_GEN, sequenceName = "gridseq") -@Table(name = "grid", uniqueConstraints = { @UniqueConstraint(columnNames = { "dataURI" }) }) +@Table(name = "grid", uniqueConstraints = { @UniqueConstraint(columnNames = { + "refTime", "forecastTime", "rangestart", "rangeend", "info_id" }) }) /* * Both refTime and forecastTime are included in the refTimeIndex since * forecastTime is unlikely to be used. @@ -254,13 +253,6 @@ public class GridRecord extends PersistablePluginDataObject implements return true; } - @Override - @Column - @Access(AccessType.PROPERTY) - public String getDataURI() { - return super.getDataURI(); - } - @Override public String getPluginName() { return "grid"; diff --git a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/DataURIDatabaseUtil.java b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/DataURIDatabaseUtil.java new file mode 100644 index 0000000000..dea907fbdb --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/DataURIDatabaseUtil.java @@ -0,0 +1,87 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.database.plugin; + +import java.util.List; +import java.util.Map; + +import com.raytheon.uf.common.dataplugin.PluginDataObject; +import com.raytheon.uf.common.dataplugin.PluginException; +import com.raytheon.uf.common.dataplugin.annotations.DataURIUtil; +import com.raytheon.uf.edex.database.DataAccessLayerException; +import com.raytheon.uf.edex.database.query.DatabaseQuery; + +/** + * Utilities related to dataURIs and their corresponding database tables. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 21, 2014 2060       njensen     Initial creation
+ * 
+ * 
+ * + * @author njensen + * @version 1.0 + */ + +public class DataURIDatabaseUtil { + + private DataURIDatabaseUtil() { + + } + + /** + * Checks for the existence in the database of a PluginDataObject that + * matches the argument. The check for existence is based on if the dataURI + * of the PluginDataObject matches. + * + * @param pdo + * the PluginDataObject to check to see if its equivalent dataURI + * is in the database + * @return true if a matching dataURI was found, false otherwise + * @throws PluginException + */ + public static boolean existingDataURI(PluginDataObject pdo) + throws PluginException { + PluginDao dao = PluginFactory.getInstance().getPluginDao( + pdo.getPluginName()); + DatabaseQuery dbQuery = new DatabaseQuery(pdo.getClass()); + Map dataUriFields = DataURIUtil.createDataURIMap(pdo); + for (Map.Entry field : dataUriFields.entrySet()) { + String fieldName = field.getKey(); + // ignore pluginName + if (!PluginDataObject.PLUGIN_NAME_ID.equals(fieldName)) { + dbQuery.addQueryParam(field.getKey(), field.getValue()); + } + } + + try { + List list = dao.queryByCriteria(dbQuery); + return (list != null && !list.isEmpty()); + } catch (DataAccessLayerException e) { + throw new PluginException("Error querying database", e); + } + } + +} diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/util/RetrievalGeneratorUtilities.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/util/RetrievalGeneratorUtilities.java index 029ae675ba..cac0b9dc73 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/util/RetrievalGeneratorUtilities.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/util/RetrievalGeneratorUtilities.java @@ -35,8 +35,7 @@ import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.time.DataTime; import com.raytheon.uf.edex.core.EDEXUtil; -import com.raytheon.uf.edex.database.dao.CoreDao; -import com.raytheon.uf.edex.database.dao.DaoConfig; +import com.raytheon.uf.edex.database.plugin.DataURIDatabaseUtil; import com.raytheon.uf.edex.datadelivery.retrieval.handlers.RetrievalRequestWrapper; import com.raytheon.uf.edex.datadelivery.retrieval.handlers.SubscriptionRetrievalRequestWrapper; @@ -54,6 +53,7 @@ import com.raytheon.uf.edex.datadelivery.retrieval.handlers.SubscriptionRetrieva * Dec 10, 2012 1259 bsteffen Switch Data Delivery from LatLon to referenced envelopes. * Dec 11, 2013 2625 mpduff Remove creation of DataURI. * Jan 30, 2014 2686 dhladky refactor of retrieval. + * Apr 21, 2014 2060 njensen Remove dependency on grid dataURI column * * * @@ -65,31 +65,6 @@ public class RetrievalGeneratorUtilities { private static final IUFStatusHandler statusHandler = UFStatus .getHandler(RetrievalGeneratorUtilities.class); - /** - * Find duplicate URI's - * - * @param dataURI - * @return - */ - public static boolean findDuplicateUri(String dataUri, String plugin) { - - boolean isDuplicate = false; - try { - String sql = "select id from " + plugin + " where datauri = '" - + dataUri + "'"; - - CoreDao dao = new CoreDao(DaoConfig.forDatabase("metadata")); - Object[] results = dao.executeSQLQuery(sql); - if (results.length > 0) { - isDuplicate = true; - } - } catch (Exception e) { - statusHandler.error("Couldn't determine duplicate status! ", e); - } - - return isDuplicate; - } - /** * Find the duplicate URI's for grid * @@ -116,13 +91,12 @@ public class RetrievalGeneratorUtilities { for (Level level : levels) { for (String ensembleMember : ensembleMembers) { try { - GridRecord rec = ResponseProcessingUtilities .getGridRecord(name, parm, level, ensembleMember, cov); rec.setDataTime(time); - boolean isDup = findDuplicateUri(rec.getDataURI(), - "grid"); + boolean isDup = DataURIDatabaseUtil + .existingDataURI(rec); if (isDup) { levDups.add(level); } @@ -140,7 +114,7 @@ public class RetrievalGeneratorUtilities { return dups; } - + /** * * Drops Retrievals by subscription into a common queue for processing @@ -151,7 +125,7 @@ public class RetrievalGeneratorUtilities { * @throws Exception */ public static void sendToRetrieval(String destinationUri, Network network, - Object[] payload) throws Exception{ + Object[] payload) throws Exception { if (payload != null) { diff --git a/edexOsgi/com.raytheon.uf.edex.grid.staticdata/src/com/raytheon/uf/edex/grid/staticdata/StaticDataGenerator.java b/edexOsgi/com.raytheon.uf.edex.grid.staticdata/src/com/raytheon/uf/edex/grid/staticdata/StaticDataGenerator.java index 7bd4e1ec92..b58a8ace71 100644 --- a/edexOsgi/com.raytheon.uf.edex.grid.staticdata/src/com/raytheon/uf/edex/grid/staticdata/StaticDataGenerator.java +++ b/edexOsgi/com.raytheon.uf.edex.grid.staticdata/src/com/raytheon/uf/edex/grid/staticdata/StaticDataGenerator.java @@ -50,10 +50,10 @@ import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.time.DataTime; -import com.raytheon.uf.edex.database.DataAccessLayerException; import com.raytheon.uf.edex.database.cluster.ClusterLockUtils; import com.raytheon.uf.edex.database.cluster.ClusterLockUtils.LockState; import com.raytheon.uf.edex.database.cluster.ClusterTask; +import com.raytheon.uf.edex.database.plugin.DataURIDatabaseUtil; import com.raytheon.uf.edex.decodertools.time.TimeTools; import com.raytheon.uf.edex.grid.staticdata.topo.StaticTopoData; import com.raytheon.uf.edex.plugin.grid.dao.GridDao; @@ -68,10 +68,11 @@ import com.raytheon.uf.edex.plugin.grid.dao.GridDao; * * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Dec 3, 2010 rjpeter Initial creation + * Dec 3, 2010 rjpeter Initial creation * Feb 15, 2013 1638 mschenke Moved DataURINotificationMessage to uf.common.dataplugin * Mar 07, 2013 1587 bsteffen rewrite static data generation. * Mar 14, 2013 1587 bsteffen Fix persisting to datastore. + * Apr 21, 2014 2060 njensen Remove dependency on grid dataURI column * * * @@ -383,19 +384,19 @@ public class StaticDataGenerator { /** * Return a set with only records which are not already in the database + * + * @throws PluginException */ private Set checkDatabase(GridDao dao, - Set staticRecords) throws DataAccessLayerException { + Set staticRecords) throws PluginException { if (staticRecords.isEmpty()) { return staticRecords; } Set missing = new HashSet(); for (GridRecord staticRecord : staticRecords) { - // a possible future optimization would be to do one bulk query for - // all records. - List list = dao.queryBySingleCriteria("dataURI", - staticRecord.getDataURI()); - if (list.isEmpty()) { + // TODO a possible future optimization would be to do one bulk query + // for all records. + if (!DataURIDatabaseUtil.existingDataURI(staticRecord)) { missing.add(staticRecord); } } diff --git a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/ArealQpeGenSrv.java b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/ArealQpeGenSrv.java index 27b977adc5..dbbe28bd54 100644 --- a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/ArealQpeGenSrv.java +++ b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/ArealQpeGenSrv.java @@ -73,6 +73,7 @@ import com.vividsolutions.jts.geom.Coordinate; * Jan 26, 2011 snaples Initial creation * Jan 10, 2013 1448 bgonzale Added app context check in processArealQpe(). * Mar 28, 2014 2952 mpduff Changed to use UFStatus for logging. + * Apr 21, 2014 2060 njensen Remove dependency on grid dataURI column * * * @@ -152,11 +153,6 @@ public class ArealQpeGenSrv { private Rectangle wfoExtent; - /** - * The reference time - */ - private Date grReftime = null; - /** * The previous Duration */ @@ -588,7 +584,7 @@ public class ArealQpeGenSrv { } /** - * Get the data URI + * Get the grid record * * @param rfc * The RFC @@ -599,13 +595,12 @@ public class ArealQpeGenSrv { * @return The database uri, or null if no data * @throws DataAccessLayerException */ - private String getDataURI(String rfc, String duration, String today) + private GridRecord getGridRecord(String rfc, String duration, String today) throws DataAccessLayerException { - String uri = null; + GridRecord rec = null; // Query for uri DatabaseQuery query = new DatabaseQuery(GridRecord.class); - query.addReturnedField("dataURI"); query.addQueryParam(GridConstants.DATASET_ID, "QPE-" + rfc); query.addQueryParam(GridConstants.PARAMETER_ABBREVIATION, "QPE" + duration + "%", "like"); @@ -615,13 +610,12 @@ public class ArealQpeGenSrv { dao = new CoreDao(DaoConfig.forDatabase("metadata")); List rs = dao.queryByCriteria(query); if ((rs != null) && (!rs.isEmpty())) { - if ((rs.get(0) != null) && (rs.get(0) instanceof String)) { - uri = (String) rs.get(0); + Object result = rs.get(0); + if (result != null && result instanceof GridRecord) { + rec = ((GridRecord) result); } - } else { - uri = null; } - return uri; + return rec; } /** @@ -656,19 +650,13 @@ public class ArealQpeGenSrv { IDataStore dataStore = null; try { - uri = getDataURI(rfc, durString, today); - if (uri == null) { - grReftime = cal.getTime(); + GridRecord gr = getGridRecord(rfc, durString, today); + if (gr == null) { return false; } - GridRecord gr = new GridRecord(uri); PluginDao gd = null; - gd = PluginFactory.getInstance().getPluginDao(gr.getPluginName()); - gr = (GridRecord) gd.getMetadata(uri); - grReftime = gr.getDataTime().getRefTime(); - dataStore = gd.getDataStore(gr); int nx = gr.getSpatialObject().getNx(); diff --git a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/GAFF.java b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/GAFF.java index 24c61a89e3..0f27010d02 100644 --- a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/GAFF.java +++ b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/GAFF.java @@ -65,6 +65,7 @@ import com.vividsolutions.jts.geom.Coordinate; * Sep 5, 2013 16437 wkwock Fix the "HiRes" issue * Mar 28, 2014 2952 mpduff Changed to use UFStatus for logging. * Apr 10, 2014 2675 mpduff Modified to be called from quartz timer. + * Apr 21, 2014 2060 njensen Remove dependency on grid dataURI column * * * @@ -263,7 +264,6 @@ public class GAFF { .buildThreadLocalSimpleDateFormat("yyyy-MM-dd HH:mm:ss", TimeZone.getTimeZone("GMT")); String today = sdf.get().format(cal.getTime()); - String uri = null; IDataRecord dataRec; Rectangle rfcExtent = null; @@ -307,22 +307,18 @@ public class GAFF { IDataStore dataStore = null; try { - uri = db.getDataURI(rfc, durString, today); - if (uri == null) { - uri = db.getDataURI(rfc + "-HiRes", durString, today); + GridRecord gr = db.getGridRecord(rfc, durString, today); + if (gr == null) { + gr = db.getGridRecord(rfc + "-HiRes", durString, today); } - if (uri == null) { + if (gr == null) { continue; } - GridRecord gr = new GridRecord(uri); PluginDao gd = null; - gd = PluginFactory.getInstance().getPluginDao( gr.getPluginName()); - gr = (GridRecord) gd.getMetadata(uri); grReftime = gr.getDataTime().getRefTime(); - dataStore = gd.getDataStore(gr); int nx = gr.getSpatialObject().getNx(); @@ -341,7 +337,8 @@ public class GAFF { (int) ulRfcNationalScale.y - ny, nx, ny); extentsMap.put(rfc, rfcExtent); - dataRec = dataStore.retrieve(uri, "Data", Request.ALL); + dataRec = dataStore.retrieve(gr.getDataURI(), "Data", + Request.ALL); if (dataRec instanceof FloatDataRecord) { gridMap.put(rfc, ((FloatDataRecord) dataRec).getFloatData()); diff --git a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/GAFFDB.java b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/GAFFDB.java index 8ddccec730..146ea05ec5 100644 --- a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/GAFFDB.java +++ b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/GAFFDB.java @@ -46,6 +46,7 @@ import com.raytheon.uf.edex.database.query.DatabaseQuery; * ------------ ---------- ----------- -------------------------- * Jan 11, 2011 mpduff Initial creation * Mar 28, 2014 2952 mpduff Changed to use UFStatus for logging. + * Apr 21, 2014 2060 njensen Remove dependency on grid dataURI column * * * @@ -152,7 +153,7 @@ public class GAFFDB { } /** - * Get the data URI + * Get the grid record * * @param rfc * The RFC @@ -163,13 +164,10 @@ public class GAFFDB { * @return The database uri, or null if no data * @throws DataAccessLayerException */ - public String getDataURI(String rfc, String duration, String today) + public GridRecord getGridRecord(String rfc, String duration, String today) throws DataAccessLayerException { - String uri = null; - - // Query for uri + GridRecord rec = null; DatabaseQuery query = new DatabaseQuery(GridRecord.class); - query.addReturnedField("dataURI"); query.addQueryParam(GridConstants.DATASET_ID, "FFG-" + rfc); query.addQueryParam(GridConstants.PARAMETER_ABBREVIATION, "FFG" + duration + "24hr"); @@ -180,14 +178,13 @@ public class GAFFDB { dao = new CoreDao(DaoConfig.forDatabase("metadata")); List rs = dao.queryByCriteria(query); if ((rs != null) && (!rs.isEmpty())) { - if ((rs.get(0) != null) && (rs.get(0) instanceof String)) { - uri = (String) rs.get(0); + Object result = rs.get(0); + if (result != null && result instanceof GridRecord) { + rec = ((GridRecord) result); } - } else { - uri = null; } - return uri; + return rec; } /** From 4e976fafedbad4331c9f68c547f3ab293a186fcf Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Tue, 22 Apr 2014 09:10:45 -0500 Subject: [PATCH 070/188] Issue #2906 removed wmo header, timeObs and timeNominal from sfcobs HDF5 times still in DB, accesible from point data view BUFR obs decoder populates WMO header for consistency Former-commit-id: c5400855f507015ab0a10cb0ce17ff7ba92a6220 --- .../res/pointdata/sfcobs.xml | 3 -- .../res/pointdata/sfcobsdb.xml | 2 ++ .../sfcobs/SfcObsPointDataTransform.java | 34 +------------------ .../bufrobs/AbstractBufrSfcObsDecoder.java | 2 ++ 4 files changed, 5 insertions(+), 36 deletions(-) diff --git a/edexOsgi/com.raytheon.edex.plugin.sfcobs/res/pointdata/sfcobs.xml b/edexOsgi/com.raytheon.edex.plugin.sfcobs/res/pointdata/sfcobs.xml index b386bb7d49..6903dd37de 100644 --- a/edexOsgi/com.raytheon.edex.plugin.sfcobs/res/pointdata/sfcobs.xml +++ b/edexOsgi/com.raytheon.edex.plugin.sfcobs/res/pointdata/sfcobs.xml @@ -20,9 +20,6 @@ --> - - - diff --git a/edexOsgi/com.raytheon.edex.plugin.sfcobs/res/pointdata/sfcobsdb.xml b/edexOsgi/com.raytheon.edex.plugin.sfcobs/res/pointdata/sfcobsdb.xml index 68b643a85b..a286121c7f 100644 --- a/edexOsgi/com.raytheon.edex.plugin.sfcobs/res/pointdata/sfcobsdb.xml +++ b/edexOsgi/com.raytheon.edex.plugin.sfcobs/res/pointdata/sfcobsdb.xml @@ -28,4 +28,6 @@ + + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.plugin.sfcobs/src/com/raytheon/edex/plugin/sfcobs/SfcObsPointDataTransform.java b/edexOsgi/com.raytheon.edex.plugin.sfcobs/src/com/raytheon/edex/plugin/sfcobs/SfcObsPointDataTransform.java index b23225b004..615d66b471 100644 --- a/edexOsgi/com.raytheon.edex.plugin.sfcobs/src/com/raytheon/edex/plugin/sfcobs/SfcObsPointDataTransform.java +++ b/edexOsgi/com.raytheon.edex.plugin.sfcobs/src/com/raytheon/edex/plugin/sfcobs/SfcObsPointDataTransform.java @@ -39,7 +39,6 @@ import com.raytheon.uf.common.pointdata.PointDataDescription; import com.raytheon.uf.common.pointdata.PointDataView; import com.raytheon.uf.common.pointdata.spatial.SurfaceObsLocation; import com.raytheon.uf.common.serialization.SerializationException; -import com.raytheon.uf.edex.decodertools.time.TimeTools; /** * Populates point data views from fields in obs common records. @@ -53,6 +52,7 @@ import com.raytheon.uf.edex.decodertools.time.TimeTools; * Oct 1, 2009 jkorman Initial creation * Feb 15,2011 5705 cjeanbap Added wmoHeader to HDR_PARAMS_LIST. * Apr 04,2014 2906 bclement made getDescription() and static constants public + * Apr 22,2014 2906 bclement removed WMO header, timeObs and timeNominal from HDF5 (times still in DB) * * * @@ -217,7 +217,6 @@ public class SfcObsPointDataTransform { sb.append("reportType,"); sb.append("dataURI,"); sb.append("rawReport,"); - sb.append("wmoHeader,"); HDR_PARAMS_LIST = sb.toString(); } @@ -371,11 +370,8 @@ public class SfcObsPointDataTransform { PointDataView pdv = container.append(); if (pdv != null) { - pdv.setLong(TIME_OBS, record.getTimeObs().getTimeInMillis()); - pdv.setLong(TIME_NOMINAL, record.getRefHour().getTimeInMillis()); pdv.setString(RAW_REPORT, record.getObsText()); - pdv.setString(WMO_HEADER, record.getWmoHeader()); pdv.setFloat(TEMPERATURE, getFloat(record.getTemp())); pdv.setFloat(DEWPOINT, getFloat(record.getDwpt())); @@ -621,31 +617,11 @@ public class SfcObsPointDataTransform { SurfaceObsLocation loc = obs.getLocation(); loc.setElevation(elev); - long tt = pdv.getNumber(TIME_OBS).longValue(); - obs.setTimeObs(TimeTools.newCalendar(tt)); - - tt = pdv.getNumber(TIME_NOMINAL).longValue(); - obs.setRefHour(TimeTools.newCalendar(tt)); - obs.setObsText(pdv.getString(RAW_REPORT)); - obs.setWmoHeader(pdv.getString(WMO_HEADER)); } return obs; } - /** - * - * @param value - * @return - */ - private static int getInt(Double value) { - int retValue = INT_DEFAULT; - if (value != null) { - retValue = value.intValue(); - } - return retValue; - } - private static int getInt(Integer value) { int retValue = INT_DEFAULT; if (value != null) { @@ -654,14 +630,6 @@ public class SfcObsPointDataTransform { return retValue; } - private static int getInt(Float value) { - int retValue = INT_DEFAULT; - if (value != null) { - retValue = value.intValue(); - } - return retValue; - } - private static float getFloat(Double value) { float retValue = FLOAT_DEFAULT; if (value != null) { diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/src/com/raytheon/uf/edex/plugin/bufrobs/AbstractBufrSfcObsDecoder.java b/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/src/com/raytheon/uf/edex/plugin/bufrobs/AbstractBufrSfcObsDecoder.java index c84d3fb62a..91f9aacdd6 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/src/com/raytheon/uf/edex/plugin/bufrobs/AbstractBufrSfcObsDecoder.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/src/com/raytheon/uf/edex/plugin/bufrobs/AbstractBufrSfcObsDecoder.java @@ -85,6 +85,7 @@ import com.raytheon.uf.edex.wmo.message.WMOHeader; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Mar 21, 2014 2906 bclement Initial creation + * Apr 21, 2014 2906 bclement populated wmo header in record for consistency * * * @@ -299,6 +300,7 @@ public abstract class AbstractBufrSfcObsDecoder { } /* shef converter looks for WMO header in obs text */ currentRecord.setObsText(header.getWmoHeader()); + currentRecord.setWmoHeader(header.getWmoHeader()); } /** From 717cdf42802f623eadd8c5c5ac9cf5dbf18209bb Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Tue, 22 Apr 2014 10:01:27 -0500 Subject: [PATCH 071/188] Issue #3038 added initialized flag to session feed view differentiates between roster population and new joins Former-commit-id: 9b6c20ac39765120efc523c03a3d11d4b21c1748 --- .../ui/session/SessionFeedView.java | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionFeedView.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionFeedView.java index d2a6ed2c9e..6997931960 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionFeedView.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/SessionFeedView.java @@ -74,6 +74,7 @@ import com.raytheon.uf.viz.core.icon.IconUtil; * Mar 24, 2014 2936 mpduff Remove join alerts from feed view. * Mar 25, 2014 2938 mpduff Show status message for site and role changes. * Apr 01, 2014 2938 mpduff Update logic for site and role changes. + * Apr 22, 2014 3038 bclement added initialized flag to differentiate between roster population and new joins * * * @@ -104,6 +105,8 @@ public class SessionFeedView extends SessionView { */ private final ConcurrentHashMap enabledUsers = new ConcurrentHashMap(); + private volatile boolean initialized = false; + /** * */ @@ -409,6 +412,18 @@ public class SessionFeedView extends SessionView { @Override protected void participantPresenceUpdated(VenueParticipant participant, Presence presence) { + /* + * when we join, the room will send presence for everyone in the room, + * then send us our own presence to signify that the list is done and we + * have been initialized. + */ + if (!initialized && session.getUserID().isSameUser(participant)) { + initialized = true; + /* + * continue and print the message for ourselves joining which will + * serve as a delimiter between historical messages and new messages + */ + } // Verify we have properties if (!presence.getPropertyNames().contains( SiteConfigInformation.SITE_NAME)) { @@ -425,7 +440,9 @@ public class SessionFeedView extends SessionView { String roleName = getRoleName(presence); if (presence.isAvailable()) { - if (prev == null || hasPresenceChanged(prev, presence)) { + /* only print announcements after we are initialized */ + if (initialized + && (prev == null || hasPresenceChanged(prev, presence))) { StringBuilder message = getMessage(roleName, siteName, user); sendSystemMessage(message); } From e53e88a351666aa8fe4d8f42579e63941014578b Mon Sep 17 00:00:00 2001 From: David Gillingham Date: Mon, 21 Apr 2014 18:07:02 -0500 Subject: [PATCH 072/188] Issue #2996: Use alpha channel to mask out no-data areas in exported GFE data. Change-Id: I827d8ecee7623a8859bf18fbfb1f70db4fe6d92d Former-commit-id: c974c49fbfcc50fae23e151d020e7aeddf531db2 --- .../uf/common/colormap/image/Colormapper.java | 84 ++++++++++--------- 1 file changed, 44 insertions(+), 40 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.colormap/src/com/raytheon/uf/common/colormap/image/Colormapper.java b/edexOsgi/com.raytheon.uf.common.colormap/src/com/raytheon/uf/common/colormap/image/Colormapper.java index d6c4251945..1cc28c63fd 100644 --- a/edexOsgi/com.raytheon.uf.common.colormap/src/com/raytheon/uf/common/colormap/image/Colormapper.java +++ b/edexOsgi/com.raytheon.uf.common.colormap/src/com/raytheon/uf/common/colormap/image/Colormapper.java @@ -19,15 +19,10 @@ **/ package com.raytheon.uf.common.colormap.image; -import java.awt.Point; +import java.awt.Color; import java.awt.image.BufferedImage; -import java.awt.image.DataBuffer; -import java.awt.image.DataBufferByte; import java.awt.image.IndexColorModel; -import java.awt.image.MultiPixelPackedSampleModel; -import java.awt.image.Raster; import java.awt.image.RenderedImage; -import java.awt.image.WritableRaster; import java.nio.Buffer; import java.nio.ByteBuffer; import java.nio.FloatBuffer; @@ -38,7 +33,6 @@ import java.util.List; import javax.measure.converter.UnitConverter; import javax.measure.unit.Unit; -import com.raytheon.uf.common.colormap.Color; import com.raytheon.uf.common.colormap.IColorMap; import com.raytheon.uf.common.colormap.LogConverter; import com.raytheon.uf.common.colormap.image.ColorMapData.ColorMapDataType; @@ -57,6 +51,8 @@ import com.raytheon.uf.common.colormap.prefs.ColorMapParameters; * Aug 13, 2010 mschenke Initial creation * Feb 15, 2013 1638 mschenke Moved IndexColorModel creation to common.colormap utility * Nov 4, 2013 2492 mschenke Rewritten to model glsl equivalent + * Apr 22, 2014 2996 dgilling Rewrite colorMap() to output images with + * proper transparency for GFE data. * * * @@ -70,6 +66,8 @@ public class Colormapper { public static final float MAX_VALUE = 255.0f; + private static final int TRANSPARENT = new Color(0, 0, 0, 0).getRGB(); + /** * This method will color map a Buffer to a RenderedImage given size and * parameters @@ -99,37 +97,40 @@ public class Colormapper { && dataUnit.isCompatible(colorMapUnit) == true) { converter = dataUnit.getConverterTo(colorMapUnit); } + int numColors = parameters.getColorMap().getSize(); - byte[] indexArray = new byte[dataSize]; + List colors = parameters + .getColorMap().getColors(); - for (int i = 0; i < dataSize; ++i) { - double dataValue = getDataValue(buf, i, dataType); - if (Double.isNaN(dataValue) || dataValue == noDataValue) { - // Skip, need equivalent of setting alpha to 0 - continue; - } - double cmapValue = dataValue; - if (converter != null) { - cmapValue = converter.convert(dataValue); - } - - double index = getColorMappingIndex(cmapValue, parameters); - indexArray[i] = (byte) (capIndex(index) * (numColors - 1)); + int[] indexedColors = new int[numColors]; + for (int i = 0; i < numColors; i++) { + com.raytheon.uf.common.colormap.Color color = colors.get(i); + indexedColors[i] = new Color(color.getRed(), color.getGreen(), + color.getBlue(), color.getAlpha()).getRGB(); } - IndexColorModel cm = buildColorModel(parameters.getColorMap()); + int[] pixels = new int[dataSize]; + for (int i = 0; i < dataSize; ++i) { + int rgbValue = TRANSPARENT; - DataBufferByte byteArray = new DataBufferByte(indexArray, width - * height); + double dataValue = getDataValue(buf, i, dataType); + if ((!Double.isNaN(dataValue)) && (dataValue != noDataValue)) { + double cmapValue = dataValue; + if (converter != null) { + cmapValue = converter.convert(dataValue); + } - MultiPixelPackedSampleModel sample = new MultiPixelPackedSampleModel( - DataBuffer.TYPE_BYTE, width, height, COLOR_MODEL_NUMBER_BITS); - WritableRaster writeRaster = Raster.createWritableRaster(sample, - byteArray, new Point(0, 0)); + double index = getColorMappingIndex(cmapValue, parameters); + int cmapIndex = (int) (capIndex(index) * (numColors - 1)); + rgbValue = indexedColors[cmapIndex]; + } + + pixels[i] = rgbValue; + } BufferedImage bi = new BufferedImage(width, height, - BufferedImage.TYPE_BYTE_INDEXED, cm); - bi.setData(writeRaster); + BufferedImage.TYPE_INT_ARGB); + bi.setRGB(0, 0, width, height, pixels, 0, width); return bi; } @@ -146,9 +147,10 @@ public class Colormapper { byte[] blue = new byte[size]; byte[] alpha = new byte[size]; - List colors = aColorMap.getColors(); + List colors = aColorMap + .getColors(); for (int i = 0; i < size; ++i) { - Color color = colors.get(i); + com.raytheon.uf.common.colormap.Color color = colors.get(i); red[i] = (byte) (color.getRed() * MAX_VALUE); green[i] = (byte) (color.getGreen() * MAX_VALUE); blue[i] = (byte) (color.getBlue() * MAX_VALUE); @@ -241,7 +243,7 @@ public class Colormapper { rangeMin = rangeMax; rangeMax = tmp; } - + double index = 0.0; // Flag if min/max values are on opposite sides of zero boolean minMaxOpposite = (cmapMin < 0 && cmapMax > 0) @@ -361,8 +363,8 @@ public class Colormapper { * @param colorMapParameters * @return */ - public static Color getColorByIndex(double index, - ColorMapParameters colorMapParameters) { + public static com.raytheon.uf.common.colormap.Color getColorByIndex( + double index, ColorMapParameters colorMapParameters) { index = capIndex(index); IColorMap colorMap = colorMapParameters.getColorMap(); if (colorMapParameters.isInterpolate()) { @@ -372,8 +374,10 @@ public class Colormapper { int highIndex = (int) Math.ceil(index); double lowWeight = highIndex - index; double highWeight = 1.0f - lowWeight; - Color low = colorMap.getColors().get(lowIndex); - Color high = colorMap.getColors().get(highIndex); + com.raytheon.uf.common.colormap.Color low = colorMap.getColors() + .get(lowIndex); + com.raytheon.uf.common.colormap.Color high = colorMap.getColors() + .get(highIndex); float r = (float) (lowWeight * low.getRed() + highWeight * high.getRed()); float g = (float) (lowWeight * low.getGreen() + highWeight @@ -382,7 +386,7 @@ public class Colormapper { * high.getBlue()); float a = (float) (lowWeight * low.getAlpha() + highWeight * high.getAlpha()); - return new Color(r, g, b, a); + return new com.raytheon.uf.common.colormap.Color(r, g, b, a); } else { return colorMap.getColors().get( (int) (index * (colorMap.getSize() - 1))); @@ -397,8 +401,8 @@ public class Colormapper { * @param colorMapParameters * @return */ - public static Color getColorByValue(double cmapValue, - ColorMapParameters colorMapParameters) { + public static com.raytheon.uf.common.colormap.Color getColorByValue( + double cmapValue, ColorMapParameters colorMapParameters) { return getColorByIndex( getColorMappingIndex(cmapValue, colorMapParameters), colorMapParameters); From aa8fdb1e5affc03d9259f3d06d84fe301f9aac4e Mon Sep 17 00:00:00 2001 From: Dave Hladky Date: Tue, 22 Apr 2014 10:44:57 -0500 Subject: [PATCH 073/188] Issue #3046 Dupe checker for DD gridded retrievals got broken. Change-Id: Iaec4c848e0a9ef06610153ce03f7c4d45deb870a Former-commit-id: 2c957466d5a4877ab7c20ddf75ea6fa8e6333c76 --- .../adapters/GridMetadataAdapter.java | 33 +++++++++---------- .../util/ResponseProcessingUtilities.java | 7 ++++ 2 files changed, 22 insertions(+), 18 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/metadata/adapters/GridMetadataAdapter.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/metadata/adapters/GridMetadataAdapter.java index ea1af6b523..07551deeaa 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/metadata/adapters/GridMetadataAdapter.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/metadata/adapters/GridMetadataAdapter.java @@ -32,6 +32,8 @@ import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataplugin.level.Level; import com.raytheon.uf.common.gridcoverage.GridCoverage; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.util.GridUtil; import com.raytheon.uf.edex.datadelivery.retrieval.util.ResponseProcessingUtilities; @@ -50,6 +52,7 @@ import com.raytheon.uf.edex.datadelivery.retrieval.util.ResponseProcessingUtilit * May 12, 2013 753 dhladky Altered to be more flexible with other types * May 31, 2013 2038 djohnson Rename setPdos to allocatePdoArray. * Sept 25, 2013 1797 dhladky separated time from gridded time + * Apr 22, 2014 3046 dhladky Got rid of duplicate code. * * * @@ -58,6 +61,9 @@ import com.raytheon.uf.edex.datadelivery.retrieval.util.ResponseProcessingUtilit */ public class GridMetadataAdapter extends AbstractMetadataAdapter { + private static final IUFStatusHandler statusHandler = UFStatus + .getHandler(GridMetadataAdapter.class); + public GridMetadataAdapter() { } @@ -91,12 +97,6 @@ public class GridMetadataAdapter extends AbstractMetadataAdapter { GridCoverage gridCoverage = ((GriddedCoverage) attXML.getCoverage()) .getRequestGridCoverage(); - try { - gridCoverage = getCoverageFromCache(gridCoverage); - } catch (Exception e) { - throw new InstantiationException(e.getMessage()); - } - if (time.getSelectedTimeIndices() != null) { int bin = 0; for (String ensemble : ensembles) { @@ -128,19 +128,16 @@ public class GridMetadataAdapter extends AbstractMetadataAdapter { */ private GridRecord populateGridRecord(String name, Parameter parm, Level level, String ensembleId, GridCoverage gridCoverage) { - return ResponseProcessingUtilities.getGridRecord(name, parm, level, - ensembleId, gridCoverage); - } - /** - * Try to find the coverage in the cache - * - * @param coverage - * @return - */ - @VisibleForTesting - GridCoverage getCoverageFromCache(GridCoverage coverage) { - return ResponseProcessingUtilities.getCoverageFromCache(coverage); + GridRecord rec = null; + + try { + rec = ResponseProcessingUtilities.getGridRecord(name, parm, level, ensembleId, gridCoverage); + } catch (Exception e) { + statusHandler.error("Couldn't create grid record! "+e); + } + + return rec; } @VisibleForTesting diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/util/ResponseProcessingUtilities.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/util/ResponseProcessingUtilities.java index 3aa218ec31..a0e908989d 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/util/ResponseProcessingUtilities.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/util/ResponseProcessingUtilities.java @@ -53,6 +53,7 @@ import com.raytheon.uf.common.time.DataTime; * Aug 30, 2013 2298 rjpeter Make getPluginName abstract * Sept 25, 2013 1797 dhladky separated time from gridded time * Oct 10, 2013 1797 bgonzale Refactored registry Time objects. + * Apr 22, 2014 3046 dhladky Sample URI creation for DD dupe check got broken. * * * @@ -74,6 +75,7 @@ public class ResponseProcessingUtilities { parameter.setUnitString(parm.getUnits()); GridRecord record = new GridRecord(); + gridCoverage = getCoverageFromCache(gridCoverage); record.setLocation(gridCoverage); record.setLevel(level); record.setParameter(parameter); @@ -82,6 +84,11 @@ public class ResponseProcessingUtilities { return record; } + /** + * Gets a grid coverage from the DB cache system wide. + * @param coverage + * @return + */ public static GridCoverage getCoverageFromCache(GridCoverage coverage) { return GridCoverageLookup.getInstance().getCoverage(coverage, true); } From 1adbf6253a179e1510a6603836794abbcd86612c Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Tue, 22 Apr 2014 11:27:59 -0500 Subject: [PATCH 074/188] Issue #3056 made venue participant equals method case insensitive needed since collaboration server lower cases room names lower cased on creation so in memory matches what is on the server Former-commit-id: 7a2423f4a90597706e52ce0f89bacb1a0e10f067 --- .../comm/provider/user/VenueParticipant.java | 38 ++++++++++++++++--- .../collaboration/ui/CreateSessionDialog.java | 7 +++- 2 files changed, 38 insertions(+), 7 deletions(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/VenueParticipant.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/VenueParticipant.java index 8c4bb1b4d3..512b6dbd3c 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/VenueParticipant.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/VenueParticipant.java @@ -21,7 +21,6 @@ package com.raytheon.uf.viz.collaboration.comm.provider.user; import javax.xml.bind.annotation.XmlRootElement; -import org.apache.commons.lang.builder.EqualsBuilder; import org.apache.commons.lang.builder.HashCodeBuilder; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; @@ -40,6 +39,7 @@ import com.raytheon.uf.viz.collaboration.comm.identity.user.IUser; * ------------ ---------- ----------- -------------------------- * Jan 29, 2014 bclement Initial creation * Feb 13, 2014 2751 bclement no longer is a subclass of UserId + * Apr 22, 2014 3056 bclement made equals case insensitive * * * @@ -131,12 +131,38 @@ public class VenueParticipant implements IUser { if (!(obj instanceof VenueParticipant)) { return false; } + /* + * the xmpp server lower cases room names so we may get them back as + * lower case when we have them locally as upper/mixed case. Treat case + * insensitive. + */ VenueParticipant other = (VenueParticipant) obj; - EqualsBuilder builder = new EqualsBuilder(); - builder.append(handle, other.handle); - builder.append(host, other.host); - builder.append(room, other.room); - return builder.isEquals(); + if (!stringFieldEquals(this.handle, other.handle)){ + return false; + } + if (!stringFieldEquals(this.room, other.room)) { + return false; + } + if (!stringFieldEquals(this.host, other.host)) { + return false; + } + return true; + } + + /** + * @param field + * @param other + * @return true if both arguments are null or arguments are equal ignoring + * case + */ + private boolean stringFieldEquals(String field, String other) { + boolean rval; + if (field == null) { + rval = other == null; + } else { + rval = field.equalsIgnoreCase(other); + } + return rval; } /** diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateSessionDialog.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateSessionDialog.java index 2af30bbe76..012d4fc974 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateSessionDialog.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateSessionDialog.java @@ -94,6 +94,7 @@ import com.raytheon.viz.ui.editor.IMultiPaneEditor; * Feb 11, 2014 2699 bclement require non-blank handle * Mar 06, 2014 2848 bclement moved session creation logic to separate method * Apr 16, 2014 3021 bclement increased width of dialog + * Apr 22, 2014 3056 bclement made room name lowercase to match xmpp server * * * @@ -452,7 +453,11 @@ public class CreateSessionDialog extends CaveSWTDialog { List errorMessages = new ArrayList(); String subject = subjectTF.getText().trim(); String err = validateVenueName(); - String name = nameTF.getText(); + /* + * xmpp server lowercases all room names, lowercase here to + * match when we get names back from the server + */ + String name = nameTF.getText().toLowerCase(); if (err != null) { focusField = nameTF; errorMessages.add(err); From d03afcdcba50a231b45e5620fb18d3848f7e9862 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Tue, 22 Apr 2014 12:03:44 -0500 Subject: [PATCH 075/188] Issue #2984 remove unnecessary dependencies Change-Id: I2066a1e903680068e0d25f7faa99bc7bda2b8877 Former-commit-id: 290ec544e38e71332be2072435aff3b933c649ab --- .../feature.xml | 14 ------ .../META-INF/MANIFEST.MF | 3 +- .../uf/common/dataplugin/ffmp/FFMPUtils.java | 43 +++++++++++++++++-- 3 files changed, 40 insertions(+), 20 deletions(-) diff --git a/cave/com.raytheon.uf.viz.common.core.feature/feature.xml b/cave/com.raytheon.uf.viz.common.core.feature/feature.xml index 30fb8a0f18..15fe41794c 100644 --- a/cave/com.raytheon.uf.viz.common.core.feature/feature.xml +++ b/cave/com.raytheon.uf.viz.common.core.feature/feature.xml @@ -64,13 +64,6 @@ version="0.0.0" unpack="false"/> - - - - * * @author dhladky @@ -209,9 +213,8 @@ public class FFMPUtils { + "where lid in " + "(select distinct(lid) from IngestFilter " + "where pe in ('PC', 'PP') " + "and ingest = 'T' " + "and dur < 2000)"; - CoreDao dao = new CoreDao(DaoConfig.forDatabase(ShefConstants.IHFS)); try { - Object[] results = dao.executeSQLQuery(sql.toString()); + Object[] results = executeSqlQuery(sql, ShefConstants.IHFS); Geometry poly = getCwaGeometry(cwa, mode); PreparedGeometry pg = PreparedGeometryFactory.prepare(poly); Coordinate coor = poly.getCentroid().getCoordinate(); @@ -1362,4 +1365,36 @@ public class FFMPUtils { + sourceSiteDataKey + ".h5"); } + /** + * Queries the specified database + * + * @param query + * the SQL query to run + * @param database + * the database to query + * @return a two dimensional Object[] representing rows and columns + * @throws Exception + */ + private static Object[] executeSqlQuery(String query, String database) + throws Exception { + // code shamelessly modeled after DirectDbQuery + // TODO DirectDbQuery should be changed to use RequestRouter instead of + // ThriftClient and should be promoted to a common plugin + Map constraints = new HashMap(); + constraints.put("query", new RequestConstraint(query)); + constraints.put("database", new RequestConstraint(database)); + constraints.put("mode", new RequestConstraint("sqlquery")); + QlServerRequest request = new QlServerRequest(constraints); + ResponseMessageGeneric resp = (ResponseMessageGeneric) RequestRouter + .route(request); + + QueryResult result = (QueryResult) resp.getContents(); + List unmappedResults = new ArrayList(); + for (QueryResultRow row : result.getRows()) { + unmappedResults.add(row.getColumnValues()); + } + + return unmappedResults.toArray(new Object[0]); + } + } From 90c7e699fa0fd89c26887817419a9c5c06546bb7 Mon Sep 17 00:00:00 2001 From: Brad Gonzales Date: Tue, 22 Apr 2014 12:22:59 -0500 Subject: [PATCH 076/188] Issue #3035 Removed jrockit missioncontrol from awips2 java rpm build. Change-Id: I558e0f080b46c76cbdfb759ef1c1a701925273ca Former-commit-id: 254c7e0298ba7fb3ad91af2d51a1bd41b0535631 --- rpms/awips2.core/Installer.java/1.7/component.spec | 4 ++++ rpms/build/x86_64/build.sh | 8 +++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/rpms/awips2.core/Installer.java/1.7/component.spec b/rpms/awips2.core/Installer.java/1.7/component.spec index 63f83e2af6..4d0ec862fe 100644 --- a/rpms/awips2.core/Installer.java/1.7/component.spec +++ b/rpms/awips2.core/Installer.java/1.7/component.spec @@ -169,6 +169,10 @@ rm -fv changeit.txt if [ $? -ne 0 ]; then exit 1 fi +# Remove jrockit missioncontrol +rm -rf %{_build_root}/awips2/java/lib/missioncontrol +rm -f %{_build_root}/awips2/java/bin/jmc.ini +rm -f %{_build_root}/awips2/java/bin/jmc # The licenses mkdir -p %{_build_root}/awips2/java/licenses diff --git a/rpms/build/x86_64/build.sh b/rpms/build/x86_64/build.sh index 7bd23abd39..417ebe6b21 100644 --- a/rpms/build/x86_64/build.sh +++ b/rpms/build/x86_64/build.sh @@ -86,7 +86,13 @@ fi if [ "${1}" = "-buildRPM" -a -n "${2}" ]; then echo "Building RPM: ${2}" - buildRPM ${2} + # also allow buildJava, buildOpenfire... buildRPM args + buildName=`echo ${2} | cut -c1-5` + if [ ${#2} -gt 5 -a "$buildName" = "build" ]; then + ${2} + else + buildRPM ${2} + fi if [ $? -ne 0 ]; then exit 1 fi From 50f3f420eb2a2ad77b3672bb683fe62b8434e986 Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Tue, 22 Apr 2014 12:34:30 -0500 Subject: [PATCH 077/188] Issue #2903 added connection tests to session close methods fixes illegal state exception problem when booted from xmpp server Former-commit-id: d570c81caed35576e867df15c2a8d900135fef5f --- .../session/SharedDisplaySession.java | 30 +++++++++++-------- .../comm/provider/session/VenueSession.java | 6 +++- 2 files changed, 22 insertions(+), 14 deletions(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java index 5435e5b37d..e03cfa34c6 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java @@ -98,6 +98,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; * Mar 31, 2014 2899 mpduff Improve error messages. * Apr 15, 2014 2822 bclement added check for other participants being subscribed to topic * Apr 21, 2014 2822 bclement removed use of resources in topicSubscribers, added skipCache + * Apr 22, 2014 2903 bclement added connection test to closePubSub() method * * * @@ -511,21 +512,24 @@ public class SharedDisplaySession extends VenueSession implements closePubSub(); } + /** + * clean up pub sub subscription and objects + */ private void closePubSub() { try { - if (pubsubMgr == null || topic == null || !topicExists()) { - return; - } - Subscription sub = findSubscription(getAccount()); - if (sub == null) { - return; - } - topic.unsubscribe(sub.getJid(), sub.getId()); - topic.removeItemDeleteListener(this); - topic.removeItemEventListener(this); - if (hasRole(SharedDisplayRole.SESSION_LEADER)) { - cleanUpHttpStorage(topic.getId()); - pubsubMgr.deleteNode(topic.getId()); + if (conn != null && conn.isConnected() && pubsubMgr != null + && topic != null && topicExists()) { + Subscription sub = findSubscription(getAccount()); + if (sub == null) { + return; + } + topic.unsubscribe(sub.getJid(), sub.getId()); + topic.removeItemDeleteListener(this); + topic.removeItemEventListener(this); + if (hasRole(SharedDisplayRole.SESSION_LEADER)) { + cleanUpHttpStorage(topic.getId()); + pubsubMgr.deleteNode(topic.getId()); + } } topic = null; pubsubMgr = null; diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java index 063232ae32..59d4724ec5 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java @@ -109,6 +109,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; * Apr 11, 2014 2903 bclement made constructor public b/c connection code moved packages * Apr 16, 2014 3020 bclement added check for invited rooms in roomExistsOnServer() * Apr 21, 2014 2822 bclement added hasMultipleHandles() + * Apr 22, 2014 2903 bclement added connection test to close method * * * @@ -192,7 +193,10 @@ public class VenueSession extends BaseSession implements IVenueSession { muc.removeParticipantListener(participantListener); participantListener = null; } - muc.leave(); + CollaborationConnection conn = getConnection(); + if (conn != null && conn.isConnected()) { + muc.leave(); + } muc = null; } From 40bb46402fb6381227ee0e1d9bf6170e55dbbbdc Mon Sep 17 00:00:00 2001 From: Ben Steffensmeier Date: Mon, 21 Apr 2014 17:57:38 -0500 Subject: [PATCH 078/188] Issue #2946 allow multiple purge files for a plugin. Former-commit-id: 044feb48d66730cbc33b1da4b160e0bcd362bbd6 --- .../uf/edex/database/plugin/PluginDao.java | 141 ++++++++++++------ .../uf/edex/database/purge/PurgeRuleSet.java | 14 +- 2 files changed, 106 insertions(+), 49 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/PluginDao.java b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/PluginDao.java index b42858845c..2ecbb96417 100644 --- a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/PluginDao.java +++ b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/PluginDao.java @@ -25,6 +25,7 @@ import java.util.ArrayList; import java.util.Arrays; import java.util.Calendar; import java.util.Collections; +import java.util.Comparator; import java.util.Date; import java.util.HashMap; import java.util.HashSet; @@ -36,6 +37,7 @@ import java.util.Map.Entry; import java.util.Set; import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ConcurrentMap; +import java.util.regex.Pattern; import org.apache.commons.beanutils.PropertyUtils; import org.hibernate.Criteria; @@ -63,13 +65,9 @@ import com.raytheon.uf.common.datastorage.StorageException; import com.raytheon.uf.common.datastorage.StorageStatus; import com.raytheon.uf.common.datastorage.records.IDataRecord; import com.raytheon.uf.common.localization.IPathManager; -import com.raytheon.uf.common.localization.LocalizationContext; -import com.raytheon.uf.common.localization.LocalizationContext.LocalizationLevel; -import com.raytheon.uf.common.localization.LocalizationContext.LocalizationType; import com.raytheon.uf.common.localization.LocalizationFile; import com.raytheon.uf.common.localization.PathManagerFactory; -import com.raytheon.uf.common.serialization.SerializationException; -import com.raytheon.uf.common.serialization.SerializationUtil; +import com.raytheon.uf.common.localization.exception.LocalizationException; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.edex.core.EdexException; @@ -117,6 +115,7 @@ import com.raytheon.uf.edex.database.query.DatabaseQuery; * Sept23, 2013 2399 dhladky Changed logging of duplicate records. * Oct 07, 2013 2392 rjpeter Updated to pass null productKeys as actual null instead of string null. * Dec 13, 2013 2555 rjpeter Refactored archiving logic into processArchiveRecords. + * Apr 21, 2014 2946 bsteffen Allow auxillary purge rules in multiple files. * * * @author bphillip @@ -215,7 +214,8 @@ public abstract class PluginDao extends CoreDao { logger.info("Discarded : " + duplicates.size() + " duplicates!"); if (logger.isDebugEnabled()) { for (PluginDataObject pdo : duplicates) { - logger.debug("Discarding duplicate: " + ((pdo)).getDataURI()); + logger.debug("Discarding duplicate: " + + ((pdo)).getDataURI()); } } } @@ -1697,52 +1697,105 @@ public abstract class PluginDao extends CoreDao { } public static PurgeRuleSet getPurgeRulesForPlugin(String pluginName) { + String masterFileName = "purge/" + pluginName + "PurgeRules.xml"; + Pattern auxFileNameMatcher = Pattern.compile(IPathManager.SEPARATOR + + pluginName + "PurgeRules\\w+\\.xml$"); IPathManager pathMgr = PathManagerFactory.getPathManager(); - Map tieredFile = pathMgr - .getTieredLocalizationFile(LocalizationType.COMMON_STATIC, - "purge/" + pluginName + "PurgeRules.xml"); - LocalizationContext[] levelHierarchy = pathMgr - .getLocalSearchHierarchy(LocalizationType.COMMON_STATIC); - File rulesFile = null; - for (LocalizationContext ctx : levelHierarchy) { - LocalizationFile lFile = tieredFile.get(ctx.getLocalizationLevel()); - if (lFile != null) { - rulesFile = lFile.getFile(); - break; + LocalizationFile[] allFiles = pathMgr.listStaticFiles("purge/", new String[] { ".xml" }, true, true); + LocalizationFile purgeRulesFile = null; + List auxRuleFiles = new ArrayList(); + /* + * Find master purge rules and any auxillary purge rules. Since the + * auxillary rules can have an arbitrary suffix before the extension we + * have to check all the files. + */ + for (LocalizationFile file : allFiles) { + if (file.exists()) { + if (auxFileNameMatcher.matcher(file.getName()).find()) { + auxRuleFiles.add(file); + } else if (file.getName().equals(masterFileName)) { + purgeRulesFile = file; + } } } - - if (rulesFile != null) { - // allow zero length file to disable purge for this plugin - if (rulesFile.length() > 0) { - try { - PurgeRuleSet purgeRules = SerializationUtil - .jaxbUnmarshalFromXmlFile(PurgeRuleSet.class, - rulesFile); - - // ensure there's a default rule - if (purgeRules.getDefaultRules() == null) { - purgeRules.setDefaultRules(loadDefaultPurgeRules()); - } - return purgeRules; - } catch (SerializationException e) { - PurgeLogger - .logError( - "Error deserializing purge rules! Data will not be purged. Please define rules.", - pluginName, e); - } + PurgeRuleSet purgeRules = null; + if (purgeRulesFile != null) { + try { + purgeRules = purgeRulesFile.jaxbUnmarshal(PurgeRuleSet.class, + PurgeRuleSet.jaxbManager); + } catch (LocalizationException e) { + PurgeLogger + .logError( + "Error deserializing purge rules! Data will not be purged. Please define rules.", + pluginName, e); + } + if (purgeRules == null) { + // allow zero length file to disable purge for this plugin + return null; + } else if (purgeRules.getDefaultRules() == null) { + // ensure there's a default rule + purgeRules.setDefaultRules(loadDefaultPurgeRules()); } } else if (!"default".equals(pluginName)) { // no purge rule for this plugin, check base purge rule return getPurgeRulesForPlugin("default"); + } else { + return null; } - return null; + /* Sorting guarantees multiple auxiliary files behave deterministicly. */ + Collections.sort(auxRuleFiles, new Comparator() { + @Override + public int compare(LocalizationFile o1, LocalizationFile o2) { + return o1.getName().compareTo(o2.getName()); + } + }); + + for (LocalizationFile file : auxRuleFiles) { + PurgeRuleSet auxRules = null; + try { + auxRules = file.jaxbUnmarshal(PurgeRuleSet.class, + PurgeRuleSet.jaxbManager); + } catch (LocalizationException e) { + PurgeLogger.logError( + "Error deserializing auxiliary purge rules! Rules from " + + file.toString() + " will be ignored", + pluginName, e); + } + if (auxRules == null) { + continue; + } + if (auxRules.getDefaultRules() != null) { + PurgeLogger + .logWarn( + file.toString() + + " should not contain default rules, they will be ignored. Default can only be defined in " + + masterFileName, pluginName); + } + /* + * TODO this could work if auxRules has less keys but would need to + * verify that auxRules isn't using more keys than are deined, + * specifically if defining 0 keys. + */ + if (auxRules.getKeys().equals(purgeRules.getKeys())) { + purgeRules.getRules().addAll(purgeRules.getRules()); + } else { + PurgeLogger.logError( + "Ignoring purge rules in " + + file.toString() + + " because the keys are different from those in " + + masterFileName, pluginName); + } + } + return purgeRules; + + } public static List loadDefaultPurgeRules() { - File defaultRule = PathManagerFactory.getPathManager().getStaticFile( + LocalizationFile defaultRule = PathManagerFactory.getPathManager() + .getStaticLocalizationFile( "purge/defaultPurgeRules.xml"); - if (defaultRule == null) { + if (defaultRule == null || defaultRule.exists() == false) { PurgeLogger .logError( "Default purge rule not defined!! Data will not be purged for plugins which do not specify purge rules!", @@ -1751,12 +1804,12 @@ public abstract class PluginDao extends CoreDao { } try { - PurgeRuleSet purgeRules = SerializationUtil - .jaxbUnmarshalFromXmlFile(PurgeRuleSet.class, defaultRule); + PurgeRuleSet purgeRules = defaultRule.jaxbUnmarshal( + PurgeRuleSet.class, PurgeRuleSet.jaxbManager); return purgeRules.getDefaultRules(); - } catch (SerializationException e) { + } catch (LocalizationException e) { PurgeLogger.logError("Error deserializing default purge rule!", - "DEFAULT"); + "DEFAULT", e); } return null; diff --git a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/purge/PurgeRuleSet.java b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/purge/PurgeRuleSet.java index 41c4d9d404..2eb69ddc9b 100644 --- a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/purge/PurgeRuleSet.java +++ b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/purge/PurgeRuleSet.java @@ -30,7 +30,7 @@ import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlElements; import javax.xml.bind.annotation.XmlRootElement; -import com.raytheon.uf.common.serialization.ISerializableObject; +import com.raytheon.uf.common.serialization.SingleTypeJAXBManager; /** * A container class used for unmarshalling purge rules. The purge rules are @@ -41,9 +41,10 @@ import com.raytheon.uf.common.serialization.ISerializableObject; * * SOFTWARE HISTORY * - * Date Ticket# Engineer Description - * ------------ ---------- ----------- -------------------------- - * 2/15/11 #2469 bphillip Initial creation + * Date Ticket# Engineer Description + * ------------- -------- ----------- -------------------------- + * Feb 15, 2011 2469 bphillip Initial creation + * Apr 22, 2014 2946 bsteffen Remove ISerializableObject, add jaxbManager * * * @@ -52,7 +53,10 @@ import com.raytheon.uf.common.serialization.ISerializableObject; */ @XmlRootElement(name = "purgeRuleSet") @XmlAccessorType(XmlAccessType.NONE) -public class PurgeRuleSet implements ISerializableObject { +public class PurgeRuleSet { + + public static final SingleTypeJAXBManager jaxbManager = SingleTypeJAXBManager + .createWithoutException(PurgeRuleSet.class); @XmlElements({ @XmlElement(name = "key", type = String.class) }) private List keys; From 4f0b83a12eb385d3a14f717e172a1c6d2df587f8 Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Tue, 22 Apr 2014 15:08:12 -0500 Subject: [PATCH 079/188] Issue #2928: Add default byte limit, set registry byte limit Change-Id: I31f6687b30f501a30f78d4b289059d2de19528f6 Former-commit-id: e32d44051831d9b587ab398a19eb5afe7b7b5c58 --- .../com/raytheon/uf/edex/auth/RemoteRequestRouteWrapper.java | 3 ++- edexOsgi/com.raytheon.uf.edex.registry.ebxml/.classpath | 2 -- .../res/spring/ebxml-thrift-client.xml | 1 + 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.edex.auth/src/com/raytheon/uf/edex/auth/RemoteRequestRouteWrapper.java b/edexOsgi/com.raytheon.uf.edex.auth/src/com/raytheon/uf/edex/auth/RemoteRequestRouteWrapper.java index 660e331284..3099418a07 100644 --- a/edexOsgi/com.raytheon.uf.edex.auth/src/com/raytheon/uf/edex/auth/RemoteRequestRouteWrapper.java +++ b/edexOsgi/com.raytheon.uf.edex.auth/src/com/raytheon/uf/edex/auth/RemoteRequestRouteWrapper.java @@ -67,7 +67,8 @@ public class RemoteRequestRouteWrapper { private RemoteRequestServer server; - private int byteLimitInMB; + // default to 100MB + private int byteLimitInMB = 100; public byte[] executeThrift(InputStream data) { /* diff --git a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/.classpath b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/.classpath index fd798babda..ad32c83a78 100644 --- a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/.classpath +++ b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/.classpath @@ -3,7 +3,5 @@ - - diff --git a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/res/spring/ebxml-thrift-client.xml b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/res/spring/ebxml-thrift-client.xml index 580a790b58..247c7aed13 100644 --- a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/res/spring/ebxml-thrift-client.xml +++ b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/res/spring/ebxml-thrift-client.xml @@ -10,6 +10,7 @@ + From fdfac581d6945514470f11e2e0e7d32f18890a9d Mon Sep 17 00:00:00 2001 From: Brad Gonzales Date: Tue, 22 Apr 2014 15:38:45 -0500 Subject: [PATCH 080/188] Issue #3024 Removed edex feature build.xml files. Removed bkowal from the buildEnvironment.sh script. Change-Id: Ic1ee22e604a68c2c475cb002901413c55bda6bd1 Former-commit-id: fdf7e47c2ddcfe4154ee117a0b5a722cd420df20 --- .../build.xml | 193 -------- .../build.xml | 278 ----------- .../build.xml | 378 --------------- .../build.xml | 318 ------------- .../build.xml | 425 ----------------- .../build.xml | 293 ------------ .../build.xml | 433 ------------------ .../build.xml | 198 -------- .../build.xml | 198 -------- .../build.xml | 223 --------- .../build.xml | 208 --------- .../build.xml | 203 -------- .../build.xml | 238 ---------- rpms/build/x86_64/buildEnvironment.sh | 4 +- 14 files changed, 2 insertions(+), 3588 deletions(-) delete mode 100644 edexOsgi/com.raytheon.uf.edex.binlightning.feature/build.xml delete mode 100644 edexOsgi/com.raytheon.uf.edex.bufr.feature/build.xml delete mode 100644 edexOsgi/com.raytheon.uf.edex.common.core.feature/build.xml delete mode 100644 edexOsgi/com.raytheon.uf.edex.core.feature/build.xml delete mode 100644 edexOsgi/com.raytheon.uf.edex.cots.feature/build.xml delete mode 100644 edexOsgi/com.raytheon.uf.edex.dat.feature/build.xml delete mode 100644 edexOsgi/com.raytheon.uf.edex.dataplugins.feature/build.xml delete mode 100644 edexOsgi/com.raytheon.uf.edex.gfe.feature/build.xml delete mode 100644 edexOsgi/com.raytheon.uf.edex.grib.feature/build.xml delete mode 100644 edexOsgi/com.raytheon.uf.edex.hydro.feature/build.xml delete mode 100644 edexOsgi/com.raytheon.uf.edex.radar.feature/build.xml delete mode 100644 edexOsgi/com.raytheon.uf.edex.satellite.feature/build.xml delete mode 100644 edexOsgi/com.raytheon.uf.edex.text.feature/build.xml diff --git a/edexOsgi/com.raytheon.uf.edex.binlightning.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.binlightning.feature/build.xml deleted file mode 100644 index e1094dd231..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.binlightning.feature/build.xml +++ /dev/null @@ -1,193 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.bufr.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.bufr.feature/build.xml deleted file mode 100644 index 0de1d971d4..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.bufr.feature/build.xml +++ /dev/null @@ -1,278 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.common.core.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.common.core.feature/build.xml deleted file mode 100644 index 14898e7242..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.common.core.feature/build.xml +++ /dev/null @@ -1,378 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.core.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.core.feature/build.xml deleted file mode 100644 index c9a6e7eb0a..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.core.feature/build.xml +++ /dev/null @@ -1,318 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.cots.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.cots.feature/build.xml deleted file mode 100644 index 24c8264175..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.cots.feature/build.xml +++ /dev/null @@ -1,425 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.dat.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.dat.feature/build.xml deleted file mode 100644 index bae35a71a8..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.dat.feature/build.xml +++ /dev/null @@ -1,293 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/build.xml deleted file mode 100644 index 29e01809e2..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/build.xml +++ /dev/null @@ -1,433 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.gfe.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.gfe.feature/build.xml deleted file mode 100644 index 29a0b38fb2..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.gfe.feature/build.xml +++ /dev/null @@ -1,198 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.grib.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.grib.feature/build.xml deleted file mode 100644 index 6abdcc0c80..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.grib.feature/build.xml +++ /dev/null @@ -1,198 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.hydro.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.hydro.feature/build.xml deleted file mode 100644 index cb4526d23e..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.hydro.feature/build.xml +++ /dev/null @@ -1,223 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.radar.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.radar.feature/build.xml deleted file mode 100644 index 7860b1a6cf..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.radar.feature/build.xml +++ /dev/null @@ -1,208 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.satellite.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.satellite.feature/build.xml deleted file mode 100644 index 9b06f1bd5b..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.satellite.feature/build.xml +++ /dev/null @@ -1,203 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.text.feature/build.xml b/edexOsgi/com.raytheon.uf.edex.text.feature/build.xml deleted file mode 100644 index 9f71153f31..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.text.feature/build.xml +++ /dev/null @@ -1,238 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/rpms/build/x86_64/buildEnvironment.sh b/rpms/build/x86_64/buildEnvironment.sh index ada7c5f90c..f294d21205 100644 --- a/rpms/build/x86_64/buildEnvironment.sh +++ b/rpms/build/x86_64/buildEnvironment.sh @@ -4,8 +4,8 @@ export AWIPSII_VERSION="11.9.0" export AWIPSII_RELEASE="20120223" -export AWIPSII_TOP_DIR="/home/bkowal/rpmbuild" -export WORKSPACE="/common/bkowal/git/thunder/baseline" +export AWIPSII_TOP_DIR="/tmp/${USER}/rpmbuild" +export WORKSPACE="/tmp/${USER}/baseline" export UFRAME_ECLIPSE="/opt/uframe-eclipse" export AWIPSCM_SHARE="/awipscm" export AWIPSII_BUILD_ROOT="/tmp/${USER}/awips-component" From 810b3737c6806ca6dffbd642ba1d6fdc4ee08d05 Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Tue, 22 Apr 2014 15:54:41 -0500 Subject: [PATCH 081/188] Issue #2726: Reduce excessive logging at startup Change-Id: I350fe246fb0d08da900b3fb2a5708a94aefec0c4 Former-commit-id: fd52ae21604814c665c2f5d7774c485d46747a5d --- edexOsgi/build.edex/esb/conf/logback-dataprovideragent.xml | 3 +++ edexOsgi/build.edex/esb/conf/logback-ingest.xml | 3 +++ edexOsgi/build.edex/esb/conf/logback-registry.xml | 3 +++ edexOsgi/build.edex/esb/conf/logback.xml | 3 +++ .../src/com/raytheon/uf/common/jms/JmsPooledSession.java | 4 +++- 5 files changed, 15 insertions(+), 1 deletion(-) diff --git a/edexOsgi/build.edex/esb/conf/logback-dataprovideragent.xml b/edexOsgi/build.edex/esb/conf/logback-dataprovideragent.xml index 185e9cd362..a6c4472772 100644 --- a/edexOsgi/build.edex/esb/conf/logback-dataprovideragent.xml +++ b/edexOsgi/build.edex/esb/conf/logback-dataprovideragent.xml @@ -42,6 +42,9 @@ + + + diff --git a/edexOsgi/build.edex/esb/conf/logback-ingest.xml b/edexOsgi/build.edex/esb/conf/logback-ingest.xml index 3a0f3a324a..9bf2310f1e 100644 --- a/edexOsgi/build.edex/esb/conf/logback-ingest.xml +++ b/edexOsgi/build.edex/esb/conf/logback-ingest.xml @@ -242,6 +242,9 @@ + + + diff --git a/edexOsgi/build.edex/esb/conf/logback-registry.xml b/edexOsgi/build.edex/esb/conf/logback-registry.xml index e4970fb742..20db4e7572 100644 --- a/edexOsgi/build.edex/esb/conf/logback-registry.xml +++ b/edexOsgi/build.edex/esb/conf/logback-registry.xml @@ -119,6 +119,9 @@ + + + diff --git a/edexOsgi/build.edex/esb/conf/logback.xml b/edexOsgi/build.edex/esb/conf/logback.xml index f407019dc7..4f72f47243 100644 --- a/edexOsgi/build.edex/esb/conf/logback.xml +++ b/edexOsgi/build.edex/esb/conf/logback.xml @@ -112,6 +112,9 @@ + + + diff --git a/edexOsgi/com.raytheon.uf.common.jms/src/com/raytheon/uf/common/jms/JmsPooledSession.java b/edexOsgi/com.raytheon.uf.common.jms/src/com/raytheon/uf/common/jms/JmsPooledSession.java index 9c1ce83c72..132bf5aff0 100644 --- a/edexOsgi/com.raytheon.uf.common.jms/src/com/raytheon/uf/common/jms/JmsPooledSession.java +++ b/edexOsgi/com.raytheon.uf.common.jms/src/com/raytheon/uf/common/jms/JmsPooledSession.java @@ -111,7 +111,9 @@ public class JmsPooledSession { this.conn = conn; this.sess = sess; this.thread = conn.getThread(); - statusHandler.info("Opening session: " + this.toString()); + if (statusHandler.isPriorityEnabled(Priority.DEBUG)) { + statusHandler.debug("Opening session: " + this.toString()); + } } public long getCreateTime() { From 35c090952c9030f7c86422e863a13c8c9069bfeb Mon Sep 17 00:00:00 2001 From: Ron Anderson Date: Tue, 22 Apr 2014 18:40:15 -0500 Subject: [PATCH 082/188] Issue #2997 Fix NullPointerException when env is null Change-Id: Iec29c2c99f43239e95de6b01cb3e91d67211a1fe Former-commit-id: 31668fe53d6b138106412516a657107f521423c5 --- .../maps/dataaccess/util/MapsQueryUtil.java | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.maps/src/com/raytheon/uf/common/dataplugin/maps/dataaccess/util/MapsQueryUtil.java b/edexOsgi/com.raytheon.uf.common.dataplugin.maps/src/com/raytheon/uf/common/dataplugin/maps/dataaccess/util/MapsQueryUtil.java index 8fbc3e18fd..e6844a7393 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.maps/src/com/raytheon/uf/common/dataplugin/maps/dataaccess/util/MapsQueryUtil.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.maps/src/com/raytheon/uf/common/dataplugin/maps/dataaccess/util/MapsQueryUtil.java @@ -80,8 +80,11 @@ public class MapsQueryUtil { List columns, List additionalConstraints, String table, String geomField) { - String geospatialConstraint = "ST_Intersects(the_geom, ST_GeometryFromText('" - + boundingGeom.toText() + "', " + WGS84_SRID + "))"; + String geospatialConstraint = null; + if (boundingGeom != null) { + geospatialConstraint = "ST_Intersects(the_geom, ST_GeometryFromText('" + + boundingGeom.toText() + "', " + WGS84_SRID + "))"; + } return assembleMapsTableQuery(geospatialConstraint, columns, additionalConstraints, table, geomField); @@ -110,10 +113,13 @@ public class MapsQueryUtil { List columns, List additionalConstraints, String table, String geomField) { - String geospatialConstraint = String.format( - "%s && ST_SetSrid('BOX3D(%f %f, %f %f)'::box3d," + WGS84_SRID - + ")", geomField, env.getMinX(), env.getMinY(), - env.getMaxX(), env.getMaxY()); + String geospatialConstraint = null; + if (env != null) { + geospatialConstraint = String.format( + "%s && ST_SetSrid('BOX3D(%f %f, %f %f)'::box3d," + + WGS84_SRID + ")", geomField, env.getMinX(), + env.getMinY(), env.getMaxX(), env.getMaxY()); + } return assembleMapsTableQuery(geospatialConstraint, columns, additionalConstraints, table, geomField); } From 43b44d911a681c1fe9590731df00dbdf3f69eb84 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Wed, 23 Apr 2014 12:05:20 -0500 Subject: [PATCH 083/188] Issue #2060 fix delta script to only drop dataURI if the constraint alterations work Change-Id: I5ad70fd87b72ebb3566aa99d7c603b2b122be5e8 Former-commit-id: 6f8459f03a5af0816f93b0a20e861aafe5a9a779 --- deltaScripts/14.3.1/dropGridDataURI.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/deltaScripts/14.3.1/dropGridDataURI.sh b/deltaScripts/14.3.1/dropGridDataURI.sh index 9b979efefc..d4d41282eb 100644 --- a/deltaScripts/14.3.1/dropGridDataURI.sh +++ b/deltaScripts/14.3.1/dropGridDataURI.sh @@ -33,9 +33,9 @@ function dropAndAddConstraint { echo "INFO: Dropping dataURI columns." -dropDatauri dropAndAddConstraint grid grid_reftime_forecasttime_rangestart_rangeend_info_id "(refTime, forecastTime, rangestart, rangeend, info_id)" dropAndAddConstraint grid_info grid_info_datasetid_secondaryid_ensembleid_location_id_parameter_abbreviation_level_id "(datasetid, secondaryid, ensembleid, location_id, parameter_abbreviation, level_id)" +dropDatauri echo "INFO: grid dataURI column dropped successfully" From 426f103e7b961692391520d02b177f11ed45ca3f Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Wed, 23 Apr 2014 12:19:50 -0500 Subject: [PATCH 084/188] Issue #3060 safety checks for SWT widgets being disposed Change-Id: I85c56318452a31122ee7f144e5500d089aa614e2 Former-commit-id: 0c391f8c7f1694c6939419b5fcc4a6a963092ae3 --- .../ui/editor/CollaborationPaneManager.java | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/editor/CollaborationPaneManager.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/editor/CollaborationPaneManager.java index c2abbc8a8e..fb0b40c538 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/editor/CollaborationPaneManager.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/editor/CollaborationPaneManager.java @@ -51,7 +51,8 @@ import com.raytheon.viz.ui.panes.VizDisplayPane; * * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Jun 7, 2012 mschenke Initial creation + * Jun 07, 2012 mschenke Initial creation + * Apr 23, 2014 3060 njensen Safety checks for SWT widgets disposed * * * @@ -179,11 +180,14 @@ public class CollaborationPaneManager extends PaneManager { setExclude(activeData, true); activeData = null; } - noDisplayLabel.setVisible(true); - ((GridData) noDisplayLabel.getLayoutData()).exclude = false; - composite.layout(); + if (!noDisplayLabel.isDisposed() && !composite.isDisposed()) { + noDisplayLabel.setVisible(true); + ((GridData) noDisplayLabel.getLayoutData()).exclude = false; + composite.layout(); + } } + @Override protected void adjustPaneLayout(int paneCount) { ;// don't do anything, we always want one pane displayed. } From 331dc3397fea716245e0427cc7a859a9fdd4bda5 Mon Sep 17 00:00:00 2001 From: Lee Venable Date: Tue, 22 Apr 2014 15:40:43 -0500 Subject: [PATCH 085/188] Issue #3053 - updated list selection dialog to be more configurable and fixed subset action. Change-Id: Ib65472679cf5c04f8c11b8fe3fe552058d9e6986 Former-commit-id: 4554f647e0f6de78f5ade64e1371fc8d9ba6a65c --- .../datadelivery/actions/SubsetAction.java | 38 ++- .../viz/ui/dialogs/ListSelectionDlg.java | 241 +++++++++++++++--- 2 files changed, 235 insertions(+), 44 deletions(-) diff --git a/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/actions/SubsetAction.java b/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/actions/SubsetAction.java index 3d31fd424f..9e825bc1e6 100644 --- a/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/actions/SubsetAction.java +++ b/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/actions/SubsetAction.java @@ -22,6 +22,8 @@ package com.raytheon.uf.viz.datadelivery.actions; import org.eclipse.core.commands.AbstractHandler; import org.eclipse.core.commands.ExecutionEvent; import org.eclipse.core.commands.ExecutionException; +import org.eclipse.swt.SWT; +import org.eclipse.swt.widgets.MessageBox; import org.eclipse.swt.widgets.Shell; import org.eclipse.ui.PlatformUI; @@ -61,6 +63,10 @@ import com.raytheon.viz.ui.dialogs.ListSelectionDlg; * Sep 04, 2013 2314 mpduff LoadSave dialog now non-blocking. * Oct 11, 2013 2386 mpduff Refactor DD Front end. * Apr 10, 2014 2864 mpduff Changed how saved subset files are stored. + * Apr 22, 2014 3053 lvenable Updated constructor args for ListSelectionDlg, put + * in a null check when the dialog is canceled, and removed + * throwing an exception that will be handled by a message box + * in the list selection dialog. * * * @@ -97,13 +103,24 @@ public class SubsetAction extends AbstractHandler { final Shell shell = PlatformUI.getWorkbench() .getActiveWorkbenchWindow().getShell(); if (selectionDlg == null || selectionDlg.isDisposed()) { - selectionDlg = new ListSelectionDlg(shell, choices); + selectionDlg = new ListSelectionDlg(shell, choices, true, + ListSelectionDlg.ReturnArray.ARRAY_STRING_ITEMS, + "Select"); selectionDlg.setCloseCallback(new ICloseCallback() { @Override public void dialogClosed(Object returnValue) { + // The the return value is null then return since + // the dialog was canceled. + if (returnValue == null) { + return; + } + if (returnValue instanceof String[]) { String[] selection = (String[]) returnValue; - if (selection.length == 1) { + + if (selection.length == 0) { + return; + } else if (selection.length == 1) { String[] parts = selection[0].split(":"); SubsetFileManager sfm = SubsetFileManager @@ -127,14 +144,21 @@ public class SubsetAction extends AbstractHandler { dlg.bringToTop(); } } else { - throw new IllegalArgumentException( - "Expected 1 item, received " - + selection.length - + " items."); + /* + * This is just a safety check in case the + * dialog is configured incorrectly. + */ + MessageBox mb = new MessageBox(shell, + SWT.ICON_WARNING | SWT.OK); + mb.setText("Multiple Items"); + mb.setMessage("Multiple items were selected. Only one item can be processed.\n" + + "You must relaunch the dialog and select one item to process."); + mb.open(); } } else { throw new IllegalArgumentException( - "Invalid return type from ListSelectionDlg"); + "Invalid return type from ListSelectionDlg: " + + returnValue.getClass()); } } }); diff --git a/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/ListSelectionDlg.java b/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/ListSelectionDlg.java index 681e93d183..7f8e167813 100644 --- a/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/ListSelectionDlg.java +++ b/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/ListSelectionDlg.java @@ -20,16 +20,19 @@ package com.raytheon.viz.ui.dialogs; import org.eclipse.swt.SWT; +import org.eclipse.swt.events.MouseAdapter; import org.eclipse.swt.events.MouseEvent; -import org.eclipse.swt.events.MouseListener; import org.eclipse.swt.events.SelectionAdapter; import org.eclipse.swt.events.SelectionEvent; +import org.eclipse.swt.graphics.GC; import org.eclipse.swt.layout.GridData; import org.eclipse.swt.layout.GridLayout; import org.eclipse.swt.widgets.Button; import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Label; import org.eclipse.swt.widgets.Layout; import org.eclipse.swt.widgets.List; +import org.eclipse.swt.widgets.MessageBox; import org.eclipse.swt.widgets.Shell; /** @@ -42,6 +45,7 @@ import org.eclipse.swt.widgets.Shell; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Apr 09, 2014 2864 mpduff Initial creation + * Apr 22, 2014 3053 lvenable Updated to be more configurable. * * * @@ -59,40 +63,143 @@ public class ListSelectionDlg extends CaveSWTDialog { /** The list widget */ private List selectList; + /** Label above the list control. */ + private String listLblText; + + /** Default minimum list width. */ + private int defaultMinListWidth = 225; + + /** Default Minimum list height. */ + private int defaultMinListHeight = 275; + + /** Minimum list width. */ + private int minListWidth = defaultMinListWidth; + + /** Minimum list height. */ + private int minListHeight = defaultMinListHeight; + + /** Text to put in the action button. */ + private String actionButtonText; + + /** + * Enumeration to determine how the selection from the list will be + * returned. + */ + public enum ReturnArray { + ARRAY_STRING_ITEMS, ARRAY_INDEXES + }; + + /** Variable to determine how the data is returned. */ + private ReturnArray returnAsArray = ReturnArray.ARRAY_STRING_ITEMS; + /** * Constructor. * * @param parent - * Parent shell + * Parent shell. * @param textChoices - * Items for the list + * Array of items to be put in the list. * @param singleSelect - * true if only a single selection allowed + * True for single selection, false for multiple selection. + * @param returnAs + * Determine how the selection is returned. + * @param actionButtonText + * Text for the action button. */ public ListSelectionDlg(Shell parent, String[] textChoices, - boolean singleSelect) { - super(parent, SWT.TITLE | SWT.RESIZE | SWT.APPLICATION_MODAL, - CAVE.DO_NOT_BLOCK); - this.textChoices = textChoices; - this.singleSelect = singleSelect; - - if (singleSelect) { - setText("Select One"); - } else { - setText("Select Items"); - } + boolean singleSelect, ReturnArray returnAs, String actionButtonText) { + this(parent, textChoices, singleSelect, returnAs, actionButtonText, + null, null); } /** - * Single select list. + * Constructor. * * @param parent - * Parent shell + * Parent shell. * @param textChoices - * Items for the list + * Array of items to be put in the list. + * @param singleSelect + * True for single selection, false for multiple selection. + * @param returnAs + * Determine how the selection is returned. + * @param actionButtonText + * Text for the action button. + * @param title + * Dialog title. + * @param listMsg + * Text displayed in the label above the list control. */ - public ListSelectionDlg(Shell parent, String[] textChoices) { - this(parent, textChoices, true); + public ListSelectionDlg(Shell parent, String[] textChoices, + boolean singleSelect, ReturnArray returnAs, + String actionButtonText, String title, String listMsg) { + this(parent, textChoices, singleSelect, returnAs, actionButtonText, + title, listMsg, 225, 275); + } + + /** + * Constructor. + * + * @param parent + * Parent shell. + * @param textChoices + * Array of items to be put in the list. + * @param singleSelect + * True for single selection, false for multiple selection. + * @param returnAs + * Determine how the selection is returned. + * @param actionButtonText + * Text for the action button. + * @param title + * Dialog title. + * @param listMsg + * Text displayed in the label above the list control. + * @param minWidth + * Minimum list control width (minimum default value is 225). + * @param minHeight + * Minimum list control height (minimum default value is 275). + */ + public ListSelectionDlg(Shell parent, String[] textChoices, + boolean singleSelect, ReturnArray returnAs, + String actionButtonText, String title, String listMsg, + int minWidth, int minHeight) { + super(parent, SWT.TITLE | SWT.RESIZE | SWT.APPLICATION_MODAL, + CAVE.DO_NOT_BLOCK); + + this.textChoices = textChoices; + this.singleSelect = singleSelect; + this.returnAsArray = returnAs; + + // Set the minimum width & height for the list control. + this.minListWidth = (defaultMinListWidth < minWidth ? defaultMinListWidth + : minWidth); + this.minListHeight = (defaultMinListHeight < minHeight ? defaultMinListHeight + : minHeight); + + // Set the action button text. + if (actionButtonText == null) { + this.actionButtonText = "Select"; + } else { + this.actionButtonText = actionButtonText; + } + + // Set the dialog title. + if (title == null) { + setText("Selection"); + } else { + setText(title); + } + + // Set the text in the label above the list control. + if (listMsg == null) { + if (singleSelect) { + listLblText = "Select an item:"; + } else { + listLblText = "Select item(s):"; + } + } else { + listLblText = listMsg; + } } @Override @@ -117,6 +224,9 @@ public class ListSelectionDlg extends CaveSWTDialog { mainComp.setLayout(new GridLayout(1, false)); mainComp.setLayoutData(gd); + Label listLbl = new Label(mainComp, SWT.NONE); + listLbl.setText(listLblText); + int style = SWT.SINGLE; if (!this.singleSelect) { style = SWT.MULTI; @@ -127,18 +237,7 @@ public class ListSelectionDlg extends CaveSWTDialog { gd = new GridData(SWT.FILL, SWT.FILL, true, true); selectList = new List(mainComp, SWT.BORDER | style); selectList.setLayoutData(gd); - selectList.addMouseListener(new MouseListener() { - - @Override - public void mouseUp(MouseEvent e) { - // No op - } - - @Override - public void mouseDown(MouseEvent e) { - // No op - } - + selectList.addMouseListener(new MouseAdapter() { @Override public void mouseDoubleClick(MouseEvent e) { action(); @@ -150,9 +249,12 @@ public class ListSelectionDlg extends CaveSWTDialog { btnComp.setLayout(new GridLayout(2, false)); btnComp.setLayoutData(gd); + int buttonWidth = 0; + Button selectBtn = new Button(btnComp, SWT.PUSH); - selectBtn.setLayoutData(new GridData(75, SWT.DEFAULT)); - selectBtn.setText("Select"); + buttonWidth = calculateButtonWidth(selectBtn, actionButtonText); + selectBtn.setLayoutData(new GridData(buttonWidth, SWT.DEFAULT)); + selectBtn.setText(actionButtonText); selectBtn.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent e) { @@ -161,7 +263,7 @@ public class ListSelectionDlg extends CaveSWTDialog { }); Button cancelBtn = new Button(btnComp, SWT.PUSH); - cancelBtn.setLayoutData(new GridData(75, SWT.DEFAULT)); + cancelBtn.setLayoutData(new GridData(buttonWidth, SWT.DEFAULT)); cancelBtn.setText("Cancel"); cancelBtn.addSelectionListener(new SelectionAdapter() { @Override @@ -171,14 +273,79 @@ public class ListSelectionDlg extends CaveSWTDialog { }); selectList.setItems(textChoices); - this.shell.setMinimumSize(225, 275); + this.shell.setMinimumSize(minListWidth, minListHeight); + } + + /** + * Calculate the button width based on the text to be displayed. + * + * @param btn + * Button control. + * @param text + * Text to be displayed. + * @return The calculated button width. + */ + private int calculateButtonWidth(Button btn, String text) { + int rv = 0; + int extentLength = 0; + int defaultButtonWidth = 75; + int textBufferWidth = 15; + + // Get the length of the text in pixels that will be displayed in the + // button. + GC gc = new GC(btn); + extentLength = gc.stringExtent(text).x; + rv = (defaultButtonWidth > extentLength) ? defaultButtonWidth + : extentLength; + gc.dispose(); + + /* + * Return the lenght of the text and the added buffer that accounts for + * the button edges. + */ + return rv + textBufferWidth; } /** * Action handler. */ private void action() { - setReturnValue(selectList.getSelection()); + + int choice = displayConfirmationBox(); + if (choice == SWT.CANCEL) { + return; + } + + if (returnAsArray == ReturnArray.ARRAY_STRING_ITEMS) { + setReturnValue(selectList.getSelection()); + } else if (returnAsArray == ReturnArray.ARRAY_INDEXES) { + setReturnValue(selectList.getSelectionIndices()); + } else { + setReturnValue(null); + } + close(); } + + /** + * Display a confirmation dialog to the user. + * + * @return SWT.OK or SWT.CANCEL + */ + private int displayConfirmationBox() { + String itemTxt = null; + + if (singleSelect) { + itemTxt = "No item is selected."; + } else { + itemTxt = "No items are selected."; + } + + MessageBox mb = new MessageBox(shell, SWT.ICON_QUESTION | SWT.OK + | SWT.CANCEL); + mb.setText("Confirmation"); + mb.setMessage(itemTxt + " Do you wish to continue?"); + int val = mb.open(); + return val; + } } From f3ee7b453a652e7274e2ec5922d80663d3aaa48e Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Wed, 23 Apr 2014 12:04:56 -0500 Subject: [PATCH 086/188] Issue #2822 shared display invitations always go to cave if user is logged in to a client that supports shared displays, invites always go there behaviour unchanged if not logged into a client that supports shared displays added better resource name than 'Smack' for cave clients Former-commit-id: 796e4dcd2d81d8b34ae835dbe8443fd56ba873e3 --- .../uf/viz/collaboration/comm/Activator.java | 18 ++ .../connection/CollaborationConnection.java | 28 +- .../session/SharedDisplaySession.java | 29 +++ .../comm/provider/session/VenueSession.java | 14 +- .../comm/provider/user/ContactsListener.java | 242 ++++++++++++++++++ .../comm/provider/user/ContactsManager.java | 73 ++---- .../comm/provider/user/ResourceInfo.java | 136 ++++++++++ .../collaboration/ui/login/LoginDialog.java | 5 +- 8 files changed, 484 insertions(+), 61 deletions(-) create mode 100644 cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsListener.java create mode 100644 cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ResourceInfo.java diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/Activator.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/Activator.java index 7ba4d0186a..94ae861a9f 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/Activator.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/Activator.java @@ -19,6 +19,7 @@ **/ package com.raytheon.uf.viz.collaboration.comm; +import org.osgi.framework.Bundle; import org.osgi.framework.BundleActivator; import org.osgi.framework.BundleContext; @@ -34,6 +35,7 @@ import com.raytheon.uf.common.comm.NetworkStatistics; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Feb 27, 2012 jkorman Initial creation + * Apr 23, 2014 2822 bclement added getBundleVersion() * * * @@ -80,4 +82,20 @@ public class Activator implements BundleActivator { return plugin; } + /** + * Get the version from the manifest + * + * @return null if not available + */ + public static String getBundleVersion(){ + String rval = null; + if ( plugin != null){ + BundleContext context = plugin.getContext(); + if ( context != null){ + Bundle bundle = context.getBundle(); + rval = bundle.getVersion().toString(); + } + } + return rval; + } } diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/CollaborationConnection.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/CollaborationConnection.java index b6e34ad338..0938d8624b 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/CollaborationConnection.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/connection/CollaborationConnection.java @@ -45,6 +45,7 @@ import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.xmpp.PacketConstants; import com.raytheon.uf.common.xmpp.iq.AuthInfo; import com.raytheon.uf.common.xmpp.iq.AuthInfoProvider; +import com.raytheon.uf.viz.collaboration.comm.Activator; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; import com.raytheon.uf.viz.collaboration.comm.identity.IAccountManager; import com.raytheon.uf.viz.collaboration.comm.identity.ISession; @@ -113,6 +114,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; * Apr 14, 2014 2903 bclement moved from session subpackage to connection, removed password from memory, * moved listeners to own classes, reworked connect/register listeners/login order * Apr 15, 2014 2822 bclement added pubsub owner subscriptions provider registration + * Apr 23, 2014 2822 bclement added resource name and getCollaborationVersion() * * * @@ -144,6 +146,8 @@ public class CollaborationConnection implements IEventPublisher { PubSubNamespace.OWNER.getXmlns(), new SubscriptionsProvider()); } + private static final String RESOURCE_BASENAME = "CAVE"; + private static final transient IUFStatusHandler statusHandler = UFStatus .getHandler(CollaborationConnection.class); @@ -303,7 +307,7 @@ public class CollaborationConnection implements IEventPublisher { private void loginInternal(String username, String password) throws CollaborationException { try { - connection.login(username, password); + connection.login(username, password, getResourceName()); } catch (XMPPException e) { close(); // get a nice reason for the user @@ -333,6 +337,28 @@ public class CollaborationConnection implements IEventPublisher { } } + /** + * get name used for CAVE collaboration XMPP resource + * + * @return + */ + public static String getResourceName() { + String rval = RESOURCE_BASENAME; + String version = getCollaborationVersion(); + if (version != null) { + rval += "-" + version; + } + return rval; + } + + /** + * @see Activator#getBundleVersion() + * @return + */ + public static String getCollaborationVersion() { + return Activator.getBundleVersion(); + } + /** * @return login data used to create this connection */ diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java index e03cfa34c6..28c67d63b0 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/SharedDisplaySession.java @@ -67,6 +67,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.account.ClientAuthManager import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.connection.PeerToPeerCommHelper; import com.raytheon.uf.viz.collaboration.comm.provider.event.LeaderChangeEvent; +import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; import com.raytheon.uf.viz.collaboration.comm.provider.user.IDConverter; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; @@ -99,6 +100,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; * Apr 15, 2014 2822 bclement added check for other participants being subscribed to topic * Apr 21, 2014 2822 bclement removed use of resources in topicSubscribers, added skipCache * Apr 22, 2014 2903 bclement added connection test to closePubSub() method + * Apr 23, 2014 2822 bclement added formatInviteAddress() * * * @@ -802,4 +804,31 @@ public class SharedDisplaySession extends VenueSession implements return rval; } + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.viz.collaboration.comm.provider.session.VenueSession# + * formatInviteAddress + * (com.raytheon.uf.viz.collaboration.comm.provider.user.UserId) + */ + @Override + protected String formatInviteAddress(UserId id) { + CollaborationConnection manager = getConnection(); + ContactsManager cm = manager.getContactsManager(); + String resource = cm.getSharedDisplayEnabledResource(id); + /* + * resource will be null if we can't find a resource that supports + * shared displays for this user + */ + String rval; + if (resource == null) { + rval = super.formatInviteAddress(id); + } else { + UserId newId = new UserId(id.getName(), id.getHost(), resource); + rval = newId.getFQName(); + } + return rval; + } + } diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java index 59d4724ec5..a118edce3d 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/session/VenueSession.java @@ -110,6 +110,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.VenueParticipant; * Apr 16, 2014 3020 bclement added check for invited rooms in roomExistsOnServer() * Apr 21, 2014 2822 bclement added hasMultipleHandles() * Apr 22, 2014 2903 bclement added connection test to close method + * Apr 23, 2014 2822 bclement added formatInviteAddress() * * * @@ -225,7 +226,6 @@ public class VenueSession extends BaseSession implements IVenueSession { SessionPayload payload = new SessionPayload(PayloadType.Invitation, invite); Message msg = new Message(); - msg.setTo(id.getNormalizedId()); UserId user = getAccount(); msg.setFrom(user.getNormalizedId()); msg.setType(Type.normal); @@ -236,7 +236,17 @@ public class VenueSession extends BaseSession implements IVenueSession { } else if (!StringUtils.isBlank(invite.getSubject())) { reason = invite.getSubject(); } - muc.invite(msg, id.getNormalizedId(), reason); + muc.invite(msg, formatInviteAddress(id), reason); + } + + /** + * format invite address for user + * + * @param id + * @return + */ + protected String formatInviteAddress(UserId id) { + return id.getNormalizedId(); } /* diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsListener.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsListener.java new file mode 100644 index 0000000000..b2bd85e5cf --- /dev/null +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsListener.java @@ -0,0 +1,242 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.viz.collaboration.comm.provider.user; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.HashMap; +import java.util.Iterator; +import java.util.List; +import java.util.Map; + +import org.jivesoftware.smack.Roster; +import org.jivesoftware.smack.RosterEntry; +import org.jivesoftware.smack.RosterListener; +import org.jivesoftware.smack.packet.Presence; +import org.jivesoftware.smack.packet.Presence.Type; + +import com.raytheon.uf.viz.collaboration.comm.identity.event.IRosterChangeEvent; +import com.raytheon.uf.viz.collaboration.comm.identity.event.RosterChangeType; +import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.event.RosterChangeEvent; + +/** + * Keeps track of contacts and resource information. Responsible for sending out + * roster change events. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 22, 2014 2822       bclement     Initial creation
+ * 
+ * 
+ * + * @author bclement + * @version 1.0 + */ +public class ContactsListener implements RosterListener { + + private final ContactsManager manager; + + private final Roster roster; + + private final Map> contactResources = new HashMap>(); + + /** + * @param manager + * @param roster + */ + public ContactsListener(ContactsManager manager, Roster roster) { + this.manager = manager; + this.roster = roster; + } + + /* + * (non-Javadoc) + * + * @see + * org.jivesoftware.smack.RosterListener#presenceChanged(org.jivesoftware + * .smack.packet.Presence) + */ + @Override + public void presenceChanged(Presence presence) { + String fromId = presence.getFrom(); + UserId u = IDConverter.convertFrom(fromId); + if (u != null) { + synchronized (contactResources) { + /* if they are logging out */ + if (presence.getType() == Type.unavailable) { + processLogout(u); + } else { + processUpdate(u, presence); + } + } + RosterEntry entry = manager.getRosterEntry(u); + post(entry); + IRosterChangeEvent event = new RosterChangeEvent( + RosterChangeType.PRESENCE, entry, presence); + post(event); + } + } + + /** + * Update contact resources when resource logs out. Must be externally + * synchronized + * + * @param uid + */ + private void processLogout(UserId uid) { + String bareId = uid.getNormalizedId(); + List resources = contactResources.get(bareId); + if (resources != null) { + String resource = uid.getResource(); + Iterator iterator = resources.iterator(); + while (iterator.hasNext()) { + ResourceInfo next = iterator.next(); + if (next.getResourceName().equalsIgnoreCase(resource)) { + iterator.remove(); + } + } + if (resources.isEmpty()) { + contactResources.remove(bareId); + } + } + } + + /** + * Update contact resources when resource changes (non-logout). Must be + * externally synchronized. + * + * @param uid + * @param presence + */ + private void processUpdate(UserId uid, Presence presence) { + String bareId = uid.getNormalizedId(); + String resource = uid.getResource(); + List resources = contactResources.get(bareId); + if (resources == null) { + /* we don't expect a large number of clients per user */ + resources = new ArrayList(2); + contactResources.put(bareId, resources); + } + ResourceInfo oldInfo = null; + for (ResourceInfo ri : resources) { + if (ri.getResourceName().equalsIgnoreCase(resource)) { + oldInfo = ri; + } + } + /* update resource */ + if (oldInfo == null) { + oldInfo = new ResourceInfo(resource, presence); + resources.add(oldInfo); + } else { + oldInfo.updateInfo(presence); + } + } + + /* + * (non-Javadoc) + * + * @see + * org.jivesoftware.smack.RosterListener#entriesUpdated(java.util.Collection + * ) + */ + @Override + public void entriesUpdated(Collection addresses) { + send(addresses, RosterChangeType.MODIFY); + } + + /* + * (non-Javadoc) + * + * @see + * org.jivesoftware.smack.RosterListener#entriesDeleted(java.util.Collection + * ) + */ + @Override + public void entriesDeleted(Collection addresses) { + send(addresses, RosterChangeType.DELETE); + } + + /* + * (non-Javadoc) + * + * @see + * org.jivesoftware.smack.RosterListener#entriesAdded(java.util.Collection) + */ + @Override + public void entriesAdded(Collection addresses) { + send(addresses, RosterChangeType.ADD); + } + + /** + * Send event bus notification for roster + * + * @param addresses + * @param type + */ + private void send(Collection addresses, RosterChangeType type) { + for (String addy : addresses) { + RosterEntry entry = roster.getEntry(addy); + if (entry != null) { + IRosterChangeEvent event = new RosterChangeEvent(type, entry); + post(event); + } + } + } + + /** + * Post event to collaboration event bus + * + * @param event + */ + private void post(Object event) { + CollaborationConnection connection = CollaborationConnection + .getConnection(); + connection.postEvent(event); + } + + /** + * Get name of resource that supports shared displays for user + * + * @param user + * @return null if no resource found for user that supports shared displays + */ + public String getSharedDisplayEnabledResource(UserId user) { + String rval = null; + synchronized (contactResources) { + List list = contactResources.get(user + .getNormalizedId()); + if (list != null) { + for (ResourceInfo ri : list) { + if (ri.supportsSharedDisplays()) { + rval = ri.getResourceName(); + break; + } + } + } + } + return rval; + } + +} diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java index b983dca2e4..37092ca567 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java @@ -31,7 +31,6 @@ import org.apache.commons.lang.StringUtils; import org.jivesoftware.smack.Roster; import org.jivesoftware.smack.RosterEntry; import org.jivesoftware.smack.RosterGroup; -import org.jivesoftware.smack.RosterListener; import org.jivesoftware.smack.XMPPConnection; import org.jivesoftware.smack.XMPPException; import org.jivesoftware.smack.packet.Presence; @@ -48,11 +47,8 @@ import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.common.util.collections.UpdatingSet; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; -import com.raytheon.uf.viz.collaboration.comm.identity.event.IRosterChangeEvent; -import com.raytheon.uf.viz.collaboration.comm.identity.event.RosterChangeType; import com.raytheon.uf.viz.collaboration.comm.provider.Tools; import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; -import com.raytheon.uf.viz.collaboration.comm.provider.event.RosterChangeEvent; /** * Manage contacts from local groups and roster on server @@ -77,6 +73,8 @@ import com.raytheon.uf.viz.collaboration.comm.provider.event.RosterChangeEvent; * Feb 3, 2014 2699 bclement fixed assumption that username search was exact * Apr 11, 2014 2903 bclement moved roster listener from collaboration connection to here * Apr 16, 2014 2981 bclement fixed NPE when cached shared group deleted on server + * Apr 23, 2014 2822 bclement moved roster listener to ContactsListener, + * added getSharedDisplayEnabledResource() * * * @@ -96,6 +94,8 @@ public class ContactsManager { private Map localAliases; + private final ContactsListener contactsListener; + /** * Cached view of shared groups list on openfire. Will only reach out to * server if it hasn't updated in an hour. This will disable itself if there @@ -133,59 +133,9 @@ public class ContactsManager { this.search = connection.createSearch(); localAliases = UserIdWrapper.readAliasMap(); this.xmpp = xmpp; - final Roster roster = xmpp.getRoster(); - roster.addRosterListener(new RosterListener() { - - @Override - public void presenceChanged(Presence presence) { - String fromId = presence.getFrom(); - UserId u = IDConverter.convertFrom(fromId); - if (u != null) { - RosterEntry entry = getRosterEntry(u); - post(entry); - IRosterChangeEvent event = new RosterChangeEvent( - RosterChangeType.PRESENCE, entry, presence); - post(event); - } - } - - @Override - public void entriesUpdated(Collection addresses) { - send(addresses, RosterChangeType.MODIFY); - } - - @Override - public void entriesDeleted(Collection addresses) { - send(addresses, RosterChangeType.DELETE); - } - - @Override - public void entriesAdded(Collection addresses) { - send(addresses, RosterChangeType.ADD); - } - - /** - * Send event bus notification for roster - * - * @param addresses - * @param type - */ - private void send(Collection addresses, - RosterChangeType type) { - for (String addy : addresses) { - RosterEntry entry = roster.getEntry(addy); - if (entry != null) { - IRosterChangeEvent event = new RosterChangeEvent(type, - entry); - post(event); - } - } - } - - private void post(Object event) { - ContactsManager.this.connection.postEvent(event); - } - }); + Roster roster = xmpp.getRoster(); + this.contactsListener = new ContactsListener(this, roster); + roster.addRosterListener(this.contactsListener); } /** @@ -747,6 +697,15 @@ public class ContactsManager { return rval; } + /** + * @see ContactsListener#getSharedDisplayEnabledResource(UserId) + * @param user + * @return + */ + public String getSharedDisplayEnabledResource(UserId user) { + return contactsListener.getSharedDisplayEnabledResource(user); + } + /** * Listener interface for group update events */ diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ResourceInfo.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ResourceInfo.java new file mode 100644 index 0000000000..da7fe0b189 --- /dev/null +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ResourceInfo.java @@ -0,0 +1,136 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.viz.collaboration.comm.provider.user; + +import org.jivesoftware.smack.packet.Presence; +import org.jivesoftware.smack.packet.Presence.Mode; +import org.jivesoftware.smack.packet.Presence.Type; + +/** + * Information for an XMPP resource (client ie pidgin) + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 22, 2014 2822       bclement     Initial creation
+ * 
+ * 
+ * + * @author bclement + * @version 1.0 + */ +public class ResourceInfo { + + public static final String VERSION_KEY = "urn:uf:viz:collaboration:version"; + + private final String resourceName; + + private String collaborationVersion; + + private Type lastType; + + private Mode lastMode; + + /** + * @param resourceName + * @param presence + */ + public ResourceInfo(String resourceName, Presence presence) { + this.resourceName = resourceName; + updateInfo(presence); + } + + /** + * Update resource information from presence + * + * @param presence + */ + public void updateInfo(Presence presence) { + Object version = presence.getProperty(VERSION_KEY); + if (version != null) { + this.collaborationVersion = version.toString(); + } + this.lastType = presence.getType(); + this.lastMode = presence.getMode(); + } + + /** + * @return true if this resource supports shared displays + */ + public boolean supportsSharedDisplays() { + return this.collaborationVersion != null; + } + + /** + * @return the resourceName + */ + public String getResourceName() { + return resourceName; + } + + /** + * @return the collaborationVersion + */ + public String getCollaborationVersion() { + return collaborationVersion; + } + + /** + * @param collaborationVersion + * the collaborationVersion to set + */ + public void setCollaborationVersion(String collaborationVersion) { + this.collaborationVersion = collaborationVersion; + } + + /** + * @return the lastType + */ + public Type getLastType() { + return lastType; + } + + /** + * @param lastType + * the lastType to set + */ + public void setLastType(Type lastType) { + this.lastType = lastType; + } + + /** + * @return the lastMode + */ + public Mode getLastMode() { + return lastMode; + } + + /** + * @param lastMode + * the lastMode to set + */ + public void setLastMode(Mode lastMode) { + this.lastMode = lastMode; + } + +} diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/login/LoginDialog.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/login/LoginDialog.java index c699a541f6..aae926e197 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/login/LoginDialog.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/login/LoginDialog.java @@ -54,6 +54,7 @@ import com.raytheon.uf.viz.collaboration.comm.identity.info.SiteConfigInformatio import com.raytheon.uf.viz.collaboration.comm.provider.Tools; import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnectionData; +import com.raytheon.uf.viz.collaboration.comm.provider.user.ResourceInfo; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.collaboration.ui.CollaborationUtils; import com.raytheon.uf.viz.collaboration.ui.ConnectionSubscriber; @@ -77,6 +78,7 @@ import com.raytheon.uf.viz.collaboration.ui.prefs.CollabPrefConstants; * Apr 07, 2014 2785 mpduff Implemented change to CollaborationConnection * Apr 11, 2014 2903 bclement added success flag, moved login logic to static method * fixed populating server with previous, removed password from heap + * Apr 23, 2014 2822 bclement added version to initial presence * * * @@ -427,7 +429,8 @@ public class LoginDialog extends Dialog { Presence initialPresence = new Presence(Type.available, loginData.getMessage(), 0, mode); Tools.setProperties(initialPresence, loginData.getAttributes()); - + initialPresence.setProperty(ResourceInfo.VERSION_KEY, + CollaborationConnection.getCollaborationVersion()); collabConnection.getAccountManager().sendPresence(initialPresence); } catch (CollaborationException e) { From a608d3a7e91897ce3fc6c9c1a13cd96f131a6448 Mon Sep 17 00:00:00 2001 From: Ben Steffensmeier Date: Wed, 23 Apr 2014 15:42:16 -0500 Subject: [PATCH 087/188] Issue #2648 Update hprof info to match grid changes in 14.3 Former-commit-id: c391a6fbb543e467030f45a494e00bc4246c6a36 --- .../uf/viz/hprof/D2DGridResourceExporter.java | 45 +++++++++++++++---- 1 file changed, 37 insertions(+), 8 deletions(-) diff --git a/javaUtilities/com.raytheon.uf.viz.hprof/src/com/raytheon/uf/viz/hprof/D2DGridResourceExporter.java b/javaUtilities/com.raytheon.uf.viz.hprof/src/com/raytheon/uf/viz/hprof/D2DGridResourceExporter.java index 493bb6d28c..06a28e7f55 100644 --- a/javaUtilities/com.raytheon.uf.viz.hprof/src/com/raytheon/uf/viz/hprof/D2DGridResourceExporter.java +++ b/javaUtilities/com.raytheon.uf.viz.hprof/src/com/raytheon/uf/viz/hprof/D2DGridResourceExporter.java @@ -177,7 +177,6 @@ public class D2DGridResourceExporter extends RequestableResourceExporter { } catch (IllegalStateException e) { /* heap dump is from after 14.2 */ } - resource.getBoolean("reprojectedData"); int floats = entry.getValue(); int size = floats * 4 / 1024; String suffix = "KB"; @@ -216,9 +215,16 @@ public class D2DGridResourceExporter extends RequestableResourceExporter { SmartInstance gridGeometry = generalGridData.get("gridGeometry"); SmartInstance gridRange = gridGeometry.get("gridRange"); int[] index = gridRange.getIntArray("index"); - width = index[2] - index[0]; - height = index[3] - index[1]; - + if (index != null) { + /* GeneralGridEnvelope */ + this.width = index[2] - index[0]; + this.height = index[3] - index[1]; + } else { + /* GridEnvelope2D */ + this.width = gridRange.getInt("width"); + this.height = gridRange.getInt("height"); + } + SmartInstance buffer = generalGridData.get("scalarData"); scalarCapacity = getCapacity(buffer); @@ -237,11 +243,34 @@ public class D2DGridResourceExporter extends RequestableResourceExporter { if (buffer == null) { return 0; } - try { - return buffer.getInt("capacity"); - } catch (IllegalStateException e) { - return buffer.get("buffer").getInt("capacity"); + while (buffer != null) { + try { + /* + * Eventually we hope to find a FloatBuffer, before 14.3 it + * even happens on the first try. + */ + return buffer.getInt("capacity"); + } catch (IllegalStateException e1) { + /* + * This case will pull the buffer out of a + * FloatBufferWrapper + */ + + SmartInstance tmp = buffer.get("buffer"); + if (tmp == null) { + /* + * This case will pull a source out of a + * GeographicDataSource or a FilteredDataSource, + * hopefully after recursing enough we will get to a + * FloatBufferWrapper. + */ + tmp = buffer.get("wrappedSource"); + } + buffer = tmp; + } } + System.err.println("Unable to count floats in GeneralGridData."); + return 0; } public int getFloatCount() { From c74786c35cea09c1e52833e018f297027dc1b8f9 Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Wed, 23 Apr 2014 16:01:40 -0500 Subject: [PATCH 088/188] Issue #2928: Update DD WebContainer to allow loading properties from environment Change-Id: I1eb31303dd87f3235c78618a7f31778f8f4d6081 Former-commit-id: 119282c58744addb3fd1a5c4a1a165f98d6437a8 --- .../web/webServiceBeans.xml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/web/webServiceBeans.xml b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/web/webServiceBeans.xml index d5d7010ca0..3d2d89fd56 100644 --- a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/web/webServiceBeans.xml +++ b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/web/webServiceBeans.xml @@ -1,12 +1,17 @@ + http://cxf.apache.org/schemas/jaxrs.xsd + http://www.springframework.org/schema/context + http://www.springframework.org/schema/context/spring-context-2.5.xsd"> + + From 221a06e467f34443798cf8126f69c27ec860890d Mon Sep 17 00:00:00 2001 From: Ron Anderson Date: Wed, 23 Apr 2014 14:43:05 -0500 Subject: [PATCH 089/188] Issue #3006 Fixed GetPointDataHandler to handle grids longer than 1 hour. Fixed Wx parsing for AvnFPS Change-Id: I34286a7cc46f6116aaa4026d22fd41223cc16f73 Former-commit-id: e636563052042d2dbfab6a4e476b71004b28c165 --- .../viz/aviation/guidance/GuidanceUtil.java | 9 + cave/com.raytheon.viz.avnconfig/.project | 6 + cave/com.raytheon.viz.avnconfig/.pydevproject | 5 + .../localization/aviation/python/GfeValues.py | 31 +- .../localization/aviation/python/GridData.py | 35 +-- .../server/handler/GetPointDataHandler.java | 294 ++++++++++-------- .../gfe/point/GFEPointDataContainer.java | 19 +- .../gfe/point/GFEPointDataContainers.java | 14 +- .../gfe/point/GFEPointDataView.java | 20 +- 9 files changed, 268 insertions(+), 165 deletions(-) create mode 100644 cave/com.raytheon.viz.avnconfig/.pydevproject diff --git a/cave/com.raytheon.viz.aviation/src/com/raytheon/viz/aviation/guidance/GuidanceUtil.java b/cave/com.raytheon.viz.aviation/src/com/raytheon/viz/aviation/guidance/GuidanceUtil.java index 05a27b97bc..bd3fa12435 100644 --- a/cave/com.raytheon.viz.aviation/src/com/raytheon/viz/aviation/guidance/GuidanceUtil.java +++ b/cave/com.raytheon.viz.aviation/src/com/raytheon/viz/aviation/guidance/GuidanceUtil.java @@ -22,6 +22,8 @@ package com.raytheon.viz.aviation.guidance; import com.raytheon.uf.common.dataplugin.gfe.point.GFEPointDataContainers; import com.raytheon.uf.common.dataplugin.gfe.request.GetPointDataRequest; import com.raytheon.uf.common.dataplugin.gfe.server.message.ServerResponse; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.viz.core.VizApp; import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.uf.viz.core.requests.ThriftClient; @@ -37,6 +39,7 @@ import com.raytheon.uf.viz.core.requests.ThriftClient; * Jul 29, 2009 njensen Initial creation * Mar 11, 2013 1735 rferrel Get a list of GFE Point Data Containers * Sep 11, 2013 2277 mschenke Got rid of ScriptCreator references + * Apr 23, 2014 3006 randerso Added error logging * * * @@ -45,6 +48,8 @@ import com.raytheon.uf.viz.core.requests.ThriftClient; */ public class GuidanceUtil { + private static final transient IUFStatusHandler statusHandler = UFStatus + .getHandler(GuidanceUtil.class); /** * Get a list of GFE Point Data information for the task request. @@ -59,6 +64,10 @@ public class GuidanceUtil { task.setWorkstationID(VizApp.getWsId()); ServerResponse sr = (ServerResponse) ThriftClient .sendRequest(task); + if (!sr.isOkay()) { + // some kind of error occurred on the server side + statusHandler.error(sr.message()); + } return sr.getPayload(); } diff --git a/cave/com.raytheon.viz.avnconfig/.project b/cave/com.raytheon.viz.avnconfig/.project index 3bf0c421ac..854ed8d30c 100644 --- a/cave/com.raytheon.viz.avnconfig/.project +++ b/cave/com.raytheon.viz.avnconfig/.project @@ -5,6 +5,11 @@ + + org.python.pydev.PyDevBuilder + + + org.eclipse.jdt.core.javabuilder @@ -24,5 +29,6 @@ org.eclipse.pde.PluginNature org.eclipse.jdt.core.javanature + org.python.pydev.pythonNature diff --git a/cave/com.raytheon.viz.avnconfig/.pydevproject b/cave/com.raytheon.viz.avnconfig/.pydevproject new file mode 100644 index 0000000000..40e9f40a0a --- /dev/null +++ b/cave/com.raytheon.viz.avnconfig/.pydevproject @@ -0,0 +1,5 @@ + + +Default +python 2.7 + diff --git a/cave/com.raytheon.viz.avnconfig/localization/aviation/python/GfeValues.py b/cave/com.raytheon.viz.avnconfig/localization/aviation/python/GfeValues.py index 1debdf7bf1..e086c7423d 100644 --- a/cave/com.raytheon.viz.avnconfig/localization/aviation/python/GfeValues.py +++ b/cave/com.raytheon.viz.avnconfig/localization/aviation/python/GfeValues.py @@ -28,8 +28,8 @@ # # Date Ticket# Engineer Description # ------------ ---------- ----------- -------------------------- -# 08/12/09 njensen Initial Creation. -# +# 08/12/09 njensen Initial Creation. +# 04/23/2-14 #3006 randerso Fix Wx parsing # # @@ -99,7 +99,7 @@ def wxVal(value, index): return value skip = index - count = 0 + count = 1 for subkey in wxStats: if subkey.wxType() not in ['','T'] + _vsbyCodes: if count == skip: @@ -120,7 +120,7 @@ def wxValInst(value, index): return value skip = index - count = 0 + count = 1 for subkey in wxStats: if subkey.wxType() not in ['','T'] + _vsbyCodes: if count == skip: @@ -141,7 +141,7 @@ def wxValCov(value, index): return value skip = index - count = 0 + count = 1 for subkey in wxStats: if subkey.wxType() not in ['','T'] + _vsbyCodes: if count == skip: @@ -149,7 +149,6 @@ def wxValCov(value, index): break else: count = count + 1 - return value def wxTstm(value): @@ -179,7 +178,7 @@ def wxTstmInt(value): for subkey in wxStats: if subkey.wxType() == 'T': - value = self._translateCode.get(subkey.intensity(), 'm' ) + value = _translateCode.get(subkey.intensity(), 'm' ) break return value @@ -188,10 +187,13 @@ def wxTstmInt(value): class FakeWxKey: def __init__(self, value): - split = value.split(',') + split = value.split('^') self.subkeys = [] for s in split: - self.subkeys.append(FakeWxSubkey(s)) + self.subkeys.append(FakeWxSubkey(s)) + + def __str__(self): + return "^".join([str(subkey) for subkey in self.subkeys]) def __getitem__(self, key): return self.subkeys[key] @@ -207,10 +209,13 @@ class FakeWxSubkey: def __init__(self, value): split = value.split(':') - self.cov = value[0] - self.type = value[1] - self.inten = value[2] - self.vis = value[3] + self.cov = split[0] + self.type = split[1] + self.inten = split[2] + self.vis = split[3] + + def __str__(self): + return ":".join([self.cov, self.type, self.inten, self.vis]) def wxType(self): return self.type diff --git a/cave/com.raytheon.viz.avnconfig/localization/aviation/python/GridData.py b/cave/com.raytheon.viz.avnconfig/localization/aviation/python/GridData.py index 0480d8dded..2a0516faba 100644 --- a/cave/com.raytheon.viz.avnconfig/localization/aviation/python/GridData.py +++ b/cave/com.raytheon.viz.avnconfig/localization/aviation/python/GridData.py @@ -141,15 +141,14 @@ # Status: TEST # Title: AvnFPS: Lack of customization in QC check # -#** -#* -#* -#*
-#* SOFTWARE HISTORY
-#* Date         Ticket#     Engineer    Description
-#* ------------ ----------  ----------- --------------------------
-#*                                      Initial creation.
-#* Mar 07, 2013 1735        rferrel     Changes to obtain grid data for a list of sites.
+# 
+# SOFTWARE HISTORY
+# Date         Ticket#     Engineer    Description
+# ------------ ----------  ----------- --------------------------
+#                                      Initial creation.
+# Mar 07, 2013 1735        rferrel     Changes to obtain grid data for a list of sites.
+# Apr 23, 2014 3006        randerso    Fix Wx parsing, handling of missing pdcs
+#
 ##  
 #
 import logging, os, time, ConfigParser
@@ -313,7 +312,7 @@ def _getData(pdc, firstTime):
             organizedData[fcstHr] = pdv
         for n in range(_NumHours):
             dd = {'time': 3600.0*n+(firstTime / 1000)}
-            dd = _createRecord(dd, organizedData[n])        
+            dd = _createRecord(dd, organizedData[n])
             data.append(dd)
     else :
     	return None
@@ -344,11 +343,11 @@ def _createRecord(dd, pdv):
         elif k == 'Tint':
             v = _stripmsng(GfeValues.wxTstmInt(arg))
         elif k[:4] == 'Prob':
-            v = _stripmsng(GfeValues.wxValCov(arg, k[4]))                                                     
+            v = _stripmsng(GfeValues.wxValCov(arg, int(k[4])))
         elif k[:4] == 'PTyp':
-            v = _wxcode(GfeValues.wxVal(arg, k[4]))
+            v = _wxcode(GfeValues.wxVal(arg, int(k[4])))
         elif k[:4] == 'Ints':
-            v = _intcode(GfeValues.wxValInst(arg, k[4]))
+            v = _intcode(GfeValues.wxValInst(arg, int(k[4])))
         else:
             v = _stripmsng(arg)
         dd[k] = v
@@ -545,12 +544,12 @@ def _retrieveMapData(siteIDs, timeSeconds, parameters=Parameters):
             results[siteID] = None
         return results
     
-    i = 0
-    for siteID in siteIDs:
-        pdc = pdcs.getContainer(i)
+    for i, siteID in enumerate(siteIDs):
+        data = None
         if i < pdcs.getSize() :
-            ++i
-        data = _getData(pdc, timeSeconds * 1000)
+            pdc = pdcs.getContainer(i)
+            data = _getData(pdc, timeSeconds * 1000)
+            
         if data is None:
             _Logger.info('Data not available for %s', siteID)
         results[siteID] = data
diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/server/handler/GetPointDataHandler.java b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/server/handler/GetPointDataHandler.java
index 96e2c1653f..149fda355f 100644
--- a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/server/handler/GetPointDataHandler.java
+++ b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/server/handler/GetPointDataHandler.java
@@ -21,22 +21,21 @@ package com.raytheon.edex.plugin.gfe.server.handler;
 
 import java.awt.Point;
 import java.util.ArrayList;
+import java.util.Date;
 import java.util.HashMap;
+import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
+import java.util.TreeMap;
 
 import javax.measure.unit.NonSI;
 import javax.measure.unit.SI;
 import javax.measure.unit.Unit;
 
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.geotools.coverage.grid.GridGeometry2D;
-
-import com.raytheon.edex.plugin.gfe.config.IFPServerConfigManager;
-import com.raytheon.edex.plugin.gfe.exception.GfeConfigurationException;
+import com.raytheon.edex.plugin.gfe.server.IFPServer;
+import com.raytheon.edex.plugin.gfe.server.database.GridDatabase;
 import com.raytheon.uf.common.dataplugin.gfe.db.objects.DatabaseID;
-import com.raytheon.uf.common.dataplugin.gfe.db.objects.GFERecord;
+import com.raytheon.uf.common.dataplugin.gfe.db.objects.GFERecord.GridType;
 import com.raytheon.uf.common.dataplugin.gfe.db.objects.GridLocation;
 import com.raytheon.uf.common.dataplugin.gfe.db.objects.ParmID;
 import com.raytheon.uf.common.dataplugin.gfe.point.GFEPointDataContainer;
@@ -44,15 +43,15 @@ import com.raytheon.uf.common.dataplugin.gfe.point.GFEPointDataContainers;
 import com.raytheon.uf.common.dataplugin.gfe.point.GFEPointDataView;
 import com.raytheon.uf.common.dataplugin.gfe.request.GetPointDataRequest;
 import com.raytheon.uf.common.dataplugin.gfe.server.message.ServerResponse;
-import com.raytheon.uf.common.dataplugin.gfe.server.request.GetGridRequest;
 import com.raytheon.uf.common.dataplugin.gfe.slice.DiscreteGridSlice;
 import com.raytheon.uf.common.dataplugin.gfe.slice.IGridSlice;
 import com.raytheon.uf.common.dataplugin.gfe.slice.ScalarGridSlice;
 import com.raytheon.uf.common.dataplugin.gfe.slice.VectorGridSlice;
-import com.raytheon.uf.common.geospatial.MapUtil;
-import com.raytheon.uf.common.geospatial.PointUtil;
+import com.raytheon.uf.common.dataplugin.gfe.slice.WeatherGridSlice;
 import com.raytheon.uf.common.pointdata.PointDataDescription.Type;
 import com.raytheon.uf.common.serialization.comm.IRequestHandler;
+import com.raytheon.uf.common.status.IUFStatusHandler;
+import com.raytheon.uf.common.status.UFStatus;
 import com.raytheon.uf.common.time.TimeRange;
 import com.raytheon.uf.common.time.util.TimeUtil;
 import com.vividsolutions.jts.geom.Coordinate;
@@ -70,6 +69,7 @@ import com.vividsolutions.jts.geom.Coordinate;
  *                                      in a single grid request.
  * Jun 13, 2013     #2044  randerso    Refactored to use IFPServer
  * Oct 31, 2013     #2508  randerso    Change to use DiscreteGridSlice.getKeys()
+ * Apr 23, 2014     #3006  randerso    Restructured code to work with multi-hour grids
  * 
  * 
* @@ -79,8 +79,8 @@ import com.vividsolutions.jts.geom.Coordinate; public class GetPointDataHandler extends BaseGfeRequestHandler implements IRequestHandler { - - protected final transient Log logger = LogFactory.getLog(getClass()); + private static final transient IUFStatusHandler statusHandler = UFStatus + .getHandler(GetPointDataHandler.class); /* * (non-Javadoc) @@ -89,143 +89,156 @@ public class GetPointDataHandler extends BaseGfeRequestHandler implements * com.raytheon.uf.common.serialization.comm.IRequestHandler#handleRequest * (com.raytheon.uf.common.serialization.comm.IServerRequest) */ - @SuppressWarnings("unchecked") @Override - public ServerResponse handleRequest(GetPointDataRequest request) - throws Exception { + public ServerResponse handleRequest( + GetPointDataRequest request) throws Exception { + ServerResponse resp = new ServerResponse(); + + IFPServer ifpServer = getIfpServer(request); + DatabaseID dbID = new DatabaseID(request.getDatabaseID()); + GridDatabase db = ifpServer.getGridParmMgr().getDatabase(dbID); + GridLocation loc = ifpServer.getConfig().dbDomain(); + List parameters = request.getParameters(); - - DatabaseID db = new DatabaseID(request.getDatabaseID()); List parmIds = new ArrayList(parameters.size()); - GridLocation loc = null; - - try { - loc = IFPServerConfigManager.getServerConfig(db.getSiteId()) - .dbDomain(); - } catch (GfeConfigurationException e) { - String msg = "Error getting grid location for site " - + db.getSiteId(); - logger.error(msg, e); - ServerResponse error = new ServerResponse(); - error.addMessage(msg); - return error; - } - - GridGeometry2D geom = MapUtil.getGridGeometry(loc); - for (String p : parameters) { - parmIds.add(new ParmID(p, db)); + parmIds.add(new ParmID(p, dbID)); } - List times = new ArrayList(); - for (int i = 0; i < request.getNumberHours(); i++) { - long iStartTime = request.getStartTime() - + (i * TimeUtil.MILLIS_PER_HOUR); - long iEndTime = iStartTime + TimeUtil.MILLIS_PER_HOUR; - TimeRange tr = new TimeRange(iStartTime, iEndTime); - times.add(tr); - } + int numHours = request.getNumberHours(); + long startTime = request.getStartTime(); + TimeRange overallTr = new TimeRange(new Date(startTime), numHours + * TimeUtil.MILLIS_PER_HOUR); List coordinates = request.getCoordinates(); - ServerResponse resp = null; - resp = new ServerResponse(); Map infoMap = new HashMap(); - boolean getSlices = false; - // See if any of the coordinates need the grid slices and set up info // map. for (Coordinate coordinate : coordinates) { - CoordinateInfo info = new CoordinateInfo(); + CoordinateInfo info = new CoordinateInfo(numHours, coordinate, loc); infoMap.put(coordinate, info); - info.container = new GFEPointDataContainer(); - Point index = PointUtil.determineIndex(coordinate, loc.getCrs(), - geom); - info.x = index.x; - info.y = index.y; - info.containsCoord = !((info.x < 0) || (info.x >= loc.getNx()) - || (info.y < 0) || (info.y >= loc.getNy())); - - if (!getSlices) { - getSlices = info.containsCoord; + if (!info.containsCoord) { + // coordinate is outside this GFE domain + resp.addMessage(coordinate + " is outside the " + + request.getSiteID() + + " GFE domain, no data will be returned."); } } - - for (TimeRange tr : times) { - List reqList = new ArrayList(); - for (ParmID p : parmIds) { - GetGridRequest req = new GetGridRequest(); - req.setParmId(p); - List reqRecList = new ArrayList( - times.size()); - GFERecord rec = new GFERecord(p, tr); - reqRecList.add(rec); - req.setRecords(reqRecList); - reqList.add(req); + for (ParmID parmId : parmIds) { + ServerResponse> invSr = db.getGridInventory(parmId, + overallTr); + if (!invSr.isOkay()) { + String msg = "Error retrieving inventory for " + parmId + "\n" + + invSr.message(); + statusHandler.error(msg); + resp.addMessage(msg); + continue; } - try { - ServerResponse> sr = null; - if (getSlices) { - sr = getIfpServer(request).getGridParmMgr().getGridData( - reqList); - } + String param = parmId.getParmName(); - for (Coordinate coordinate : coordinates) { - CoordinateInfo info = infoMap.get(coordinate); - boolean containsCoord = info.containsCoord; - GFEPointDataContainer container = info.container; - GFEPointDataView view = new GFEPointDataView(); - int x = info.x; - int y = info.y; + List inv = invSr.getPayload(); + ServerResponse> slicesSR = db.getGridData(parmId, + inv); + if (!slicesSR.isOkay()) { + String msg = "Error retrieving data for " + parmId + "\n" + + slicesSR.message(); + statusHandler.error(msg); + resp.addMessage(msg); + continue; + } + List slices = slicesSR.getPayload(); + Iterator sliceIter = slices.iterator(); + IGridSlice slice = null; + for (int i = 0; i < numHours; i++) { + Date time = new Date(startTime + (i * TimeUtil.MILLIS_PER_HOUR)); + try { + for (Coordinate coordinate : coordinates) { + CoordinateInfo info = infoMap.get(coordinate); + boolean containsCoord = info.containsCoord; + GFEPointDataView view = info.getView(time); + int x = info.x; + int y = info.y; - view.setData("time", Type.LONG, SI.MILLI(SI.SECOND), tr - .getStart().getTime()); - view.setData("lat", Type.FLOAT, null, coordinate.y); - view.setData("lon", Type.FLOAT, null, coordinate.x); + // initially set all requested params to missing + view.setData(parmId.getParmName(), Type.FLOAT, + Unit.ONE, 999.0f); - // initially set all requested params to missing - for (String param : parameters) { - view.setData(param, Type.FLOAT, Unit.ONE, 999.0f); - } + if (containsCoord) { - if (containsCoord) { + // find the slice that contains the current time + if ((slice == null) && sliceIter.hasNext()) { + slice = sliceIter.next(); + } + if ((slice != null) + && (time.getTime() >= slice.getValidTime() + .getEnd().getTime()) + && sliceIter.hasNext()) { + slice = sliceIter.next(); + } + if ((slice != null) + && slice.getValidTime().contains(time)) { + Unit unit = slice.getGridInfo() + .getUnitObject(); - // set the retrieved data - for (IGridSlice slice : sr.getPayload()) { - String param = slice.getGridInfo().getParmID() - .getParmName(); - Unit unit = slice.getGridInfo().getUnitObject(); - if (slice instanceof VectorGridSlice) { - VectorGridSlice gs = (VectorGridSlice) slice; - Type type = Type.FLOAT; - view.setData(param + "Dir", type, - NonSI.DEGREE_ANGLE, gs.getDirGrid() - .get(x, y)); - view.setData(param + "Spd", type, unit, gs - .getMagGrid().get(x, y)); - } else if (slice instanceof ScalarGridSlice) { - ScalarGridSlice gs = (ScalarGridSlice) slice; - float val = gs.getScalarGrid().get(x, y); - Type type = Type.FLOAT; - view.setData(param, type, unit, val); - } else if (slice instanceof DiscreteGridSlice) { - DiscreteGridSlice gs = (DiscreteGridSlice) slice; - byte value = gs.getDiscreteGrid().get(x, y); - String key = gs.getKeys()[value].toString(); - Type type = Type.STRING; - view.setData(param, type, unit, key); + Type type; + GridType gridType = slice.getGridInfo() + .getGridType(); + switch (gridType) { + case VECTOR: + VectorGridSlice vectorSlice = (VectorGridSlice) slice; + type = Type.FLOAT; + view.setData(param + "Dir", type, + NonSI.DEGREE_ANGLE, vectorSlice + .getDirGrid().get(x, y)); + view.setData(param + "Spd", type, unit, + vectorSlice.getMagGrid().get(x, y)); + break; + case SCALAR: + ScalarGridSlice scalarSlice = (ScalarGridSlice) slice; + float val = scalarSlice.getScalarGrid() + .get(x, y); + type = Type.FLOAT; + view.setData(param, type, unit, val); + break; + case DISCRETE: + DiscreteGridSlice discreteSlice = (DiscreteGridSlice) slice; + byte discreteValue = discreteSlice + .getDiscreteGrid().get(x, y); + String discreteKey = discreteSlice + .getKeys()[discreteValue] + .toString(); + type = Type.STRING; + view.setData(param, type, unit, discreteKey); + break; + case WEATHER: + WeatherGridSlice weatherSlice = (WeatherGridSlice) slice; + byte wxValue = weatherSlice + .getWeatherGrid().get(x, y); + String wxKey = weatherSlice.getKeys()[wxValue] + .toString(); + type = Type.STRING; + view.setData(param, type, unit, wxKey); + break; + + default: + String msg = "Unknown gridType: " + + gridType + " for " + parmId + + ", data will be ignored."; + statusHandler.error(msg); + resp.addMessage(msg); + break; + } } } } - container.append(view); + } catch (Exception e) { + resp.addMessage(e.getMessage()); } - } catch (Exception e) { - resp.addMessage(e.getMessage()); } - } GFEPointDataContainers gfeContainers = new GFEPointDataContainers(); @@ -235,11 +248,17 @@ public class GetPointDataHandler extends BaseGfeRequestHandler implements // Keep the results list in the same order as the request's // coordinate list. for (Coordinate coordinate : coordinates) { - containers.add(infoMap.get(coordinate).container); + CoordinateInfo info = infoMap.get(coordinate); + + List views = new ArrayList( + info.viewMap.values()); + + GFEPointDataContainer container = new GFEPointDataContainer(); + container.setViews(views); + containers.add(container); } gfeContainers.setContainers(containers); - ((ServerResponse) resp) - .setPayload(gfeContainers); + resp.setPayload(gfeContainers); return resp; } @@ -247,12 +266,41 @@ public class GetPointDataHandler extends BaseGfeRequestHandler implements * Information for a coordinate. */ private class CoordinateInfo { - GFEPointDataContainer container; + Map viewMap; boolean containsCoord; int x; int y; + + Coordinate coordinate; + + public CoordinateInfo(int numHours, Coordinate coordinate, + GridLocation gloc) { + viewMap = new TreeMap(); + this.coordinate = coordinate; + + Point gridCell = gloc.gridCoordinate(coordinate); + x = gridCell.x; + y = gridCell.y; + + containsCoord = !((x < 0) || (x >= gloc.getNx()) || (y < 0) || (y >= gloc + .getNy())); + } + + public GFEPointDataView getView(Date fcstHour) { + GFEPointDataView view = viewMap.get(fcstHour); + if (view == null) { + view = new GFEPointDataView(); + view.setData("time", Type.LONG, SI.MILLI(SI.SECOND), + fcstHour.getTime()); + view.setData("lat", Type.FLOAT, null, coordinate.y); + view.setData("lon", Type.FLOAT, null, coordinate.x); + viewMap.put(fcstHour, view); + } + + return view; + } } } diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/point/GFEPointDataContainer.java b/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/point/GFEPointDataContainer.java index a356a6e69c..cc410956a3 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/point/GFEPointDataContainer.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/point/GFEPointDataContainer.java @@ -26,19 +26,19 @@ import java.util.Set; import com.raytheon.uf.common.pointdata.IPointDataContainerReader; import com.raytheon.uf.common.pointdata.IPointDataViewReader; -import com.raytheon.uf.common.serialization.ISerializableObject; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; /** - * TODO Add Description + * GFE Point Data Container * *
  * 
  * SOFTWARE HISTORY
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
- * Aug 4, 2009            njensen     Initial creation
+ * Aug  4, 2009            njensen     Initial creation
+ * Apr 23, 2014  #3006     randerso    Added toString to aid in debugging
  * 
  * 
* @@ -47,8 +47,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; */ @DynamicSerialize -public class GFEPointDataContainer implements IPointDataContainerReader, - ISerializableObject { +public class GFEPointDataContainer implements IPointDataContainerReader { @DynamicSerializeElement private List views = new ArrayList(); @@ -104,4 +103,14 @@ public class GFEPointDataContainer implements IPointDataContainerReader, this.views = views; } + /* + * (non-Javadoc) + * + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + return views.toString(); + } + } diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/point/GFEPointDataContainers.java b/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/point/GFEPointDataContainers.java index 16344e4793..a53cd180fc 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/point/GFEPointDataContainers.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/point/GFEPointDataContainers.java @@ -33,7 +33,8 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; * * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Mar 6, 2013 1735 rferrel Initial creation + * Mar 6, 2013 1735 rferrel Initial creation + * Apr 23, 2014 #3006 randerso Added toString to aid in debugging * * * @@ -86,4 +87,15 @@ public class GFEPointDataContainers { public GFEPointDataContainer getContainer(int index) { return containers.get(index); } + + /* + * (non-Javadoc) + * + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + return containers.toString(); + } + } diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/point/GFEPointDataView.java b/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/point/GFEPointDataView.java index 95091655fd..4124d0154d 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/point/GFEPointDataView.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.gfe/src/com/raytheon/uf/common/dataplugin/gfe/point/GFEPointDataView.java @@ -31,12 +31,11 @@ import javax.persistence.Transient; import com.raytheon.uf.common.pointdata.IPointDataContainerReader; import com.raytheon.uf.common.pointdata.IPointDataViewReader; import com.raytheon.uf.common.pointdata.PointDataDescription.Type; -import com.raytheon.uf.common.serialization.ISerializableObject; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; /** - * TODO Add Description + * GFE Point Data View * *
  * 
@@ -44,6 +43,8 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
  * Aug 4, 2009            njensen     Initial creation
+ * Apr 23, 2014  #3006    randerso    Added toString to aid in debugging
+ *                                    Fixed conversion of Double to float
  * 
  * 
* @@ -52,8 +53,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; */ @DynamicSerialize -public class GFEPointDataView implements IPointDataViewReader, - ISerializableObject { +public class GFEPointDataView implements IPointDataViewReader { @DynamicSerializeElement private Map valueMap = new HashMap(); @@ -99,7 +99,7 @@ public class GFEPointDataView implements IPointDataViewReader, Type type = pd.getType(); Object obj = pd.getValue(); if (type == Type.FLOAT) { - return (Float) obj; + return ((Number) obj).floatValue(); } else if (type == Type.STRING) { return Float.valueOf((String) obj); } else { @@ -264,4 +264,14 @@ public class GFEPointDataView implements IPointDataViewReader, parent = container; } + /* + * (non-Javadoc) + * + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + return valueMap.toString(); + } + } From c19d52db72dda709101784c97daf28ceef096514 Mon Sep 17 00:00:00 2001 From: Ben Steffensmeier Date: Wed, 23 Apr 2014 17:13:49 -0500 Subject: [PATCH 090/188] Issue #2947 Fixes for derived products with multiple records per frame. Former-commit-id: f47911308acb9d0a90304233da304bdbd0d002e4 --- .../inventory/ComparableSatMapCoverage.java | 68 ++++++++++++++-- .../viz/satellite/rsc/SatResourceData.java | 77 ++++++++++++++----- 2 files changed, 117 insertions(+), 28 deletions(-) diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/ComparableSatMapCoverage.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/ComparableSatMapCoverage.java index 6a92d705dc..a05d276a67 100644 --- a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/ComparableSatMapCoverage.java +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/ComparableSatMapCoverage.java @@ -19,10 +19,11 @@ **/ package com.raytheon.viz.satellite.inventory; +import java.awt.geom.Rectangle2D; + import org.geotools.coverage.grid.GridEnvelope2D; import org.geotools.coverage.grid.GridGeometry2D; import org.geotools.geometry.Envelope2D; -import org.opengis.geometry.BoundingBox; import org.opengis.referencing.crs.CoordinateReferenceSystem; import com.raytheon.uf.common.dataplugin.satellite.SatMapCoverage; @@ -65,16 +66,46 @@ public class ComparableSatMapCoverage implements @Override public IGridGeometryProvider compare(IGridGeometryProvider other) { + if (other.equals(this)) { + return this; + } if (other instanceof ComparableSatMapCoverage) { ComparableSatMapCoverage otherCoverage = (ComparableSatMapCoverage) other; - if (otherCoverage.getCRS().equals(getCRS()) - && otherCoverage.getBoundingBox().intersects( - getBoundingBox())){ - if(getResolution() > otherCoverage.getResolution()){ + if (compatibleArea(otherCoverage)) { + if (getResolution() > otherCoverage.getResolution()) { return this; - }else{ + } else if (getResolution() < otherCoverage.getResolution()) { return other; } + /* Resolutions are the same */ + Envelope2D env = getEnvelope(); + Envelope2D otherEnv = otherCoverage.getEnvelope(); + if (area(env) < area(otherEnv)) { + return this; + } else if (area(env) > area(otherEnv)) { + return other; + } + /* Area is the same. */ + /* + * there is no meaningful way to pick one so start checking + * meaningless things. + */ + if (env.x < otherEnv.x) { + return this; + } else if (env.x > otherEnv.x) { + return other; + } + if (env.y < otherEnv.y) { + return this; + } else if (env.y > otherEnv.y) { + return other; + } + if (env.width < otherEnv.width) { + return this; + } else if (env.width > otherEnv.width) { + return other; + } + /* This is nuts, why aren't they equal, give up. */ } } return null; @@ -88,7 +119,24 @@ public class ComparableSatMapCoverage implements return coverage.getGridGeometry().getCoordinateReferenceSystem(); } - protected BoundingBox getBoundingBox() { + protected boolean compatibleArea(ComparableSatMapCoverage other) { + if (!other.getCRS().equals(getCRS())) { + return false; + } + Rectangle2D i = other.getEnvelope().createIntersection(getEnvelope()); + if (i == null || i.isEmpty()) { + return false; + } + /* Intersection must cover at least 25% of area. */ + double a = area(i) * 4; + if (a > area(getEnvelope()) || a > area(other.getEnvelope())) { + return true; + } else { + return false; + } + } + + protected Envelope2D getEnvelope() { return coverage.getGridGeometry().getEnvelope2D(); } @@ -100,7 +148,7 @@ public class ComparableSatMapCoverage implements GridGeometry2D gg = coverage.getGridGeometry(); Envelope2D e = gg.getEnvelope2D(); GridEnvelope2D r = gg.getGridRange2D(); - return (r.width * r.height) / (e.width * e.height); + return area(r) / area(e); } @Override @@ -129,4 +177,8 @@ public class ComparableSatMapCoverage implements return true; } + private static double area(Rectangle2D r) { + return r.getHeight() * r.getWidth(); + } + } diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResourceData.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResourceData.java index c86ba28899..39007c159d 100644 --- a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResourceData.java +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResourceData.java @@ -21,9 +21,12 @@ package com.raytheon.viz.satellite.rsc; import java.util.ArrayList; import java.util.Arrays; +import java.util.HashSet; +import java.util.Iterator; import java.util.List; import java.util.Map; import java.util.Map.Entry; +import java.util.Set; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; @@ -34,11 +37,14 @@ import com.raytheon.uf.common.dataquery.requests.RequestConstraint; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; +import com.raytheon.uf.common.time.DataTime; import com.raytheon.uf.viz.core.RecordFactory; import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.uf.viz.core.rsc.AbstractRequestableResourceData; import com.raytheon.uf.viz.core.rsc.AbstractVizResource; +import com.raytheon.uf.viz.core.rsc.IResourceDataChanged.ChangeType; import com.raytheon.uf.viz.core.rsc.LoadProperties; +import com.raytheon.viz.satellite.inventory.SatelliteDataCubeAdapter; /** * Resource data for satellite data @@ -46,10 +52,12 @@ import com.raytheon.uf.viz.core.rsc.LoadProperties; *
  * 
  * SOFTWARE HISTORY
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Feb 17, 2009            njensen     Initial creation
- * Feb 20, 2000	2032	   jsanchez	   Added @XmlAccessorType(XmlAccessType.NONE).
+ * Date          Ticket#  Engineer    Description
+ * ------------- -------- ----------- --------------------------
+ * Feb 17, 2009           njensen     Initial creation
+ * Feb 20, 2000	 2032	  jsanchez	  Added @XmlAccessorType(XmlAccessType.NONE).
+ * Apr 23, 2013  2947     bsteffen    Fix updates for derived products with
+ *                                    multiple records per frame.
  * 
  * 
* @@ -81,33 +89,42 @@ public class SatResourceData extends AbstractRequestableResourceData { return new SatResource(this, loadProperties); } + @Override public void update(Object updateData) { if (updateData instanceof PluginDataObject[]) { - // This is here because derived updates will send us records that we - // don't want, so filter them. + /* + * This is here because derived updates will send us records that we + * don't want, so filter them. + */ PluginDataObject[] pdos = (PluginDataObject[]) updateData; - List wrongPDOs = new ArrayList(); + Set invalidTimes = new HashSet(); for (PluginDataObject pdo : (PluginDataObject[]) updateData) { try { Map pdoMap = RecordFactory.getInstance() .loadMapFromUri(pdo.getDataURI()); for (Entry entry : metadataMap .entrySet()) { - if (entry.getKey().equals("DERIVED")) { + if (entry.getKey().equals( + SatelliteDataCubeAdapter.DERIVED)) { continue; } Object pdoItem = pdoMap.get(entry.getKey()); RequestConstraint rc = entry.getValue(); - // Record Factor automatically replaces space with - // underscore, but some derived parameters have - // underscore in them + /* + * Record Factory automatically replaces space with + * underscore, but some derived parameters have + * underscore in them + */ String pdoItemStr = pdoItem.toString() .replace(" ", "_"); - if (pdoItem == null - || !(rc.evaluate(pdoItem) || rc + if (!(rc.evaluate(pdoItem) || rc .evaluate(pdoItemStr))) { - wrongPDOs.add(pdo); + DataTime time = pdo.getDataTime(); + if (binOffset != null) { + time = binOffset.getNormalizedTime(time); + } + invalidTimes.add(time); break; } } @@ -116,15 +133,35 @@ public class SatResourceData extends AbstractRequestableResourceData { e.getLocalizedMessage(), e); } } - if (wrongPDOs.size() == pdos.length) { - invalidateAvailableTimesCache(); - return; - } else if (!wrongPDOs.isEmpty()) { + if (!invalidTimes.isEmpty()) { + /* Next time query should requery */ invalidateAvailableTimesCache(); + /* Remove times from resources where three is new derived data. */ + for (DataTime time : invalidTimes) { + fireChangeListeners(ChangeType.DATA_REMOVE, time); + } + /* + * Don't send updates for PDO's with invalidTimes, the time + * matcher will pull in all the records including derived + * records. + */ List pdoList = new ArrayList( Arrays.asList(pdos)); - pdoList.removeAll(wrongPDOs); - updateData = pdoList.toArray(new PluginDataObject[0]); + Iterator it = pdoList.iterator(); + while (it.hasNext()) { + DataTime t = it.next().getDataTime(); + if (binOffset != null) { + t = binOffset.getNormalizedTime(t); + } + if (invalidTimes.contains(t)) { + it.remove(); + } + } + if (pdoList.isEmpty()) { + return; + } else { + updateData = pdoList.toArray(new PluginDataObject[0]); + } } } super.update(updateData); From 27d5639b5882dd3a337968d96fa38fa32ed30ee1 Mon Sep 17 00:00:00 2001 From: Ron Anderson Date: Wed, 23 Apr 2014 17:24:41 -0500 Subject: [PATCH 091/188] Issue #2971 Fix regex in warning.xml Change-Id: I74998354d07596551763a0453973ea4a6ea6f806 Former-commit-id: 60c4d87b387b3902fb0feacbf48807490b17e90c --- .../utility/edex_static/base/distribution/warning.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/edexOsgi/com.raytheon.edex.plugin.warning/utility/edex_static/base/distribution/warning.xml b/edexOsgi/com.raytheon.edex.plugin.warning/utility/edex_static/base/distribution/warning.xml index d874dc71b2..1361d3ae98 100644 --- a/edexOsgi/com.raytheon.edex.plugin.warning/utility/edex_static/base/distribution/warning.xml +++ b/edexOsgi/com.raytheon.edex.plugin.warning/utility/edex_static/base/distribution/warning.xml @@ -22,5 +22,5 @@ ^(W[FGHOTUW]|FZ)[ACHKMPU][AHKQSWY].* ^(WT)(NT|PZ)\d{2} KNHC.* ^(WTP)A\d{2} PHFO.* - ^NWUS([13-9]\\d|2[1-9]) KWNS.* + ^NWUS([13-9]\d|2[1-9]) KWNS.* From 07fec6a69c8c504914c61ed691bb98574036f987 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Wed, 23 Apr 2014 17:29:00 -0500 Subject: [PATCH 092/188] Issue #2623 remove ecf plugins from being included in cave Change-Id: I2a822440735cee1cc7ef9e556dff3c49ae976d18 Former-commit-id: 98e3e2137ecb9ce14f8dfd295791a79a897867a2 --- .../feature.xml | 28 ------------------- 1 file changed, 28 deletions(-) diff --git a/cave/com.raytheon.uf.viz.application.feature/feature.xml b/cave/com.raytheon.uf.viz.application.feature/feature.xml index 000113995f..4d17db91fa 100644 --- a/cave/com.raytheon.uf.viz.application.feature/feature.xml +++ b/cave/com.raytheon.uf.viz.application.feature/feature.xml @@ -70,34 +70,6 @@ version="0.0.0" unpack="false"/> - - - - - - - - Date: Wed, 23 Apr 2014 18:22:39 -0500 Subject: [PATCH 093/188] Issue #3040 - Fixed contact request and group name issues. Change-Id: I7a430d4a443bdbcf7951ca9b6047b5cbda88238e Former-commit-id: badc9fa46aebe7f7da25c3a115294a37b30aa507 --- .../collaboration/ui/CreateGroupDialog.java | 94 +++++++++--- .../collaboration/ui/SubRequestDialog.java | 137 ++++++++++++++---- 2 files changed, 184 insertions(+), 47 deletions(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateGroupDialog.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateGroupDialog.java index 2f9530cca8..9ce75a3055 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateGroupDialog.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/CreateGroupDialog.java @@ -25,11 +25,12 @@ import org.eclipse.swt.events.KeyEvent; import org.eclipse.swt.events.SelectionAdapter; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.layout.GridData; -import org.eclipse.swt.layout.RowData; -import org.eclipse.swt.layout.RowLayout; +import org.eclipse.swt.layout.GridLayout; import org.eclipse.swt.widgets.Button; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Label; +import org.eclipse.swt.widgets.Layout; +import org.eclipse.swt.widgets.MessageBox; import org.eclipse.swt.widgets.Shell; import org.eclipse.swt.widgets.Text; @@ -48,6 +49,7 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * ------------ ---------- ----------- -------------------------- * Jun 27, 2012 bsteffen Initial creation * Jan 24, 2014 2701 bclement removed local groups + * Apr 23, 2014 3040 lvenable Cleaned up dialog code/layout. Added check for group name. * * * @@ -56,72 +58,122 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; */ public class CreateGroupDialog extends CaveSWTDialog { + /** Name text field. */ private Text nameText; + /** New group name. */ private String newGroup = null; + /** + * Constructor. + * + * @param parentShell + * Parent shell. + */ public CreateGroupDialog(Shell parentShell) { super(parentShell, SWT.DIALOG_TRIM); setText("Create Group"); } + @Override + protected Layout constructShellLayout() { + GridLayout mainLayout = new GridLayout(1, false); + return mainLayout; + } + + @Override + protected Object constructShellLayoutData() { + return new GridData(SWT.FILL, SWT.DEFAULT, true, false); + } + @Override protected void initializeComponents(Shell shell) { Composite entryComp = new Composite(shell, SWT.NONE); - RowLayout layout = new RowLayout(SWT.HORIZONTAL); - layout.center = true; - entryComp.setLayout(layout); + entryComp.setLayout(new GridLayout(2, false)); + entryComp + .setLayoutData(new GridData(SWT.FILL, SWT.DEFAULT, true, false)); + new Label(entryComp, SWT.NONE).setText("Group Name: "); nameText = new Text(entryComp, SWT.BORDER); - nameText.setLayoutData(new RowData(100, SWT.DEFAULT)); + nameText.setLayoutData(new GridData(150, SWT.DEFAULT)); nameText.addKeyListener(new KeyAdapter() { - @Override public void keyReleased(KeyEvent e) { if (e.keyCode == SWT.CR || e.keyCode == SWT.KEYPAD_CR) { - finish(); + handleOkAction(); } } - }); + + /* + * Action buttons + */ Composite buttonComp = new Composite(shell, SWT.NONE); - buttonComp.setLayoutData(new GridData(SWT.RIGHT, SWT.NONE, false, - false, 1, 1)); - layout = new RowLayout(SWT.HORIZONTAL); - layout.pack = false; - buttonComp.setLayout(layout); + buttonComp.setLayout(new GridLayout(2, false)); + buttonComp.setLayoutData(new GridData(SWT.FILL, SWT.DEFAULT, true, + false)); + + GridData gd = new GridData(SWT.RIGHT, SWT.DEFAULT, true, false); + gd.widthHint = 75; Button okButton = new Button(buttonComp, SWT.PUSH); okButton.setText("OK"); + okButton.setLayoutData(gd); okButton.addSelectionListener(new SelectionAdapter() { - @Override public void widgetSelected(SelectionEvent e) { - finish(); + handleOkAction(); } - }); + gd = new GridData(SWT.LEFT, SWT.DEFAULT, true, false); + gd.widthHint = 75; Button cancelButton = new Button(buttonComp, SWT.PUSH); cancelButton.setText("Cancel"); + cancelButton.setLayoutData(gd); cancelButton.addSelectionListener(new SelectionAdapter() { - @Override public void widgetSelected(SelectionEvent e) { close(); } - }); } - private void finish() { + /** + * Handle the OK action. + */ + private void handleOkAction() { + if (validGroupName() == false) { + return; + } newGroup = nameText.getText(); CollaborationConnection.getConnection().getContactsManager() .createGroup(newGroup); close(); } + /** + * Check if there was something entered in the text field. + * + * @return True if there is text in the group name text field. + */ + private boolean validGroupName() { + if (nameText.getText().length() == 0) { + MessageBox mb = new MessageBox(shell, SWT.ICON_WARNING | SWT.OK); + mb.setText("Invalid Name"); + mb.setMessage("You have not entered a group name. Please enter one."); + mb.open(); + return false; + } + + return true; + } + + /** + * Get the group name. + * + * @return The group name. + */ public String getNewGroup() { return newGroup; } - } diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/SubRequestDialog.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/SubRequestDialog.java index 25a831a14a..2eacd1077e 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/SubRequestDialog.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/SubRequestDialog.java @@ -34,6 +34,7 @@ import org.eclipse.swt.widgets.Combo; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Display; import org.eclipse.swt.widgets.Label; +import org.eclipse.swt.widgets.Layout; import org.eclipse.swt.widgets.Shell; import org.jivesoftware.smack.RosterGroup; @@ -55,6 +56,9 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * Feb 13, 2014 2755 bclement roster addition now done in account manager, user input passed back * Apr 07, 2014 2785 mpduff Changed to implement CaveSWTDialog * Fix loading of groups + * Apr 23, 2014 3040 lvenable Cleaned up dialog code/layout. Allow the cancellation of the create + * group dialog without closing this dialog. Added capability to resize + * the group combo box if the names get too long. * * * @@ -62,12 +66,19 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * @version 1.0 */ public class SubRequestDialog extends CaveSWTDialog { - private final String NEW_GROUP = "New Group..."; + /** User ID. */ private final String userid; + /** Combo listing all of the available groups. */ private Combo groupCbo; + /** Create group dialog. */ + private CreateGroupDialog createGroupDlg; + + /** Allow button. */ + private Button allowBtn; + /** * Constructor * @@ -80,35 +91,70 @@ public class SubRequestDialog extends CaveSWTDialog { setText("Contact Request"); } + @Override + protected Layout constructShellLayout() { + GridLayout mainLayout = new GridLayout(1, false); + return mainLayout; + } + + @Override + protected Object constructShellLayoutData() { + return new GridData(SWT.FILL, SWT.DEFAULT, true, false); + } + @Override protected void initializeComponents(Shell shell) { - GridLayout gl = new GridLayout(1, false); - GridData gd = new GridData(SWT.FILL, SWT.FILL, true, true); Composite mainComp = new Composite(shell, SWT.NONE); + GridLayout gl = new GridLayout(1, false); + GridData gd = new GridData(SWT.FILL, SWT.DEFAULT, true, false); mainComp.setLayout(gl); mainComp.setLayoutData(gd); + /* + * Top Label + */ gd = new GridData(SWT.CENTER, SWT.DEFAULT, true, false); Label msgLbl = new Label(mainComp, SWT.NONE); - msgLbl.setText(userid + " wants to add you to their contacts list."); + msgLbl.setText(userid + " wants to add you to a contacts list:"); msgLbl.setLayoutData(gd); - gl = new GridLayout(2, false); - gd = new GridData(SWT.FILL, SWT.DEFAULT, true, false); + /* + * Group composite and controls. + */ Composite groupComp = new Composite(mainComp, SWT.NONE); + gl = new GridLayout(3, false); + gd = new GridData(SWT.FILL, SWT.DEFAULT, true, false); groupComp.setLayout(gl); groupComp.setLayoutData(gd); - gd = new GridData(SWT.RIGHT, SWT.DEFAULT, true, false); + gd = new GridData(SWT.DEFAULT, SWT.CENTER, false, true); Label groupLbl = new Label(groupComp, SWT.NONE); groupLbl.setText("Group: "); groupLbl.setLayoutData(gd); + + gd = new GridData(SWT.FILL, SWT.CENTER, true, true); + gd.minimumWidth = 130; groupCbo = new Combo(groupComp, SWT.DROP_DOWN | SWT.READ_ONLY); groupCbo.setItems(getGroupNames()); groupCbo.select(0); - groupCbo.setLayout(gl); groupCbo.setLayoutData(gd); + gd = new GridData(); + gd.horizontalIndent = 5; + Button newGroup = new Button(groupComp, SWT.PUSH); + newGroup.setText("New Group..."); + newGroup.addSelectionListener(new SelectionAdapter() { + @Override + public void widgetSelected(SelectionEvent e) { + handleNewGroupAction(); + } + }); + + addSeparator(mainComp); + + /* + * Action buttons. + */ gl = new GridLayout(2, false); gd = new GridData(SWT.CENTER, SWT.DEFAULT, true, false); Composite btnComp = new Composite(mainComp, SWT.NONE); @@ -118,16 +164,21 @@ public class SubRequestDialog extends CaveSWTDialog { int btnWidth = 75; gd = new GridData(btnWidth, SWT.DEFAULT); - Button allowBtn = new Button(btnComp, SWT.PUSH); + allowBtn = new Button(btnComp, SWT.PUSH); allowBtn.setText("Allow"); allowBtn.setLayoutData(gd); allowBtn.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent event) { - action(true); + handleAllowDenyAction(true); } }); + // Disable the allow button if there are no items in the combo box. + if (groupCbo.getItemCount() == 0) { + allowBtn.setEnabled(false); + } + gd = new GridData(btnWidth, SWT.DEFAULT); Button denyBtn = new Button(btnComp, SWT.PUSH); denyBtn.setText("Deny"); @@ -135,12 +186,14 @@ public class SubRequestDialog extends CaveSWTDialog { denyBtn.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent event) { - action(false); + handleAllowDenyAction(false); } }); } /** + * Get the list of group names. + * * @return list of existing group names */ private String[] getGroupNames() { @@ -157,28 +210,45 @@ public class SubRequestDialog extends CaveSWTDialog { } Collections.sort(groupList); - groupList.add(0, NEW_GROUP); return groupList.toArray(new String[groupList.size()]); } /** - * Action handler. - * - * @param approved - * true if request approved, false if denied + * Handle adding a new group. */ - private void action(boolean approved) { - if (approved) { - if (groupCbo.getSelectionIndex() == 0) { - // new group - CreateGroupDialog dialog = new CreateGroupDialog(Display - .getCurrent().getActiveShell()); - dialog.open(); - String group = dialog.getNewGroup(); - setReturnValue(group); - } else { + private void handleNewGroupAction() { + if (createGroupDlg == null || createGroupDlg.isDisposed()) { + createGroupDlg = new CreateGroupDialog(Display.getCurrent() + .getActiveShell()); + createGroupDlg.open(); + String groupName = createGroupDlg.getNewGroup(); + + // If the group name is not null, add it to the combo and then + // select it. + if (groupName != null) { + allowBtn.setEnabled(true); + groupCbo.add(groupName, 0); + groupCbo.select(0); + shell.pack(); + } + } else { + createGroupDlg.bringToTop(); + } + } + + /** + * Handle Allow/Deny action. + * + * @param allowRequest + * True if request allowed, false if denied + */ + private void handleAllowDenyAction(boolean allowRequest) { + if (allowRequest) { + if (groupCbo.getItemCount() != 0) { setReturnValue(groupCbo.getItem(groupCbo.getSelectionIndex())); + } else { + } } else { setReturnValue(null); @@ -186,4 +256,19 @@ public class SubRequestDialog extends CaveSWTDialog { close(); } + + /** + * Add a line separator to the given composite. + * + * @param parentComp + * Parent composite. + */ + private void addSeparator(Composite parentComp) { + GridLayout gl = (GridLayout) parentComp.getLayout(); + + GridData gd = new GridData(SWT.FILL, SWT.DEFAULT, true, false); + gd.horizontalSpan = gl.numColumns; + Label sepLbl = new Label(parentComp, SWT.SEPARATOR | SWT.HORIZONTAL); + sepLbl.setLayoutData(gd); + } } From f888819646a32a1b9bdfaa092c75da35326c8d12 Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Thu, 24 Apr 2014 09:25:54 -0500 Subject: [PATCH 094/188] Issue #2955 ignore duplicate session invites Former-commit-id: a48b12b8aaeea250680c0726f72425eac170ecd7 --- .../ui/ConnectionSubscriber.java | 51 +++++++++++++++++-- 1 file changed, 47 insertions(+), 4 deletions(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/ConnectionSubscriber.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/ConnectionSubscriber.java index 6c753aa145..3b61143917 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/ConnectionSubscriber.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/ConnectionSubscriber.java @@ -19,6 +19,9 @@ **/ package com.raytheon.uf.viz.collaboration.ui; +import java.util.HashSet; +import java.util.Set; + import org.eclipse.core.runtime.jobs.Job; import org.eclipse.swt.widgets.Display; import org.eclipse.swt.widgets.Shell; @@ -71,6 +74,7 @@ import com.raytheon.viz.ui.views.CaveWorkbenchPageManager; * Mar 06, 2014 2848 bclement moved SharedDisplaySessionMgr.joinSession call to InviteDialog * Apr 08, 2014 2785 mpduff removed preference listener * Apr 11, 2014 2903 bclement added disconnect handler + * Apr 24, 2014 2955 bclement ignore duplicate session invites * * * @@ -91,6 +95,8 @@ public class ConnectionSubscriber { private final DisconnectHandler disconnect = new DisconnectHandler(); + private final Set pendingInviteDialogs = new HashSet(); + private ConnectionSubscriber() { } @@ -178,16 +184,53 @@ public class ConnectionSubscriber { @Subscribe public void handleInvitationEvent(final IVenueInvitationEvent event) { + final String roomId = event.getRoomId().getFQName(); + VizApp.runAsync(new Runnable() { @Override public void run() { - Shell shell = new Shell(Display.getCurrent()); - InviteDialog inviteBox = new InviteDialog(shell, event); - if (!(Boolean) inviteBox.open()) { - return; + if (!invitePending(roomId)) { + try { + Shell shell = new Shell(Display.getCurrent()); + InviteDialog inviteBox = new InviteDialog(shell, event); + if ((Boolean) inviteBox.open()) { + /* user accepted invite */ + openSession(inviteBox); + } + } finally { + synchronized (pendingInviteDialogs) { + pendingInviteDialogs.remove(roomId); + } + } + } else { + statusHandler.debug("Ignoring duplicate session invite: " + + roomId); } + } + /** + * @param roomId + * @return true if there is already an invitation pending for this + * room + */ + private boolean invitePending(String roomId) { + synchronized (pendingInviteDialogs) { + boolean pending = pendingInviteDialogs.contains(roomId); + if (!pending) { + /* immediately set to pending to ignore dup invites */ + pendingInviteDialogs.add(roomId); + } + return pending; + } + } + + /** + * Open session view after invite has been accepted + * + * @param inviteBox + */ + private void openSession(InviteDialog inviteBox) { try { IVenueSession session = inviteBox.getSession(); if (inviteBox.isSharedDisplay()) { From eea20ba3ef53449fdc2e7d8c96d698251c52e0cd Mon Sep 17 00:00:00 2001 From: David Gillingham Date: Thu, 24 Apr 2014 11:10:53 -0500 Subject: [PATCH 095/188] Issue #3068: Update pqact and bufrascat distribution patterns to support MetOp-B T winds data. Change-Id: I750323b3330016a98eef9778e8491ac920ea77ec Former-commit-id: 0b91ae192358aa162833fb332ba4e551878199f9 --- .../utility/edex_static/base/distribution/bufrascat.xml | 7 +++++++ rpms/awips2.core/Installer.ldm/patch/etc/pqact.conf.dev | 3 +++ .../Installer.ldm/patch/etc/pqact.conf.template | 5 +++++ 3 files changed, 15 insertions(+) diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.bufrascat/utility/edex_static/base/distribution/bufrascat.xml b/edexOsgi/com.raytheon.uf.edex.plugin.bufrascat/utility/edex_static/base/distribution/bufrascat.xml index c1ff88c7d8..05f58f386b 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.bufrascat/utility/edex_static/base/distribution/bufrascat.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrascat/utility/edex_static/base/distribution/bufrascat.xml @@ -18,6 +18,13 @@ See_the_AWIPS_II_Master_Rights_File_("Master_Rights_File.pdf")_for further_licensing_information. --> + + ^JSXX(0[1-9]|10).* + ^JSYY0[1-9].* diff --git a/rpms/awips2.core/Installer.ldm/patch/etc/pqact.conf.dev b/rpms/awips2.core/Installer.ldm/patch/etc/pqact.conf.dev index 5c63cb7ae5..a5ceb94acb 100644 --- a/rpms/awips2.core/Installer.ldm/patch/etc/pqact.conf.dev +++ b/rpms/awips2.core/Installer.ldm/patch/etc/pqact.conf.dev @@ -538,6 +538,9 @@ ANY ^(ISXA..) (....) (..)(..)(..) ANY ^JSXX((0[1-9])|(10)) (....) (..)(..)(..) FILE -overwrite -close -edex /data_store/bufrascat/(\5:yyyy)(\5:mm)\5/\6/JSXX\1_\4_\5\6\7_(seq).bufr.%Y%m%d%H +ANY ^JSYY(0[1-9]) (....) (..)(..)(..) + FILE -overwrite -close -edex /data_store/bufrascat/(\3:yyyy)(\3:mm)\3/\4/JSYY\1_\2_\3\4\5_(seq).bufr.%Y%m%d%H + ANY ^ISXX(..) (....) (..)(..)(..) FILE -overwrite -close -edex /data_store/bufrquikscat/(\3:yyyy)(\3:mm)\3/\4/ISXX\1_\2_\3\4\5_(seq).bufr.%Y%m%d%H diff --git a/rpms/awips2.core/Installer.ldm/patch/etc/pqact.conf.template b/rpms/awips2.core/Installer.ldm/patch/etc/pqact.conf.template index 3ed4ae1beb..10c4b6b459 100644 --- a/rpms/awips2.core/Installer.ldm/patch/etc/pqact.conf.template +++ b/rpms/awips2.core/Installer.ldm/patch/etc/pqact.conf.template @@ -35,6 +35,7 @@ #20130530 2054 rferrel Minor fix to two grib patterns. #20130624 1966 rferrel The acars pattern changed to place files in the proper subdirectories. # Name changes to reflect plugin names for modelsounding, goessounding, poessounding. +#20140424 3068 dgilling Add pattern for MetOp-B ASCAT T winds. #*************************************************************** # AWIPS 1 PATTERN GRAPHIC ^[PQ].* /redbook/Raw # PGNA00 KWNS 010001 !redbook 1_1/NMCGPHMCD/MCDSUM/PXSF001CN/20110201 0001 @@ -684,6 +685,10 @@ HDS ^(ISXA..) (.{4}) (..)(..)(..) # AWIPS2 distribution file bufrascat.xml: ^JSXX(0[1-9]|10).* HDS ^(JSXX(0[1-9]|10)) (.{4}) (..)(..)(..) FILE -overwrite -log -close -edex /data_store/bufrascat/(\4:yyyy)(\4:mm)\4/\5/\1_\3_\4\5\6_(seq).bufr.%Y%m%d%H + +# AWIPS2 distribution file bufrascat.xml: ^JSYY0[1-9].* +HDS ^(JSYY0[1-9]) (.{4}) (..)(..)(..) + FILE -overwrite -log -close -edex /data_store/bufrascat/(\3:yyyy)(\3:mm)\3/\4/\1_\2_\3\4\5_(seq).bufr.%Y%m%d%H # AWIPS2 distribution file bufrmthdw.xml: ^JUTX(([2-4]1)|53).* HDS ^(JUTX(([2-4]1)|53)) (.{4}) (..)(..)(..) From 15985b9eac851b10781284a5170a13b2e8881177 Mon Sep 17 00:00:00 2001 From: Brad Gonzales Date: Thu, 24 Apr 2014 12:48:40 -0500 Subject: [PATCH 096/188] Issue #3035 Increment java component.spec revision value. Change-Id: I869e6f6adab74ef97d45a057fe42e48d1134dfbf Former-commit-id: 245c5214910e1a69d1a6de4b46a36130dbd253b4 --- rpms/awips2.core/Installer.java/1.7/component.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rpms/awips2.core/Installer.java/1.7/component.spec b/rpms/awips2.core/Installer.java/1.7/component.spec index 4d0ec862fe..ffe21ec6ca 100644 --- a/rpms/awips2.core/Installer.java/1.7/component.spec +++ b/rpms/awips2.core/Installer.java/1.7/component.spec @@ -11,7 +11,7 @@ Name: awips2-java Summary: AWIPS II Java Distribution Version: %{_java_version} -Release: 1 +Release: 2 Group: AWIPSII BuildRoot: %{_build_root} BuildArch: %{_build_arch} From 689930c4849bbf4066ff08b7bccc750b34a6615c Mon Sep 17 00:00:00 2001 From: Slav Korolev Date: Wed, 23 Apr 2014 17:18:46 -0400 Subject: [PATCH 097/188] Issue #3054 - Fix issues in the Fog, SAFESEAS and SNOW Area configuration dialogs. Former-commit-id: 879a50a60209abf95752c178a0266cdd42bde012 --- .../dialogs/FogMonitoringAreaConfigDlg.java | 28 +--- .../ui/dialogs/SSMonitoringAreaConfigDlg.java | 27 +--- .../dialogs/SnowMonitoringAreaConfigDlg.java | 21 +-- .../monitor/ui/dialogs/AddNewStationDlg.java | 75 +++-------- .../viz/monitor/ui/dialogs/AddNewZoneDlg.java | 29 ++-- .../monitor/ui/dialogs/DeleteStationDlg.java | 30 +++-- .../monitor/ui/dialogs/EditNewZoneDlg.java | 72 ++++++---- .../monitor/ui/dialogs/INewZoneStnAction.java | 27 ++-- .../ui/dialogs/MonitoringAreaConfigDlg.java | 125 +++++++++++++++--- .../config/MonitorConfigurationManager.java | 14 +- 10 files changed, 243 insertions(+), 205 deletions(-) diff --git a/cave/com.raytheon.uf.viz.monitor.fog/src/com/raytheon/uf/viz/monitor/fog/ui/dialogs/FogMonitoringAreaConfigDlg.java b/cave/com.raytheon.uf.viz.monitor.fog/src/com/raytheon/uf/viz/monitor/fog/ui/dialogs/FogMonitoringAreaConfigDlg.java index 5ea6744e5d..e3dedafe2c 100644 --- a/cave/com.raytheon.uf.viz.monitor.fog/src/com/raytheon/uf/viz/monitor/fog/ui/dialogs/FogMonitoringAreaConfigDlg.java +++ b/cave/com.raytheon.uf.viz.monitor.fog/src/com/raytheon/uf/viz/monitor/fog/ui/dialogs/FogMonitoringAreaConfigDlg.java @@ -41,6 +41,7 @@ import com.raytheon.uf.viz.monitor.ui.dialogs.MonitoringAreaConfigDlg; * Jan 5, 2010 mpduff Initial creation * Nov 27, 2012 1351 skorolev Changes for non-blocking dialog. * Jan 29, 2014 2757 skorolev Changed OK button handler. + * Apr 23, 2014 3054 skorolev Fixed issue with removing a new station from list. * * * @@ -66,22 +67,16 @@ public class FogMonitoringAreaConfigDlg extends MonitoringAreaConfigDlg { @Override protected void handleOkBtnSelection() { // Check for changes in the data - if (!configManager.getAddedZones().isEmpty() - || !configManager.getAddedStations().isEmpty() - || this.timeWindowChanged || this.shipDistanceChanged - || this.fogChkChanged || this.maZonesRemoved) { + if (dataIsChanged()) { int choice = showMessage(shell, SWT.OK | SWT.CANCEL, "Fog Monitor Confirm Changes", "Want to Update Fog Monitor's Setup files?"); if (choice == SWT.OK) { // Save the config xml file configManager.setTimeWindow(timeWindow.getSelection()); - this.timeWindowChanged = false; configManager.setShipDistance(shipDistance.getSelection()); - this.shipDistanceChanged = false; configManager.setUseAlgorithms(fogChk.getSelection()); - this.fogChkChanged = false; - this.maZonesRemoved = false; + resetStatus(); configManager.saveConfigData(); /** * DR#11279: re-initialize threshold manager and the monitor @@ -92,22 +87,7 @@ public class FogMonitoringAreaConfigDlg extends MonitoringAreaConfigDlg { if ((!configManager.getAddedZones().isEmpty()) || (!configManager.getAddedStations().isEmpty())) { - String message = "New zones have been added, the display " - + "thresholds for the new zones are set to " - + "default values, you may edit them with the display " - + "thresholds editor which can be launched from Fog Monitor " - + "zone table.\n\nIf Fog Monitor is running anywhere within " - + "the office, clear it.\n"; - - showMessage(shell, SWT.ICON_INFORMATION | SWT.OK, - "Fog Monitor Confirm Changes", message); - - String message2 = "New zones have been added, and their monitoring thresholds " - + "have been set to default values; would you like to modify " - + "their threshold values now?"; - int yesno = showMessage(shell, SWT.ICON_QUESTION | SWT.YES - | SWT.NO, "Edit Thresholds Now?", message2); - if (yesno == SWT.YES) { + if (editDialog() == SWT.YES) { FogMonDispThreshDlg fogMonitorDlg = new FogMonDispThreshDlg( shell, CommonConfig.AppName.FOG, DataUsageKey.MONITOR); diff --git a/cave/com.raytheon.uf.viz.monitor.safeseas/src/com/raytheon/uf/viz/monitor/safeseas/ui/dialogs/SSMonitoringAreaConfigDlg.java b/cave/com.raytheon.uf.viz.monitor.safeseas/src/com/raytheon/uf/viz/monitor/safeseas/ui/dialogs/SSMonitoringAreaConfigDlg.java index 2e3280a6ad..7f21dbd69a 100644 --- a/cave/com.raytheon.uf.viz.monitor.safeseas/src/com/raytheon/uf/viz/monitor/safeseas/ui/dialogs/SSMonitoringAreaConfigDlg.java +++ b/cave/com.raytheon.uf.viz.monitor.safeseas/src/com/raytheon/uf/viz/monitor/safeseas/ui/dialogs/SSMonitoringAreaConfigDlg.java @@ -41,6 +41,7 @@ import com.raytheon.uf.viz.monitor.ui.dialogs.MonitoringAreaConfigDlg; * Jan 5, 2010 mpduff Initial creation * Nov 27, 2012 1351 skorolev Changes for non-blocking dialog. * Jan 29, 2014 2757 skorolev Changed OK button handler. + * Apr 23, 2014 3054 skorolev Fixed issue with removing a new station from list. * * * @@ -73,22 +74,16 @@ public class SSMonitoringAreaConfigDlg extends MonitoringAreaConfigDlg { @Override protected void handleOkBtnSelection() { // Check for changes in the data - if (!configManager.getAddedZones().isEmpty() - || !configManager.getAddedStations().isEmpty() - || this.timeWindowChanged || this.shipDistanceChanged - || this.fogChkChanged || this.maZonesRemoved) { + if (dataIsChanged()) { int choice = showMessage(shell, SWT.OK | SWT.CANCEL, "SAFESEAS Monitor Confirm Changes", "Want to update the SAFESEAS setup files?"); if (choice == SWT.OK) { // Save the config xml file configManager.setTimeWindow(timeWindow.getSelection()); - this.timeWindowChanged = false; configManager.setShipDistance(shipDistance.getSelection()); - this.shipDistanceChanged = false; configManager.setUseAlgorithms(fogChk.getSelection()); - this.fogChkChanged = false; - this.maZonesRemoved = false; + resetStatus(); configManager.saveConfigData(); /** * DR#11279: re-initialize threshold manager and the monitor @@ -98,21 +93,7 @@ public class SSMonitoringAreaConfigDlg extends MonitoringAreaConfigDlg { SafeSeasMonitor.reInitialize(); if ((!configManager.getAddedZones().isEmpty()) || (!configManager.getAddedStations().isEmpty())) { - - String message = "You're updating the SAFESEAS monitoring settings." - + "\n\nIf SAFESEAS is running anywhere within " - + "the office, please clear it.\n"; - - showMessage(shell, SWT.OK, "SAFESEAS Config Change", - message); - - String message2 = "New zones have been added, and their monitoring thresholds " - + "have been set to default values; would you like to modify " - + "their threshold values now?"; - - int yesno = showMessage(shell, SWT.ICON_QUESTION | SWT.YES - | SWT.NO, "Edit Thresholds Now?", message2); - if (yesno == SWT.YES) { + if (editDialog() == SWT.YES) { SSDispMonThreshDlg ssMonitorDlg = new SSDispMonThreshDlg( shell, CommonConfig.AppName.SAFESEAS, DataUsageKey.MONITOR); diff --git a/cave/com.raytheon.uf.viz.monitor.snow/src/com/raytheon/uf/viz/monitor/snow/ui/dialogs/SnowMonitoringAreaConfigDlg.java b/cave/com.raytheon.uf.viz.monitor.snow/src/com/raytheon/uf/viz/monitor/snow/ui/dialogs/SnowMonitoringAreaConfigDlg.java index 74fc07479f..066f6bfc82 100644 --- a/cave/com.raytheon.uf.viz.monitor.snow/src/com/raytheon/uf/viz/monitor/snow/ui/dialogs/SnowMonitoringAreaConfigDlg.java +++ b/cave/com.raytheon.uf.viz.monitor.snow/src/com/raytheon/uf/viz/monitor/snow/ui/dialogs/SnowMonitoringAreaConfigDlg.java @@ -41,6 +41,7 @@ import com.raytheon.uf.viz.monitor.ui.dialogs.MonitoringAreaConfigDlg; * Jan 5, 2010 mpduff Initial creation * Nov 27, 2012 1351 skorolev Changes for non-blocking dialog. * Jan 29, 2014 2757 skorolev Changed OK button handler. + * Apr 23, 2014 3054 skorolev Fixed issue with removing a new station from list. * * * @@ -67,17 +68,14 @@ public class SnowMonitoringAreaConfigDlg extends MonitoringAreaConfigDlg { @Override protected void handleOkBtnSelection() { // Check for changes in the data - if (!configManager.getAddedZones().isEmpty() - || !configManager.getAddedStations().isEmpty() - || this.timeWindowChanged || this.maZonesRemoved) { + if (dataIsChanged()) { int choice = showMessage(shell, SWT.OK | SWT.CANCEL, "SNOW Monitor Confirm Changes", "Want to update the SNOW setup files?"); if (choice == SWT.OK) { // Save the config xml file configManager.setTimeWindow(timeWindow.getSelection()); - this.timeWindowChanged = false; - this.maZonesRemoved = false; + resetStatus(); configManager.saveConfigData(); /** * DR#11279: re-initialize threshold manager and the monitor @@ -88,18 +86,7 @@ public class SnowMonitoringAreaConfigDlg extends MonitoringAreaConfigDlg { if ((!configManager.getAddedZones().isEmpty()) || (!configManager.getAddedStations().isEmpty())) { - showMessage(shell, SWT.ICON_INFORMATION | SWT.OK, - "SNOW Config Change", - "You're updating the SNOW monitoring settings." - + "\n\nIf SNOW is running anywhere within " - + "the office, please clear it.\n"); - - String message2 = "New zones have been added, and their monitoring thresholds " - + "have been set to default values; would you like to modify " - + "their threshold values now?"; - int yesno = showMessage(shell, SWT.ICON_QUESTION | SWT.YES - | SWT.NO, "Edit Thresholds Now?", message2); - if (yesno == SWT.YES) { + if (editDialog() == SWT.YES) { SnowMonDispThreshDlg snowMonitorDlg = new SnowMonDispThreshDlg( shell, CommonConfig.AppName.SNOW, DataUsageKey.MONITOR); diff --git a/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/AddNewStationDlg.java b/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/AddNewStationDlg.java index 459e5c428a..08bf955ba2 100644 --- a/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/AddNewStationDlg.java +++ b/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/AddNewStationDlg.java @@ -58,6 +58,7 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * ------------ ---------- ----------- -------------------------- * Apr 2, 2009 lvenable Initial creation * Nov 20, 2012 1297 skorolev Changes for non-blocking dialog. + * Apr 23, 2014 3054 skorolev Added MESONET handling * * * @@ -159,7 +160,7 @@ public class AddNewStationDlg extends CaveSWTDialog { createTopLabelRadioControls(); createTextControls(); createBottomButtons(); - setStationLabel(); + stationLbl.setText("StationID:"); } /** @@ -183,30 +184,13 @@ public class AddNewStationDlg extends CaveSWTDialog { metarRdo = new Button(radioComp, SWT.RADIO); metarRdo.setText("Metar"); metarRdo.setSelection(true); - metarRdo.addSelectionListener(new SelectionAdapter() { - @Override - public void widgetSelected(SelectionEvent event) { - setStationLabel(); - } - }); - // TODO: Disable if area has no marine zones. + maritimeRdo = new Button(radioComp, SWT.RADIO); maritimeRdo.setText("Maritime"); maritimeRdo.setEnabled(appName != CommonConfig.AppName.SNOW); - maritimeRdo.addSelectionListener(new SelectionAdapter() { - @Override - public void widgetSelected(SelectionEvent event) { - setStationLabel(); - } - }); + mesonetRdo = new Button(radioComp, SWT.RADIO); mesonetRdo.setText("Mesonet"); - mesonetRdo.addSelectionListener(new SelectionAdapter() { - @Override - public void widgetSelected(SelectionEvent event) { - setStationLabel(); - } - }); } /** @@ -251,23 +235,22 @@ public class AddNewStationDlg extends CaveSWTDialog { if (metarRdo.getSelection()) { stationType = StationIdXML.METAR; } else if (mesonetRdo.getSelection()) { - String s = stationTF.getText(); - s = s.substring(s.indexOf("#") + 1, s.length()); - stationType = s.toUpperCase(); + stationType = StationIdXML.MESONET; // TODO need to verify the stationType exists. // was in SSmesonetStationInfo.txt in AWIPS1. } else { stationType = StationIdXML.MARITIME; } if (!stationTF.getText().isEmpty()) { - configManager.addStation(area, stationTF.getText(), - stationType, false); + configManager.addStation(area, stationTF.getText() + .toUpperCase(), stationType, false); /** * for DR #7854: add new station to Monitor Area Config GUI */ handleAddNewStation(); } else { - displayInputErrorMsg("Invalid Station ID entered: Please enter a valid Station ID for the selected Station Type"); + displayInputErrorMsg("No Station ID entered." + + "\nPlease enter a valid Station ID for the selected Station Type."); } } }); @@ -285,37 +268,28 @@ public class AddNewStationDlg extends CaveSWTDialog { }); } - /** - * Set the station label. - */ - private void setStationLabel() { - if (mesonetRdo.getSelection() == true) { - stationLbl.setText("StationID#Provider:"); - } else { - stationLbl.setText("StationID:"); - } - } - /** * Adds a new station. */ private void handleAddNewStation() { - if (!isValidStation()) { - displayInputErrorMsg("Invalid Station ID entered: Please enter a valid Station ID for the selected Station Type"); + String stn = stationTF.getText().toUpperCase(); + if (!isValidStation(stn)) { + displayInputErrorMsg("Invalid Station ID entered: " + + stn + + " \nPlease enter a valid Station ID for the selected Station Type."); return; } - String stn = stationTF.getText(); if (metarRdo.getSelection()) { stn = stn + "#METAR"; } else if (maritimeRdo.getSelection()) { stn = stn + "#MARITIME"; } else { - // TODO: Mesonet + stn = stn + "#MESONET"; } if (macDlg.isExistingStation(stn)) { - displayInputErrorMsg("The Station, " + displayInputErrorMsg("The Station '" + stn - + ", is already in your Monitoring Area or among your Additional Stations"); + + "' is already in your Monitoring Area or among your Additional Stations."); return; } macDlg.addNewStationAction(stn); @@ -325,13 +299,11 @@ public class AddNewStationDlg extends CaveSWTDialog { /** * Checks if station is valid. * + * @param stnId + * * @return boolean value */ - private boolean isValidStation() { - String stnId = stationTF.getText(); - if (stnId.contains("#") && !mesonetRdo.getSelection()) { - return false; - } + private boolean isValidStation(String stnId) { String catalogtypePhrase = ""; if (metarRdo.getSelection()) { catalogtypePhrase = "catalogtype = 1"; // METAR @@ -339,7 +311,6 @@ public class AddNewStationDlg extends CaveSWTDialog { catalogtypePhrase = "catalogtype = 33 or catalogtype = 32"; // MARITIME } else { catalogtypePhrase = "catalogtype = 1000"; // MESONET - stnId = stnId.substring(0, stnId.indexOf("#")); } try { String sql = "select stationid, catalogtype from common_obs_spatial where ( " @@ -353,11 +324,9 @@ public class AddNewStationDlg extends CaveSWTDialog { return false; } return true; - /** - * TODO: need to add code for handling Mesonet station type - */ } catch (Exception e) { - statusHandler.handle(Priority.ERROR, e.getMessage()); + statusHandler.handle(Priority.ERROR, "Can not get " + stnId + + " station in the database. ", e); } return false; } diff --git a/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/AddNewZoneDlg.java b/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/AddNewZoneDlg.java index d85858a9c0..96f554cb2a 100644 --- a/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/AddNewZoneDlg.java +++ b/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/AddNewZoneDlg.java @@ -51,6 +51,7 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * ------------ ---------- ----------- -------------------------- * Apr 2, 2009 lvenable Initial creation * Nov 20, 2012 1297 skorolev Changes for non-blocking dialog. + * Apr 23, 2014 3054 skorolev Deleted unnecessary parameter in addArea method. * * * @@ -225,7 +226,8 @@ public class AddNewZoneDlg extends CaveSWTDialog { gd = new GridData(SWT.FILL, SWT.DEFAULT, true, false); gd.horizontalSpan = 2; Label useDecimalLbl = new Label(textComp, SWT.CENTER); - useDecimalLbl.setText("Use Decimal Degrees, West Longitude negative"); + useDecimalLbl + .setText("Use Decimal Degrees. West Longitude is negative."); useDecimalLbl.setLayoutData(gd); } @@ -283,23 +285,19 @@ public class AddNewZoneDlg extends CaveSWTDialog { String areaId = idTF.getText(); if (areaId.equals("") || areaId.length() != 6 || (areaId.charAt(2) != 'C' && areaId.charAt(2) != 'Z')) { - displayInputErrorMsg("Invalid Area ID entered. Please enter a correctly formatted Area ID"); + displayInputErrorMsg("Invalid Area ID = '" + areaId + + "' entered. Please enter a correctly formatted Area ID."); return; } if (macDlg.isExistingZone(areaId)) { displayInputErrorMsg("The Area ID, " + areaId - + ", is already in your Monitoring Area or among your Additional Zones"); + + ", is already in your Monitoring Area or among your Additional Zones."); return; } if (latString == null || latString.isEmpty() || lonString == null || lonString.isEmpty()) { - MessageBox messageBox = new MessageBox(shell, SWT.ICON_INFORMATION - | SWT.OK); - messageBox.setText("Invalid Lat/Lon"); - messageBox - .setMessage("Invalid Lat/Lon entered. Please enter correctly formatted Lat and Lon values"); - messageBox.open(); + macDlg.latLonErrorMsg(latString, lonString); return; } else { try { @@ -311,16 +309,15 @@ public class AddNewZoneDlg extends CaveSWTDialog { type = ZoneType.MARITIME; } } - configMan.addArea(areaId, lat, lon, type, false); + if (lat > 90.0 || lat < -90.0 || lon > 180.0 || lon < -180.0) { + macDlg.latLonErrorMsg(latString, lonString); + return; + } + configMan.addArea(areaId, lat, lon, type); macDlg.addNewZoneAction(areaId, centroidLatTF.getText(), centroidLonTF.getText()); } catch (NumberFormatException e) { - MessageBox messageBox = new MessageBox(shell, - SWT.ICON_INFORMATION | SWT.OK); - messageBox.setText("Invalid Lat/Lon"); - messageBox - .setMessage("Invalid Lat/Lon entered. Please enter correctly formatted Lat and Lon values"); - messageBox.open(); + macDlg.latLonErrorMsg(latString, lonString); return; } } diff --git a/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/DeleteStationDlg.java b/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/DeleteStationDlg.java index 380ba8b80c..f4b55ab0bc 100644 --- a/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/DeleteStationDlg.java +++ b/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/DeleteStationDlg.java @@ -30,6 +30,7 @@ import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Label; import org.eclipse.swt.widgets.Layout; import org.eclipse.swt.widgets.List; +import org.eclipse.swt.widgets.MessageBox; import org.eclipse.swt.widgets.Shell; import com.raytheon.uf.common.monitor.config.FogMonitorConfigurationManager; @@ -50,6 +51,7 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * ------------ ---------- ----------- -------------------------- * Apr 2, 2009 lvenable Initial creation * Nov 20, 2012 1297 skorolev Changes for non-blocking dialog. + * Apr 23, 2014 3054 skorolev Fixed issue with deleting a new station. * * * @@ -155,7 +157,8 @@ public class DeleteStationDlg extends CaveSWTDialog { deleteBtn.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent event) { - deleteSelected(); + String delStn = deleteSelected(); + setReturnValue(delStn); } }); @@ -166,7 +169,6 @@ public class DeleteStationDlg extends CaveSWTDialog { closeBtn.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent event) { - setReturnValue(true); close(); } }); @@ -184,14 +186,26 @@ public class DeleteStationDlg extends CaveSWTDialog { /** * Delete stations from the list. */ - private void deleteSelected() { + private String deleteSelected() { + String retval = null; if (stationList.getItemCount() != 0) { - String selection = stationList.getItem(stationList - .getSelectionIndex()); - configMan.removeStation(selection); - stationList.remove(stationList.getSelectionIndex()); - populate(); + if (stationList.getSelectionIndex() != -1) { + int idx = stationList.getSelectionIndex(); + String selection = stationList.getItem(idx); + retval = configMan.getAddedStations().get(idx); + configMan.getAddedStations().remove(idx); + stationList.remove(selection); + populate(); + } else { + MessageBox messageBox = new MessageBox(shell, + SWT.ICON_INFORMATION | SWT.NONE); + messageBox.setText("Selection error."); + messageBox.setMessage("Please select station to delete."); + messageBox.open(); + stationList.select(0); + } } + return retval; } /** diff --git a/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/EditNewZoneDlg.java b/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/EditNewZoneDlg.java index 7dbe5dc72a..33789ed2cd 100644 --- a/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/EditNewZoneDlg.java +++ b/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/EditNewZoneDlg.java @@ -53,6 +53,7 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * ------------ ---------- ----------- -------------------------- * Apr 2, 2009 lvenable Initial creation * Nov 20, 2012 1297 skorolev Changes for non-blocking dialog. + * Apr 23, 2014 3054 skorolev Fixed issues with removing a new zone from list. * * * @@ -60,6 +61,12 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * @version 1.0 */ public class EditNewZoneDlg extends CaveSWTDialog { + + /** + * Call back interface. + */ + private INewZoneStnAction macDlg; + /** * Zone list control. */ @@ -115,6 +122,8 @@ public class EditNewZoneDlg extends CaveSWTDialog { */ private Label bottomLbl; + private String delZone; + /** * Constructor. * @@ -122,10 +131,13 @@ public class EditNewZoneDlg extends CaveSWTDialog { * Parent shell. * @param appName * Application name. + * @param monitoringAreaConfigDlg */ - public EditNewZoneDlg(Shell parent, AppName appName) { + public EditNewZoneDlg(Shell parent, AppName appName, + INewZoneStnAction macDlg) { super(parent, SWT.DIALOG_TRIM, CAVE.DO_NOT_BLOCK); setText(appName.toString() + ": Edit a Newly Added Zone"); + this.macDlg = macDlg; configMan = this.getConfigManager(appName); } @@ -279,7 +291,7 @@ public class EditNewZoneDlg extends CaveSWTDialog { deleteBtn.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent event) { - deleteSelected(); + delZone = deleteSelected(); } }); } @@ -316,7 +328,7 @@ public class EditNewZoneDlg extends CaveSWTDialog { closeBtn.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent event) { - setReturnValue(true); + setReturnValue(delZone); close(); } }); @@ -339,6 +351,7 @@ public class EditNewZoneDlg extends CaveSWTDialog { // DR #7343: a null areaXml causes an "Unhandled event loop exception" if (areaXml != null) { idTF.setText(areaXml.getAreaId()); + idTF.setEnabled(false); latTF.setText(String.valueOf(areaXml.getCLat())); lonTF.setText(String.valueOf(areaXml.getCLon())); if (areaXml.getType() == ZoneType.REGULAR) { @@ -354,8 +367,7 @@ public class EditNewZoneDlg extends CaveSWTDialog { /** * Delete selected zones. */ - // TODO: Delete zone from left list in the Area Configuration dialog. - private void deleteSelected() { + private String deleteSelected() { if (zoneList.getItemCount() != 0) { String area = zoneList.getItem(zoneList.getSelectionIndex()); zoneList.remove(zoneList.getSelectionIndex()); @@ -363,9 +375,11 @@ public class EditNewZoneDlg extends CaveSWTDialog { idTF.setText(""); latTF.setText(""); lonTF.setText(""); + return area; } else { bottomLbl.setText("No zones have been added."); } + return null; } /** @@ -375,28 +389,36 @@ public class EditNewZoneDlg extends CaveSWTDialog { if (zoneList.getItemCount() != 0) { String area = zoneList.getItem(zoneList.getSelectionIndex()); - double lat; - if (!latTF.getText().isEmpty()) { - lat = Double.parseDouble(latTF.getText()); + String latStr = latTF.getText(); + String lontStr = lonTF.getText(); + if (latStr == null || latStr.isEmpty() || lontStr == null + || lontStr.isEmpty()) { + macDlg.latLonErrorMsg(latStr, lontStr); + return; } else { - // wrong value will be filtered when save - lat = 9999.0; + try { + double lat = Double.parseDouble(latStr); + double lon = Double.parseDouble(lontStr); + if (lat > 90.0 || lat < -90.0 || lon > 180.0 + || lon < -180.0) { + macDlg.latLonErrorMsg(latStr, lontStr); + return; + } + ZoneType type = ZoneType.REGULAR; + if (marineRdo.getSelection()) { + type = ZoneType.MARITIME; + } + configMan.removeArea(area); + configMan.removeAddedArea(area); + configMan.addArea(area, lat, lon, type); + populate(); + // Return cursor to the top of the list. + zoneList.select(0); + } catch (NumberFormatException e) { + macDlg.latLonErrorMsg(latStr, lontStr); + return; + } } - double lon; - if (!lonTF.getText().isEmpty()) { - lon = Double.parseDouble(lonTF.getText()); - } else { - // wrong value will be filtered when save - lon = 9999.0; - } - ZoneType type = ZoneType.REGULAR; - if (marineRdo.getSelection()) { - type = ZoneType.MARITIME; - } - configMan.removeArea(area); - configMan.removeAddedArea(area); - configMan.addArea(idTF.getText(), lat, lon, type, false); - populate(); } else { bottomLbl.setText("No zones have been added."); } diff --git a/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/INewZoneStnAction.java b/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/INewZoneStnAction.java index e5272f9aa2..d17718dc9a 100644 --- a/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/INewZoneStnAction.java +++ b/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/INewZoneStnAction.java @@ -1,18 +1,19 @@ package com.raytheon.uf.viz.monitor.ui.dialogs; + /** - * Interface used for action callbacks for the Monitor Area - * Configure Dlg + * Interface used for action callbacks for the Monitor Area Configure Dlg * *
- *
+ * 
  * SOFTWARE HISTORY
- *
+ * 
  * Date         Ticket#      Engineer    Description
  * ------------ ----------   ----------- --------------------------
- * Feb 9, 2011  7854, 7855   zhao        Initial creation
- *
+ * Feb  9, 2011  7854, 7855   zhao        Initial creation
+ * Apr 24, 2014  3054         skorolev    Add an error message box action.
+ * 
  * 
- * + * * @author zhao * @version 1.0 */ @@ -21,11 +22,19 @@ public interface INewZoneStnAction { * Action to add a new zone to Monitor Area. */ public void addNewZoneAction(String id, String lat, String log); + public boolean isExistingZone(String id); - + /** * Action to add a new station to Monitor Area */ - public void addNewStationAction(String stnWithType); + public void addNewStationAction(String stnWithType); + public boolean isExistingStation(String stnWithType); + + /** + * Action to show an error message box for invalid Latitude and Longitude + * values. + */ + public void latLonErrorMsg(String latStr, String lonStr); } diff --git a/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/MonitoringAreaConfigDlg.java b/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/MonitoringAreaConfigDlg.java index 971b7f5cf8..274379e9ab 100644 --- a/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/MonitoringAreaConfigDlg.java +++ b/cave/com.raytheon.uf.viz.monitor/src/com/raytheon/uf/viz/monitor/ui/dialogs/MonitoringAreaConfigDlg.java @@ -72,6 +72,7 @@ import com.raytheon.viz.ui.dialogs.ICloseCallback; * Feb 06, 2013 1578 skorolev Fixed a cursor problem for checkboxes. * Oct 07, 2013 #2443 lvenable Fixed image memory leak. * Jan 29, 2014 2757 skorolev Added status variables. + * Apr 23, 2014 3054 skorolev Fixed issue with removing from list a new zone and a new station. * * * @author lvenable @@ -187,6 +188,9 @@ public abstract class MonitoringAreaConfigDlg extends CaveSWTDialog implements /** monitor area stations **/ private java.util.List maStations = null; + /** monitor area stations status. */ + protected boolean maStationsRemoved = false; + /** monitor area additional zones **/ private java.util.List additionalZones = null; @@ -287,6 +291,7 @@ public abstract class MonitoringAreaConfigDlg extends CaveSWTDialog implements " Error initiate Additional Zone/Stations list.", e); } Collections.sort(additionalStns); + mode = Mode.Zone; } /* @@ -565,6 +570,7 @@ public abstract class MonitoringAreaConfigDlg extends CaveSWTDialog implements @Override public void widgetSelected(SelectionEvent event) { removeAssociated(); + maStationsRemoved = true; } }); /* @@ -864,25 +870,32 @@ public abstract class MonitoringAreaConfigDlg extends CaveSWTDialog implements } addNewZoneDlg.open(); } else { - if (associatedList.getSelectionIndex() == -1) { - associatedList.setSelection(0); - } - String area = associatedList.getItem(associatedList - .getSelectionIndex()); - if (addNewStnDlg == null) { - addNewStnDlg = new AddNewStationDlg(shell, appName, area, this); - addNewStnDlg.setCloseCallback(new ICloseCallback() { - @Override - public void dialogClosed(Object returnValue) { - if ((Boolean) returnValue) { - // Update the dialog - populateLeftLists(); + if (associatedList.getSelectionIndex() != -1) { + String area = associatedList.getItem(associatedList + .getSelectionIndex()); + if (addNewStnDlg == null) { + addNewStnDlg = new AddNewStationDlg(shell, appName, area, + this); + addNewStnDlg.setCloseCallback(new ICloseCallback() { + @Override + public void dialogClosed(Object returnValue) { + if ((Boolean) returnValue) { + // Update the dialog + populateLeftLists(); + } + addNewStnDlg = null; } - addNewStnDlg = null; - } - }); + }); + } + addNewStnDlg.open(); + } else { + MessageBox messageBox = new MessageBox(shell, + SWT.ICON_INFORMATION | SWT.NONE); + messageBox.setText("Selection error."); + messageBox.setMessage("Please select associated zone."); + messageBox.open(); + associatedList.select(0); } - addNewStnDlg.open(); } } @@ -892,12 +905,14 @@ public abstract class MonitoringAreaConfigDlg extends CaveSWTDialog implements private void handleEditDeleteAction() { if (zoneRdo.getSelection() == true) { if (editDlg == null) { - editDlg = new EditNewZoneDlg(shell, appName); + editDlg = new EditNewZoneDlg(shell, appName, this); editDlg.setCloseCallback(new ICloseCallback() { @Override public void dialogClosed(Object returnValue) { - if ((Boolean) returnValue) { - // Update the dialog + if (returnValue instanceof String) { + // Update the edit dialog + String selectedZone = returnValue.toString(); + maZones.remove(selectedZone); populateLeftLists(); } editDlg = null; @@ -911,8 +926,10 @@ public abstract class MonitoringAreaConfigDlg extends CaveSWTDialog implements deleteStnDlg.setCloseCallback(new ICloseCallback() { @Override public void dialogClosed(Object returnValue) { - if ((Boolean) returnValue) { - // Update the dialog + if (returnValue instanceof String) { + // Update the delete dialog + String selectedStn = returnValue.toString(); + maStations.remove(selectedStn); populateLeftLists(); } deleteStnDlg = null; @@ -1385,4 +1402,68 @@ public abstract class MonitoringAreaConfigDlg extends CaveSWTDialog implements arrowUpImg.dispose(); arrowDownImg.dispose(); } + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.viz.monitor.ui.dialogs.INewZoneStnAction#latLonErrorMsg() + */ + public void latLonErrorMsg(String latStr, String lonStr) { + MessageBox messageBox = new MessageBox(shell, SWT.ICON_INFORMATION + | SWT.OK); + messageBox.setText("Invalid Lat/Lon"); + StringBuilder errMsg = new StringBuilder("Invalid Lat/Lon entered:"); + errMsg.append("\nLatitude = "); + errMsg.append(latStr); + errMsg.append("\nLongitude = "); + errMsg.append(lonStr); + errMsg.append("\nPlease enter correctly formatted Lat and Lon values:"); + errMsg.append("\nLatitude should be between -90,90."); + errMsg.append("\nLongitude should be between -180,180."); + messageBox.setMessage(errMsg.toString()); + messageBox.open(); + } + + /** + * Reset data status. + */ + protected void resetStatus() { + this.timeWindowChanged = false; + this.maZonesRemoved = false; + this.maStationsRemoved = false; + this.shipDistanceChanged = false; + this.fogChkChanged = false; + } + + /** + * Check if data and data states have been changed. + * + * @return + */ + protected boolean dataIsChanged() { + if (!configMgr.getAddedZones().isEmpty() + || !configMgr.getAddedStations().isEmpty() + || this.timeWindowChanged || this.shipDistanceChanged + || this.fogChkChanged || this.maZonesRemoved + || this.maStationsRemoved) { + return true; + } + return false; + } + + protected int editDialog() { + showMessage(shell, SWT.ICON_INFORMATION | SWT.OK, appName + + " Config Change", "You're updating the " + appName + + " monitoring settings." + "\n\nIf " + appName + + " is running anywhere within " + + "the office, please clear it.\n"); + + String message2 = "New zones have been added, and their monitoring thresholds " + + "have been set to default values; would you like to modify " + + "their threshold values now?"; + int yesno = showMessage(shell, SWT.ICON_QUESTION | SWT.YES | SWT.NO, + "Edit Thresholds Now?", message2); + return yesno; + } } diff --git a/edexOsgi/com.raytheon.uf.common.monitor/src/com/raytheon/uf/common/monitor/config/MonitorConfigurationManager.java b/edexOsgi/com.raytheon.uf.common.monitor/src/com/raytheon/uf/common/monitor/config/MonitorConfigurationManager.java index 2a744b9cc6..b9822a1204 100644 --- a/edexOsgi/com.raytheon.uf.common.monitor/src/com/raytheon/uf/common/monitor/config/MonitorConfigurationManager.java +++ b/edexOsgi/com.raytheon.uf.common.monitor/src/com/raytheon/uf/common/monitor/config/MonitorConfigurationManager.java @@ -56,6 +56,7 @@ import com.raytheon.uf.common.status.UFStatus.Priority; * Nov 20 2012 1297 skorolev Cleaned code * Oct 02 2013 2361 njensen Use JAXBManager for XML * Oct 17 2013 16682 zhao fixed a bug in readConfigXml() + * Apr 23 2014 3054 skorolev Removed unnecessary parameter in the addArea method. * * * @@ -325,11 +326,8 @@ public abstract class MonitorConfigurationManager { * The area longitude * @param type * The area type - * @param existingArea - * Does the area already exist */ - public void addArea(String areaId, double lat, double lon, ZoneType type, - boolean existingArea) { + public void addArea(String areaId, double lat, double lon, ZoneType type) { List areaXmlList = configXml.getAreaIds(); boolean areaExists = false; for (AreaIdXML area : areaXmlList) { @@ -343,10 +341,10 @@ public abstract class MonitorConfigurationManager { AreaIdXML area = new AreaIdXML(); area.setAreaId(areaId); area.setType(type); - if (lat < -90.0 || lat > 90.0) { + if (lat > -90.0 && lat < 90.0) { area.setCLat(lat); } - if (lon < -180.0 || lon > 180.0) { + if (lon > -180.0 && lon < 180.0) { area.setCLon(lon); } configXml.addAreaId(area); @@ -380,7 +378,7 @@ public abstract class MonitorConfigurationManager { stationXml.setName(stationId); stationXml.setType(type); area.addStationIdXml(stationXml); - addedStations.add(stationId); + addedStations.add(stationId + "#" + type); } } } @@ -586,7 +584,7 @@ public abstract class MonitorConfigurationManager { public AreaIdXML getAreaXml(String area) { List areaList = configXml.getAreaIds(); for (AreaIdXML areaXml : areaList) { - if (areaXml.equals(area)) { + if (areaXml.getAreaId().equals(area)) { return areaXml; } } From 9dad4c959bd7cb52e57b2fefed209b6aecec8731 Mon Sep 17 00:00:00 2001 From: Roger Ferrel Date: Wed, 23 Apr 2014 11:02:38 -0500 Subject: [PATCH 098/188] Issue #3045 - Change to prevent race conditions while getting table labels. Change-Id: I82d0ab9deaa2b2b89a859fcb76af5d5cd7692120 Former-commit-id: 17a06743e41fe6bf15a895d9842bb51d99901602 --- .../data/ILoadDisplayDataListener.java | 44 +++ .../raytheon/uf/viz/archive/data/SizeJob.java | 314 ++++++++++++------ .../uf/viz/archive/ui/AbstractArchiveDlg.java | 104 ++++-- .../viz/archive/ui/ArchiveRetentionDlg.java | 6 + .../uf/viz/archive/ui/ArchiveTableComp.java | 9 + .../uf/viz/archive/ui/CaseCreationDlg.java | 74 ++++- .../viz/archive/ui/CaseLoadSaveDeleteDlg.java | 4 +- 7 files changed, 412 insertions(+), 143 deletions(-) create mode 100644 cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/data/ILoadDisplayDataListener.java diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/data/ILoadDisplayDataListener.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/data/ILoadDisplayDataListener.java new file mode 100644 index 0000000000..06541d1167 --- /dev/null +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/data/ILoadDisplayDataListener.java @@ -0,0 +1,44 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.viz.archive.data; + +/** + * A listener to notify when SizeJob has obtain all display data. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 23, 2014 3045       rferrel     Initial creation
+ * 
+ * 
+ * + * @author rferrel + * @version 1.0 + */ +public interface ILoadDisplayDataListener { + /** + * Called by SizeJob after obtaining all display data for all + * archive/category tables. + */ + public void loadedAllDisplayData(); +} diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/data/SizeJob.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/data/SizeJob.java index 79183cbf93..2724cf7bc5 100644 --- a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/data/SizeJob.java +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/data/SizeJob.java @@ -52,6 +52,7 @@ import com.raytheon.uf.common.time.util.TimeUtil; * Dec 11, 2013 #2603 rferrel Selected list changed to a Set. * Dec 11, 2013 #2624 rferrel Clear display variables when recomputing sizes. * Mar 27, 2014 #2879 rferrel Loading Case no longer changes Start/End times. + * Apr 23, 2014 #3045 rferrel Changes to prevent race condition while getting labels. * * * @@ -156,17 +157,17 @@ public class SizeJob extends Job { private boolean stopComputeSize; /** - * Priority queue for getting display data for an archive/category. + * Priority queue for getting display data all archive/category tables. */ // Do not use a PriorityBlockingQueue since the load select and change // display methods need to be notified when the display data is available. - private final PriorityQueue missingDataQueue = new PriorityQueue( - DEFAULT_INITIAL_CAPACITY, new Comparator() { + private final PriorityQueue loadDisplayDataQueue = new PriorityQueue( + DEFAULT_INITIAL_CAPACITY, new Comparator() { @Override - public int compare(MissingData o1, MissingData o2) { - if (o1.visiable != o2.visiable) { - return o1.visiable ? -1 : +1; + public int compare(LoadDisplayData o1, LoadDisplayData o2) { + if (o1.visible != o2.visible) { + return o1.visible ? -1 : +1; } if (o1.isSelected() != o2.isSelected()) { return o1.isSelected() ? -1 : +1; @@ -182,16 +183,22 @@ public class SizeJob extends Job { }); /** - * Job for processing the missing data queue. + * Job for obtaining display data for all the archive/category tables. */ - private final MissingDataJob missingDataJob = new MissingDataJob(); + private LoadDisplayDataJob loadDisplayDataJob; + + /** + * Listener to invoke when all display data loaded. + */ + private final ILoadDisplayDataListener loadDisplayDataListener; /** * Constructor. */ - public SizeJob() { + public SizeJob(ILoadDisplayDataListener loadDisplayDataListener) { super("Size Job"); setSystem(true); + this.loadDisplayDataListener = loadDisplayDataListener; } /** @@ -285,9 +292,11 @@ public class SizeJob extends Job { * Check all displayData selection state so only the data in selections are * set. * - * @param selections + * @param selectName + * @param type + * @return errorMessage when unable to load else null */ - public void loadSelect(String selectName, ArchiveConstants.Type type) { + public String loadSelect(String selectName, ArchiveConstants.Type type) { ArchiveConfigManager manager = ArchiveConfigManager.getInstance(); String fileName = ArchiveConstants.selectFileName(type, selectName); SelectConfig selections = manager.loadSelection(fileName); @@ -301,24 +310,18 @@ public class SizeJob extends Job { for (String categoryName : archiveInfo.getCategoryNames()) { Set selectionsSet = selections.getSelectedSet( archiveName, categoryName); - MissingData missingData = removeMissingData(archiveName, - categoryName); - if (missingData != null) { - missingData.setSelectedSet(selectionsSet); - addMissingData(missingData); - } else { - CategoryInfo categoryInfo = archiveInfo.get(categoryName); - for (DisplayData displayData : categoryInfo - .getDisplayDataList()) { - String displayLabel = displayData.getDisplayLabel(); - boolean selected = selectionsSet.contains(displayLabel); - if (selected != displayData.isSelected()) { - setSelect(displayData, selected); - } + CategoryInfo categoryInfo = archiveInfo.get(categoryName); + for (DisplayData displayData : categoryInfo + .getDisplayDataList()) { + String displayLabel = displayData.getDisplayLabel(); + boolean selected = selectionsSet.contains(displayLabel); + if (selected != displayData.isSelected()) { + setSelect(displayData, selected); } } } } + return null; } /** @@ -327,10 +330,13 @@ public class SizeJob extends Job { * @return selected */ public List getSelectAll() { - synchronized (missingDataQueue) { - while (!missingDataQueue.isEmpty()) { - if (missingDataJob.currentMissingData == null - || missingDataJob.currentMissingData.isSelected()) { + synchronized (loadDisplayDataQueue) { + while (!loadDisplayDataQueue.isEmpty()) { + if ((loadDisplayDataJob.currentLoadDisplayData == null) + || loadDisplayDataJob.currentLoadDisplayData + .isVisible() + || loadDisplayDataJob.currentLoadDisplayData + .isSelected()) { missingDataQueueWait(); } else { break; @@ -440,33 +446,81 @@ public class SizeJob extends Job { } /** - * Change the archive/category display. * * @param archiveName + * - non null value * @param categoryName - * @return displayData when display needs to change otherwise null + * - non null value + * @return true if archiveName and categoryName match the current display + */ + public boolean isCurrentDisplay(String archiveName, String categoryName) { + return archiveName.equals(displayArchive) + && categoryName.equals(displayCategory); + } + + /** + * This method returns a display data list to replace the contents of the + * GUI's achive/category display table or a null list if no update is + * needed. It is assumed this method is called from an non-UI thread. + * + * @param archiveName + * - archive for the new display table + * @param categoryName + * - category for the new display table + * @param shutdown + * - Becomes true when user requests a different table while this + * is waiting for data. + * @return displayData */ public List changeDisplay(String archiveName, - String categoryName) { + String categoryName, AtomicBoolean shutdown) { List displayDatas = null; + + // Only get data when the display really needs to be changed. if (!archiveName.equals(displayArchive) || !categoryName.equals(displayCategory)) { - MissingData missingData = removeMissingData(archiveName, + + // Update visible status of current display. + if ((displayArchive != null) && (displayCategory != null)) { + LoadDisplayData currentMissingData = removeLoadDisplayData( + displayArchive, displayCategory); + if (currentMissingData != null) { + currentMissingData.setVisible(false); + addLoadDisplayData(currentMissingData); + } + } + + LoadDisplayData missingData = removeLoadDisplayData(archiveName, categoryName); + displayArchive = archiveName; + displayCategory = categoryName; + + // Update visible status of the new current display. if (missingData != null) { - missingData.setVisiable(true); - synchronized (missingDataQueue) { - addMissingData(missingData); - while (missingDataQueue.contains(missingData)) { - missingDataQueueWait(); + synchronized (loadDisplayDataQueue) { + missingData.setVisible(true); + addLoadDisplayData(missingData); + + /* + * Wait for the display data to be loaded or no longer + * needed. + */ + while (loadDisplayDataJob.processing(missingData) + && !shutdown.get()) { + missingDataQueueWait(500L); } } } - displayDatas = archiveInfoMap.get(archiveName).get(categoryName) - .getDisplayDataList(); - displayArchive = archiveName; - displayCategory = categoryName; - changeDisplay(displayDatas); + + /* + * If user still needs the data update status of old visible data + * and the new visible data. + */ + if (!shutdown.get()) { + displayDatas = archiveInfoMap.get(archiveName) + .get(categoryName).getDisplayDataList(); + changeDisplay(displayDatas); + } } return displayDatas; } @@ -474,7 +528,7 @@ public class SizeJob extends Job { /** * Change to display all selected data.. * - * @return displayhData when display needs to change otherwise null. + * @return displayData when display needs to change otherwise null. */ public List changeDisplayAll() { List selectedData = null; @@ -499,7 +553,7 @@ public class SizeJob extends Job { } iRetentionHour.setRetentionTimes(selections.getStarRetentionHours()); - missingDataQueue.clear(); + loadDisplayDataQueue.clear(); visibleList = manager.getDisplayData(displayArchive, displayCategory, false); @@ -527,51 +581,48 @@ public class SizeJob extends Job { } else { selectedSet = selections.getSelectedSet(archiveName, categoryName); - MissingData missingData = new MissingData(archiveName, - categoryName, selectedSet); - missingDataQueue.add(missingData); + LoadDisplayData missingData = new LoadDisplayData( + archiveName, categoryName, selectedSet); + loadDisplayDataQueue.add(missingData); } } put(archiveName, archiveInfo); } - missingDataJob.schedule(); + loadDisplayDataJob = new LoadDisplayDataJob(loadDisplayDataListener, + loadDisplayDataQueue.size()); + + loadDisplayDataJob.schedule(); return selections.getName(); } /** - * Find and remove the missing data from the missing data queue. + * Find and remove the associated load display data from the queue. * * @param archiveName * @param categoryName - * @return missingData or null if not on the missing data queue + * @return loadDisplayData or null if no longer on the queue */ - private MissingData removeMissingData(String archiveName, + private LoadDisplayData removeLoadDisplayData(String archiveName, String categoryName) { - MissingData missingData = null; - synchronized (missingDataQueue) { - if (missingDataJob.currentMissingData != null - && archiveName - .equals(missingDataJob.currentMissingData.archive) - && categoryName - .equals(missingDataJob.currentMissingData.category)) { - // Finish the process of getting the data. - missingDataQueueWait(); - } else if (!missingDataQueue.isEmpty()) { - Iterator iterator = missingDataQueue.iterator(); + LoadDisplayData loadDisplayData = null; + synchronized (loadDisplayDataQueue) { + if (!loadDisplayDataQueue.isEmpty()) { + Iterator iterator = loadDisplayDataQueue + .iterator(); while (iterator.hasNext()) { - MissingData md = iterator.next(); + LoadDisplayData md = iterator.next(); if (md.archive.equals(archiveName) && md.category.equals(categoryName)) { iterator.remove(); - missingData = md; + loadDisplayData = md; break; } } } } - return missingData; + return loadDisplayData; } /** @@ -580,9 +631,20 @@ public class SizeJob extends Job { * @return false when interrupted exception */ private boolean missingDataQueueWait() { + return missingDataQueueWait(0L); + } + + /** + * Wait for notification that the current missing data is finished + * processing or the desired time has lapsed. + * + * @param time + * @return false when interrupted exception + */ + private boolean missingDataQueueWait(long time) { boolean state = true; try { - missingDataQueue.wait(); + loadDisplayDataQueue.wait(time); } catch (InterruptedException e) { state = false; statusHandler.handle(Priority.INFO, e.getLocalizedMessage(), e); @@ -591,32 +653,30 @@ public class SizeJob extends Job { } /** + * This inserts a load display data onto the queue. Should * - * @param missingData + * @param loadDisplayData */ - private void addMissingData(MissingData missingData) { - synchronized (missingDataQueue) { - missingDataQueue.add(missingData); - if (missingDataJob.getState() == Job.NONE) { - missingDataJob.schedule(); + private void addLoadDisplayData(LoadDisplayData loadDisplayData) { + synchronized (loadDisplayDataQueue) { + loadDisplayDataQueue.add(loadDisplayData); + if (loadDisplayDataJob.getState() == Job.NONE) { + loadDisplayDataJob.schedule(); } } } /** - * Change update visible to the new list. + * Change visible status to reflect the new list. * * @param newDisplays */ private void changeDisplay(List newDisplays) { List oldDisplays = visibleList; visibleList = newDisplays; - List visibleList = new ArrayList(newDisplays); for (DisplayData displayData : oldDisplays) { - if (!visibleList.remove(displayData)) { - setVisible(displayData, false); - } + setVisible(displayData, false); } for (DisplayData displayData : visibleList) { @@ -761,25 +821,25 @@ public class SizeJob extends Job { @Override protected void canceling() { clearQueue(); - missingDataQueue.clear(); - missingDataJob.cancel(); + loadDisplayDataQueue.clear(); + loadDisplayDataJob.cancel(); shutdown.set(true); } /** - * Class used by the missing data job to obtain display data for given - * archive/category off the UI thread. + * Class used to track missing display data for the archive/category tables. + * Allowing the information to be retrieved in a non-UI thread. */ - private static class MissingData { + private static class LoadDisplayData { protected final String archive; protected final String category; protected final Set selectedSet; - protected boolean visiable = false; + protected boolean visible = false; - public MissingData(String archive, String category, + public LoadDisplayData(String archive, String category, Set selectedSet) { this.archive = archive; this.category = category; @@ -790,21 +850,20 @@ public class SizeJob extends Job { return !selectedSet.isEmpty(); } - public void setVisiable(boolean state) { - this.visiable = state; + public boolean isVisible() { + return visible; } - public void setSelectedSet(Set selectedSet) { - this.selectedSet.clear(); - this.selectedSet.addAll(selectedSet); + public void setVisible(boolean state) { + this.visible = state; } @Override public String toString() { - StringBuilder sb = new StringBuilder("MissingData["); + StringBuilder sb = new StringBuilder("LoadDisplayData["); sb.append("archive: ").append(archive); sb.append(", category: ").append(category); - sb.append(", visible: ").append(visiable); + sb.append(", visible: ").append(isVisible()); sb.append(", isSelected: ").append(isSelected()); sb.append("]"); return sb.toString(); @@ -815,14 +874,34 @@ public class SizeJob extends Job { * This handles getting the display data in the missing data queue and * queuing the results for the size job. */ - private class MissingDataJob extends Job { + private class LoadDisplayDataJob extends Job { private final AtomicBoolean shutdown = new AtomicBoolean(false); - protected MissingData currentMissingData = null; + protected LoadDisplayData currentLoadDisplayData = null; - public MissingDataJob() { - super("MissingData"); + private final ILoadDisplayDataListener loadDisplayDataListener; + + /** + * Must be set to the maximum number of LoadDisplayData to process. + * Cannot use the queue size since adjusting the queue to change the + * priority may make its size 0. This could cause the job to be + * rescheduled to finish when data added back onto the queue. + */ + private int loadDisplayDataCnt; + + /** + * The constructor. + * + * @param loadDisplayDataListener + * @param loadDisplayDataCnt + */ + public LoadDisplayDataJob( + ILoadDisplayDataListener loadDisplayDataListener, + int loadDisplayDataCnt) { + super("Loading Category labels"); + this.loadDisplayDataListener = loadDisplayDataListener; + this.loadDisplayDataCnt = loadDisplayDataCnt; } @Override @@ -834,20 +913,21 @@ public class SizeJob extends Job { ArchiveConfigManager manager = ArchiveConfigManager.getInstance(); while (!shutdown.get()) { - synchronized (missingDataQueue) { - if (currentMissingData != null) { - missingDataQueue.notifyAll(); + synchronized (loadDisplayDataQueue) { + if (currentLoadDisplayData != null) { + currentLoadDisplayData = null; + loadDisplayDataQueue.notifyAll(); + --loadDisplayDataCnt; + } + currentLoadDisplayData = loadDisplayDataQueue.poll(); + if (currentLoadDisplayData == null) { + break; } - currentMissingData = missingDataQueue.poll(); } - if (currentMissingData == null) { - break; - } - - String archiveName = currentMissingData.archive; - String categoryName = currentMissingData.category; - Set selectedSet = currentMissingData.selectedSet; + String archiveName = currentLoadDisplayData.archive; + String categoryName = currentLoadDisplayData.category; + Set selectedSet = currentLoadDisplayData.selectedSet; List displayDatas = manager.getDisplayData( archiveName, categoryName, false); if (shutdown.get()) { @@ -868,13 +948,31 @@ public class SizeJob extends Job { } } + if (loadDisplayDataCnt == 0) { + if (loadDisplayDataListener != null) { + loadDisplayDataListener.loadedAllDisplayData(); + } + } + return Status.OK_STATUS; } + /** + * + * @param loadDisplayData + * @return true when missingData still needs to be processed. + */ + public boolean processing(LoadDisplayData loadDisplayData) { + synchronized (loadDisplayDataQueue) { + return loadDisplayDataQueue.contains(loadDisplayData) + || loadDisplayData.equals(currentLoadDisplayData); + + } + } + @Override protected void canceling() { shutdown.set(true); } } - } \ No newline at end of file diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/AbstractArchiveDlg.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/AbstractArchiveDlg.java index 7cb9486838..a095803415 100644 --- a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/AbstractArchiveDlg.java +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/AbstractArchiveDlg.java @@ -22,6 +22,7 @@ package com.raytheon.uf.viz.archive.ui; import java.util.ArrayList; import java.util.Calendar; import java.util.List; +import java.util.concurrent.atomic.AtomicBoolean; import java.util.concurrent.atomic.AtomicInteger; import org.eclipse.core.runtime.IProgressMonitor; @@ -53,6 +54,7 @@ import com.raytheon.uf.common.util.SizeUtil; import com.raytheon.uf.viz.archive.data.ArchiveInfo; import com.raytheon.uf.viz.archive.data.CategoryInfo; import com.raytheon.uf.viz.archive.data.IArchiveTotals; +import com.raytheon.uf.viz.archive.data.ILoadDisplayDataListener; import com.raytheon.uf.viz.archive.data.IRetentionHour; import com.raytheon.uf.viz.archive.data.IUpdateListener; import com.raytheon.uf.viz.archive.data.SizeJob; @@ -79,6 +81,7 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * Dec 11, 2013 2624 rferrel No longer clear table prior to populating. * Apr 15, 2014 3034 lvenable Added dispose checks in runAsync calls. * Apr 10, 2014 3023 rferrel Added setTotalSelectedSize method. + * Apr 23, 2014 3045 rferrel Changes to prevent race condition while getting labels. * * * @@ -87,7 +90,8 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; */ public abstract class AbstractArchiveDlg extends CaveSWTDialog implements - IArchiveTotals, IUpdateListener, IModifyListener, IRetentionHour { + IArchiveTotals, IUpdateListener, IModifyListener, IRetentionHour, + ILoadDisplayDataListener { /** Table composite that holds the table controls. */ private ArchiveTableComp tableComp; @@ -115,7 +119,7 @@ public abstract class AbstractArchiveDlg extends CaveSWTDialog implements /** * Job that computes sizes of table row entries off the UI thread. */ - protected final SizeJob sizeJob = new SizeJob(); + protected final SizeJob sizeJob = new SizeJob(this); /** Keeps track of when it is safe to clear the busy cursor. */ protected final AtomicInteger busyCnt = new AtomicInteger(0); @@ -139,6 +143,9 @@ public abstract class AbstractArchiveDlg extends CaveSWTDialog implements private String previousSelectedCategory = null; + /** Job running to populate the currently selected archive/category. */ + private Job populateTableJob = null; + /** * @param parentShell */ @@ -365,6 +372,9 @@ public abstract class AbstractArchiveDlg extends CaveSWTDialog implements protected void disposed() { sizeJob.removeUpdateListener(this); sizeJob.cancel(); + if (populateTableJob != null) { + populateTableJob.cancel(); + } } /** @@ -463,12 +473,17 @@ public abstract class AbstractArchiveDlg extends CaveSWTDialog implements } /** - * Load a select configuration file. + * Load selected configuration file. * * @param selectName */ - protected void loadSelect(String selectName) { - sizeJob.loadSelect(selectName, type); + protected boolean loadSelect(String selectName) { + String message = sizeJob.loadSelect(selectName, type); + if (message != null) { + MessageDialog.openError(shell, "Unable to load Case", message); + return false; + } + return true; } /** @@ -483,15 +498,39 @@ public abstract class AbstractArchiveDlg extends CaveSWTDialog implements setShowingSelected(false); - Job job = new Job("populate category table") { + if (populateTableJob != null) { + populateTableJob.cancel(); + setCursorBusy(false); + } + + populateTableJob = new Job("populate category table") { + private AtomicBoolean shutdown = new AtomicBoolean(false); @Override protected IStatus run(IProgressMonitor monitor) { - getCategoryTableData(archiveName, categoryName); + getCategoryTableData(archiveName, categoryName, shutdown); + + // Just populated the current table update cursor. + if (!shutdown.get()) { + populateTableJob = null; + VizApp.runAsync(new Runnable() { + + @Override + public void run() { + setCursorBusy(false); + } + }); + } return Status.OK_STATUS; } + + @Override + protected void canceling() { + shutdown.set(true); + } + }; - job.schedule(); + populateTableJob.schedule(); } /** @@ -501,12 +540,25 @@ public abstract class AbstractArchiveDlg extends CaveSWTDialog implements * * @param archiveName * @param categoryName + * @param shutdown */ private void getCategoryTableData(final String archiveName, - final String categoryName) { + final String categoryName, final AtomicBoolean shutdown) { + + if (!sizeJob.isCurrentDisplay(archiveName, categoryName)) { + VizApp.runAsync(new Runnable() { + + @Override + public void run() { + if (!isDisposed()) { + tableComp.clearTable(); + } + } + }); + } final List displayDatas = sizeJob.changeDisplay( - archiveName, categoryName); + archiveName, categoryName, shutdown); VizApp.runAsync(new Runnable() { @@ -517,15 +569,11 @@ public abstract class AbstractArchiveDlg extends CaveSWTDialog implements return; } - try { - if (displayDatas != null) { - tableComp.populateTable(archiveName, categoryName, - displayDatas); - } else { - tableComp.refresh(); - } - } finally { - setCursorBusy(false); + if (displayDatas != null) { + tableComp.populateTable(archiveName, categoryName, + displayDatas); + } else { + tableComp.refresh(); } } }); @@ -537,11 +585,14 @@ public abstract class AbstractArchiveDlg extends CaveSWTDialog implements * @param state */ protected void setCursorBusy(boolean state) { - if (state) { - busyCnt.addAndGet(1); - shell.setCursor(shell.getDisplay().getSystemCursor(SWT.CURSOR_WAIT)); - } else if (busyCnt.addAndGet(-1) == 0) { - shell.setCursor(null); + if (!shell.isDisposed()) { + if (state) { + busyCnt.addAndGet(1); + shell.setCursor(shell.getDisplay().getSystemCursor( + SWT.CURSOR_WAIT)); + } else if (busyCnt.addAndGet(-1) == 0) { + shell.setCursor(null); + } } } @@ -786,6 +837,11 @@ public abstract class AbstractArchiveDlg extends CaveSWTDialog implements return errorMsg == null; } + /** + * Allows sub-class to perform updates once all the display data is loaded. + */ + abstract public void loadedAllDisplayData(); + /** * When unsaved modifications this asks the user to verify the close. * diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveRetentionDlg.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveRetentionDlg.java index 04662713eb..1428d288a7 100644 --- a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveRetentionDlg.java +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveRetentionDlg.java @@ -57,6 +57,7 @@ import com.raytheon.uf.common.time.util.TimeUtil; * Oct 01, 2013 #2147 rferrel Change getEnd() to pick up files with future time stamps. * Oct 07, 2013 #2438 rferrel Properly save and load retention times. * Apr 14, 2014 #3023 rferrel Code clean up. + * Apr 24, 2014 #3045 rferrel Implement loadedAllDsipalyData. * * * @@ -415,4 +416,9 @@ public class ArchiveRetentionDlg extends AbstractArchiveDlg { archiveComboSelection(); categoryComboSelection(); } + + @Override + public void loadedAllDisplayData() { + // nothing to update. + } } diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveTableComp.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveTableComp.java index fab9434476..a11a6c90a6 100644 --- a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveTableComp.java +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveTableComp.java @@ -19,6 +19,7 @@ **/ package com.raytheon.uf.viz.archive.ui; +import java.util.ArrayList; import java.util.Arrays; import java.util.List; import java.util.concurrent.CopyOnWriteArrayList; @@ -63,6 +64,7 @@ import com.raytheon.uf.viz.archive.data.SizeJob; * Aug 06, 2013 #2222 rferrel Changes to display all selected data. * Aug 14, 2013 #2220 rferrel Add refresh method. * Aug 26, 2013 #2225 rferrel Add missing updates. + * Apr 23, 2014 #3045 rferrel Added clearTable method. * * * @@ -468,6 +470,13 @@ public class ArchiveTableComp extends Composite { populateTable(displayDatas); } + /** + * Clear table entries. + */ + protected void clearTable() { + populateTable(new ArrayList(0)); + } + /** * Flag table as showing all selected data and update display. * diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationDlg.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationDlg.java index 06f445f4a0..4d201d27ec 100644 --- a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationDlg.java +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationDlg.java @@ -72,6 +72,8 @@ import com.raytheon.viz.ui.dialogs.ICloseCallback; * Aug 06, 2013 #2222 rferrel Changes to display all selected data. * Aug 26, 2013 #2225 rferrel Make perspective independent and no longer modal. * Apr 11, 2014 #3023 rferrel Configurable Threshold options. + * Apr 23, 2014 #3045 rferrel To prevent race condition only allow a case + * load after all labels are loaded. * * * @@ -166,6 +168,9 @@ public class CaseCreationDlg extends AbstractArchiveDlg { /** Manager for configurable values for the dialog. */ private final CaseCreationManager ccManager; + /** Flag to indicate all labels for all tables are loaded. */ + private volatile boolean haveAllLabels = false; + /** * Constructor. * @@ -490,34 +495,48 @@ public class CaseCreationDlg extends AbstractArchiveDlg { // } // }); + String tooltip = "Waiting on loading of table labels."; + Color color = shell.getDisplay().getSystemColor(SWT.COLOR_YELLOW); saveBtn = new Button(actionControlComp, SWT.PUSH); saveBtn.setText(" Save "); saveBtn.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent selectionEvent) { - saveSelection(selectName); - clearModified(); + if (haveAllLabels) { + saveSelection(selectName); + clearModified(); + } } }); + saveBtn.setToolTipText(tooltip); saveBtn.setEnabled(false); + saveBtn.setBackground(color); saveAsBtn = new Button(actionControlComp, SWT.PUSH); saveAsBtn.setText(" Save As... "); saveAsBtn.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent selectionEvent) { - handleSaveAsCase(); + if (haveAllLabels) { + handleSaveAsCase(); + } } }); + saveAsBtn.setToolTipText(tooltip); + saveAsBtn.setBackground(color); loadBtn = new Button(actionControlComp, SWT.PUSH); loadBtn.setText(" Load... "); loadBtn.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent selectionEvent) { - handleLoadCase(); + if (haveAllLabels) { + handleLoadCase(); + } } }); + loadBtn.setToolTipText(tooltip); + loadBtn.setBackground(color); deleteBtn = new Button(actionControlComp, SWT.PUSH); deleteBtn.setText(" Delete... "); @@ -606,11 +625,12 @@ public class CaseCreationDlg extends AbstractArchiveDlg { public void dialogClosed(Object returnValue) { if (returnValue instanceof String) { String name = returnValue.toString(); - loadSelect(name); - populateTableComp(); - updateTotals(null); - setSelectName(name); - clearModified(); + if (loadSelect(name)) { + populateTableComp(); + updateTotals(null); + setSelectName(name); + clearModified(); + } } } }); @@ -1059,4 +1079,40 @@ public class CaseCreationDlg extends AbstractArchiveDlg { super.clearModified(); saveBtn.setEnabled(false); } + + /* + * (non-Javadoc) + * + * @see com.raytheon.uf.viz.archive.ui.AbstractArchiveDlg#haveAllLabels() + */ + @Override + public void loadedAllDisplayData() { + haveAllLabels = true; + + /* + * Restore the buttons' default background color and tooltip text. The + * buttons color is not the system standard and the tool tip text + * indicates it is waiting for the labels to be loaded. + */ + VizApp.runAsync(new Runnable() { + + @Override + public void run() { + if (!isDisposed()) { + saveBtn.setBackground(null); + saveBtn.setToolTipText(null); + saveAsBtn.setBackground(null); + saveAsBtn.setToolTipText(null); + loadBtn.setBackground(null); + loadBtn.setToolTipText(null); + } + } + }); + } + + @Override + protected boolean isModified() { + return super.isModified(); + } + } diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseLoadSaveDeleteDlg.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseLoadSaveDeleteDlg.java index 3dd68b9058..a374461259 100644 --- a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseLoadSaveDeleteDlg.java +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseLoadSaveDeleteDlg.java @@ -116,7 +116,7 @@ public class CaseLoadSaveDeleteDlg extends CaveSWTDialog { private void init() { createCaseControls(); GuiUtil.addSeparator(shell, SWT.HORIZONTAL); - createBottomAcitonButtons(); + createBottomActionButtons(); } /** @@ -151,7 +151,7 @@ public class CaseLoadSaveDeleteDlg extends CaveSWTDialog { /** * Button layout at the bottom of the dialog. */ - private void createBottomAcitonButtons() { + private void createBottomActionButtons() { Composite actionControlComp = new Composite(shell, SWT.NONE); GridLayout gl = new GridLayout(2, false); GridData gd = new GridData(SWT.FILL, SWT.DEFAULT, true, false); From 6cbd35aa476d4ff93f0d5f61debed9dcd820b144 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Thu, 24 Apr 2014 15:04:54 -0500 Subject: [PATCH 099/188] Issue #2060 remove dependency on grid dataURI column from more of DAT Change-Id: I9123d2508f359e65124f90dafdfdf5efeaf1241a Former-commit-id: e7963b0bcea141f33a00c264b26ae264d00f3abf --- .../common/dataplugin/scan/ScanException.java | 73 +++++++ .../raytheon/uf/edex/dat/utils/DATUtils.java | 86 +++----- .../uf/edex/dat/utils/FreezingLevel.java | 206 ++++++++++-------- .../uf/edex/database/query/DatabaseQuery.java | 26 ++- .../edex/plugin/cwat/common/CWATConfig.java | 26 ++- .../edex/plugin/ffmp/common/FFMPConfig.java | 11 +- .../uf/edex/plugin/qpf/common/QPFConfig.java | 34 ++- .../edex/plugin/scan/ScanGridRecordSet.java | 113 ++++++++++ .../uf/edex/plugin/scan/ScanURIFilter.java | 167 +++++--------- .../edex/plugin/scan/process/CAPEProduct.java | 24 +- .../plugin/scan/process/GH1000Product.java | 10 +- .../plugin/scan/process/GH500Product.java | 10 +- .../edex/plugin/scan/process/GridProduct.java | 103 ++++++--- .../edex/plugin/scan/process/HELIProduct.java | 11 +- .../edex/plugin/scan/process/U500Product.java | 10 +- .../edex/plugin/scan/process/U700Product.java | 10 +- .../edex/plugin/scan/process/V700Product.java | 10 +- 17 files changed, 592 insertions(+), 338 deletions(-) create mode 100644 edexOsgi/com.raytheon.uf.common.dataplugin.scan/src/com/raytheon/uf/common/dataplugin/scan/ScanException.java create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/ScanGridRecordSet.java diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.scan/src/com/raytheon/uf/common/dataplugin/scan/ScanException.java b/edexOsgi/com.raytheon.uf.common.dataplugin.scan/src/com/raytheon/uf/common/dataplugin/scan/ScanException.java new file mode 100644 index 0000000000..c092852362 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.scan/src/com/raytheon/uf/common/dataplugin/scan/ScanException.java @@ -0,0 +1,73 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.common.dataplugin.scan; + +/** + * Exception specific to SCAN + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 24, 2014            njensen     Initial creation
+ * 
+ * 
+ * + * @author njensen + * @version 1.0 + */ + +public class ScanException extends Exception { + + private static final long serialVersionUID = 1L; + + /** + * Default Constructor + * + */ + public ScanException() { + super(); + } + + /** + * @param message + */ + public ScanException(String message) { + super(message); + } + + /** + * @param message + * @param cause + */ + public ScanException(String message, Throwable cause) { + super(message, cause); + } + + /** + * @param cause + */ + public ScanException(Throwable cause) { + super(cause); + } + +} diff --git a/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/DATUtils.java b/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/DATUtils.java index 0b64cbd375..3143b8f76a 100644 --- a/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/DATUtils.java +++ b/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/DATUtils.java @@ -52,6 +52,7 @@ import com.raytheon.uf.edex.database.plugin.PluginFactory; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * 06/22/09 2152 D. Hladky Initial release + * Apr 24, 2014 2060 njensen Updates for removal of grid dataURI column * * * @@ -69,8 +70,7 @@ public class DATUtils { * @param uri * @return */ - public static PluginDataObject getPDORecord(String uri, SourceXML xml) - throws PluginException { + public static PluginDataObject getPDORecord(String uri, SourceXML xml) { PluginDataObject rec = null; try { Class clazz = Class.forName(xml.getPluginClass()); @@ -104,19 +104,7 @@ public class DATUtils { gr = (GridRecord) gd.getMetadata(uri); if (gr != null) { - - IDataStore dataStore = gd.getDataStore(gr); - - try { - IDataRecord[] dataRec = dataStore.retrieve(uri); - for (int i = 0; i < dataRec.length; i++) { - if (dataRec[i] instanceof FloatDataRecord) { - gr.setMessageData(dataRec[i]); - } - } - } catch (Exception se) { - logger.error("No Grib record found....."); - } + populateGridRecord(gr); } else { logger.error("URI: " + uri + " Not in Database..."); } @@ -125,31 +113,27 @@ public class DATUtils { } /** - * Make a DB request + * Fills a GridRecord with the raw data retrieved from IDataStore * - * @param sql - * @return + * @param gr + * @throws PluginException */ - public static Object[] dbRequest(String sql) { - - logger.debug("SQL to run: " + sql); - CoreDao cdao = null; - Object[] results = null; - try { - if (cdao == null) { - try { - cdao = new CoreDao(DaoConfig.DEFAULT); - } catch (Exception ed1) { - logger.error("Core DAO access failed. " + ed1); + public static void populateGridRecord(GridRecord gr) throws PluginException { + if (gr != null) { + PluginDao gd = PluginFactory.getInstance().getPluginDao( + gr.getPluginName()); + IDataStore dataStore = gd.getDataStore(gr); + try { + IDataRecord[] dataRec = dataStore.retrieve(gr.getDataURI()); + for (int i = 0; i < dataRec.length; i++) { + if (dataRec[i] instanceof FloatDataRecord) { + gr.setMessageData(dataRec[i]); + } } + } catch (Exception e) { + logger.error("Error retrieving grid data for " + gr, e); } - results = cdao.executeSQLQuery(sql); - - } catch (Exception ed2) { - logger.error("SQL Query Failed to process. SQL=" + sql + " : " - + ed2); } - return results; } /** @@ -159,7 +143,9 @@ public class DATUtils { * @param startTime * @param endTime * @return + * @deprecated Nothing seems to be calling this.... */ + @Deprecated public static FFMPVirtualGageBasin getVirtualBasinData(String lid, FFMPVirtualGageBasin vgb, String endTime, String startTime) { @@ -229,13 +215,6 @@ public class DATUtils { } } - int totalDurations = 0; - for (int dur : durations) { - totalDurations += dur; - } - - int avDuration = totalDurations / durations.size(); - float totalVals = 0.0f; for (float val : values) { totalVals += val; @@ -263,20 +242,18 @@ public class DATUtils { * @param param * @return */ - public static GridRecord getMostRecentGridRecord(int interval, String sql, - SCANModelParameterXML param) { - + public static GridRecord getMostRecentGridRecord(int interval, + GridRecord newRec, SCANModelParameterXML param) { GridRecord rec = null; try { ScanDataCache cache = ScanDataCache.getInstance(); - Object[] obs = dbRequest(sql); - GridRecord newRec = null; - - if (obs != null && obs.length > 0) { - String uri = (String) obs[0]; - newRec = getGridRecord(uri); - } + /* + * TODO njensen: we should only spend time populating if the new rec + * replaces the old rec. Delaying that change as at present as I'm + * just trying to make it work the same as before. + */ + populateGridRecord(newRec); if (cache.getModelData().isType(param.getModelName(), param.getParameterName())) { @@ -304,9 +281,8 @@ public class DATUtils { } } } catch (Exception e) { - logger.error("DatUtils: " + param.getModelName() + ": " - + param.getParameterName() + " SQL: " + sql - + " error in retrieval.."); + logger.error("Error in retrieval: " + param.getModelName() + ": " + + param.getParameterName() + " record: " + newRec); } return rec; diff --git a/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java b/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java index 1415a59ff2..535f2d11f0 100644 --- a/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java +++ b/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java @@ -19,21 +19,21 @@ package com.raytheon.uf.edex.dat.utils; * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -import java.text.SimpleDateFormat; import java.util.ArrayList; import java.util.Calendar; import java.util.Date; import java.util.HashMap; import java.util.Iterator; import java.util.LinkedHashMap; +import java.util.List; import java.util.Map.Entry; import java.util.TreeSet; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; import org.geotools.coverage.grid.GridGeometry2D; import org.geotools.geometry.DirectPosition2D; import org.opengis.referencing.crs.CoordinateReferenceSystem; -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.datastorage.records.FloatDataRecord; @@ -41,6 +41,9 @@ import com.raytheon.uf.common.geospatial.ISpatialObject; import com.raytheon.uf.common.geospatial.MapUtil; import com.raytheon.uf.common.geospatial.PointUtil; import com.raytheon.uf.common.monitor.xml.SCANModelParameterXML; +import com.raytheon.uf.edex.database.plugin.PluginDao; +import com.raytheon.uf.edex.database.plugin.PluginFactory; +import com.raytheon.uf.edex.database.query.DatabaseQuery; import com.vividsolutions.jts.geom.Coordinate; /** @@ -56,6 +59,7 @@ import com.vividsolutions.jts.geom.Coordinate; * 19Nov 2011 dhladky Initial creation * 29 Jan 2013 15729 wkwock fix the algorithm * Jan 07, 2013 njensen Change some logs to debug + * Apr 24, 2014 2060 njensen Updates for removal of grid dataURI column * * * @@ -86,8 +90,9 @@ public class FreezingLevel { // reference time Calendar refTime = null; + private transient final Log logger = LogFactory.getLog(getClass()); - + public FreezingLevel(String modelName) { this.modelName = modelName; times = new HashMap(); @@ -112,72 +117,80 @@ public class FreezingLevel { /** * find (x,y) coordinate for lat,lon(coor) + * * @param coors */ - public DirectPosition2D findXYloc(Coordinate coor, String type){ + public DirectPosition2D findXYloc(Coordinate coor, String type) { ScanDataCache cache = ScanDataCache.getInstance(); - ISpatialObject iso = cache.getModelData().getGridRecord(modelName, type).getSpatialObject(); - CoordinateReferenceSystem crs=iso.getCrs(); + ISpatialObject iso = cache.getModelData() + .getGridRecord(modelName, type).getSpatialObject(); + CoordinateReferenceSystem crs = iso.getCrs(); GridGeometry2D mapGeometry = MapUtil.getGridGeometry(iso); DirectPosition2D resultPoint; try { - resultPoint = PointUtil.determineExactIndex( - coor, crs, mapGeometry); - return resultPoint; - } catch (Exception e) { - logger.error("Error: Freezing level -- unable to find x,y coordinate for lat,lon:"+coor); + resultPoint = PointUtil.determineExactIndex(coor, crs, mapGeometry); + return resultPoint; + } catch (Exception e) { + logger.error("Error: Freezing level -- unable to find x,y coordinate for lat,lon:" + + coor); } - return null; + return null; } - + /** * get the bi-linear interpolation value amount the nearest 4 points * - * @param modelName, prodType, coor + * @param modelName + * , prodType, coor * @return bi-linear interpolation amount the nearest 4 points * @throws VizException */ public Double getValue(String modelName, String prodType, Coordinate coor) { double value = -99999.0; try { - //xyLoc is the location in x,y - DirectPosition2D xyLoc = findXYloc(coor, prodType); + // xyLoc is the location in x,y + DirectPosition2D xyLoc = findXYloc(coor, prodType); - //data from hdf5 - ScanDataCache cache = ScanDataCache.getInstance(); - GridRecord gribRec = cache.getModelData().getGridRecord(modelName, prodType); + // data from hdf5 + ScanDataCache cache = ScanDataCache.getInstance(); + GridRecord gribRec = cache.getModelData().getGridRecord(modelName, + prodType); FloatDataRecord rec = (FloatDataRecord) gribRec.getMessageData(); - - //dimension of the record from hdf5, recNx =151 and recNy=113 during development + + // dimension of the record from hdf5, recNx =151 and recNy=113 + // during development int recNx = gribRec.getSpatialObject().getNx(); - - //get four nearest points/values form the record around xyLoc - xyLoc.y=xyLoc.y * 0.9941; //A special adjustment due to PointUtil.determineExactIndex - xyLoc.x=xyLoc.x * 0.9983; // is not as accurate as A1 - int x0=(int)(xyLoc.x); - int x1=x0+1; - int y0=(int)(xyLoc.y); - int y1=y0+1; + // get four nearest points/values form the record around xyLoc + xyLoc.y = xyLoc.y * 0.9941; // A special adjustment due to + // PointUtil.determineExactIndex + xyLoc.x = xyLoc.x * 0.9983; // is not as accurate as A1 + + int x0 = (int) (xyLoc.x); + int x1 = x0 + 1; + int y0 = (int) (xyLoc.y); + int y1 = y0 + 1; + + double p1 = xyLoc.x - x0; + double p2 = 1 - p1; + double p3 = xyLoc.y - y0; + double p4 = 1 - p3; - double p1=xyLoc.x-x0; - double p2=1-p1; - double p3=xyLoc.y-y0; - double p4=1-p3; - double value0 = rec.getFloatData()[(recNx * y0) + x0]; double value1 = rec.getFloatData()[(recNx * y0) + x1]; double value2 = rec.getFloatData()[(recNx * y1) + x0]; double value3 = rec.getFloatData()[(recNx * y1) + x1]; - //do a bi-linear interpolation amount the nearest 4 points - value = (p1*p4*value1)+(p2*p4*value0)+(p1*p3*value3)+(p2*p3*value2); - logger.debug("bi-linear interpolation: "+value+"-->("+value0+","+value1+ - ","+value2+","+value3+") at "+xyLoc); + // do a bi-linear interpolation amount the nearest 4 points + value = (p1 * p4 * value1) + (p2 * p4 * value0) + + (p1 * p3 * value3) + (p2 * p3 * value2); + logger.debug("bi-linear interpolation: " + value + "-->(" + value0 + + "," + value1 + "," + value2 + "," + value3 + ") at " + + xyLoc); } catch (Exception e) { logger.error("No Grib value available....." + modelName + " " - + prodType+" lat,lon:"+coor); + + prodType + " lat,lon:" + coor); return null; } return value; @@ -194,7 +207,7 @@ public class FreezingLevel { HashMap freezingMap = new HashMap(); ScanDataCache cache = ScanDataCache.getInstance(); - //get data from hdf5 files + // get data from hdf5 files for (Coordinate coor : coors) { HashMap ghValues = new HashMap(); @@ -202,37 +215,43 @@ public class FreezingLevel { for (Entry entry : getGHLevelMap().entrySet()) { if (cache.getModelData().isType(modelName, entry.getKey())) { - ghValues.put(entry.getValue(), getValue(modelName, entry.getKey(), coor)); + ghValues.put(entry.getValue(), + getValue(modelName, entry.getKey(), coor)); } else { - ghValues.put(entry.getValue(),null); + ghValues.put(entry.getValue(), null); } } for (Entry entry : getTLevelMap().entrySet()) { if (cache.getModelData().isType(modelName, entry.getKey())) { - tValues.put(entry.getValue(), getValue(modelName, entry.getKey(), coor)); + tValues.put(entry.getValue(), + getValue(modelName, entry.getKey(), coor)); } } - - //here's the calculation + + // here's the calculation Double fLevel = 0.0; Integer jtopLevel = null; Integer ktopLevel = null; - int foundValFlag=-1;//-1=all ghValue and tValue are null, - //0=all ghValue<=-9000 and tValue<=273.16, 1=found a fLevel + int foundValFlag = -1;// -1=all ghValue and tValue are null, + // 0=all ghValue<=-9000 and tValue<=273.16, 1=found a fLevel - TreeSet ts= new TreeSet(ghValues.keySet());//want an asc sorted list + TreeSet ts = new TreeSet(ghValues.keySet());// want + // an + // asc + // sorted + // list Iterator it = ts.iterator(); - //for (Integer level : ghValues.keySet()) { + // for (Integer level : ghValues.keySet()) { while (it.hasNext()) { - Integer level = (Integer) it.next(); + Integer level = it.next(); Double tValue = tValues.get(level); Double ghValue = ghValues.get(level); - if (ghValue != null && tValue != null && foundValFlag ==-1){ - foundValFlag=0; + if (ghValue != null && tValue != null && foundValFlag == -1) { + foundValFlag = 0; } if (ghValue != null && ghValue.doubleValue() > -9000) { @@ -242,14 +261,13 @@ public class FreezingLevel { .get(ktopLevel) - ghValue) * ((273.16 - tValues .get(jtopLevel)) / (tValue - tValues .get(jtopLevel))))) * .00328; - logger.debug("***Freezing level: "+fLevel+"=" - + "(" + ghValues.get(ktopLevel) - + " - ((" + ghValues.get(ktopLevel) + " - " - + ghValue + ") * ((273.16 - " - + tValues.get(jtopLevel) + ") / (" + tValue - + " - " + tValues.get(jtopLevel) - + ")))) * .00328"); - foundValFlag=1; + logger.debug("***Freezing level: " + fLevel + "=" + "(" + + ghValues.get(ktopLevel) + " - ((" + + ghValues.get(ktopLevel) + " - " + ghValue + + ") * ((273.16 - " + tValues.get(jtopLevel) + + ") / (" + tValue + " - " + + tValues.get(jtopLevel) + ")))) * .00328"); + foundValFlag = 1; freezingMap.put(coor, fLevel.floatValue()); break; } else { @@ -258,10 +276,10 @@ public class FreezingLevel { } } } - - if (foundValFlag==0) {//this means all tValue are <= 273.16 - freezingMap.put(coor, 0.0f); - logger.debug("*** FreezingLevel = 0.0"); + + if (foundValFlag == 0) {// this means all tValue are <= 273.16 + freezingMap.put(coor, 0.0f); + logger.debug("*** FreezingLevel = 0.0"); } } @@ -343,15 +361,21 @@ public class FreezingLevel { * @param param * @return */ - private GridRecord populateRecord(String model, String param, Date refTime) { + private void populateRecord(String model, String param, Date refTime) { int interval = 1440; SCANModelParameterXML paramXML = new SCANModelParameterXML(); paramXML.setModelName(model); paramXML.setParameterName(param); - String sql = getSQL(interval, model, param, refTime); - logger.debug("Freezing level sql="+sql); - GridRecord modelRec = DATUtils.getMostRecentGridRecord(interval, sql, + GridRecord modelRec = null; + try { + modelRec = getGridRecord(interval, model, param, refTime); + } catch (Exception e) { + logger.error("Error retrieving grid record " + model + " " + param + + " " + refTime, e); + } + logger.debug("Freezing level rec=" + modelRec); + modelRec = DATUtils.getMostRecentGridRecord(interval, modelRec, paramXML); if (modelRec != null) { @@ -359,8 +383,6 @@ public class FreezingLevel { addForecastTime(fcHour); times.put(fcHour, modelRec.getDataTime().getRefTime()); } - - return modelRec; } /** @@ -432,17 +454,11 @@ public class FreezingLevel { return times; } - /** - * The SQL - * - * @return - */ - private String getSQL(int interval, String model, String param, Date refTime) { + private GridRecord getGridRecord(int interval, String model, String param, + Date refTime) throws Exception { String paramName = null; String level = null; - SimpleDateFormat sdt = new SimpleDateFormat("yyyy-MM-dd HH:00:00"); - String refTimeStr = sdt.format(refTime); if (param.startsWith("GH")) { paramName = "GH"; level = param.substring(2, param.length()); @@ -451,13 +467,29 @@ public class FreezingLevel { level = param.substring(1, param.length()); } - // Gets the most recent record of it's type - String sql = "select grid.datauri from grid, grid_info, level where grid.info_id = grid_info.id and grid_info.level_id = level.id and grid_info.parameter_abbreviation = \'" - + paramName - + "\' and grid_info.datasetId = \'" - + model - + "\' and level.masterlevel_name = 'MB' and level.levelonevalue = '" - + level + "\' and grid.reftime=\'" + refTimeStr + "\' and grid.forecasttime=0 order by grid.reftime desc limit 1"; - return sql; + DatabaseQuery dbQuery = new DatabaseQuery(GridRecord.class); + dbQuery.addQueryParam("info.datasetId", model); + dbQuery.addQueryParam("info.parameter.abbreviation", paramName); + dbQuery.addQueryParam("info.level.masterLevel.name", "MB"); + dbQuery.addQueryParam("info.level.levelonevalue", level); + dbQuery.addQueryParam("dataTime.refTime", refTime); + dbQuery.addQueryParam("dataTime.fcstTime", 0); + dbQuery.addOrder("dataTime.refTime", false); + dbQuery.setMaxResults(1); + + try { + PluginDao dao = PluginFactory.getInstance().getPluginDao("grid"); + List list = dao.queryByCriteria(dbQuery); + GridRecord result = null; + if (list != null && !list.isEmpty()) { + result = (GridRecord) list.get(0); + } + return result; + } catch (Exception e) { + throw new Exception("Error querying database for grid record " + + dbQuery, e); + } + } + } diff --git a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/query/DatabaseQuery.java b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/query/DatabaseQuery.java index 2e195101c6..3eb2eef310 100644 --- a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/query/DatabaseQuery.java +++ b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/query/DatabaseQuery.java @@ -54,6 +54,7 @@ import com.raytheon.uf.edex.database.DataAccessLayerException; * 05/29/08 #875 bphillip Initial Creation * 06/03/08 #875 bphillip Added returned fields * 09/19/08 #1531 bphillip Refactored to include join capability + * Apr 24, 2014 2060 njensen Added toString() * * * @author bphillip @@ -675,12 +676,12 @@ public class DatabaseQuery { } } } else if (parameters.get(i).getValue() instanceof List) { - for (int j = 0; j < ((List) parameters.get(i) + for (int j = 0; j < ((List) parameters.get(i) .getValue()).size(); j++) { queryString.append(QueryUtil.COLON); queryString.append(QueryUtil.QUERY_CONSTRAINT + constraintIndex++); - if (j != ((List) parameters.get(i).getValue()) + if (j != ((List) parameters.get(i).getValue()) .size() - 1) { queryString.append(QueryUtil.COMMA); } @@ -951,10 +952,12 @@ public class DatabaseQuery { } } else if (value instanceof List) { - for (int j = 0; j < ((List) value).size(); j++) { - if (((List) value).get(0) instanceof String) { - ((List) value).add(ConvertUtil.convertObject( - (String) ((List) value).remove(0), returnedClass)); + for (int j = 0; j < ((List) value).size(); j++) { + if (((List) value).get(0) instanceof String) { + ((List) value) + .add(ConvertUtil.convertObject( + (String) ((List) value).remove(0), + returnedClass)); } } } @@ -1039,4 +1042,15 @@ public class DatabaseQuery { public void setEntityName(String entityName) { this.entityName = entityName; } + + @Override + public String toString() { + return "DatabaseQuery [maxResults=" + maxResults + ", parameters=" + + parameters + ", distinctParameter=" + distinctParameter + + ", returnedFields=" + returnedFields + ", orderFields=" + + orderFields + ", joinedClasses=" + joinedClasses + + ", joinFields=" + joinFields + ", entityName=" + entityName + + "]"; + } + } diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.cwat/src/com/raytheon/uf/edex/plugin/cwat/common/CWATConfig.java b/edexOsgi/com.raytheon.uf.edex.plugin.cwat/src/com/raytheon/uf/edex/plugin/cwat/common/CWATConfig.java index b93edcfbfd..265137639e 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.cwat/src/com/raytheon/uf/edex/plugin/cwat/common/CWATConfig.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.cwat/src/com/raytheon/uf/edex/plugin/cwat/common/CWATConfig.java @@ -42,6 +42,7 @@ import com.raytheon.uf.common.monitor.xml.SCANModelParameterXML; import com.raytheon.uf.common.monitor.xml.SCANSiteXML; import com.raytheon.uf.common.serialization.SerializationException; import com.raytheon.uf.common.sounding.VerticalSounding; +import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.edex.dat.utils.DATUtils; import com.raytheon.uf.edex.dat.utils.ScanDataCache; import com.raytheon.uf.edex.plugin.cwat.CWATGenerator; @@ -55,13 +56,14 @@ import com.vividsolutions.jts.geom.Coordinate; /** * CWATConfig object * - * Hold config for CWAT Generator + * Config for CWAT Generator * *
  * SOFTWARE HISTORY
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
- * 06/02/2009   2037       dhladky    Initial Creation.
+ * 06/02/2009   2037       dhladky     Initial Creation.
+ * Apr 24, 2014  2060      njensen     Updates for removal of grid dataURI column
  * 
  * 
* @@ -560,19 +562,29 @@ public class CWATConfig { SCANModelParameterXML param500U = siteXML .getModelParameter("U500"); - // check back for a couple hours - int interval = 1440; + int interval = TimeUtil.MINUTES_PER_DAY; + /* + * FIXME the inner calls to ####Product.getGridProduct below + * will always return null. The second parameter is supposed to + * be the model (e.g. RUC130) but is passing in the parameter. + * + * Despite this problem, the code continues to function without + * exceptions because the call to + * DATUtils.getMostRecentGridRecord() will see the null record + * and then return the cached record, which was retrieved + * correctly. + */ u700 = DATUtils.getMostRecentGridRecord(interval, - U700Product.getSQL(interval, U700Product.U700), + U700Product.getGridRecord(interval, U700Product.U700), param700U); v700 = DATUtils.getMostRecentGridRecord(interval, - V700Product.getSQL(interval, V700Product.V700), + V700Product.getGridRecord(interval, V700Product.V700), param700V); u500 = DATUtils.getMostRecentGridRecord(interval, - U500Product.getSQL(interval, U500Product.U500), + U500Product.getGridRecord(interval, U500Product.U500), param500U); if (u700 != null && v700 != null && u500 != null) { diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPConfig.java b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPConfig.java index 68459bae77..44031e4278 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPConfig.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPConfig.java @@ -56,7 +56,8 @@ import com.vividsolutions.jts.geom.GeometryFactory; * SOFTWARE HISTORY * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * 06/30/2009 2521 dhladky Initial Creation. + * 06/30/2009 2521 dhladky Initial Creation. + * Apr 24, 2014 2060 njensen Removed unnecessary catch * * * @@ -244,13 +245,7 @@ public class FFMPConfig { * @return */ private IMonitorProcessing getPDOFile(SourceXML xml, String uri) { - IMonitorProcessing obj = null; - try { - obj = (IMonitorProcessing) DATUtils.getPDORecord(uri, xml); - } catch (PluginException e) { - e.printStackTrace(); - } - return obj; + return (IMonitorProcessing) DATUtils.getPDORecord(uri, xml); } /** diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.qpf/src/com/raytheon/uf/edex/plugin/qpf/common/QPFConfig.java b/edexOsgi/com.raytheon.uf.edex.plugin.qpf/src/com/raytheon/uf/edex/plugin/qpf/common/QPFConfig.java index bb46f7f36a..1a35481e33 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.qpf/src/com/raytheon/uf/edex/plugin/qpf/common/QPFConfig.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.qpf/src/com/raytheon/uf/edex/plugin/qpf/common/QPFConfig.java @@ -40,6 +40,7 @@ import com.raytheon.uf.common.monitor.xml.SCANSiteXML; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; +import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.edex.dat.utils.DATUtils; import com.raytheon.uf.edex.dat.utils.ScanDataCache; import com.raytheon.uf.edex.plugin.qpf.QPFGenerator; @@ -59,9 +60,10 @@ import com.vividsolutions.jts.geom.Coordinate; * SOFTWARE HISTORY * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * 02/17/2009 1981 dhladky Initial Creation. - * 01/07/2013 DR 15647 gzhang Use logger.warn for null earlyVilURI/earlyCZURI. - * 11/11/2013 2377 bclement setRadarRecords returns bool for success + * 02/17/2009 1981 dhladky Initial Creation. + * 01/07/2013 DR 15647 gzhang Use logger.warn for null earlyVilURI/earlyCZURI. + * 11/11/2013 2377 bclement setRadarRecords returns bool for success + * Apr 24, 2014 2060 njensen Updates for removal of grid dataURI column * * * @author dhladky @@ -357,11 +359,11 @@ public class QPFConfig { Set vilKeys = vilmap.keySet(); Iterator iter1 = vilKeys.iterator(); while (iter1.hasNext()) { - Date vilcal = (Date) iter1.next(); + Date vilcal = iter1.next(); Set czKeys = czMap.keySet(); Iterator iter2 = czKeys.iterator(); while (iter2.hasNext()) { - Date czcal = (Date) iter2.next(); + Date czcal = iter2.next(); if (czcal.equals(vilcal)) { earlyVilURI = vilmap.get(vilcal); earlyCZURI = czMap.get(czcal); @@ -375,7 +377,9 @@ public class QPFConfig { } if (earlyVilURI == null || earlyCZURI == null) { - qpfgen.logger.warn("QPFConfig: No previous data for QPF. Check the RADAR OP Mode.");// DR 15647 + qpfgen.logger + .warn("QPFConfig: No previous data for QPF. Check the RADAR OP Mode.");// DR + // 15647 return false; } @@ -542,13 +546,25 @@ public class QPFConfig { SCANModelParameterXML paramXMLU = siteXML.getModelParameter("U700"); SCANModelParameterXML paramXMLV = siteXML.getModelParameter("V700"); - int interval = 1440; + int interval = TimeUtil.MINUTES_PER_DAY; + /* + * FIXME the inner calls to ####Product.getGridProduct below will + * always return null. The second parameter is supposed to be the + * model (e.g. RUC130) but is passing in the parameter. + * + * Despite this problem, the code continues to function without + * exceptions because the call to DATUtils.getMostRecentGridRecord() + * will see the null record and then return the cached record, which + * was retrieved correctly. + */ GridRecord modelURec = DATUtils.getMostRecentGridRecord(interval, - U700Product.getSQL(interval, U700Product.U700), paramXMLU); + U700Product.getGridRecord(interval, U700Product.U700), + paramXMLU); GridRecord modelVRec = DATUtils.getMostRecentGridRecord(interval, - V700Product.getSQL(interval, V700Product.V700), paramXMLV); + V700Product.getGridRecord(interval, V700Product.V700), + paramXMLV); if (modelURec != null && modelVRec != null) { useModel = true; diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/ScanGridRecordSet.java b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/ScanGridRecordSet.java new file mode 100644 index 0000000000..7f705ecbdb --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/ScanGridRecordSet.java @@ -0,0 +1,113 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.plugin.scan; + +import com.raytheon.uf.common.dataplugin.grid.GridRecord; + +/** + * Container for grid records that are potentially used by SCAN + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 24, 2014            njensen     Initial creation
+ * 
+ * 
+ * + * @author njensen + * @version 1.0 + */ + +public class ScanGridRecordSet { + + private GridRecord cape; + + private GridRecord heli; + + private GridRecord u500; + + private GridRecord u700; + + private GridRecord v700; + + private GridRecord gh500; + + private GridRecord gh1000; + + public GridRecord getCape() { + return cape; + } + + public void setCape(GridRecord cape) { + this.cape = cape; + } + + public GridRecord getHeli() { + return heli; + } + + public void setHeli(GridRecord heli) { + this.heli = heli; + } + + public GridRecord getU500() { + return u500; + } + + public void setU500(GridRecord u500) { + this.u500 = u500; + } + + public GridRecord getU700() { + return u700; + } + + public void setU700(GridRecord u700) { + this.u700 = u700; + } + + public GridRecord getV700() { + return v700; + } + + public void setV700(GridRecord v700) { + this.v700 = v700; + } + + public GridRecord getGh500() { + return gh500; + } + + public void setGh500(GridRecord gh500) { + this.gh500 = gh500; + } + + public GridRecord getGh1000() { + return gh1000; + } + + public void setGh1000(GridRecord gh1000) { + this.gh1000 = gh1000; + } + +} diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/ScanURIFilter.java b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/ScanURIFilter.java index 312744d120..e700292a86 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/ScanURIFilter.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/ScanURIFilter.java @@ -33,7 +33,6 @@ import org.geotools.coverage.grid.GridGeometry2D; import com.raytheon.edex.urifilter.URIFilter; import com.raytheon.edex.urifilter.URIGenerateMessage; -import com.raytheon.uf.common.dataplugin.PluginException; import com.raytheon.uf.common.dataplugin.binlightning.BinLightningRecord; import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataplugin.message.DataURINotificationMessage; @@ -58,6 +57,7 @@ import com.raytheon.uf.common.monitor.xml.SCANSiteXML; import com.raytheon.uf.common.serialization.SingleTypeJAXBManager; import com.raytheon.uf.common.sounding.VerticalSounding; import com.raytheon.uf.common.time.DataTime; +import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.edex.dat.utils.DATUtils; import com.raytheon.uf.edex.plugin.scan.common.ScanCommonUtils; import com.raytheon.uf.edex.plugin.scan.process.CAPEProduct; @@ -91,6 +91,7 @@ import com.vividsolutions.jts.geom.Coordinate; * Mar 23, 2010 dhladky Initial creation * Jun 21, 2013 7613 zhao Modified setGridRecords() etc. * Oct 15, 2013 2361 njensen Use JAXBManager for XML + * Apr 24, 2014 2060 njensen Updates for removal of grid dataURI column * * * @@ -885,76 +886,74 @@ public class ScanURIFilter extends URIFilter { /** * Set Grib Record in Model Data */ - public void setGridRecords() { + public void initializeGridRecords() { try { - GridRecord[] records = { null, null, null, null, null, null, null }; - records = getGridRecords(); + ScanGridRecordSet records = getGridData(); - if (records[0] != null) { + if (records.getCape() != null) { scan.getCache() .getModelData() .setGridRecord( site.getModelParameter(CAPEProduct.cape) .getModelName(), CAPEProduct.cape, - records[0]); + records.getCape()); } - if (records[1] != null) { + if (records.getHeli() != null) { scan.getCache() .getModelData() .setGridRecord( site.getModelParameter(HELIProduct.heli) .getModelName(), HELIProduct.heli, - records[1]); + records.getHeli()); } - if (records[2] != null) { + if (records.getU500() != null) { scan.getCache() .getModelData() .setGridRecord( site.getModelParameter(U500Product.U500) .getModelName(), U500Product.U500, - records[2]); + records.getU500()); } - if (records[3] != null) { + if (records.getU700() != null) { scan.getCache() .getModelData() .setGridRecord( site.getModelParameter(U700Product.U700) .getModelName(), U700Product.U700, - records[3]); + records.getU700()); } - if (records[4] != null) { + if (records.getV700() != null) { scan.getCache() .getModelData() .setGridRecord( site.getModelParameter(V700Product.V700) .getModelName(), V700Product.V700, - records[4]); + records.getV700()); } - if (records[5] != null) { + if (records.getGh500() != null) { scan.getCache() .getModelData() .setGridRecord( site.getModelParameter(GH500Product.GH500) .getModelName(), GH500Product.GH500, - records[5]); + records.getGh500()); } - if (records[6] != null) { + if (records.getGh1000() != null) { scan.getCache() .getModelData() .setGridRecord( site.getModelParameter(GH1000Product.GH1000) .getModelName(), GH1000Product.GH1000, - records[6]); + records.getGh1000()); } } catch (Exception e) { - logger.debug("Grib record setter failed....."); - e.printStackTrace(); + logger.error("Grib record initialization failed", e); } } @@ -1062,7 +1061,7 @@ public class ScanURIFilter extends URIFilter { * to retrieve the data from a database. */ public void init() { - setGridRecords(); + initializeGridRecords(); setSoundingRecord(ScanProduct.UA, ""); } @@ -1136,127 +1135,67 @@ public class ScanURIFilter extends URIFilter { } /** - * get Populated grib records for CAPE and HELI - * - * @return - */ - public GridRecord[] getGridRecords() throws PluginException { - - GridRecord[] records = { null, null, null, null, null, null, null }; - try { - String[] modelUris = getModelSQL(); - for (String uri : modelUris) { - logger.info(" model uri = " + uri); - } - for (int i = 0; i < modelUris.length; i++) { - if (!modelUris[i].isEmpty()) { - records[i] = DATUtils.getGridRecord(modelUris[i]); - } else { - logger.info(" modelUris[" + i + "] is empty"); - } - } - // // CAPE - // records[0] = DATUtils.getGridRecord(modelUris[0]); - // // HELI - // records[1] = DATUtils.getGridRecord(modelUris[1]); - // // U500 - // records[2] = DATUtils.getGridRecord(modelUris[2]); - // // U700 - // records[3] = DATUtils.getGridRecord(modelUris[3]); - // // V700 - // records[4] = DATUtils.getGridRecord(modelUris[4]); - // // GH500 - // records[5] = DATUtils.getGridRecord(modelUris[5]); - // // GH1000 - // records[6] = DATUtils.getGridRecord(modelUris[6]); - } catch (Exception e) { - logger.error("No Grib record(s) found....."); - logger.error(e.toString()); - e.printStackTrace(); - } - return records; - } - - /** - * Get the Model SQL Uses the environmental data backup for the + * Get the grid data. Uses the environmental data backup for the * "pull strategy" for All model params. */ - private String[] getModelSQL() throws Exception { + protected ScanGridRecordSet getGridData() throws Exception { SCANSiteXML site = scan.getRunConfig().getSiteConfig(getIcao()); logger.info(" site = " + site.getScanSite()); - int interval = 1440 * 3; - // Set interval to 1 day, 1440 minutes + int interval = TimeUtil.MINUTES_PER_DAY; + ScanGridRecordSet result = new ScanGridRecordSet(); String modelCape = site.getModelParameter(CAPEProduct.cape) .getModelName(); - String sqlCapeUri = CAPEProduct.getSQL(interval, modelCape); - logger.info("modelCape = " + modelCape + "; sqlCapeUri = " + sqlCapeUri); - Object[] objectsCapeUri = scan.dbRequest(sqlCapeUri); + GridRecord cape = CAPEProduct.getGridRecord(interval, modelCape); + logger.info("modelCape = " + modelCape + "; record = " + cape); + DATUtils.populateGridRecord(cape); + result.setCape(cape); String modelHeli = site.getModelParameter(HELIProduct.heli) .getModelName(); - String sqlHeliUri = HELIProduct.getSQL(interval, modelHeli); - logger.info("modelHeli = " + modelHeli + "; sqlHeliUri = " + sqlHeliUri); - Object[] objectsHeliUri = scan.dbRequest(sqlHeliUri); + GridRecord heli = HELIProduct.getGridRecord(interval, modelHeli); + logger.info("modelHeli = " + modelHeli + "; record = " + heli); + DATUtils.populateGridRecord(heli); + result.setHeli(heli); String modelU500 = site.getModelParameter(U500Product.U500) .getModelName(); - String sqlU500Uri = U500Product.getSQL(interval, modelU500); - logger.info("modelU500 = " + modelU500 + "; sqlU500Uri = " + sqlU500Uri); - Object[] objectsU500Uri = scan.dbRequest(sqlU500Uri); + GridRecord u500 = U500Product.getGridRecord(interval, modelU500); + logger.info("modelU500 = " + modelU500 + "; record = " + u500); + DATUtils.populateGridRecord(u500); + result.setU500(u500); String modelU700 = site.getModelParameter(U700Product.U700) .getModelName(); - String sqlU700Uri = U700Product.getSQL(interval, modelU700); - logger.info("modelU700 = " + modelU700 + "; sqlU700Uri = " + sqlU700Uri); - Object[] objectsU700Uri = scan.dbRequest(sqlU700Uri); + GridRecord u700 = U700Product.getGridRecord(interval, modelU700); + logger.info("modelU700 = " + modelU700 + "; record = " + u700); + DATUtils.populateGridRecord(u700); + result.setU700(u700); String modelV700 = site.getModelParameter(V700Product.V700) .getModelName(); - String sqlV700Uri = V700Product.getSQL(interval, modelV700); - logger.info("modelV700 = " + modelV700 + "; sqlV700Uri = " + sqlV700Uri); - Object[] objectsV700Uri = scan.dbRequest(sqlV700Uri); + GridRecord v700 = V700Product.getGridRecord(interval, modelV700); + logger.info("modelV700 = " + modelV700 + "; record = " + v700); + DATUtils.populateGridRecord(v700); + result.setV700(v700); String modelGH500 = site.getModelParameter(GH500Product.GH500) .getModelName(); - String sqlGH500Uri = GH500Product.getSQL(interval, modelGH500); - logger.info("modelGH500 = " + modelGH500 + "; sqlGH500Uri = " - + sqlGH500Uri); - Object[] objectsGH500Uri = scan.dbRequest(sqlGH500Uri); + GridRecord gh500 = GH500Product.getGridRecord(interval, modelGH500); + logger.info("modelGH500 = " + modelGH500 + "; record = " + gh500); + DATUtils.populateGridRecord(gh500); + result.setGh500(gh500); String modelGH1000 = site.getModelParameter(GH1000Product.GH1000) .getModelName(); - String sqlGH1000Uri = GH1000Product.getSQL(interval, modelGH1000); - logger.info("modelGH1000 = " + modelGH1000 + "; sqlGH1000Uri = " - + sqlGH1000Uri); - Object[] objectsGH1000Uri = scan.dbRequest(sqlGH1000Uri); + GridRecord gh1000 = GH1000Product.getGridRecord(interval, modelGH1000); + logger.info("modelGH1000 = " + modelGH1000 + "; record = " + gh1000); + DATUtils.populateGridRecord(gh1000); + result.setGh1000(gh1000); - // always grab the most recent time data - String[] results = { "", "", "", "", "", "", "" }; + return result; - if (objectsCapeUri.length > 0) { - results[0] = (String) objectsCapeUri[0]; - } - if (objectsHeliUri.length > 0) { - results[1] = (String) objectsHeliUri[0]; - } - if (objectsU500Uri.length > 0) { - results[2] = (String) objectsU500Uri[0]; - } - if (objectsU700Uri.length > 0) { - results[3] = (String) objectsU700Uri[0]; - } - if (objectsV700Uri.length > 0) { - results[4] = (String) objectsV700Uri[0]; - } - if (objectsGH500Uri.length > 0) { - results[5] = (String) objectsGH500Uri[0]; - } - if (objectsGH1000Uri.length > 0) { - results[6] = (String) objectsGH1000Uri[0]; - } - return results; } /** diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/CAPEProduct.java b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/CAPEProduct.java index 47810616ea..96dbc29785 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/CAPEProduct.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/CAPEProduct.java @@ -26,11 +26,27 @@ import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataplugin.level.Level; import com.raytheon.uf.common.dataplugin.persist.PersistableDataObject; import com.raytheon.uf.common.dataplugin.persist.PersistablePluginDataObject; +import com.raytheon.uf.common.dataplugin.scan.ScanException; import com.raytheon.uf.common.dataplugin.scan.data.ScanTableDataRow; import com.raytheon.uf.common.monitor.config.SCANRunSiteConfigurationManager; import com.raytheon.uf.common.monitor.scan.config.SCANConfigEnums.ScanTables; import com.raytheon.uf.edex.plugin.scan.ScanURIFilter; +/** + * CAPE Product + * + *
+ * 
+ * SOFTWARE HISTORY
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ *                                     Initial creation
+ * Apr 24, 2014 2060       njensen     Updates for removal of grid dataURI column
+ * 
+ * 
+ * + * @version 1.0 + */ public class CAPEProduct extends GridProduct { /** @@ -113,13 +129,15 @@ public class CAPEProduct extends GridProduct { } /** - * The SQL for CAPE + * Retrieves the record for CAPE * * @param wmo * @return + * @throws ScanException */ - public static String getSQL(int interval, String model) { - return getGridSQL(interval, model, cape, "SFC", "0.0", + public static GridRecord getGridRecord(int interval, String model) + throws ScanException { + return getGridRecord(interval, model, cape, "SFC", "0.0", Level.getInvalidLevelValueAsString()); } } diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GH1000Product.java b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GH1000Product.java index 4d7ad4a5cc..7e5e81d098 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GH1000Product.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GH1000Product.java @@ -26,6 +26,7 @@ import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataplugin.level.Level; import com.raytheon.uf.common.dataplugin.persist.PersistableDataObject; import com.raytheon.uf.common.dataplugin.persist.PersistablePluginDataObject; +import com.raytheon.uf.common.dataplugin.scan.ScanException; import com.raytheon.uf.common.dataplugin.scan.data.ScanTableDataRow; import com.raytheon.uf.common.monitor.config.SCANRunSiteConfigurationManager; import com.raytheon.uf.common.monitor.scan.config.SCANConfigEnums.ScanTables; @@ -40,6 +41,7 @@ import com.raytheon.uf.edex.plugin.scan.ScanURIFilter; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Jul 27, 2010 5098 grichard Initial creation + * Apr 24, 2014 2060 njensen Updates for removal of grid dataURI column * * * @@ -134,12 +136,14 @@ public class GH1000Product extends GridProduct { } /** - * The SQL + * Retrieves the record for gh1000 * * @return + * @throws ScanException */ - public static String getSQL(int interval, String model) { - return getGridSQL(interval, model, "GH", "MB", "1000.0", + public static GridRecord getGridRecord(int interval, String model) + throws ScanException { + return getGridRecord(interval, model, "GH", "MB", "1000.0", Level.getInvalidLevelValueAsString()); } diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GH500Product.java b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GH500Product.java index ac41d746db..62adc7566b 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GH500Product.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GH500Product.java @@ -26,6 +26,7 @@ import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataplugin.level.Level; import com.raytheon.uf.common.dataplugin.persist.PersistableDataObject; import com.raytheon.uf.common.dataplugin.persist.PersistablePluginDataObject; +import com.raytheon.uf.common.dataplugin.scan.ScanException; import com.raytheon.uf.common.dataplugin.scan.data.ScanTableDataRow; import com.raytheon.uf.common.monitor.config.SCANRunSiteConfigurationManager; import com.raytheon.uf.common.monitor.scan.config.SCANConfigEnums.ScanTables; @@ -40,6 +41,7 @@ import com.raytheon.uf.edex.plugin.scan.ScanURIFilter; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Jul 27, 2010 5098 grichard Initial creation + * Apr 24, 2014 2060 njensen Updates for removal of grid dataURI column * * * @@ -134,12 +136,14 @@ public class GH500Product extends GridProduct { } /** - * The SQL for MODEL 500 thickness + * Retrieves the record for gh500 * * @return + * @throws ScanException */ - public static String getSQL(int interval, String model) { - return getGridSQL(interval, model, "GH", "MB", "500.0", + public static GridRecord getGridRecord(int interval, String model) + throws ScanException { + return getGridRecord(interval, model, "GH", "MB", "500.0", Level.getInvalidLevelValueAsString()); } diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GridProduct.java b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GridProduct.java index 37ae0ff582..2e85e20ab0 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GridProduct.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GridProduct.java @@ -19,14 +19,23 @@ **/ package com.raytheon.uf.edex.plugin.scan.process; +import java.util.Date; +import java.util.List; import java.util.regex.Pattern; +import com.raytheon.uf.common.dataplugin.grid.GridRecord; +import com.raytheon.uf.common.dataplugin.scan.ScanException; import com.raytheon.uf.common.monitor.scan.config.SCANConfigEnums.ScanTables; +import com.raytheon.uf.common.time.SimulatedTime; +import com.raytheon.uf.common.time.util.TimeUtil; +import com.raytheon.uf.edex.database.plugin.PluginDao; +import com.raytheon.uf.edex.database.plugin.PluginFactory; +import com.raytheon.uf.edex.database.query.DatabaseQuery; import com.raytheon.uf.edex.plugin.scan.ScanURIFilter; /** * - * TODO Add Description + * Abstract grid product for SCAN * *
  * 
@@ -34,8 +43,9 @@ import com.raytheon.uf.edex.plugin.scan.ScanURIFilter;
  * 
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
- * Mar 2, 2012             bsteffen     Initial creation
- * Jun 21, 2013 7613       zhao         Modified getGrigSQL()
+ * Mar 2, 2012             bsteffen    Initial creation
+ * Jun 21, 2013 7613       zhao        Modified getGridSQL()
+ * Apr 24, 2014 2060       njensen     Updates for removal of grid dataURI column
  * 
  * 
* @@ -52,6 +62,21 @@ public abstract class GridProduct extends ScanProduct { super(uri, tableType, filter); } + /** + * Gets a pattern for matching a URI with the specified parameters. + * + * @param dataset + * @param parameter + * @param levelName + * @param levelOne + * @param levelTwo + * @return + * @deprecated This entire method should be removed and/or replaced, + * possibly by using the PluginNotifier or methods in + * DataURIUtil. At present the method is coupled too tightly to + * the grid dataURI format. + */ + @Deprecated protected static Pattern getGridPattern(String dataset, String parameter, String levelName, String levelOne, String levelTwo) { // Format = @@ -92,34 +117,52 @@ public abstract class GridProduct extends ScanProduct { } /** - * The SQL for MODEL 500 thickness + * Gets the newest grid record that has a reftime newer than the interval + * back in time * - * @return + * @param interval + * the number of minutes back from the current time to check for + * a matching record + * @param dataset + * the grid dataset + * @param parameter + * the grid parameter + * @param levelName + * the grid level name + * @param levelOne + * the grid level one value + * @param levelTwo + * the grid level two value + * @return the newest grid record that matches, or null if none are found + * @throws ScanException */ - public static String getGridSQL(int interval, String dataset, - String parameter, String levelName, String levelOne, String levelTwo) { - StringBuilder sql = new StringBuilder( - "select grid.datauri from grid, grid_info, level where"); - sql.append(" grid.info_id = grid_info.id"); - sql.append(" and"); - // datasetId - sql.append(" grid_info.datasetId = \'" + dataset + "\'"); - sql.append(" and"); - // parameterAbbreviation - sql.append(" grid_info.parameter_abbreviation = \'" + parameter + "\'"); - sql.append(" and"); - // level - sql.append(" level.id = grid_info.level_id"); - sql.append(" and"); - sql.append(" level.masterlevel_name = \'" + levelName + "\'"); - sql.append(" and"); - sql.append(" level.levelonevalue = \'" + levelOne + "\'"); - sql.append(" and"); - sql.append(" level.leveltwovalue = \'" + levelTwo + "\'"); - // interval - sql.append("and reftime > (now()- interval \'" + interval - + " minutes\')"); - sql.append(" order by reftime desc, forecasttime desc" + " limit 1"); - return sql.toString(); + public static GridRecord getGridRecord(int interval, String dataset, + String parameter, String levelName, String levelOne, String levelTwo) + throws ScanException { + DatabaseQuery dbQuery = new DatabaseQuery(GridRecord.class); + dbQuery.addQueryParam("info.datasetId", dataset); + dbQuery.addQueryParam("info.parameter.abbreviation", parameter); + dbQuery.addQueryParam("info.level.masterLevel.name", levelName); + dbQuery.addQueryParam("info.level.levelonevalue", levelOne); + dbQuery.addQueryParam("info.level.leveltwovalue", levelTwo); + dbQuery.addQueryParam("dataTime.refTime", new Date(SimulatedTime + .getSystemTime().getMillis() + - (interval * TimeUtil.MILLIS_PER_MINUTE)), ">"); + dbQuery.addOrder("dataTime.refTime", false); + dbQuery.addOrder("dataTime.fcstTime", false); + dbQuery.setMaxResults(1); + + try { + PluginDao dao = PluginFactory.getInstance().getPluginDao("grid"); + List list = dao.queryByCriteria(dbQuery); + GridRecord result = null; + if (list != null && !list.isEmpty()) { + result = (GridRecord) list.get(0); + } + return result; + } catch (Exception e) { + throw new ScanException("Error querying database for grid record " + + dbQuery, e); + } } } diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/HELIProduct.java b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/HELIProduct.java index 24fde781d8..23d6510088 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/HELIProduct.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/HELIProduct.java @@ -26,6 +26,7 @@ import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataplugin.level.Level; import com.raytheon.uf.common.dataplugin.persist.PersistableDataObject; import com.raytheon.uf.common.dataplugin.persist.PersistablePluginDataObject; +import com.raytheon.uf.common.dataplugin.scan.ScanException; import com.raytheon.uf.common.dataplugin.scan.data.ScanTableDataRow; import com.raytheon.uf.common.monitor.config.SCANRunSiteConfigurationManager; import com.raytheon.uf.common.monitor.scan.config.SCANConfigEnums.ScanTables; @@ -41,6 +42,7 @@ import com.raytheon.uf.edex.plugin.scan.ScanURIFilter; * ------------ ---------- ----------- -------------------------- * May 18, 2010 5098 grichard Initial creation * Jun 20, 2013 7613 zhao Modified getSQL() + * Apr 24, 2014 2060 njensen Updates for removal of grid dataURI column * * * @@ -131,13 +133,14 @@ public class HELIProduct extends GridProduct { } /** - * The SQL HELI + * Retrieves the record for heli * * @param interval * @return + * @throws ScanException */ - public static String getSQL(int interval, String model) { - return getGridSQL(interval, model, "Heli", "FHAG", "0.0", - "3000.0"); + public static GridRecord getGridRecord(int interval, String model) + throws ScanException { + return getGridRecord(interval, model, "Heli", "FHAG", "0.0", "3000.0"); } } diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/U500Product.java b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/U500Product.java index 64249d530e..3c4cf22640 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/U500Product.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/U500Product.java @@ -26,6 +26,7 @@ import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataplugin.level.Level; import com.raytheon.uf.common.dataplugin.persist.PersistableDataObject; import com.raytheon.uf.common.dataplugin.persist.PersistablePluginDataObject; +import com.raytheon.uf.common.dataplugin.scan.ScanException; import com.raytheon.uf.common.dataplugin.scan.data.ScanTableDataRow; import com.raytheon.uf.common.monitor.config.SCANRunSiteConfigurationManager; import com.raytheon.uf.common.monitor.scan.config.SCANConfigEnums.ScanTables; @@ -40,6 +41,7 @@ import com.raytheon.uf.edex.plugin.scan.ScanURIFilter; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Jul 27, 2010 5098 grichard Initial creation + * Apr 24, 2014 2060 njensen Updates for removal of grid dataURI column * * * @@ -134,13 +136,15 @@ public class U500Product extends GridProduct { } /** - * The SQL for RUC13 CAPE + * Retrieves the record for u500 * * @param wmo * @return + * @throws ScanException */ - public static String getSQL(int interval, String model) { - return getGridSQL(interval, model, "uW", "MB", "500.0", + public static GridRecord getGridRecord(int interval, String model) + throws ScanException { + return getGridRecord(interval, model, "uW", "MB", "500.0", Level.getInvalidLevelValueAsString()); } diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/U700Product.java b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/U700Product.java index ef2cb01b6e..834ec9d4b2 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/U700Product.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/U700Product.java @@ -26,6 +26,7 @@ import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataplugin.level.Level; import com.raytheon.uf.common.dataplugin.persist.PersistableDataObject; import com.raytheon.uf.common.dataplugin.persist.PersistablePluginDataObject; +import com.raytheon.uf.common.dataplugin.scan.ScanException; import com.raytheon.uf.common.dataplugin.scan.data.ScanTableDataRow; import com.raytheon.uf.common.monitor.config.SCANRunSiteConfigurationManager; import com.raytheon.uf.common.monitor.scan.config.SCANConfigEnums.ScanTables; @@ -40,6 +41,7 @@ import com.raytheon.uf.edex.plugin.scan.ScanURIFilter; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Jul 27, 2010 5098 grichard Initial creation + * Apr 24, 2014 2060 njensen Updates for removal of grid dataURI column * * * @@ -134,12 +136,14 @@ public class U700Product extends GridProduct { } /** - * The SQL + * Retrieves the record for u700 * * @return + * @throws ScanException */ - public static String getSQL(int interval, String model) { - return getGridSQL(interval, model, "uW", "MB", "700.0", + public static GridRecord getGridRecord(int interval, String model) + throws ScanException { + return getGridRecord(interval, model, "uW", "MB", "700.0", Level.getInvalidLevelValueAsString()); } diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/V700Product.java b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/V700Product.java index 6ac5e2709a..f880155577 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/V700Product.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/V700Product.java @@ -26,6 +26,7 @@ import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataplugin.level.Level; import com.raytheon.uf.common.dataplugin.persist.PersistableDataObject; import com.raytheon.uf.common.dataplugin.persist.PersistablePluginDataObject; +import com.raytheon.uf.common.dataplugin.scan.ScanException; import com.raytheon.uf.common.dataplugin.scan.data.ScanTableDataRow; import com.raytheon.uf.common.monitor.config.SCANRunSiteConfigurationManager; import com.raytheon.uf.common.monitor.scan.config.SCANConfigEnums.ScanTables; @@ -40,6 +41,7 @@ import com.raytheon.uf.edex.plugin.scan.ScanURIFilter; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Jul 27, 2010 5098 grichard Initial creation + * Apr 24, 2014 2060 njensen Updates for removal of grid dataURI column * * * @@ -134,13 +136,15 @@ public class V700Product extends GridProduct { } /** - * The SQL for RUC13 CAPE + * Retrieves the record for v700 * * @param wmo * @return + * @throws ScanException */ - public static String getSQL(int interval, String model) { - return getGridSQL(interval, model, "vW", "MB", "700.0", + public static GridRecord getGridRecord(int interval, String model) + throws ScanException { + return getGridRecord(interval, model, "vW", "MB", "700.0", Level.getInvalidLevelValueAsString()); } From 02f08d75c6ca14cd795582a0b4c37b51a04737e5 Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Thu, 24 Apr 2014 15:46:06 -0500 Subject: [PATCH 100/188] Issue #3070 fixed contact request handling no longer get empty group if user denies contact request fixed UI update issue when server removes from your roster added icon for pending contact request fixed auto accept reply from users you initiated contact request with Former-commit-id: 01e773fb9d4ec8b0ab75ddf714b79debb9ad4096 --- .../identity/event/IRosterChangeEvent.java | 6 ++- .../account/SubscriptionPacketListener.java | 41 +++++++-------- .../provider/event/RosterChangeEvent.java | 11 ++-- .../comm/provider/user/ContactsListener.java | 26 +++++----- .../comm/provider/user/ContactsManager.java | 47 ++++++++++++++++-- .../icons/pending.gif | Bin 0 -> 92 bytes .../ui/AbstractUserLabelProvider.java | 12 ++++- .../uf/viz/collaboration/ui/Activator.java | 3 ++ .../ui/UsersTreeContentProvider.java | 5 +- .../ui/actions/AddToGroupAction.java | 4 +- .../ui/actions/RemoveFromRosterAction.java | 6 ++- .../ui/actions/SendSubReqAction.java | 10 ++-- .../ui/prefs/CollabPrefConstants.java | 3 ++ .../ui/prefs/SubscriptionResponderImpl.java | 14 +++--- 14 files changed, 125 insertions(+), 63 deletions(-) create mode 100644 cave/com.raytheon.uf.viz.collaboration.ui/icons/pending.gif diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/event/IRosterChangeEvent.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/event/IRosterChangeEvent.java index 3356ea0976..ebc281e7cc 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/event/IRosterChangeEvent.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/identity/event/IRosterChangeEvent.java @@ -19,9 +19,10 @@ **/ package com.raytheon.uf.viz.collaboration.comm.identity.event; -import org.jivesoftware.smack.RosterEntry; import org.jivesoftware.smack.packet.Presence; +import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; + /** * Event fired when the roster has changed * @@ -33,6 +34,7 @@ import org.jivesoftware.smack.packet.Presence; * ------------ ---------- ----------- -------------------------- * Apr 06, 2012 jkorman Initial creation. * Feb 24, 2014 2632 mpduff Added getPresence, changed getItem to getEntry. + * Apr 24, 2014 3070 bclement getEntry() returns UserId * * * @@ -54,7 +56,7 @@ public interface IRosterChangeEvent { * * @return The changed entry */ - RosterEntry getEntry(); + UserId getEntry(); /** * Get the Presence object. diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/SubscriptionPacketListener.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/SubscriptionPacketListener.java index a5f23cd2e0..cb83eba223 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/SubscriptionPacketListener.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/account/SubscriptionPacketListener.java @@ -50,7 +50,8 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Apr 04, 2014 2785 mpduff Initial creation - * Apr 14, 2014 2903 bclement moved from session subpackage to account + * Apr 14, 2014 2903 bclement moved from session subpackage to account + * Apr 24, 2014 3070 bclement RosterChangeEvent changes, adds back even if blocked * * * @@ -119,10 +120,8 @@ public class SubscriptionPacketListener implements PacketListener, * @param fromID */ private void handleSubscribed(UserId fromID) { - ContactsManager cm = sessionManager.getContactsManager(); - RosterEntry entry = cm.getRosterEntry(fromID); IRosterChangeEvent event = new RosterChangeEvent(RosterChangeType.ADD, - entry); + fromID); sessionManager.postEvent(event); } @@ -132,13 +131,8 @@ public class SubscriptionPacketListener implements PacketListener, * @param fromID */ private void handleUnsubscribed(UserId fromID) { - ContactsManager cm = sessionManager.getContactsManager(); - RosterEntry entry = cm.getRosterEntry(fromID); - if (entry == null) { - return; - } IRosterChangeEvent event = new RosterChangeEvent( - RosterChangeType.DELETE, entry); + RosterChangeType.DELETE, fromID); sessionManager.postEvent(event); } @@ -149,28 +143,29 @@ public class SubscriptionPacketListener implements PacketListener, */ private void handleSubResponse(UserId fromId, SubscriptionResponse response) { Presence.Type subscribedType; - ContactsManager cm = sessionManager.getContactsManager(); - boolean addToRoster = false; if (response.isAccepted()) { subscribedType = Presence.Type.subscribed; - RosterEntry entry = cm.getRosterEntry(fromId); - if (entry == null) { - addToRoster = true; - } } else { subscribedType = Presence.Type.unsubscribed; } - Presence presence = new Presence(subscribedType); try { sendPresence(fromId, presence); - if (addToRoster) { - if (response.addToGroup()) { - cm.addToGroup(response.getGroup(), fromId); - } else { - cm.addToRoster(fromId); + if (response.isAccepted()) { + /* add them back */ + ContactsManager cm = sessionManager.getContactsManager(); + RosterEntry entry = cm.getRosterEntry(fromId); + if (entry != null && ContactsManager.isBlocked(entry)) { + /* in roster, but blocked */ + cm.sendContactRequest(fromId); + } + if (response.addToGroup()) { + /* + * if contact is not in roster, this will also send them a + * contact request, otherwise it just add them to the group + */ + cm.addToGroup(response.getGroup(), fromId); } - } } catch (CollaborationException e) { log.error("Unable to send presence", e); diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/event/RosterChangeEvent.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/event/RosterChangeEvent.java index 0e99c81091..56279ab062 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/event/RosterChangeEvent.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/event/RosterChangeEvent.java @@ -19,11 +19,11 @@ **/ package com.raytheon.uf.viz.collaboration.comm.provider.event; -import org.jivesoftware.smack.RosterEntry; import org.jivesoftware.smack.packet.Presence; import com.raytheon.uf.viz.collaboration.comm.identity.event.IRosterChangeEvent; import com.raytheon.uf.viz.collaboration.comm.identity.event.RosterChangeType; +import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; /** * Event posted when a roster entry needs to be updated @@ -36,6 +36,7 @@ import com.raytheon.uf.viz.collaboration.comm.identity.event.RosterChangeType; * ------------ ---------- ----------- -------------------------- * Apr 11, 2012 jkorman Initial creation * Feb 24, 2014 2632 mpduff Added getPresence, changed getItem to getEntry. + * Apr 24, 2014 3070 bclement getEntry() returns UserId * * * @@ -47,7 +48,7 @@ public class RosterChangeEvent implements IRosterChangeEvent { private final RosterChangeType type; - private final RosterEntry entry; + private final UserId entry; /** The presence object */ private Presence presence; @@ -60,7 +61,7 @@ public class RosterChangeEvent implements IRosterChangeEvent { * @param entry * The changed entry. */ - public RosterChangeEvent(RosterChangeType type, RosterEntry entry) { + public RosterChangeEvent(RosterChangeType type, UserId entry) { this.type = type; this.entry = entry; } @@ -76,7 +77,7 @@ public class RosterChangeEvent implements IRosterChangeEvent { * @param presence * The presence object */ - public RosterChangeEvent(RosterChangeType type, RosterEntry entry, + public RosterChangeEvent(RosterChangeType type, UserId entry, Presence presence) { this.type = type; this.entry = entry; @@ -102,7 +103,7 @@ public class RosterChangeEvent implements IRosterChangeEvent { * @see com.raytheon.uf.viz.collaboration.comm.identity.event.IRosterChangeEvent#getEntry() */ @Override - public RosterEntry getEntry() { + public UserId getEntry() { return entry; } diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsListener.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsListener.java index b2bd85e5cf..0bab8a089e 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsListener.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsListener.java @@ -26,7 +26,6 @@ import java.util.Iterator; import java.util.List; import java.util.Map; -import org.jivesoftware.smack.Roster; import org.jivesoftware.smack.RosterEntry; import org.jivesoftware.smack.RosterListener; import org.jivesoftware.smack.packet.Presence; @@ -48,6 +47,8 @@ import com.raytheon.uf.viz.collaboration.comm.provider.event.RosterChangeEvent; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Apr 22, 2014 2822 bclement Initial creation + * Apr 24, 2014 3070 bclement removed roster, + * RosterChangedEvent sends UserId not RosterEntry * * * @@ -58,17 +59,14 @@ public class ContactsListener implements RosterListener { private final ContactsManager manager; - private final Roster roster; - private final Map> contactResources = new HashMap>(); /** * @param manager * @param roster */ - public ContactsListener(ContactsManager manager, Roster roster) { + public ContactsListener(ContactsManager manager) { this.manager = manager; - this.roster = roster; } /* @@ -92,9 +90,11 @@ public class ContactsListener implements RosterListener { } } RosterEntry entry = manager.getRosterEntry(u); - post(entry); + if (entry != null) { + post(entry); + } IRosterChangeEvent event = new RosterChangeEvent( - RosterChangeType.PRESENCE, entry, presence); + RosterChangeType.PRESENCE, u, presence); post(event); } } @@ -197,11 +197,13 @@ public class ContactsListener implements RosterListener { */ private void send(Collection addresses, RosterChangeType type) { for (String addy : addresses) { - RosterEntry entry = roster.getEntry(addy); - if (entry != null) { - IRosterChangeEvent event = new RosterChangeEvent(type, entry); - post(event); - } + UserId entry = IDConverter.convertFrom(addy); + /* + * RosterChangeEvents can't use RosterEntry objects because DELETE + * events happen after the entry is removed from the server roster + */ + IRosterChangeEvent event = new RosterChangeEvent(type, entry); + post(event); } } diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java index 37092ca567..8cfe54ffac 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java @@ -47,6 +47,7 @@ import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.common.util.collections.UpdatingSet; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; +import com.raytheon.uf.viz.collaboration.comm.identity.IAccountManager; import com.raytheon.uf.viz.collaboration.comm.provider.Tools; import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; @@ -75,6 +76,8 @@ import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationC * Apr 16, 2014 2981 bclement fixed NPE when cached shared group deleted on server * Apr 23, 2014 2822 bclement moved roster listener to ContactsListener, * added getSharedDisplayEnabledResource() + * Apr 24, 2014 3070 bclement added checks for empty groups, added isContact(), + * added sendContactRequest() * * * @@ -134,7 +137,7 @@ public class ContactsManager { localAliases = UserIdWrapper.readAliasMap(); this.xmpp = xmpp; Roster roster = xmpp.getRoster(); - this.contactsListener = new ContactsListener(this, roster); + this.contactsListener = new ContactsListener(this); roster.addRosterListener(this.contactsListener); } @@ -154,7 +157,7 @@ public class ContactsManager { * group will be null if it has been removed from server after * cached in shared groups. */ - if (rg != null) { + if (rg != null && !rg.getEntries().isEmpty()) { rval.add(new SharedGroup(rg)); } } @@ -176,7 +179,8 @@ public class ContactsManager { } else { rval = new ArrayList(groups.size()); for (RosterGroup group : groups) { - if (!shared.contains(group.getName())) { + if (!shared.contains(group.getName()) + && !group.getEntries().isEmpty()) { rval.add(group); } } @@ -667,6 +671,7 @@ public class ContactsManager { } /** + * * @param entry * @return true if we are blocked from seeing updates from user in entry */ @@ -697,6 +702,31 @@ public class ContactsManager { return rval; } + /** + * + * @param entry + * @return true if we can see updates from user in entry + */ + public static boolean isContact(RosterEntry entry) { + ItemType type = entry.getType(); + return type != null + && (type.equals(ItemType.both) || type.equals(ItemType.to)); + } + + /** + * @see #isContact(RosterEntry) + * @param id + * @return true if we can see updates from user + */ + public boolean isContact(UserId id) { + RosterEntry entry = getRosterEntry(id); + boolean rval = false; + if (entry != null) { + rval = isContact(entry); + } + return rval; + } + /** * @see ContactsListener#getSharedDisplayEnabledResource(UserId) * @param user @@ -706,6 +736,17 @@ public class ContactsManager { return contactsListener.getSharedDisplayEnabledResource(user); } + /** + * Send a contact request to user + * + * @param user + * @throws CollaborationException + */ + public void sendContactRequest(UserId user) throws CollaborationException { + IAccountManager manager = connection.getAccountManager(); + manager.sendPresence(user, new Presence(Type.subscribe)); + } + /** * Listener interface for group update events */ diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/icons/pending.gif b/cave/com.raytheon.uf.viz.collaboration.ui/icons/pending.gif new file mode 100644 index 0000000000000000000000000000000000000000..2314a1e69651fa2a08f35724405a0f8392b54219 GIT binary patch literal 92 zcmZ?wbhEHb6krfwXkcV8H8uVJ|G(ltLFb~>#FEq$h4Rdj31pDc`A42%pq t3_t)<&cGzs)4%dGBfs>V1Xts$-rFC(O-(%Bk^FS2*o;X+tBqJ0tO4W`9MJ#( literal 0 HcmV?d00001 diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/AbstractUserLabelProvider.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/AbstractUserLabelProvider.java index 6b8787ab42..f930b7ab1d 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/AbstractUserLabelProvider.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/AbstractUserLabelProvider.java @@ -52,6 +52,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; * Feb 13, 2014 2751 bclement made generic for IUsers * Feb 13, 2014 2751 njensen Extracted getImageName() to allow overrides * Feb 17, 2014 2751 bclement moved block image logic to roster specific code + * Apr 24, 2014 3070 bclement added pending contact icon * * * @@ -103,6 +104,14 @@ public abstract class AbstractUserLabelProvider extends return null; } String key = getImageName(user); + if (element instanceof RosterEntry) { + RosterEntry entry = (RosterEntry) element; + ItemStatus status = entry.getStatus(); + if (status != null) { + /* status always indicates pending */ + key = "pending"; + } + } if (imageMap.get(key) == null && !key.equals("")) { imageMap.put(key, CollaborationUtils.getNodeImage(key)); @@ -144,7 +153,8 @@ public abstract class AbstractUserLabelProvider extends } ItemStatus status = entry.getStatus(); if (status != null) { - text.append(status).append(" pending\n"); + /* status always indicates pending */ + text.append("Contact request pending\n"); } } // delete trailing newline diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/Activator.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/Activator.java index bad07eb095..e4e0a2db86 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/Activator.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/Activator.java @@ -42,6 +42,7 @@ import com.raytheon.uf.viz.core.localization.HierarchicalPreferenceStore; * Mar 1, 2012 rferrel Initial creation * Feb 19, 2014 2631 mpduff Changed to use the HierarchicalPreferenceStore. * Feb 20, 2014 2631 mpduff Need to set defaults here since we changed to use the HierarchicalPreferenceStore + * Apr 24, 2014 3070 bclement added default groupname to preference defaults * * * @@ -126,6 +127,8 @@ public class Activator extends AbstractUIPlugin { prefs.setDefault(CollabPrefConstants.DEFAULT_HANDLE, CollabPrefConstants.HandleOption.USERNAME.name()); prefs.setDefault(CollabPrefConstants.CUSTOM_HANDLE, ""); + prefs.setDefault(CollabPrefConstants.DEFAULT_GROUPNAME_PREF, + "Contacts"); } return prefs; } diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UsersTreeContentProvider.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UsersTreeContentProvider.java index 2abc7f20cc..a17c4b8e84 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UsersTreeContentProvider.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/UsersTreeContentProvider.java @@ -32,7 +32,6 @@ import org.jivesoftware.smack.RosterEntry; import org.jivesoftware.smack.RosterGroup; import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; -import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; import com.raytheon.uf.viz.collaboration.comm.provider.user.SharedGroup; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.ui.data.CollaborationGroupContainer; @@ -51,6 +50,7 @@ import com.raytheon.uf.viz.collaboration.ui.data.SessionGroupContainer; * Dec 6, 2013 2561 bclement removed ECF * Jan 24, 2014 2701 bclement removed local groups, added shared groups * Jan 27, 2014 2700 bclement added support roster entries + * Apr 24, 2014 3070 bclement removed check for hasInteraction() from group entries * * * @@ -141,8 +141,7 @@ public class UsersTreeContentProvider implements ITreeContentProvider { UserId localUser = connection.getUser(); for (RosterEntry entry : entries) { String user = entry.getUser(); - if (!localUser.isSameUser(user) - && ContactsManager.hasInteraction(entry)) { + if (!localUser.isSameUser(user)) { result.add(entry); } } diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/AddToGroupAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/AddToGroupAction.java index be2de69002..a44afb0c06 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/AddToGroupAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/AddToGroupAction.java @@ -51,6 +51,7 @@ import com.raytheon.uf.viz.core.icon.IconUtil; * Jul 3, 2012 bsteffen Initial creation * Dec 20, 2013 2563 bclement added support for ungrouped roster entries * Jan 24, 2014 2701 bclement removed local groups + * Apr 24, 2014 3070 bclement RosterChangeEvent changes * * * @@ -114,8 +115,9 @@ public class AddToGroupAction extends Action { if (entry != null) { // the entry wasn't in a group, so the entire tree needs to be // refreshed + UserId entryId = IDConverter.convertFrom(entry); connection.postEvent(new RosterChangeEvent(RosterChangeType.MODIFY, - entry)); + entryId)); } } diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/RemoveFromRosterAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/RemoveFromRosterAction.java index 91cc894ea9..118d1a3b0d 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/RemoveFromRosterAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/RemoveFromRosterAction.java @@ -26,6 +26,8 @@ import com.raytheon.uf.viz.collaboration.comm.identity.event.RosterChangeType; import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; import com.raytheon.uf.viz.collaboration.comm.provider.event.RosterChangeEvent; import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; +import com.raytheon.uf.viz.collaboration.comm.provider.user.IDConverter; +import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.core.icon.IconUtil; @@ -40,6 +42,7 @@ import com.raytheon.uf.viz.core.icon.IconUtil; * ------------ ---------- ----------- -------------------------- * Dec 20, 2013 2563 bclement Initial creation * Mar 05, 2014 2837 bclement changed wording from Roster to Contacts, added image + * Apr 24, 2014 3070 bclement RosterChangeEvent changes * * * @@ -64,7 +67,8 @@ public class RemoveFromRosterAction extends Action { ContactsManager manager = connection .getContactsManager(); manager.removeFromRoster(entry); + UserId entryId = IDConverter.convertFrom(entry); connection.postEvent(new RosterChangeEvent(RosterChangeType.DELETE, - entry)); + entryId)); } } diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/SendSubReqAction.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/SendSubReqAction.java index e9a5dd5b0d..d864e7f4b5 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/SendSubReqAction.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/actions/SendSubReqAction.java @@ -21,12 +21,10 @@ package com.raytheon.uf.viz.collaboration.ui.actions; import org.eclipse.jface.action.Action; import org.jivesoftware.smack.RosterEntry; -import org.jivesoftware.smack.packet.Presence; -import org.jivesoftware.smack.packet.Presence.Type; import com.raytheon.uf.viz.collaboration.comm.identity.CollaborationException; -import com.raytheon.uf.viz.collaboration.comm.identity.IAccountManager; import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; import com.raytheon.uf.viz.collaboration.comm.provider.user.IDConverter; import com.raytheon.uf.viz.collaboration.ui.Activator; import com.raytheon.uf.viz.core.icon.IconUtil; @@ -42,6 +40,7 @@ import com.raytheon.uf.viz.core.icon.IconUtil; * ------------ ---------- ----------- -------------------------- * Jan 24, 2014 bclement Initial creation * Mar 05, 2014 2837 bclement added image + * Apr 24, 2014 3070 bclement moved contact request logic to contacts manager * * * @@ -71,10 +70,9 @@ public class SendSubReqAction extends Action { @Override public void run() { CollaborationConnection connection = CollaborationConnection.getConnection(); - IAccountManager manager = connection.getAccountManager(); + ContactsManager manager = connection.getContactsManager(); try { - manager.sendPresence(IDConverter.convertFrom(entry), new Presence( - Type.subscribe)); + manager.sendContactRequest(IDConverter.convertFrom(entry)); } catch (CollaborationException e) { Activator.statusHandler.error( "Unable to send subscription request", e); diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/CollabPrefConstants.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/CollabPrefConstants.java index f7d2b6dcc3..fbc0a327b5 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/CollabPrefConstants.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/CollabPrefConstants.java @@ -34,6 +34,7 @@ package com.raytheon.uf.viz.collaboration.ui.prefs; * Feb 3, 2014 2699 bclement added handle preferences * Feb 18, 2014 2631 mpduff Add constants for room change events. * Mar 24, 2014 2936 mpduff Remove INCLUDE_NWS_FEED_FIELD_EDITOR_ID. + * Apr 24, 2014 3070 bclement added DEFAULT_GROUPNAME_PREF * * * @@ -62,6 +63,8 @@ public class CollabPrefConstants { public static final String CUSTOM_HANDLE = "customHandle"; + public static final String DEFAULT_GROUPNAME_PREF = "defaultGroupName"; + public static final int AWAY_TIMEOUT_DEFAULT = 10; // ten minutes /** Enable join events field editor id */ diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/SubscriptionResponderImpl.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/SubscriptionResponderImpl.java index 8759920497..06312f91bd 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/SubscriptionResponderImpl.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/prefs/SubscriptionResponderImpl.java @@ -19,7 +19,6 @@ **/ package com.raytheon.uf.viz.collaboration.ui.prefs; -import java.util.Collection; import java.util.Collections; import java.util.Set; import java.util.concurrent.ConcurrentHashMap; @@ -27,7 +26,6 @@ import java.util.concurrent.ConcurrentHashMap; import org.eclipse.jface.preference.IPersistentPreferenceStore; import org.eclipse.swt.widgets.Display; import org.eclipse.swt.widgets.Shell; -import org.jivesoftware.smack.RosterGroup; import org.jivesoftware.smack.XMPPException; import com.raytheon.uf.common.status.IUFStatusHandler; @@ -36,6 +34,7 @@ import com.raytheon.uf.viz.collaboration.comm.identity.roster.ISubscriptionRespo import com.raytheon.uf.viz.collaboration.comm.identity.roster.SubscriptionResponse; import com.raytheon.uf.viz.collaboration.comm.provider.account.ISubscriptionRequestCompleteAction; import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationConnection; +import com.raytheon.uf.viz.collaboration.comm.provider.user.ContactsManager; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserId; import com.raytheon.uf.viz.collaboration.comm.provider.user.UserSearch; import com.raytheon.uf.viz.collaboration.ui.Activator; @@ -52,6 +51,8 @@ import com.raytheon.uf.viz.core.VizApp; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Apr 03, 2014 2785 mpduff Initial creation + * Apr 24, 2014 3070 bclement added default group for auto accept + * fixed auto accept known contacts * * * @@ -88,15 +89,16 @@ public class SubscriptionResponderImpl implements ISubscriptionResponder { .getPreferenceStore(); if (prefs.getBoolean(CollabPrefConstants.AUTO_ACCEPT_SUBSCRIBE)) { rval.setAccepted(true); + rval.setGroup(prefs + .getString(CollabPrefConstants.DEFAULT_GROUPNAME_PREF)); action.executeSubscriptionRequestComplete(fromID, rval); return; } CollaborationConnection conn = CollaborationConnection.getConnection(); - Collection groups = conn.getContactsManager().getGroups( - fromID); - if (!groups.isEmpty()) { - // we already have this user in a group in our roster + ContactsManager cm = conn.getContactsManager(); + if (cm.isContact(fromID)) { + /* we already have a subscription to this user */ rval.setAccepted(true); action.executeSubscriptionRequestComplete(fromID, rval); } else { From 3a2a6afaf10fc18336de2ef6c7616300ebc10387 Mon Sep 17 00:00:00 2001 From: Roger Ferrel Date: Thu, 24 Apr 2014 16:02:31 -0500 Subject: [PATCH 101/188] Issue #3045 Change column label to "Data Set". Change-Id: I4088fb29fd942ecc07c82e3da24d9561cb3b1b13 Former-commit-id: f00ce42d8e79ef47d9b14125dc61129fc60fc0cf --- .../com/raytheon/uf/viz/archive/data/SizeJob.java | 2 +- .../uf/viz/archive/ui/ArchiveTableComp.java | 15 +++++++++++---- .../uf/viz/archive/ui/CaseCreationDlg.java | 2 +- 3 files changed, 13 insertions(+), 6 deletions(-) diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/data/SizeJob.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/data/SizeJob.java index 2724cf7bc5..a9735621ce 100644 --- a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/data/SizeJob.java +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/data/SizeJob.java @@ -899,7 +899,7 @@ public class SizeJob extends Job { public LoadDisplayDataJob( ILoadDisplayDataListener loadDisplayDataListener, int loadDisplayDataCnt) { - super("Loading Category labels"); + super("Loading Data Sets"); this.loadDisplayDataListener = loadDisplayDataListener; this.loadDisplayDataCnt = loadDisplayDataCnt; } diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveTableComp.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveTableComp.java index a11a6c90a6..921cbcccd8 100644 --- a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveTableComp.java +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/ArchiveTableComp.java @@ -64,7 +64,7 @@ import com.raytheon.uf.viz.archive.data.SizeJob; * Aug 06, 2013 #2222 rferrel Changes to display all selected data. * Aug 14, 2013 #2220 rferrel Add refresh method. * Aug 26, 2013 #2225 rferrel Add missing updates. - * Apr 23, 2014 #3045 rferrel Added clearTable method. + * Apr 23, 2014 #3045 rferrel Added clearTable method and new column name. * * * @@ -73,12 +73,19 @@ import com.raytheon.uf.viz.archive.data.SizeJob; */ public class ArchiveTableComp extends Composite { + /** Column label when table displaying category information. */ + private final String CATEGORY_COL_LABEL = "Data Set"; + + /** Column label when table displaying select all information. */ + private final String SEL_ALL_COL_LABEL = "Archive | Category | Data Set"; + /** Column to display label information. */ private final int LABEL_COL_INDEX = 0; /** Column to display size information,. */ private final int SIZE_COL_INDEX = 1; + /** Flag to indicate all selections are being displayed. */ private boolean showSelectAll = false; /** Name of table's archive. */ @@ -207,7 +214,7 @@ public class ArchiveTableComp extends Composite { }); TableColumn pathColumn = new TableColumn(table, SWT.LEFT); - pathColumn.setText("Label"); + pathColumn.setText(CATEGORY_COL_LABEL); TableColumn sizeColumn = new TableColumn(table, SWT.CENTER); if (type == Type.Retention) { @@ -466,7 +473,7 @@ public class ArchiveTableComp extends Composite { protected void populateTable(String archiveName, String categoryName, List displayDatas) { showSelectAll = false; - table.getColumn(0).setText("Label"); + table.getColumn(0).setText(CATEGORY_COL_LABEL); populateTable(displayDatas); } @@ -484,7 +491,7 @@ public class ArchiveTableComp extends Composite { */ protected void populateSelectAll(List displayDatas) { showSelectAll = true; - table.getColumn(0).setText("Archive | Category | Label"); + table.getColumn(0).setText(SEL_ALL_COL_LABEL); populateTable(displayDatas); } diff --git a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationDlg.java b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationDlg.java index 4d201d27ec..d12c364d6a 100644 --- a/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationDlg.java +++ b/cave/com.raytheon.uf.viz.archive/src/com/raytheon/uf/viz/archive/ui/CaseCreationDlg.java @@ -495,7 +495,7 @@ public class CaseCreationDlg extends AbstractArchiveDlg { // } // }); - String tooltip = "Waiting on loading of table labels."; + String tooltip = "Waiting on loading of Data Sets."; Color color = shell.getDisplay().getSystemColor(SWT.COLOR_YELLOW); saveBtn = new Button(actionControlComp, SWT.PUSH); saveBtn.setText(" Save "); From 37342cba87edfa815891f8c6ea86b8dbb93628ff Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Thu, 24 Apr 2014 17:52:52 -0500 Subject: [PATCH 102/188] Issue #2726: Add hooks to stop archiving processes during shutdown. Change-Id: I16a219d8300eae431a8baaf27bcb00707908c67a Former-commit-id: 75ec73e02885fe0f646bc8961f3ea876597abab9 --- .../META-INF/MANIFEST.MF | 2 +- .../META-INF/MANIFEST.MF | 2 +- .../META-INF/MANIFEST.MF | 2 +- cots/org.jep.win64/META-INF/MANIFEST.MF | 2 +- .../META-INF/MANIFEST.MF | 2 +- .../META-INF/MANIFEST.MF | 2 +- .../META-INF/MANIFEST.MF | 2 +- .../META-INF/MANIFEST.MF | 2 +- .../META-INF/MANIFEST.MF | 2 +- .../archive/DatabaseArchiveProcessor.java | 14 +- .../uf/edex/archive/DatabaseArchiver.java | 12 +- .../archive/purge/ArchivePurgeManager.java | 19 +- .../uf/edex/archive/purge/ArchivePurger.java | 49 ++--- .../META-INF/MANIFEST.MF | 2 +- .../feature.xml | 14 -- .../META-INF/MANIFEST.MF | 3 +- .../com/raytheon/uf/edex/core/EDEXUtil.java | 32 ++++ .../uf/edex/core/EdexTimerBasedThread.java | 20 ++- .../core/exception/ShutdownException.java | 71 ++++++++ .../uf/edex/database/dao/CoreDao.java | 37 ++-- .../processor/IDatabaseProcessor.java | 4 +- .../META-INF/MANIFEST.MF | 2 +- .../esb/camel/context/ContextManager.java | 168 +++++++----------- .../META-INF/MANIFEST.MF | 2 +- .../META-INF/MANIFEST.MF | 2 +- .../ModelSoundingPersistenceManager.java | 9 +- .../raytheon/uf/edex/stats/dao/StatsDao.java | 3 +- 27 files changed, 289 insertions(+), 192 deletions(-) create mode 100644 edexOsgi/com.raytheon.uf.edex.core/src/com/raytheon/uf/edex/core/exception/ShutdownException.java diff --git a/cave/com.raytheon.uf.viz.ccfp/META-INF/MANIFEST.MF b/cave/com.raytheon.uf.viz.ccfp/META-INF/MANIFEST.MF index fdcfff3df6..d43165c4b5 100644 --- a/cave/com.raytheon.uf.viz.ccfp/META-INF/MANIFEST.MF +++ b/cave/com.raytheon.uf.viz.ccfp/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Ccfp Plug-in Bundle-SymbolicName: com.raytheon.uf.viz.ccfp;singleton:=true -Bundle-Version: 1.14.0 +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: RAYTHEON Require-Bundle: com.raytheon.uf.viz.core Bundle-RequiredExecutionEnvironment: JavaSE-1.6 diff --git a/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF b/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF index a555b1bdeb..bf91f504a6 100644 --- a/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF +++ b/cave/com.raytheon.viz.aviation/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Aviation Plug-in Bundle-SymbolicName: com.raytheon.viz.aviation;singleton:=true -Bundle-Version: 1.14.0 +Bundle-Version: 1.14.0.qualifier Bundle-Activator: com.raytheon.viz.aviation.activator.Activator Bundle-Vendor: Raytheon Require-Bundle: org.eclipse.ui, diff --git a/cots/javax.media.opengl.win64/META-INF/MANIFEST.MF b/cots/javax.media.opengl.win64/META-INF/MANIFEST.MF index 13762725cb..14689af0b7 100644 --- a/cots/javax.media.opengl.win64/META-INF/MANIFEST.MF +++ b/cots/javax.media.opengl.win64/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: JOGL Win64 Specific Fragment Bundle-SymbolicName: javax.media.opengl.win64 -Bundle-Version: 1.14.0 +Bundle-Version: 1.14.0.qualifier Fragment-Host: javax.media.opengl;bundle-version="1.1.1" Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Eclipse-PlatformFilter: (& (osgi.os=win32) (osgi.arch=x86_64)) diff --git a/cots/org.jep.win64/META-INF/MANIFEST.MF b/cots/org.jep.win64/META-INF/MANIFEST.MF index 9d6e46be92..e8e64d6361 100644 --- a/cots/org.jep.win64/META-INF/MANIFEST.MF +++ b/cots/org.jep.win64/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Windows 64-bit Jep Library Bundle-SymbolicName: org.jep.win64 -Bundle-Version: 1.14.0 +Bundle-Version: 1.14.0.qualifier Fragment-Host: org.jep;bundle-version="2.3.0" Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Eclipse-PlatformFilter: (& (osgi.os=win32) (osgi.arch=x86_64)) diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/META-INF/MANIFEST.MF index 2ddf9956a1..7eab7f3790 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.ccfp/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: CCFP common Plug-in Bundle-SymbolicName: com.raytheon.uf.common.dataplugin.ccfp -Bundle-Version: 1.14.0 +Bundle-Version: 1.14.0.qualifier Eclipse-RegisterBuddy: com.raytheon.uf.common.serialization Bundle-Vendor: RAYTHEON Bundle-RequiredExecutionEnvironment: JavaSE-1.6 diff --git a/edexOsgi/com.raytheon.uf.common.http/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.http/META-INF/MANIFEST.MF index 3dcded65af..72c039815b 100644 --- a/edexOsgi/com.raytheon.uf.common.http/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.http/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Common Http Bundle-SymbolicName: com.raytheon.uf.common.http -Bundle-Version: 1.14.0 +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: RAYTHEON Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Export-Package: com.raytheon.uf.common.http, diff --git a/edexOsgi/com.raytheon.uf.common.localization/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.localization/META-INF/MANIFEST.MF index f0fbbca4ad..5f5fabcd45 100644 --- a/edexOsgi/com.raytheon.uf.common.localization/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.localization/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Localization Plug-in Bundle-SymbolicName: com.raytheon.uf.common.localization -Bundle-Version: 1.14.0 +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: Raytheon Require-Bundle: org.apache.commons.lang, com.raytheon.uf.common.serialization, diff --git a/edexOsgi/com.raytheon.uf.common.nc.bufr/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.nc.bufr/META-INF/MANIFEST.MF index 231e4193a2..0a56fc8735 100644 --- a/edexOsgi/com.raytheon.uf.common.nc.bufr/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.nc.bufr/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: NetCDF Bufr Bundle-SymbolicName: com.raytheon.uf.common.nc.bufr -Bundle-Version: 1.14.0 +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: RAYTHEON Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Require-Bundle: ucar.nc2, diff --git a/edexOsgi/com.raytheon.uf.common.util/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.util/META-INF/MANIFEST.MF index d82760aedd..2cabab5d90 100644 --- a/edexOsgi/com.raytheon.uf.common.util/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.util/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Utility Plug-in Bundle-SymbolicName: com.raytheon.uf.common.util -Bundle-Version: 1.14.0 +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: RAYTHEON Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Require-Bundle: org.apache.commons.beanutils;bundle-version="1.8.3", diff --git a/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/DatabaseArchiveProcessor.java b/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/DatabaseArchiveProcessor.java index 646061083c..60d40d15e5 100644 --- a/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/DatabaseArchiveProcessor.java +++ b/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/DatabaseArchiveProcessor.java @@ -59,7 +59,9 @@ import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.util.FileUtil; +import com.raytheon.uf.edex.core.EDEXUtil; import com.raytheon.uf.edex.core.dataplugin.PluginRegistry; +import com.raytheon.uf.edex.core.exception.ShutdownException; import com.raytheon.uf.edex.database.plugin.PluginDao; import com.raytheon.uf.edex.database.processor.IDatabaseProcessor; @@ -78,6 +80,7 @@ import com.raytheon.uf.edex.database.processor.IDatabaseProcessor; * Jan 23, 2014 2555 rjpeter Updated to be a row at a time using ScrollableResults. * Feb 04, 2014 2770 rferrel The dumpPdos now dumps all PluginDataObjects. * Feb 12, 2014 2784 rjpeter Update logging for dup elim scenarios. + * Apr 23, 2014 2726 rjpeter Add shutdown checks to allow for timely shutdown. * * * @author rjpeter @@ -143,7 +146,7 @@ public class DatabaseArchiveProcessor> * .util.List) */ @Override - public boolean process(T object) { + public boolean process(T object) throws ShutdownException { if (object != null) { if (pdosByFile == null) { pdosByFile = new HashMap>>( @@ -191,7 +194,7 @@ public class DatabaseArchiveProcessor> * archives any associated hdf5 files. */ @Override - public void finish() { + public void finish() throws ShutdownException { if (entriesInMemory > 0) { try { savePdoMap(pdosByFile); @@ -228,6 +231,7 @@ public class DatabaseArchiveProcessor> } for (String dataStoreFile : datastoreFilesToArchive) { + EDEXUtil.checkShuttingDown(); IDataStore ds = DataStoreFactory.getDataStore(new File(FileUtil .join(pluginName, dataStoreFile))); // all dataStore files should end with .h5 @@ -346,12 +350,13 @@ public class DatabaseArchiveProcessor> * @throws IOException */ protected void savePdoMap(Map>> pdoMap) - throws SerializationException, IOException { + throws SerializationException, IOException, ShutdownException { StringBuilder baseDir = new StringBuilder(160); Set identifierSet = null; for (Map.Entry>> entry : pdoMap .entrySet()) { + EDEXUtil.checkShuttingDown(); baseDir.setLength(0); baseDir.append(archivePath).append(File.separator) .append(pluginName).append(File.separator) @@ -421,10 +426,11 @@ public class DatabaseArchiveProcessor> protected List> dupElimPreviousFiles( SortedMap fileMap, List> pdos, Set identifierSet) - throws IOException, SerializationException { + throws IOException, SerializationException, ShutdownException { if (!fileMap.isEmpty()) { Iterator fileIter = fileMap.values().iterator(); while (fileIter.hasNext()) { + EDEXUtil.checkShuttingDown(); File dataFile = fileIter.next(); int dupElimUntil = Integer.MAX_VALUE; FileStatus prevFileStatus = filesCreatedThisSession diff --git a/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/DatabaseArchiver.java b/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/DatabaseArchiver.java index 4f762aa9ff..a3facab329 100644 --- a/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/DatabaseArchiver.java +++ b/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/DatabaseArchiver.java @@ -38,6 +38,7 @@ import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.time.util.TimeUtil; +import com.raytheon.uf.edex.core.EDEXUtil; import com.raytheon.uf.edex.core.dataplugin.PluginRegistry; import com.raytheon.uf.edex.database.DataAccessLayerException; import com.raytheon.uf.edex.database.cluster.ClusterLockUtils; @@ -67,6 +68,7 @@ import com.raytheon.uf.edex.database.plugin.PluginFactory; * Dec 13, 2013 2555 rjpeter Refactored logic into DatabaseArchiveProcessor. * Feb 12, 2014 2784 rjpeter Fixed clusterLock to not update the time by default. * Apr 01, 2014 2862 rferrel Add exclusive lock at plug-in level. + * Apr 23, 2014 2726 rjpeter Added shutdown hook for quicker shutdown while archiver is running. * * * @author rjpeter @@ -92,7 +94,7 @@ public class DatabaseArchiver implements IPluginArchiver { private static final long MIN_DURATION_MILLIS = 30 * TimeUtil.MILLIS_PER_MINUTE; /** Maximum time increment to archive, note based off of insertTime. */ - private static final long MAX_DURATION_MILLIS = 120 * TimeUtil.MILLIS_PER_MINUTE; + private static final long MAX_DURATION_MILLIS = 60 * TimeUtil.MILLIS_PER_MINUTE; /** Default batch size for database queries */ private static final Integer defaultBatchSize = 10000; @@ -210,6 +212,10 @@ public class DatabaseArchiver implements IPluginArchiver { } public void archivePluginData(String pluginName, String archivePath) { + if (EDEXUtil.isShuttingDown()) { + return; + } + File archiveDir = new File(archivePath); File pluginDir = new File(archiveDir, pluginName); ClusterTask ctPlugin = getWriteLock(pluginDir.getAbsolutePath()); @@ -281,8 +287,8 @@ public class DatabaseArchiver implements IPluginArchiver { processor.setDebugArchiver(debugArchiver); processor.setBatchSize(batchSize.intValue()); - while ((startTime != null) && (endTime != null) - && !processor.isFailed()) { + while (!EDEXUtil.isShuttingDown() && (startTime != null) + && (endTime != null) && !processor.isFailed()) { statusHandler.info(pluginName + ": Checking for records from " + TimeUtil.formatDate(startTime) + " to " + TimeUtil.formatDate(endTime)); diff --git a/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/purge/ArchivePurgeManager.java b/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/purge/ArchivePurgeManager.java index a559eb5e37..1ff098d62d 100644 --- a/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/purge/ArchivePurgeManager.java +++ b/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/purge/ArchivePurgeManager.java @@ -43,6 +43,8 @@ import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.time.util.ITimer; import com.raytheon.uf.common.time.util.TimeUtil; +import com.raytheon.uf.edex.core.EDEXUtil; +import com.raytheon.uf.edex.core.exception.ShutdownException; import com.raytheon.uf.edex.database.cluster.ClusterLockUtils; import com.raytheon.uf.edex.database.cluster.ClusterLockUtils.LockState; import com.raytheon.uf.edex.database.cluster.ClusterTask; @@ -61,7 +63,7 @@ import com.raytheon.uf.edex.database.cluster.handler.SharedLockHandler.LockType; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Apr 01, 2014 2862 rferrel Initial creation - * + * Apr 24, 2014 2726 rjpeter Added shutdown cancel * * * @author rferrel @@ -107,7 +109,8 @@ public class ArchivePurgeManager { * @param archive * @return purgeCount */ - public int purgeExpiredFromArchive(ArchiveConfig archive) { + public int purgeExpiredFromArchive(ArchiveConfig archive) + throws ShutdownException { String archiveRootDirPath = archive.getRootDir(); File archiveRootDir = new File(archiveRootDirPath); @@ -332,7 +335,9 @@ public class ArchivePurgeManager { private int purgeDir(File dir, IOFileFilter defaultTimeFilter, Calendar minPurgeTime, Calendar extPurgeTime, CategoryFileDateHelper helper, CategoryConfig category, - ClusterTask ct) { + ClusterTask ct) throws ShutdownException { + EDEXUtil.checkShuttingDown(); + int purgeCount = 0; File[] dirFiles = dir.listFiles(); @@ -342,6 +347,7 @@ public class ArchivePurgeManager { } for (File file : dirFiles) { + EDEXUtil.checkShuttingDown(); updateLockTime(ct); if (!file.isHidden()) { @@ -408,13 +414,18 @@ public class ArchivePurgeManager { * @param fileDataFilter * @return purgeCount */ - private int purgeDir(File dir, IOFileFilter fileDataFilter) { + private int purgeDir(File dir, IOFileFilter fileDataFilter) + throws ShutdownException { + EDEXUtil.checkShuttingDown(); + int purgeCount = 0; File[] dirFiles = dir.listFiles(); if (dirFiles == null) { sendPurgeMessage(); } else { for (File file : dirFiles) { + EDEXUtil.checkShuttingDown(); + if (!file.isHidden()) { if (file.isDirectory()) { purgeCount += purgeDir(file, fileDataFilter); diff --git a/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/purge/ArchivePurger.java b/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/purge/ArchivePurger.java index e011d6673f..4c022f3a4d 100644 --- a/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/purge/ArchivePurger.java +++ b/edexOsgi/com.raytheon.uf.edex.archive/src/com/raytheon/uf/edex/archive/purge/ArchivePurger.java @@ -27,6 +27,7 @@ import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.time.util.ITimer; import com.raytheon.uf.common.time.util.TimeUtil; +import com.raytheon.uf.edex.core.exception.ShutdownException; /** * Purge task to purge archived data based on configured expiration. @@ -67,29 +68,37 @@ public class ArchivePurger { ITimer timer = TimeUtil.getTimer(); timer.start(); statusHandler.info("Archive Purge started."); - ArchivePurgeManager manager = ArchivePurgeManager.getInstance(); - manager.reset(); - Collection archives = manager.getArchives(); - for (ArchiveConfig archive : archives) { - ITimer archiveTimer = TimeUtil.getTimer(); - archiveTimer.start(); - int purgeCount = manager.purgeExpiredFromArchive(archive); - if (statusHandler.isPriorityEnabled(Priority.INFO)) { - StringBuilder sb = new StringBuilder(archive.getName()); - sb.append("::Archive Purged "); - sb.append(purgeCount); - sb.append(" file"); - if (purgeCount != 1) { - sb.append("s"); + try { + ArchivePurgeManager manager = ArchivePurgeManager.getInstance(); + manager.reset(); + Collection archives = manager.getArchives(); + for (ArchiveConfig archive : archives) { + ITimer archiveTimer = TimeUtil.getTimer(); + archiveTimer.start(); + int purgeCount = manager.purgeExpiredFromArchive(archive); + if (statusHandler.isPriorityEnabled(Priority.INFO)) { + StringBuilder sb = new StringBuilder(archive.getName()); + sb.append("::Archive Purged "); + sb.append(purgeCount); + sb.append(" file"); + if (purgeCount != 1) { + sb.append("s"); + } + sb.append(" in ") + .append(TimeUtil.prettyDuration(archiveTimer + .getElapsedTime())).append("."); + statusHandler.info(sb.toString()); } - sb.append(" in ") - .append(TimeUtil.prettyDuration(archiveTimer - .getElapsedTime())).append("."); - statusHandler.info(sb.toString()); } + + statusHandler.info("Archive Purge finished. Time to run: " + + TimeUtil.prettyDuration(timer.getElapsedTime())); + } catch (ShutdownException e) { + statusHandler + .info("Aborting Purge due to EDEX shutdown being initiated. Time to run: " + + TimeUtil.prettyDuration(timer + .getElapsedTime())); } - statusHandler.info("Archive Purge finished. Time to run: " - + TimeUtil.prettyDuration(timer.getElapsedTime())); } else { statusHandler.info("Archive Purge disabled, exiting"); } diff --git a/edexOsgi/com.raytheon.uf.edex.auth/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.auth/META-INF/MANIFEST.MF index d69c756259..23cb2c18dc 100644 --- a/edexOsgi/com.raytheon.uf.edex.auth/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.auth/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Auth Plug-in Bundle-SymbolicName: com.raytheon.uf.edex.auth -Bundle-Version: 1.14.0 +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: RAYTHEON Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Require-Bundle: com.raytheon.uf.common.serialization;bundle-version="1.11.31", diff --git a/edexOsgi/com.raytheon.uf.edex.common.core.feature/feature.xml b/edexOsgi/com.raytheon.uf.edex.common.core.feature/feature.xml index 394a231c84..32e469db17 100644 --- a/edexOsgi/com.raytheon.uf.edex.common.core.feature/feature.xml +++ b/edexOsgi/com.raytheon.uf.edex.common.core.feature/feature.xml @@ -84,20 +84,6 @@ version="0.0.0" unpack="false"/> - - - - + * + * SOFTWARE HISTORY + * + * Date Ticket# Engineer Description + * ------------ ---------- ----------- -------------------------- + * Apr 23, 2014 2726 rjpeter Initial creation + * + * + * + * @author rjpeter + * @version 1.0 + */ +public class ShutdownException extends EdexException { + + /** + * Default serial verion UID + */ + private static final long serialVersionUID = 1L; + + public ShutdownException() { + super("Aborting process, EDEX shutting down"); + } + + /** + * Create a Shutdown Exception instance from only a message + * + * @param message + */ + public ShutdownException(String message) { + super(message); + } + + /** + * Create a Shutdown Exception instance from both a message and a cause + * + * @param message + * @param cause + */ + public ShutdownException(String message, Throwable cause) { + super(message, cause); + } + +} diff --git a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/dao/CoreDao.java b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/dao/CoreDao.java index 9318c58209..943b272171 100644 --- a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/dao/CoreDao.java +++ b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/dao/CoreDao.java @@ -99,7 +99,8 @@ import com.raytheon.uf.edex.database.query.DatabaseQuery; * Apr 15, 2013 1868 bsteffen Rewrite mergeAll in PluginDao. * Nov 08, 2013 2361 njensen Changed method signature of saveOrUpdate to take Objects, not PersistableDataObjects * Dec 13, 2013 2555 rjpeter Added processByCriteria and fixed Generics warnings. - * Jan 23, 2014 2555 rjpeter Updated processByCriteriato be a row at a time using ScrollableResults. + * Jan 23, 2014 2555 rjpeter Updated processByCriteria to be a row at a time using ScrollableResults. + * Apr 23, 2014 2726 rjpeter Updated processByCriteria to throw exceptions back up to caller. * * * @author bphillip @@ -494,24 +495,34 @@ public class CoreDao extends HibernateDaoSupport { .scroll(ScrollMode.FORWARD_ONLY); boolean continueProcessing = true; - while (rs.next() && continueProcessing) { - Object[] row = rs.get(); - if (row.length > 0) { - continueProcessing = processor - .process((T) row[0]); - } - count++; - if ((count % batchSize) == 0) { - getSession().clear(); + try { + while (rs.next() && continueProcessing) { + Object[] row = rs.get(); + if (row.length > 0) { + continueProcessing = processor + .process((T) row[0]); + } + count++; + if ((count % batchSize) == 0) { + getSession().clear(); + } } + processor.finish(); + } catch (Exception e) { + /* + * Only way to propogate the error to the caller + * is to throw a runtime exception + */ + throw new RuntimeException( + "Error occurred during processing", e); } - processor.finish(); return count; } }); - } catch (TransactionException e) { - throw new DataAccessLayerException("Transaction failed", e); + } catch (Exception e) { + throw new DataAccessLayerException( + "Error occurred during processing", e); } return rowsProcessed; diff --git a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/processor/IDatabaseProcessor.java b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/processor/IDatabaseProcessor.java index 0a3a4e7e73..a0fa49ae20 100644 --- a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/processor/IDatabaseProcessor.java +++ b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/processor/IDatabaseProcessor.java @@ -44,12 +44,12 @@ public interface IDatabaseProcessor { * @param row * @return True if should continue processing, false otherwise. */ - public boolean process(T row); + public boolean process(T row) throws Exception; /** * Perform any post processing if necessary. */ - public void finish(); + public void finish() throws Exception; /** * Get the batch size of the query. diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.esb.camel/META-INF/MANIFEST.MF index cf2c77856c..57d55f2f8b 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Camel Plug-in Bundle-SymbolicName: com.raytheon.uf.edex.esb.camel -Bundle-Version: 1.14.0 +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: Raytheon Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Require-Bundle: org.apache.camel;bundle-version="1.0.0", diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java index 231a546fda..7490a1e673 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java @@ -155,7 +155,7 @@ public class ContextManager implements ApplicationContextAware, .addAll(ContextDependencyMapping.DEPENDENCY_ENDPOINT_TYPES); internalEndpointTypes.add("timer"); internalEndpointTypes.add("quartz"); - internalEndpointTypes.add("clusteredquartz"); + internalEndpointTypes.add("direct"); } /** @@ -343,117 +343,18 @@ public class ContextManager implements ApplicationContextAware, .info("Spring Context not set. Start up never completed, cannot orderly shutdown"); } - statusHandler.info("Context Manager stopping routes"); + statusHandler.info("Context Manager stopping contexts"); try { - /* - * begin immediate shutdown of routes that are not an internal - * type - */ - LinkedList routesToStop = new LinkedList(); ContextData ctxData = getContextData(); List contexts = ctxData.getContexts(); List>> callbacks = new LinkedList>>(); for (final CamelContext context : contexts) { - /* - * group routes by context due to sync lock at context level - * for stopping a route - */ - List routes = context.getRoutes(); - if ((routes != null) && (routes.size() > 0)) { - for (Route route : routes) { - String uri = route.getEndpoint().getEndpointUri(); - Pair typeAndName = ContextData - .getEndpointTypeAndName(uri); - String type = typeAndName.getFirst(); - if (!internalEndpointTypes.contains(type)) { - routesToStop.add(route); - } - } - } - if (routesToStop.size() > 0) { - final IContextStateManager stateMgr = getStateManager(context); - final List tmp = routesToStop; - callbacks - .add(service - .submit(new Callable>() { - @Override - public Pair call() - throws Exception { - boolean rval = true; - for (Route route : tmp) { - try { - statusHandler.info("Stopping route [" - + route.getId() - + "]"); - rval &= stateMgr - .stopRoute(route); - } catch (Exception e) { - statusHandler.error( - "Error occurred closing route: " - + route.getId(), - e); - } - } - - return new Pair( - context, rval); - } - })); - routesToStop = new LinkedList(); - } + callbacks.add(service.submit(new StopContext(context))); } List failures = waitForCallbacks(callbacks, - "Waiting for external routes to shutdown: ", 1000); - - for (CamelContext failure : failures) { - statusHandler.error("Context [" + failure.getName() - + "] has routes that failed to stop"); - } - - statusHandler.info("Shutting down contexts"); - - for (final CamelContext context : contexts) { - final IContextStateManager stateManager = getStateManager(context); - if (stateManager.isContextStoppable(context)) { - callbacks - .add(service - .submit(new Callable>() { - @Override - public Pair call() - throws Exception { - boolean rval = false; - try { - statusHandler.info("Stopping context [" - + context.getName() - + "]"); - rval = stateManager - .stopContext(context); - - if (!rval) { - statusHandler.error("Context [" - + context - .getName() - + "] failed to stop"); - } - } catch (Throwable e) { - statusHandler.fatal( - "Error occurred stopping context: " - + context - .getName(), - e); - } - - return new Pair( - context, rval); - } - })); - } - } - - failures = waitForCallbacks(callbacks, "Waiting for contexts to shutdown: ", 1000); for (CamelContext failure : failures) { @@ -461,11 +362,72 @@ public class ContextManager implements ApplicationContextAware, + "] had a failure trying to stop"); } } catch (Throwable e) { - statusHandler.fatal("Error occurred during shutdown", e); + statusHandler.error("Error occurred during shutdown", e); } } } + /** + * Private Callable for stopping a context. If context not immediately + * stoppable will instead shutdown external routes first. + */ + private class StopContext implements Callable> { + final CamelContext context; + + private StopContext(CamelContext context) { + this.context = context; + } + + @Override + public Pair call() throws Exception { + boolean rval = false; + IContextStateManager stateManager = getStateManager(context); + + if (stateManager.isContextStoppable(context)) { + try { + statusHandler.info("Stopping context [" + context.getName() + + "]"); + rval = stateManager.stopContext(context); + + if (!rval) { + statusHandler.error("Context [" + context.getName() + + "] failed to stop"); + } + } catch (Throwable e) { + statusHandler.fatal("Error occurred stopping context: " + + context.getName(), e); + } + } else { + /* + * context not immediately stoppable, begin shutting down + * external routes instead + */ + List routes = context.getRoutes(); + rval = true; + + for (Route route : routes) { + String uri = route.getEndpoint().getEndpointUri(); + Pair typeAndName = ContextData + .getEndpointTypeAndName(uri); + String type = typeAndName.getFirst(); + if (!internalEndpointTypes.contains(type)) { + try { + statusHandler.info("Stopping route [" + + route.getId() + "]"); + rval &= stateManager.stopRoute(route); + } catch (Exception e) { + statusHandler.error( + "Error occurred Stopping route: " + + route.getId(), e); + } + } + } + } + + return new Pair(context, rval); + } + } + /** * Waits for all callbacks to finish printing a periodic message with number * of remaining callbacks. Returns a list of contexts that had a failure diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/META-INF/MANIFEST.MF index 73325d4bbe..69f18f6d58 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Bufrobs Bundle-SymbolicName: com.raytheon.uf.edex.plugin.bufrobs -Bundle-Version: 1.14.0 +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: RAYTHEON Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Require-Bundle: com.raytheon.uf.common.nc.bufr, diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/META-INF/MANIFEST.MF index ea432442f1..c46bd23971 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.plugin.ccfp/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: Ccfp Plug-in Bundle-SymbolicName: com.raytheon.uf.edex.plugin.ccfp -Bundle-Version: 1.14.0 +Bundle-Version: 1.14.0.qualifier Eclipse-RegisterBuddy: com.raytheon.uf.common.serialization, com.raytheon.edex.common Bundle-Vendor: RAYTHEON Require-Bundle: com.raytheon.edex.common, diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingPersistenceManager.java b/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingPersistenceManager.java index d9a3fb6e27..d4a1554cd8 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingPersistenceManager.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/src/com/raytheon/uf/edex/plugin/modelsounding/ModelSoundingPersistenceManager.java @@ -72,11 +72,13 @@ public class ModelSoundingPersistenceManager implements IContextStateProcessor { public void run() { run = true; - while (run) { + + // continue as long as there is data in the map + while (run || !containerMap.isEmpty()) { try { ModelSoundingStorageContainer container = null; synchronized (containerMap) { - while (containerMap.isEmpty() && run) { + while (run && containerMap.isEmpty()) { try { containerMap.wait(); } catch (InterruptedException e) { @@ -201,9 +203,8 @@ public class ModelSoundingPersistenceManager implements IContextStateProcessor { @Override public void preStop() { if (run) { - run = false; - synchronized (containerMap) { + run = false; containerMap.notifyAll(); while (!shutdown) { diff --git a/edexOsgi/com.raytheon.uf.edex.stats/src/com/raytheon/uf/edex/stats/dao/StatsDao.java b/edexOsgi/com.raytheon.uf.edex.stats/src/com/raytheon/uf/edex/stats/dao/StatsDao.java index 6965d305eb..ed506f2b06 100644 --- a/edexOsgi/com.raytheon.uf.edex.stats/src/com/raytheon/uf/edex/stats/dao/StatsDao.java +++ b/edexOsgi/com.raytheon.uf.edex.stats/src/com/raytheon/uf/edex/stats/dao/StatsDao.java @@ -117,8 +117,7 @@ public class StatsDao extends SessionManagedDao { sess = template.getSessionFactory().openStatelessSession(); // vacuum can't run within a transaction, hack to allow vacuum to // run from within hibernate - Query query = sess - .createSQLQuery("rollback; VACUUM ANALYZE events.stats"); + Query query = sess.createSQLQuery("rollback; VACUUM events.stats"); query.executeUpdate(); statusHandler.info("stats vacuumed"); } catch (Exception e) { From 2426e463f76b537e836f573b7eb73a3e05841e13 Mon Sep 17 00:00:00 2001 From: David Gillingham Date: Fri, 25 Apr 2014 10:53:30 -0500 Subject: [PATCH 103/188] Issue #2897: Add support for Multi-grid Hurricane Wave Models to D2D and GFE. Change-Id: I66e609d17afcfc900ceaf1b1eed328320d022fbb Former-commit-id: 33197dc6708b65e85233b51be1e99e6411ece60f --- .../localization/volumebrowser/VbSources.xml | 10 + .../base/grid/dataset/alias/gfeParamInfo.xml | 10 + .../base/config/gfe/serverConfig.py | 35 ++- .../base/grid/parameterInfo/AKHwave10.xml | 249 ++++++++++++++++++ .../base/grid/parameterInfo/AKHwave4.xml | 249 ++++++++++++++++++ .../base/grid/parameterInfo/GLOBHwave.xml | 249 ++++++++++++++++++ .../base/grid/parameterInfo/NAHwave10.xml | 249 ++++++++++++++++++ .../base/grid/parameterInfo/NAHwave15.xml | 249 ++++++++++++++++++ .../base/grid/parameterInfo/NAHwave4.xml | 249 ++++++++++++++++++ .../base/grid/parameterInfo/NPHwave10.xml | 249 ++++++++++++++++++ .../base/grid/parameterInfo/NPHwave15.xml | 249 ++++++++++++++++++ .../base/grid/parameterInfo/NPHwave4.xml | 249 ++++++++++++++++++ .../base/grid/parameterInfo/WPHwave10.xml | 249 ++++++++++++++++++ .../base/grib/models/gribModels_NCEP-7.xml | 100 +++++++ .../base/purge/gridPurgeRules.xml | 42 +++ 15 files changed, 2685 insertions(+), 2 deletions(-) create mode 100644 edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/AKHwave10.xml create mode 100644 edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/AKHwave4.xml create mode 100644 edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/GLOBHwave.xml create mode 100644 edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NAHwave10.xml create mode 100644 edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NAHwave15.xml create mode 100644 edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NAHwave4.xml create mode 100644 edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NPHwave10.xml create mode 100644 edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NPHwave15.xml create mode 100644 edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NPHwave4.xml create mode 100644 edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/WPHwave10.xml diff --git a/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/VbSources.xml b/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/VbSources.xml index 5fdfc623a8..669914444c 100644 --- a/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/VbSources.xml +++ b/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/VbSources.xml @@ -60,6 +60,8 @@ + + @@ -70,6 +72,7 @@ + @@ -86,7 +89,13 @@ + + + + + + @@ -123,6 +132,7 @@ + diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/common_static/base/grid/dataset/alias/gfeParamInfo.xml b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/common_static/base/grid/dataset/alias/gfeParamInfo.xml index c32bde4c53..e5c32fa5d4 100644 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/common_static/base/grid/dataset/alias/gfeParamInfo.xml +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/common_static/base/grid/dataset/alias/gfeParamInfo.xml @@ -195,4 +195,14 @@ rtofsGlobal rtofsGlobal rtofsGlobal + GLOBHwave + AKHwave10 + AKHwave4 + WPHwave10 + NPHwave15 + NPHwave10 + NPHwave4 + NAHwave15 + NAHwave10 + NAHwave4 diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/config/gfe/serverConfig.py b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/config/gfe/serverConfig.py index 5d0b3211b9..67b38d920f 100644 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/config/gfe/serverConfig.py +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/config/gfe/serverConfig.py @@ -37,6 +37,7 @@ # to get correct offsets for Alaska # 01/17/2014 #2719 randerso Added NHA domain # 02/20/2014 #2824 randerso Added log message when local override files are not found +# 03/11/2014 #2897 dgilling Add new MHWM databases to default configuration. # ######################################################################## @@ -1063,7 +1064,11 @@ if SID in ALASKA_SITES: 'RTOFS-Arctic', 'RTOFS-Bering', 'RTOFS-GulfAlaska', - 'RTOFS-HudsonBaffin' + 'RTOFS-HudsonBaffin', + 'NPHwave15', + 'AKHwave10', + 'AKHwave4', + 'GLOBHwave', ] # Hawaii OCONUS @@ -1082,6 +1087,10 @@ elif SID == "HFO": ('TPCWindProb', 'TPCProb'), ('ECMWF-HiRes','ECMWFHiRes'), 'RTOFS-Honolulu', + 'NPHwave15', + 'WPHwave10', + 'NPHwave4', + 'GLOBHwave', ] # San Juan OCONUS @@ -1105,6 +1114,10 @@ elif SID == "SJU": ('TPCWindProb', 'TPCProb'), ('ECMWF-HiRes','ECMWFHiRes'), 'RTOFS-Atlantic', + 'NAHwave15', + 'NAHwave10', + 'NAHwave4', + 'GLOBHwave', ] # Guam OCONUS @@ -1114,7 +1127,9 @@ elif SID == "GUM": 'GWW233', 'GlobalWave', ('TPCWindProb', 'TPCProb'), - 'RTOFS-Guam' + 'RTOFS-Guam', + 'WPHwave10', + 'GLOBHwave', ] #CONUS sites @@ -1165,6 +1180,14 @@ elif SID in CONUS_EAST_SITES: ('SPCGuide', 'SPC'), ('ECMWF-HiRes','ECMWFHiRes'), ('ENPWAVE253', 'ENPwave'), + 'NAHwave15', + 'NAHwave10', + 'NAHwave4', + 'NPHwave15', + 'NPHwave10', + 'NPHwave4', + 'WPHwave10', + 'GLOBHwave', ] else: #######DCS3501 WEST_CONUS @@ -1216,6 +1239,14 @@ else: #######DCS3501 WEST_CONUS ('SPCGuide', 'SPC'), ('ECMWF-HiRes','ECMWFHiRes'), ('ENPWAVE253', 'ENPwave'), + 'NAHwave15', + 'NAHwave10', + 'NAHwave4', + 'NPHwave15', + 'NPHwave10', + 'NPHwave4', + 'WPHwave10', + 'GLOBHwave', ] if SID in GreatLake_SITES: diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/AKHwave10.xml b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/AKHwave10.xml new file mode 100644 index 0000000000..c6d45c5352 --- /dev/null +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/AKHwave10.xml @@ -0,0 +1,249 @@ + + + + 0 + 10800 + 21600 + 32400 + 43200 + 54000 + 64800 + 75600 + 86400 + 97200 + 108000 + 118800 + 129600 + 140400 + 151200 + 162000 + 172800 + 183600 + 194400 + 205200 + 216000 + 226800 + 237600 + 248400 + 259200 + 280800 + 302400 + 324000 + 345600 + 367200 + 388800 + 410400 + 432000 + 453600 + + + perpw + Primary wave period + s + seconds + primaryWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + wvhgt + Wind wave height + m + meters + heightWindWaves + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + staticSpacing + Grid spacing + meters + -999999.0 + + + vw + v-component wind + m/s + meter/sec + vWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + swdir + Swell peak period direction + degree true + degree_True + swellWaveDir + 0.0 + 360.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + staticCoriolis + Coriolis parameter + /s + -999999.0 + + + wd + Wind Direction + degreeTrue + degree_True + windDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvdir + Direction of wind waves (from which) + degree true + degree_True + dirWindWaves + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvper + Wind wave peak period + s + seconds + peakPeriodWindWaves + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + htsgw + Sig height combined wind waves and swell + m + meters + heightWindWavesandSwell + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + swper + Swell wave peak period + s + seconds + swellWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + swell + Significant swell wave height + m + meters + heightSwellWaves + 0.0 + 50.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + dirpw + Primary wave direction + degree true + degree_True + primaryWaveDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + uw + u-component wind + m/s + meter/sec + uWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + ws + Wind Speed + m/s + meter/sec + windSpeed + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/AKHwave4.xml b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/AKHwave4.xml new file mode 100644 index 0000000000..c6d45c5352 --- /dev/null +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/AKHwave4.xml @@ -0,0 +1,249 @@ + + + + 0 + 10800 + 21600 + 32400 + 43200 + 54000 + 64800 + 75600 + 86400 + 97200 + 108000 + 118800 + 129600 + 140400 + 151200 + 162000 + 172800 + 183600 + 194400 + 205200 + 216000 + 226800 + 237600 + 248400 + 259200 + 280800 + 302400 + 324000 + 345600 + 367200 + 388800 + 410400 + 432000 + 453600 + + + perpw + Primary wave period + s + seconds + primaryWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + wvhgt + Wind wave height + m + meters + heightWindWaves + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + staticSpacing + Grid spacing + meters + -999999.0 + + + vw + v-component wind + m/s + meter/sec + vWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + swdir + Swell peak period direction + degree true + degree_True + swellWaveDir + 0.0 + 360.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + staticCoriolis + Coriolis parameter + /s + -999999.0 + + + wd + Wind Direction + degreeTrue + degree_True + windDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvdir + Direction of wind waves (from which) + degree true + degree_True + dirWindWaves + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvper + Wind wave peak period + s + seconds + peakPeriodWindWaves + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + htsgw + Sig height combined wind waves and swell + m + meters + heightWindWavesandSwell + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + swper + Swell wave peak period + s + seconds + swellWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + swell + Significant swell wave height + m + meters + heightSwellWaves + 0.0 + 50.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + dirpw + Primary wave direction + degree true + degree_True + primaryWaveDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + uw + u-component wind + m/s + meter/sec + uWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + ws + Wind Speed + m/s + meter/sec + windSpeed + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/GLOBHwave.xml b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/GLOBHwave.xml new file mode 100644 index 0000000000..75966a4a38 --- /dev/null +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/GLOBHwave.xml @@ -0,0 +1,249 @@ + + + + 0 + 10800 + 21600 + 32400 + 43200 + 54000 + 64800 + 75600 + 86400 + 97200 + 108000 + 118800 + 129600 + 140400 + 151200 + 162000 + 172800 + 183600 + 194400 + 205200 + 216000 + 226800 + 237600 + 248400 + 259200 + 280800 + 302400 + 324000 + 345600 + 367200 + 388800 + 410400 + 432000 + 453600 + + + perpw + Primary wave period + s + seconds + primaryWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + wvhgt + Wind wave height + m + meters + heightWindWaves + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + staticSpacing + Grid spacing + meters + -99999.0 + + + vw + v-component wind + m/s + meter/sec + vWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + swdir + Swell peak period direction + degree true + degree_True + swellWaveDir + 0.0 + 360.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + staticCoriolis + Coriolis parameter + /s + -999999.0 + + + wd + Wind Direction + degreeTrue + degree_True + windDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvdir + Direction of wind waves (from which) + degree true + degree_True + dirWindWaves + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvper + Wind wave peak period + s + seconds + peakPeriodWindWaves + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + htsgw + Sig height combined wind waves and swell + m + meters + heightWindWavesandSwell + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + swper + Swell wave peak period + s + seconds + swellWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + swell + Significant swell wave height + m + meters + heightSwellWaves + 0.0 + 50.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + dirpw + Primary wave direction + degree true + degree_True + primaryWaveDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + uw + u-component wind + m/s + meter/sec + uWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + ws + Wind Speed + m/s + meter/sec + windSpeed + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NAHwave10.xml b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NAHwave10.xml new file mode 100644 index 0000000000..c6d45c5352 --- /dev/null +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NAHwave10.xml @@ -0,0 +1,249 @@ + + + + 0 + 10800 + 21600 + 32400 + 43200 + 54000 + 64800 + 75600 + 86400 + 97200 + 108000 + 118800 + 129600 + 140400 + 151200 + 162000 + 172800 + 183600 + 194400 + 205200 + 216000 + 226800 + 237600 + 248400 + 259200 + 280800 + 302400 + 324000 + 345600 + 367200 + 388800 + 410400 + 432000 + 453600 + + + perpw + Primary wave period + s + seconds + primaryWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + wvhgt + Wind wave height + m + meters + heightWindWaves + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + staticSpacing + Grid spacing + meters + -999999.0 + + + vw + v-component wind + m/s + meter/sec + vWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + swdir + Swell peak period direction + degree true + degree_True + swellWaveDir + 0.0 + 360.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + staticCoriolis + Coriolis parameter + /s + -999999.0 + + + wd + Wind Direction + degreeTrue + degree_True + windDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvdir + Direction of wind waves (from which) + degree true + degree_True + dirWindWaves + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvper + Wind wave peak period + s + seconds + peakPeriodWindWaves + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + htsgw + Sig height combined wind waves and swell + m + meters + heightWindWavesandSwell + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + swper + Swell wave peak period + s + seconds + swellWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + swell + Significant swell wave height + m + meters + heightSwellWaves + 0.0 + 50.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + dirpw + Primary wave direction + degree true + degree_True + primaryWaveDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + uw + u-component wind + m/s + meter/sec + uWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + ws + Wind Speed + m/s + meter/sec + windSpeed + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NAHwave15.xml b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NAHwave15.xml new file mode 100644 index 0000000000..c6d45c5352 --- /dev/null +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NAHwave15.xml @@ -0,0 +1,249 @@ + + + + 0 + 10800 + 21600 + 32400 + 43200 + 54000 + 64800 + 75600 + 86400 + 97200 + 108000 + 118800 + 129600 + 140400 + 151200 + 162000 + 172800 + 183600 + 194400 + 205200 + 216000 + 226800 + 237600 + 248400 + 259200 + 280800 + 302400 + 324000 + 345600 + 367200 + 388800 + 410400 + 432000 + 453600 + + + perpw + Primary wave period + s + seconds + primaryWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + wvhgt + Wind wave height + m + meters + heightWindWaves + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + staticSpacing + Grid spacing + meters + -999999.0 + + + vw + v-component wind + m/s + meter/sec + vWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + swdir + Swell peak period direction + degree true + degree_True + swellWaveDir + 0.0 + 360.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + staticCoriolis + Coriolis parameter + /s + -999999.0 + + + wd + Wind Direction + degreeTrue + degree_True + windDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvdir + Direction of wind waves (from which) + degree true + degree_True + dirWindWaves + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvper + Wind wave peak period + s + seconds + peakPeriodWindWaves + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + htsgw + Sig height combined wind waves and swell + m + meters + heightWindWavesandSwell + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + swper + Swell wave peak period + s + seconds + swellWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + swell + Significant swell wave height + m + meters + heightSwellWaves + 0.0 + 50.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + dirpw + Primary wave direction + degree true + degree_True + primaryWaveDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + uw + u-component wind + m/s + meter/sec + uWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + ws + Wind Speed + m/s + meter/sec + windSpeed + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NAHwave4.xml b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NAHwave4.xml new file mode 100644 index 0000000000..c6d45c5352 --- /dev/null +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NAHwave4.xml @@ -0,0 +1,249 @@ + + + + 0 + 10800 + 21600 + 32400 + 43200 + 54000 + 64800 + 75600 + 86400 + 97200 + 108000 + 118800 + 129600 + 140400 + 151200 + 162000 + 172800 + 183600 + 194400 + 205200 + 216000 + 226800 + 237600 + 248400 + 259200 + 280800 + 302400 + 324000 + 345600 + 367200 + 388800 + 410400 + 432000 + 453600 + + + perpw + Primary wave period + s + seconds + primaryWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + wvhgt + Wind wave height + m + meters + heightWindWaves + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + staticSpacing + Grid spacing + meters + -999999.0 + + + vw + v-component wind + m/s + meter/sec + vWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + swdir + Swell peak period direction + degree true + degree_True + swellWaveDir + 0.0 + 360.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + staticCoriolis + Coriolis parameter + /s + -999999.0 + + + wd + Wind Direction + degreeTrue + degree_True + windDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvdir + Direction of wind waves (from which) + degree true + degree_True + dirWindWaves + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvper + Wind wave peak period + s + seconds + peakPeriodWindWaves + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + htsgw + Sig height combined wind waves and swell + m + meters + heightWindWavesandSwell + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + swper + Swell wave peak period + s + seconds + swellWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + swell + Significant swell wave height + m + meters + heightSwellWaves + 0.0 + 50.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + dirpw + Primary wave direction + degree true + degree_True + primaryWaveDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + uw + u-component wind + m/s + meter/sec + uWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + ws + Wind Speed + m/s + meter/sec + windSpeed + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NPHwave10.xml b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NPHwave10.xml new file mode 100644 index 0000000000..c6d45c5352 --- /dev/null +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NPHwave10.xml @@ -0,0 +1,249 @@ + + + + 0 + 10800 + 21600 + 32400 + 43200 + 54000 + 64800 + 75600 + 86400 + 97200 + 108000 + 118800 + 129600 + 140400 + 151200 + 162000 + 172800 + 183600 + 194400 + 205200 + 216000 + 226800 + 237600 + 248400 + 259200 + 280800 + 302400 + 324000 + 345600 + 367200 + 388800 + 410400 + 432000 + 453600 + + + perpw + Primary wave period + s + seconds + primaryWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + wvhgt + Wind wave height + m + meters + heightWindWaves + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + staticSpacing + Grid spacing + meters + -999999.0 + + + vw + v-component wind + m/s + meter/sec + vWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + swdir + Swell peak period direction + degree true + degree_True + swellWaveDir + 0.0 + 360.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + staticCoriolis + Coriolis parameter + /s + -999999.0 + + + wd + Wind Direction + degreeTrue + degree_True + windDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvdir + Direction of wind waves (from which) + degree true + degree_True + dirWindWaves + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvper + Wind wave peak period + s + seconds + peakPeriodWindWaves + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + htsgw + Sig height combined wind waves and swell + m + meters + heightWindWavesandSwell + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + swper + Swell wave peak period + s + seconds + swellWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + swell + Significant swell wave height + m + meters + heightSwellWaves + 0.0 + 50.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + dirpw + Primary wave direction + degree true + degree_True + primaryWaveDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + uw + u-component wind + m/s + meter/sec + uWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + ws + Wind Speed + m/s + meter/sec + windSpeed + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NPHwave15.xml b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NPHwave15.xml new file mode 100644 index 0000000000..c6d45c5352 --- /dev/null +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NPHwave15.xml @@ -0,0 +1,249 @@ + + + + 0 + 10800 + 21600 + 32400 + 43200 + 54000 + 64800 + 75600 + 86400 + 97200 + 108000 + 118800 + 129600 + 140400 + 151200 + 162000 + 172800 + 183600 + 194400 + 205200 + 216000 + 226800 + 237600 + 248400 + 259200 + 280800 + 302400 + 324000 + 345600 + 367200 + 388800 + 410400 + 432000 + 453600 + + + perpw + Primary wave period + s + seconds + primaryWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + wvhgt + Wind wave height + m + meters + heightWindWaves + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + staticSpacing + Grid spacing + meters + -999999.0 + + + vw + v-component wind + m/s + meter/sec + vWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + swdir + Swell peak period direction + degree true + degree_True + swellWaveDir + 0.0 + 360.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + staticCoriolis + Coriolis parameter + /s + -999999.0 + + + wd + Wind Direction + degreeTrue + degree_True + windDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvdir + Direction of wind waves (from which) + degree true + degree_True + dirWindWaves + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvper + Wind wave peak period + s + seconds + peakPeriodWindWaves + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + htsgw + Sig height combined wind waves and swell + m + meters + heightWindWavesandSwell + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + swper + Swell wave peak period + s + seconds + swellWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + swell + Significant swell wave height + m + meters + heightSwellWaves + 0.0 + 50.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + dirpw + Primary wave direction + degree true + degree_True + primaryWaveDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + uw + u-component wind + m/s + meter/sec + uWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + ws + Wind Speed + m/s + meter/sec + windSpeed + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NPHwave4.xml b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NPHwave4.xml new file mode 100644 index 0000000000..c6d45c5352 --- /dev/null +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/NPHwave4.xml @@ -0,0 +1,249 @@ + + + + 0 + 10800 + 21600 + 32400 + 43200 + 54000 + 64800 + 75600 + 86400 + 97200 + 108000 + 118800 + 129600 + 140400 + 151200 + 162000 + 172800 + 183600 + 194400 + 205200 + 216000 + 226800 + 237600 + 248400 + 259200 + 280800 + 302400 + 324000 + 345600 + 367200 + 388800 + 410400 + 432000 + 453600 + + + perpw + Primary wave period + s + seconds + primaryWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + wvhgt + Wind wave height + m + meters + heightWindWaves + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + staticSpacing + Grid spacing + meters + -999999.0 + + + vw + v-component wind + m/s + meter/sec + vWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + swdir + Swell peak period direction + degree true + degree_True + swellWaveDir + 0.0 + 360.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + staticCoriolis + Coriolis parameter + /s + -999999.0 + + + wd + Wind Direction + degreeTrue + degree_True + windDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvdir + Direction of wind waves (from which) + degree true + degree_True + dirWindWaves + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvper + Wind wave peak period + s + seconds + peakPeriodWindWaves + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + htsgw + Sig height combined wind waves and swell + m + meters + heightWindWavesandSwell + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + swper + Swell wave peak period + s + seconds + swellWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + swell + Significant swell wave height + m + meters + heightSwellWaves + 0.0 + 50.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + dirpw + Primary wave direction + degree true + degree_True + primaryWaveDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + uw + u-component wind + m/s + meter/sec + uWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + ws + Wind Speed + m/s + meter/sec + windSpeed + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/WPHwave10.xml b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/WPHwave10.xml new file mode 100644 index 0000000000..c6d45c5352 --- /dev/null +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/utility/edex_static/base/grid/parameterInfo/WPHwave10.xml @@ -0,0 +1,249 @@ + + + + 0 + 10800 + 21600 + 32400 + 43200 + 54000 + 64800 + 75600 + 86400 + 97200 + 108000 + 118800 + 129600 + 140400 + 151200 + 162000 + 172800 + 183600 + 194400 + 205200 + 216000 + 226800 + 237600 + 248400 + 259200 + 280800 + 302400 + 324000 + 345600 + 367200 + 388800 + 410400 + 432000 + 453600 + + + perpw + Primary wave period + s + seconds + primaryWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + wvhgt + Wind wave height + m + meters + heightWindWaves + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + staticSpacing + Grid spacing + meters + -999999.0 + + + vw + v-component wind + m/s + meter/sec + vWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + swdir + Swell peak period direction + degree true + degree_True + swellWaveDir + 0.0 + 360.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + staticCoriolis + Coriolis parameter + /s + -999999.0 + + + wd + Wind Direction + degreeTrue + degree_True + windDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvdir + Direction of wind waves (from which) + degree true + degree_True + dirWindWaves + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + wvper + Wind wave peak period + s + seconds + peakPeriodWindWaves + 0.0 + 100.0 + -999999.0 + 1 + SFC + + SFC + + + + htsgw + Sig height combined wind waves and swell + m + meters + heightWindWavesandSwell + 0.0 + 50.0 + -999999.0 + 1 + SFC + + SFC + + + + swper + Swell wave peak period + s + seconds + swellWavePeriod + 0.0 + 100.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + swell + Significant swell wave height + m + meters + heightSwellWaves + 0.0 + 50.0 + -999999.0 + 1 + OSEQD 1 2 + + OSEQD1 + OSEQD2 + + + + dirpw + Primary wave direction + degree true + degree_True + primaryWaveDir + 0.0 + 360.0 + -999999.0 + 1 + SFC + + SFC + + + + uw + u-component wind + m/s + meter/sec + uWind + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + + ws + Wind Speed + m/s + meter/sec + windSpeed + -150.0 + 150.0 + -999999.0 + 1 + SFC + + SFC + + + diff --git a/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/models/gribModels_NCEP-7.xml b/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/models/gribModels_NCEP-7.xml index 06d90d8177..4610adc23f 100644 --- a/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/models/gribModels_NCEP-7.xml +++ b/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/models/gribModels_NCEP-7.xml @@ -2095,6 +2095,106 @@ 11 + + + GLOBHwave +
7
+ 0 + 720311001 + + 13 + +
+ + + AKHwave10 +
7
+ 0 + 15 + + 13 + +
+ + + AKHwave4 +
7
+ 0 + 16 + + 13 + +
+ + + NAHwave15 +
7
+ 0 + 238 + + 13 + +
+ + + NAHwave10 +
7
+ 0 + 12 + + 13 + +
+ + + NAHwave4 +
7
+ 0 + 18 + + 13 + +
+ + + NPHwave15 +
7
+ 0 + 253 + + 13 + +
+ + + NPHwave10 +
7
+ 0 + 13 + + 13 + +
+ + + NPHwave4 +
7
+ 0 + 17 + + 13 + +
+ + + WPHwave10 +
7
+ 0 + 14 + + 13 + +
diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.grid/utility/common_static/base/purge/gridPurgeRules.xml b/edexOsgi/com.raytheon.uf.edex.plugin.grid/utility/common_static/base/purge/gridPurgeRules.xml index d0c1625e11..bd66a0e029 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.grid/utility/common_static/base/purge/gridPurgeRules.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.grid/utility/common_static/base/purge/gridPurgeRules.xml @@ -732,4 +732,46 @@ 5 00-00:15:00 + + + + GLOBHwave + 1 + + + NAHwave15 + 1 + + + NAHwave10 + 1 + + + NAHwave4 + 1 + + + NPHwave15 + 1 + + + NPHwave10 + 1 + + + NPHwave4 + 1 + + + WPHwave10 + 1 + + + AKHwave10 + 1 + + + AKHwave4 + 1 + From 3305aee6925e7c93ecf21885692b1400af92274a Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Fri, 25 Apr 2014 11:04:00 -0500 Subject: [PATCH 104/188] Issue #3079 update to lightning name will continue if it encounters invalid xml Former-commit-id: 07e7a0eaa6973a705d5fff1beb8ebcb553c172d0 --- deltaScripts/14.3.1/utility/updateLightningNameInXML.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/deltaScripts/14.3.1/utility/updateLightningNameInXML.sh b/deltaScripts/14.3.1/utility/updateLightningNameInXML.sh index 4e20f21b25..b7a1a11528 100755 --- a/deltaScripts/14.3.1/utility/updateLightningNameInXML.sh +++ b/deltaScripts/14.3.1/utility/updateLightningNameInXML.sh @@ -53,7 +53,6 @@ for f in $files; do fi else echo "ERROR: Problem updating file $f" - exit 1 fi done From 7da49c00f5ca50ff9426a34c533bee504a7eae77 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Fri, 25 Apr 2014 12:19:23 -0500 Subject: [PATCH 105/188] Issue #2060 remove FFG post processor dependency on dataURI, other minor cleanups Change-Id: I4c572c3f7d2bef1bdd0b9a596f916e29f8e53410 Former-commit-id: b45cdd1a3f4742937b9085ca70d538ae724d6aab --- .../FFGGribPostProcessor.java | 28 ++++++++++++++----- .../TemperatureCorrectionPostProcessor.java | 27 ++++++------------ .../localization/region/RegionLookup.java | 17 ++++++----- .../uf/common/serialization/JAXBManager.java | 9 ++++-- .../uf/edex/dat/utils/FreezingLevel.java | 12 ++++---- .../edex/plugin/scan/process/GridProduct.java | 14 ++++++---- 6 files changed, 59 insertions(+), 48 deletions(-) diff --git a/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/decoderpostprocessors/FFGGribPostProcessor.java b/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/decoderpostprocessors/FFGGribPostProcessor.java index 39147c4e42..83cb17b975 100644 --- a/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/decoderpostprocessors/FFGGribPostProcessor.java +++ b/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/decoderpostprocessors/FFGGribPostProcessor.java @@ -25,7 +25,6 @@ import java.util.List; import com.raytheon.edex.plugin.grib.exception.GribException; import com.raytheon.uf.common.dataplugin.grid.GridConstants; import com.raytheon.uf.common.dataplugin.grid.GridRecord; -import com.raytheon.uf.common.dataquery.db.QueryParam.QueryOperand; import com.raytheon.uf.edex.database.plugin.PluginFactory; import com.raytheon.uf.edex.database.query.DatabaseQuery; import com.raytheon.uf.edex.plugin.grid.dao.GridDao; @@ -43,6 +42,7 @@ import com.raytheon.uf.edex.plugin.grid.dao.GridDao; * Aug 31, 2010 5875 bphillip Initial Creation * Mar 26, 2013 1821 bsteffen Optimize FFG version query. * Oct 15, 2013 2473 bsteffen Remove deprecated method calls. + * Apr 25, 2014 2060 njensen Remove dependency on grid dataURI column * * * @@ -57,13 +57,14 @@ public class FFGGribPostProcessor implements IDecoderPostProcessor { try { GridDao gribDao = (GridDao) PluginFactory.getInstance() .getPluginDao(GridConstants.GRID); - record.setSecondaryId("%"); - record.setDataURI(null); + /* + * All we want to do is check for pre-existing records, and if some + * are found, increment the version number in the secondaryId so + * it's not identified as a duplicate + */ DatabaseQuery query = new DatabaseQuery(GridRecord.class); query.addReturnedField(GridConstants.SECONDARY_ID); - // The dataURI constraint does the final selection but the other - // constraints help the db optimize efficiently. query.addQueryParam(GridConstants.DATASET_ID, record.getDatasetId()); query.addQueryParam(GridConstants.PARAMETER_ABBREVIATION, record .getParameter().getAbbreviation()); @@ -71,9 +72,21 @@ public class FFGGribPostProcessor implements IDecoderPostProcessor { .getId()); query.addQueryParam(GridConstants.LOCATION_ID, record.getLocation() .getId()); - query.addQueryParam("dataURI", record.getDataURI(), - QueryOperand.LIKE); + query.addQueryParam("dataTime.refTime", record.getDataTime() + .getRefTime()); + query.addQueryParam("dataTime.fcstTime", record.getDataTime() + .getFcstTime()); + query.addQueryParam(GridConstants.ENSEMBLE_ID, + record.getEnsembleId()); List result = gribDao.queryByCriteria(query); + + /* + * TODO this does not appear to be cluster safe, but we probably + * dodge it due to the low frequency of this data arriving for the + * same parameters, time, etc + */ + + // find the highest version number int maxVersion = -1; for (Object row : result) { String secondaryId = (String) row; @@ -90,6 +103,7 @@ public class FFGGribPostProcessor implements IDecoderPostProcessor { } record.setSecondaryId("Version" + (maxVersion + 1)); record.getInfo().setId(null); + // clear out dataURI in case it was cached record.setDataURI(null); } catch (Exception e) { throw new GribException("Error decoding FFG grid", e); diff --git a/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/decoderpostprocessors/TemperatureCorrectionPostProcessor.java b/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/decoderpostprocessors/TemperatureCorrectionPostProcessor.java index 3aed2f789f..e14a1e01be 100644 --- a/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/decoderpostprocessors/TemperatureCorrectionPostProcessor.java +++ b/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/decoderpostprocessors/TemperatureCorrectionPostProcessor.java @@ -25,7 +25,7 @@ import java.util.Map; import javax.measure.converter.UnitConverter; import javax.measure.unit.SI; -import javax.xml.bind.JAXBException; +import javax.xml.bind.JAXB; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlAttribute; @@ -39,9 +39,7 @@ import com.raytheon.uf.common.localization.ILocalizationFileObserver; import com.raytheon.uf.common.localization.IPathManager; import com.raytheon.uf.common.localization.LocalizationFile; import com.raytheon.uf.common.localization.PathManagerFactory; -import com.raytheon.uf.common.localization.exception.LocalizationException; import com.raytheon.uf.common.parameter.Parameter; -import com.raytheon.uf.common.serialization.JAXBManager; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; @@ -62,6 +60,7 @@ import com.raytheon.uf.common.status.UFStatus.Priority; * Date Ticket# Engineer Description * ------------- -------- ----------- -------------------------- * Mar 28, 2010 2874 bsteffen Initial creation + * Apr 25, 2014 2060 njensen Use JAXB instead of JAXBManager * * * @@ -93,31 +92,23 @@ public class TemperatureCorrectionPostProcessor implements } } - protected LocalizationFile readConfiguration() throws GribException { + protected LocalizationFile readConfiguration() { LocalizationFile file = PathManagerFactory.getPathManager() .getStaticLocalizationFile(LOCALIZATON_LOCATION); Map paramThresholdMap = new HashMap(8); if (file != null && file.exists()) { - JAXBManager manager = null; - try { - manager = new JAXBManager(TemperatureCorrectionParameters.class); - - } catch (JAXBException e) { - /* No hope of recovering */ - throw new GribException( - "Error occured preparing to load temperate correction parameters.", - e); - } TemperatureCorrectionParameters params = null; try { - params = file.jaxbUnmarshal( - TemperatureCorrectionParameters.class, manager); - } catch (LocalizationException e) { + params = JAXB.unmarshal(file.getFile(), + TemperatureCorrectionParameters.class); + } catch (Exception e) { /* Some hope of recovering with a better file. */ statusHandler .error("Error occured loading temperate correction parameters, verify the file is formatted correctly.", e); + } + if (params != null) { for (TemperatureCorrectionParameter param : params .getParameters()) { @@ -134,7 +125,7 @@ public class TemperatureCorrectionPostProcessor implements public void fileUpdated(FileUpdatedMessage message) { try { readConfiguration(); - } catch (GribException e) { + } catch (Exception e) { statusHandler.handle(Priority.PROBLEM, e.getLocalizedMessage(), e); } } diff --git a/edexOsgi/com.raytheon.uf.common.localization/src/com/raytheon/uf/common/localization/region/RegionLookup.java b/edexOsgi/com.raytheon.uf.common.localization/src/com/raytheon/uf/common/localization/region/RegionLookup.java index ec97f09dfc..4831b6b92f 100644 --- a/edexOsgi/com.raytheon.uf.common.localization/src/com/raytheon/uf/common/localization/region/RegionLookup.java +++ b/edexOsgi/com.raytheon.uf.common.localization/src/com/raytheon/uf/common/localization/region/RegionLookup.java @@ -23,10 +23,9 @@ import java.io.InputStream; import java.util.HashMap; import java.util.Map; +import javax.xml.bind.JAXB; + import com.raytheon.uf.common.localization.region.RegionSites.Region; -import com.raytheon.uf.common.serialization.JAXBManager; -import com.raytheon.uf.common.serialization.SerializationException; -import com.raytheon.uf.common.serialization.SingleTypeJAXBManager; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; @@ -39,7 +38,8 @@ import com.raytheon.uf.common.status.UFStatus; * * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Jan 30, 2014 mnash Initial creation + * Jan 30, 2014 mnash Initial creation + * Apr 25, 2014 2060 njensen Use JAXB instead of JAXBManager * * * @@ -89,16 +89,15 @@ public class RegionLookup { * @return */ private static RegionSites parseFile() { + RegionSites sites = null; InputStream stream = RegionLookup.class .getResourceAsStream("/regions.xml"); - JAXBManager manager = SingleTypeJAXBManager - .createWithoutException(RegionSites.class); try { - return (RegionSites) manager.unmarshalFromInputStream(stream); - } catch (SerializationException e) { + sites = JAXB.unmarshal(stream, RegionSites.class); + } catch (Exception e) { handler.error("Unable to unmarshal regions.xml file", e); } - return null; + return sites; } } \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.common.serialization/src/com/raytheon/uf/common/serialization/JAXBManager.java b/edexOsgi/com.raytheon.uf.common.serialization/src/com/raytheon/uf/common/serialization/JAXBManager.java index ff2f8fcc6b..09745ea54f 100644 --- a/edexOsgi/com.raytheon.uf.common.serialization/src/com/raytheon/uf/common/serialization/JAXBManager.java +++ b/edexOsgi/com.raytheon.uf.common.serialization/src/com/raytheon/uf/common/serialization/JAXBManager.java @@ -58,6 +58,7 @@ import com.raytheon.uf.common.status.UFStatus.Priority; * Sep 30, 2013 2361 njensen Refactored for cleanliness * Nov 14, 2013 2361 njensen Added lazy init option, improved unmarshal error message * Apr 16, 2014 2928 rjpeter Updated marshalToStream to not close the stream. + * Apr 25, 2014 2060 njensen Improved printout * * * @author chammack @@ -178,9 +179,11 @@ public class JAXBManager { if (jaxbContext == null) { long t0 = System.currentTimeMillis(); jaxbContext = JAXBContext.newInstance(clazz); - System.out.println("JAXB context with " + clazz.length - + " classes inited in: " - + (System.currentTimeMillis() - t0)); + if (clazz.length == 1) { + System.out.println("JAXB context for " + + clazz[0].getSimpleName() + " inited in: " + + (System.currentTimeMillis() - t0) + "ms"); + } clazz = null; } } diff --git a/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java b/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java index 535f2d11f0..539109ba4c 100644 --- a/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java +++ b/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java @@ -35,6 +35,7 @@ import org.geotools.coverage.grid.GridGeometry2D; import org.geotools.geometry.DirectPosition2D; import org.opengis.referencing.crs.CoordinateReferenceSystem; +import com.raytheon.uf.common.dataplugin.grid.GridConstants; import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.datastorage.records.FloatDataRecord; import com.raytheon.uf.common.geospatial.ISpatialObject; @@ -468,17 +469,18 @@ public class FreezingLevel { } DatabaseQuery dbQuery = new DatabaseQuery(GridRecord.class); - dbQuery.addQueryParam("info.datasetId", model); - dbQuery.addQueryParam("info.parameter.abbreviation", paramName); - dbQuery.addQueryParam("info.level.masterLevel.name", "MB"); - dbQuery.addQueryParam("info.level.levelonevalue", level); + dbQuery.addQueryParam(GridConstants.DATASET_ID, model); + dbQuery.addQueryParam(GridConstants.PARAMETER_ABBREVIATION, paramName); + dbQuery.addQueryParam(GridConstants.MASTER_LEVEL_NAME, "MB"); + dbQuery.addQueryParam(GridConstants.LEVEL_ONE, level); dbQuery.addQueryParam("dataTime.refTime", refTime); dbQuery.addQueryParam("dataTime.fcstTime", 0); dbQuery.addOrder("dataTime.refTime", false); dbQuery.setMaxResults(1); try { - PluginDao dao = PluginFactory.getInstance().getPluginDao("grid"); + PluginDao dao = PluginFactory.getInstance().getPluginDao( + GridConstants.GRID); List list = dao.queryByCriteria(dbQuery); GridRecord result = null; if (list != null && !list.isEmpty()) { diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GridProduct.java b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GridProduct.java index 2e85e20ab0..7fe81debf6 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GridProduct.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/GridProduct.java @@ -23,6 +23,7 @@ import java.util.Date; import java.util.List; import java.util.regex.Pattern; +import com.raytheon.uf.common.dataplugin.grid.GridConstants; import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataplugin.scan.ScanException; import com.raytheon.uf.common.monitor.scan.config.SCANConfigEnums.ScanTables; @@ -140,11 +141,11 @@ public abstract class GridProduct extends ScanProduct { String parameter, String levelName, String levelOne, String levelTwo) throws ScanException { DatabaseQuery dbQuery = new DatabaseQuery(GridRecord.class); - dbQuery.addQueryParam("info.datasetId", dataset); - dbQuery.addQueryParam("info.parameter.abbreviation", parameter); - dbQuery.addQueryParam("info.level.masterLevel.name", levelName); - dbQuery.addQueryParam("info.level.levelonevalue", levelOne); - dbQuery.addQueryParam("info.level.leveltwovalue", levelTwo); + dbQuery.addQueryParam(GridConstants.DATASET_ID, dataset); + dbQuery.addQueryParam(GridConstants.PARAMETER_ABBREVIATION, parameter); + dbQuery.addQueryParam(GridConstants.MASTER_LEVEL_NAME, levelName); + dbQuery.addQueryParam(GridConstants.LEVEL_ONE, levelOne); + dbQuery.addQueryParam(GridConstants.LEVEL_TWO, levelTwo); dbQuery.addQueryParam("dataTime.refTime", new Date(SimulatedTime .getSystemTime().getMillis() - (interval * TimeUtil.MILLIS_PER_MINUTE)), ">"); @@ -153,7 +154,8 @@ public abstract class GridProduct extends ScanProduct { dbQuery.setMaxResults(1); try { - PluginDao dao = PluginFactory.getInstance().getPluginDao("grid"); + PluginDao dao = PluginFactory.getInstance().getPluginDao( + GridConstants.GRID); List list = dao.queryByCriteria(dbQuery); GridRecord result = null; if (list != null && !list.isEmpty()) { From 44701f31f286e6f796035d51c3d601b19f335137 Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Fri, 25 Apr 2014 13:07:48 -0500 Subject: [PATCH 106/188] Issue #2995: Update DB Class Finder to search all plugin jars Change-Id: I42b5207372aa9d6f07afff0d18819c60b85fb3f8 Former-commit-id: f3fe2db624f7f9e6c7b0b65d600ddba5e42de361 --- .../build.edex/esb/conf/spring/edex-db.xml | 11 +--- .../DatabaseClassAnnotationFinder.java | 61 +++++++++++++++---- 2 files changed, 52 insertions(+), 20 deletions(-) diff --git a/edexOsgi/build.edex/esb/conf/spring/edex-db.xml b/edexOsgi/build.edex/esb/conf/spring/edex-db.xml index 5ff9b46335..c764b51416 100644 --- a/edexOsgi/build.edex/esb/conf/spring/edex-db.xml +++ b/edexOsgi/build.edex/esb/conf/spring/edex-db.xml @@ -12,15 +12,8 @@ - - - - - com.raytheon - gov.noaa - - - + + diff --git a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/DatabaseClassAnnotationFinder.java b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/DatabaseClassAnnotationFinder.java index 8689e3dfd4..ea1e26d33a 100644 --- a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/DatabaseClassAnnotationFinder.java +++ b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/DatabaseClassAnnotationFinder.java @@ -19,6 +19,9 @@ **/ package com.raytheon.uf.edex.database; +import java.io.File; +import java.io.FileFilter; +import java.net.MalformedURLException; import java.util.Set; import javax.persistence.Embeddable; @@ -26,9 +29,12 @@ import javax.persistence.Entity; import org.reflections.Reflections; import org.reflections.scanners.TypeAnnotationsScanner; -import org.reflections.util.ClasspathHelper; import org.reflections.util.ConfigurationBuilder; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.edex.core.props.PropertiesFactory; + /** * Uses the reflections package to find classes on the classpath that match the * start of a package name and will be needed to access the database. @@ -40,7 +46,7 @@ import org.reflections.util.ConfigurationBuilder; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Oct 11, 2013 njensen Initial creation - * + * Apr 25, 2014 2995 rjpeter Updated to scan PLUGINDIR for all files. * * * @author njensen @@ -49,26 +55,59 @@ import org.reflections.util.ConfigurationBuilder; public class DatabaseClassAnnotationFinder { - private Set> dbAnnotatedClassSet; + private final Set> dbAnnotatedClassSet; - public DatabaseClassAnnotationFinder(String... packageNames) { - dbAnnotatedClassSet = findClasses(packageNames); + private final IUFStatusHandler statusHandler = UFStatus + .getHandler(DatabaseClassAnnotationFinder.class); + + public DatabaseClassAnnotationFinder() { + dbAnnotatedClassSet = findClasses(); } /** - * Searches the classpath for classes that will be needed by the database + * Searches the plugin dir for classes that will be needed by the database * layer. * - * @param packageNames - * The start of pacakge names to include, e.g. com.raytheon * @return */ - protected Set> findClasses(String... packageNames) { + protected Set> findClasses() { long t0 = System.currentTimeMillis(); ConfigurationBuilder cb = new ConfigurationBuilder(); - for (String pkg : packageNames) { - cb.addUrls(ClasspathHelper.forPackage(pkg)); + File pluginDir = new File(PropertiesFactory.getInstance() + .getEnvProperties().getEnvValue("PLUGINDIR")); + + if (!pluginDir.exists()) { + throw new AssertionError( + "Cannot find Database classes to load. PluginDir [" + + pluginDir.getAbsolutePath() + "] does not exist."); } + + File[] pluginJarFiles = pluginDir.listFiles(new FileFilter() { + @Override + public boolean accept(File file) { + if (file.isFile()) { + String name = file.getName(); + if (name.endsWith(".jar")) { + return true; + } + } + return false; + } + + }); + + for (File jarFile : pluginJarFiles) { + try { + cb.addUrls(jarFile.toURI().toURL()); + } catch (MalformedURLException e) { + statusHandler + .error("Unable to scan jar file [" + + jarFile.getAbsolutePath() + + "] for database annotations. File will be skipped", + e); + } + } + cb.setScanners(new TypeAnnotationsScanner()); Reflections reflecs = cb.build(); Set> set = reflecs.getTypesAnnotatedWith(Entity.class, false); From 17ab4f618476b35f52c1c3360634b4115cf4bf23 Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Fri, 25 Apr 2014 13:40:52 -0500 Subject: [PATCH 107/188] Issue #3070 fixed contact request logic when adding to group Former-commit-id: 57120491452b36bf15227bd4b6d0236221c71124 --- .../comm/provider/user/ContactsManager.java | 29 +++++++------------ 1 file changed, 10 insertions(+), 19 deletions(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java index 8cfe54ffac..223c4f60e2 100644 --- a/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java +++ b/cave/com.raytheon.uf.viz.collaboration.comm/src/com/raytheon/uf/viz/collaboration/comm/provider/user/ContactsManager.java @@ -78,6 +78,7 @@ import com.raytheon.uf.viz.collaboration.comm.provider.connection.CollaborationC * added getSharedDisplayEnabledResource() * Apr 24, 2014 3070 bclement added checks for empty groups, added isContact(), * added sendContactRequest() + * fixed contact request logic in addToGroup() * * * @@ -201,24 +202,14 @@ public class ContactsManager { if (group == null) { group = createGroup(groupName); } - String id = user.getNormalizedId(); - RosterEntry entry = group.getEntry(id); - if (entry != null) { - if (isBlocked(entry)) { - // entry is in roster, but we aren't subscribed. Request a - // subscription. - try { - connection.getAccountManager().sendPresence(user, - new Presence(Type.subscribe)); - } catch (CollaborationException e) { - statusHandler.error("Problem subscribing to user", e); - } - } else { - statusHandler - .debug("Attempted to add user to group it was already in: " - + id + " in " + groupName); + RosterEntry entry = getRosterEntry(user); + if (entry != null && isBlocked(entry)) { + /* entry is in roster, but we are blocked */ + try { + sendContactRequest(user); + } catch (CollaborationException e) { + statusHandler.error("Problem subscribing to user", e); } - return; } try { addToGroup(group, user); @@ -227,8 +218,8 @@ public class ContactsManager { } } catch (XMPPException e) { String msg = getGroupModInfo(e); - statusHandler.error("Problem adding user to group: " + id + " to " - + group.getName() + ". " + msg, e); + statusHandler.error("Problem adding user to group: " + user + + " to " + group.getName() + ". " + msg, e); } } From 8b595435e20864df0bdb892d04224830792af089 Mon Sep 17 00:00:00 2001 From: David Friedman Date: Fri, 25 Apr 2014 19:31:58 +0000 Subject: [PATCH 108/188] ASM #525 - Text Workstation expiration pop-up inconsistent Change-Id: I3867a0050962d97125ca6612fcded2fe62b48619 Former-commit-id: f7bfa197b1b61b69029efd8e225ba5dea22c17f2 --- .../texteditor/notify/NotifyExpiration.java | 3 +- .../notify/NotifyExpirationTask.java | 37 ++++++++++++------- 2 files changed, 25 insertions(+), 15 deletions(-) diff --git a/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/notify/NotifyExpiration.java b/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/notify/NotifyExpiration.java index 56215a86ca..6e4f9055ea 100644 --- a/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/notify/NotifyExpiration.java +++ b/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/notify/NotifyExpiration.java @@ -42,6 +42,7 @@ import com.raytheon.viz.texteditor.util.VtecUtil; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * May 24, 2010 jsanchez Initial creation + * Apr 25, 2014 DR 16668 D. Friedman Only notify on NEW products. * * * @@ -83,7 +84,7 @@ public class NotifyExpiration { } VtecObject vtecObject = VtecUtil.parseMessage(warning); - if (vtecObject == null) { + if (vtecObject == null || !"NEW".equals(vtecObject.getAction())) { return; } Calendar expire = vtecObject.getEndTime(); diff --git a/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/notify/NotifyExpirationTask.java b/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/notify/NotifyExpirationTask.java index 40c329a6e6..ae6544d3eb 100644 --- a/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/notify/NotifyExpirationTask.java +++ b/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/notify/NotifyExpirationTask.java @@ -51,6 +51,7 @@ import com.raytheon.viz.ui.dialogs.SWTMessageBox; * Sep 21, 2010 2187 cjeanbap Removed hard coded values of * tables names. * Dec 20, 2010 7210 cjeanbap Added non-blocking dialog. + * Apr 25, 2014 DR 16668 D. Friedman Handle partial cancellations * * * @author jsanchez @@ -114,8 +115,6 @@ public class NotifyExpirationTask extends TimerTask { req.setMode(ActiveTableMode.OPERATIONAL); } - /* textNotifyExpiration.tcl ln 76: Only queries for a CAN */ - req.setAct("CAN"); req.setSiteID(office); req.setPhensigList(phenSig); req.setEtn(etn); @@ -127,22 +126,32 @@ public class NotifyExpirationTask extends TimerTask { activeTable = resp.getActiveTable(); } catch (VizException e) { statusHandler.handle(Priority.ERROR, - "Error querying active table for CAN." + office + "." + "Error querying active table for " + office + "." + phenSig + "." + etn, e); } - if (activeTable != null && activeTable.size() > 0) { - ActiveTableRecord record = activeTable.get(0); - - /* - * textNotifyExpiration.tcl ln 97: If any of the found products are - * less than 48 hours old,return true. - */ - if (record != null - && (System.currentTimeMillis() - - record.getIssueTime().getTimeInMillis() < TWO_DAYS)) { - return true; + if (activeTable != null) { + boolean haveCAN = false; + for (ActiveTableRecord record : activeTable) { + if (record != null) { + /* + * textNotifyExpiration.tcl ln 106: If any of the found products are + * less than 48 hours old,return true. + */ + if ("CAN".equals(record.getAct()) + && (System.currentTimeMillis() + - record.getIssueTime().getTimeInMillis() < TWO_DAYS)) { + haveCAN = true; + } else if ("CON".equals(record.getAct())) { + /* If there CANs and the event is still active, there + * should be some CONs. Thus, it is not necessary to + * check for every other kind of non-terminal action. + */ + return false; + } + } } + return haveCAN; } return false; From 2d96d9d2df83edf5b8a48137973a75ad5fc96d2b Mon Sep 17 00:00:00 2001 From: Ben Steffensmeier Date: Wed, 23 Apr 2014 14:54:54 -0500 Subject: [PATCH 109/188] Issue #2874 Allow RTOFS nowcast to be identified by process type. Former-commit-id: 1e430dd1227f2e368a7da21d116677a3b522d5ed --- .../localization/volumebrowser/VbSources.xml | 47 ++-- .../GribDecoder.py | 11 +- .../edex/plugin/grib/Grib1Decoder.java | 4 +- .../plugin/grib/util/GribModelLookup.java | 106 ++++---- .../edex/plugin/grib/util/GridModel.java | 12 + .../grib/grids/RTOFS/RTOFS-HudsonBaffin.xml | 4 +- .../edex_static/base/grib/models/RTOFS.xml | 233 ++++++++++++++++-- .../base/grib/tables/-1/-1/4.3.table | 7 +- 8 files changed, 327 insertions(+), 97 deletions(-) diff --git a/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/VbSources.xml b/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/VbSources.xml index 669914444c..1acdc40846 100644 --- a/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/VbSources.xml +++ b/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/VbSources.xml @@ -106,21 +106,36 @@ - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -159,4 +174,4 @@ subCategory="Column" /> - \ No newline at end of file + diff --git a/edexOsgi/com.raytheon.edex.plugin.grib/GribDecoder.py b/edexOsgi/com.raytheon.edex.plugin.grib/GribDecoder.py index 8d04f490b3..daf40d1fec 100644 --- a/edexOsgi/com.raytheon.edex.plugin.grib/GribDecoder.py +++ b/edexOsgi/com.raytheon.edex.plugin.grib/GribDecoder.py @@ -59,7 +59,7 @@ from com.raytheon.uf.common.parameter.mapping import ParameterMapper; # Static values for accessing parameter lookup tables PARAMETER_TABLE = "4.2" -GENPROCESS_TABLE = "A" +PROCESS_TYPE_TABLE = "4.3" LEVELS_TABLE = "4.5" DOT = "." MISSING = "Missing" @@ -429,6 +429,9 @@ class GribDecoder(): gribDict['parameterName'] = MISSING parameterAbbreviation = MISSING gribDict['parameterUnit'] = MISSING + + processType = int(pdsTemplate[2]) + gribDict['processType'] = str(GribTableLookup.getInstance().getTableValue(centerID, subcenterID, PROCESS_TYPE_TABLE, processType)) levelName = None; levelUnit = None; @@ -1157,7 +1160,8 @@ class GribDecoder(): subcenter = gribDict['subcenter'] process = gribDict['genprocess'] - gridModel = GribModelLookup.getInstance().getModel(center, subcenter, grid, process) + processType = gribDict['processType'] + gridModel = GribModelLookup.getInstance().getModel(center, subcenter, grid, process, processType) return gridModel def _createModelName(self, gribDict, grid): @@ -1165,7 +1169,8 @@ class GribDecoder(): subcenter = gribDict['subcenter'] process = gribDict['genprocess'] - return GribModelLookup.getInstance().getModelName(center, subcenter, grid, process) + processType = gribDict['processType'] + return GribModelLookup.getInstance().getModelName(center, subcenter, grid, process, processType) def _checkForecastFlag(self, gribDict, grid, dataTime): gridModel = self._getGridModel(gribDict, grid) diff --git a/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/Grib1Decoder.java b/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/Grib1Decoder.java index 07aa70ed40..e906627146 100644 --- a/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/Grib1Decoder.java +++ b/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/Grib1Decoder.java @@ -899,7 +899,7 @@ public class Grib1Decoder extends AbstractDecoder { private String createModelName(int centerId, int subcenterId, int process, GridCoverage grid) { return GribModelLookup.getInstance().getModelName(centerId, - subcenterId, grid, process); + subcenterId, grid, process, null); } /** @@ -915,7 +915,7 @@ public class Grib1Decoder extends AbstractDecoder { private void checkForecastFlag(DataTime time, int centerId, int subcenterId, int process, GridCoverage grid) { GridModel gridModel = GribModelLookup.getInstance().getModel(centerId, - subcenterId, grid, process); + subcenterId, grid, process, null); if ((gridModel != null) && gridModel.getAnalysisOnly()) { time.getUtilityFlags().remove(FLAG.FCST_USED); } diff --git a/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/util/GribModelLookup.java b/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/util/GribModelLookup.java index 7736ebe232..9af2c1260e 100644 --- a/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/util/GribModelLookup.java +++ b/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/util/GribModelLookup.java @@ -55,6 +55,8 @@ import com.raytheon.uf.common.util.mapping.MultipleMappingException; * reverse. * Apr 30, 2013 1961 bsteffen Add ability to disable grib tables. * Oct 14, 2013 2473 bsteffen Remove lookup of deprecated grib files. + * Apr 25, 2014 2874 bsteffen Add processType + * * * * @@ -94,42 +96,60 @@ public class GribModelLookup { initModelList(); } - public GridModel getModel(int center, int subcenter, String grid, - int process) { - GridModel model = models.get(toKey(center, subcenter, grid, process)); - if (model == null) { - // See if there is a version for all grids. - model = models.get(toKey(center, subcenter, null, process)); + /** + * Get a model based off some fields in the grib file. + * + * @param center + * the id of the center + * @param subcenter + * the id of the subcenter + * @param grid + * gridcoverage as defined in the grib file(don't use subgrids) + * @param process + * the process id + * @param processType + * the process type, although this is a byte in the grib file + * this method expects the byte to be resolved to a string by + * looking up the type id in the grib tables(4.3). grib1 does not + * include a value for process type so null is acceptable. + * @return The grid model if one is find or null if no such model is defined + * in the localization files.. + */ + public GridModel getModel(int center, int subcenter, GridCoverage grid, + int process, String processType) { + /* Match all fields */ + GridModel model = getModelSimple(center, subcenter, grid, process, + processType); + if (model == null && processType != null) { + /* Match with no processType specified */ + model = getModelSimple(center, subcenter, grid, process, null); + } + if (model == null && grid != null) { + /* Match with no grid specified */ + model = getModelSimple(center, subcenter, null, process, + processType); + } + if (model == null && grid != null && processType != null) { + /* Match with no grid or processType */ + model = getModelSimple(center, subcenter, null, process, null); } return model; } - public GridModel getModel(int center, int subcenter, GridCoverage grid, - int process) { - GridModel model = null; - if (grid.getName() != null) { - models.get(toKey(center, subcenter, grid.getName(), process)); - } - if (model == null) { + private GridModel getModelSimple(int center, int subcenter, + GridCoverage grid, int process, String processType) { + if (grid != null) { for (String gribGridName : GribSpatialCache.getInstance() .getGribCoverageNames(grid)) { - model = models.get(toKey(center, subcenter, gribGridName, - process)); + String key = toKey(center, subcenter, gribGridName, process, + processType); + GridModel model = models.get(key); if (model != null) { - break; + return model; } } - if (model == null) { - // last step is to look for a matching center, subcenter, and - // process with no grid. - model = models.get(toKey(center, subcenter, null, process)); - } } - return model; - } - - public GridModel getModel(int center, int subcenter, int gridid, int process) { - return getModel(center, subcenter, String.valueOf(gridid), process); + return null; } public GridModel getModelByName(String name) { @@ -141,8 +161,9 @@ public class GribModelLookup { } public String getModelName(int center, int subcenter, GridCoverage grid, - int process) { - GridModel model = getModel(center, subcenter, grid, process); + int process, String processType) { + GridModel model = getModel(center, subcenter, grid, process, + processType); if (model == null || model.getName() == null) { String cenSubProc = "GribModel:" + String.valueOf(center) + ":" + String.valueOf(subcenter) + ":" + String.valueOf(process); @@ -219,41 +240,32 @@ public class GribModelLookup { private void addModels(GridModelSet modelSet) { for (GridModel model : modelSet.getModels()) { + int subCenter = Integer.parseInt(model.getSubCenter()); modelsByName.put(model.getName(), model); for (int process : model.getProcess()) { if (model.getAllGrids().isEmpty()) { - models.put( - toKey(model.getCenter(), - Integer.parseInt(model.getSubCenter()), - null, process), model); + String key = toKey(model.getCenter(), subCenter, null, + process, model.getProcessType()); + models.put(key, model); } for (String grid : model.getAllGrids()) { - models.put( - toKey(model.getCenter(), - Integer.parseInt(model.getSubCenter()), - grid, process), model); + String key = toKey(model.getCenter(), subCenter, grid, + process, model.getProcessType()); + models.put(key, model); } } } } - private String toKey(Integer center, Integer subcenter, String grid, - Integer process) { + Integer process, String processType) { StringBuilder builder = new StringBuilder(); builder.append(center); builder.append(subcenter); builder.append(grid); builder.append(process); + builder.append(processType); return builder.toString(); - // final int PRIME = 31; - // int result = 1; - // result = PRIME * result + ((center == null) ? 0 : center.hashCode()); - // result = PRIME * result - // + ((subcenter == null) ? 0 : subcenter.hashCode()); - // result = PRIME * result + ((grid == null) ? 0 : grid.hashCode()); - // result = PRIME * result + ((process == null) ? 0 : - // process.hashCode()); - // return result; + } } diff --git a/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/util/GridModel.java b/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/util/GridModel.java index faa661fdde..5c5b806698 100644 --- a/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/util/GridModel.java +++ b/edexOsgi/com.raytheon.edex.plugin.grib/src/com/raytheon/edex/plugin/grib/util/GridModel.java @@ -76,6 +76,10 @@ public class GridModel { @XmlElement(name = "id") private ArrayList process; + /** The generating processes associated with this model */ + @XmlElement + private String processType; + @XmlElement private String alias; @@ -130,6 +134,14 @@ public class GridModel { public void setProcess(ArrayList process) { this.process = process; } + + public String getProcessType() { + return processType; + } + + public void setProcessType(String processType) { + this.processType = processType; + } public Integer getCenter() { return center; diff --git a/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/grids/RTOFS/RTOFS-HudsonBaffin.xml b/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/grids/RTOFS/RTOFS-HudsonBaffin.xml index b219166244..80cc66ee9d 100755 --- a/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/grids/RTOFS/RTOFS-HudsonBaffin.xml +++ b/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/grids/RTOFS/RTOFS-HudsonBaffin.xml @@ -23,10 +23,10 @@ HudsonBaffin Real Time Ocean Forecast System LowerLeft degree - 45.0 + 40.0 251.0 328 - 132 + 152 0.25 0.25 diff --git a/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/models/RTOFS.xml b/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/models/RTOFS.xml index 02c6e5c10e..641d2b24d8 100644 --- a/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/models/RTOFS.xml +++ b/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/models/RTOFS.xml @@ -27,10 +27,10 @@ RTOFS-Alaska - 0 + 85 + Forecast - RTOFS-Arctic
7
@@ -39,10 +39,10 @@ RTOFS-Arctic - 0 + 85 + Forecast
- RTOFS-Bering
7
@@ -51,10 +51,10 @@ RTOFS-Bering - 0 + 85 + Forecast
- RTOFS-Guam
7
@@ -63,10 +63,10 @@ RTOFS-Guam - 0 + 85 + Forecast
- RTOFS-GulfAlaska
7
@@ -75,10 +75,10 @@ RTOFS-GulfAlaska - 0 + 85 + Forecast
- RTOFS-Honolulu
7
@@ -87,10 +87,10 @@ RTOFS-Honolulu - 0 + 85 + Forecast
- RTOFS-HudsonBaffin
7
@@ -99,10 +99,10 @@ RTOFS-HudsonBaffin - 0 + 85 + Forecast
- RTOFS-Samoa
7
@@ -111,10 +111,10 @@ RTOFS-Samoa - 0 + 85 + Forecast
- RTOFS-TropPaciLowres
7
@@ -123,10 +123,10 @@ RTOFS-TropPaciLowres - 0 + 85 + Forecast
- RTOFS-WestAtl
7
@@ -135,10 +135,10 @@ RTOFS-WestAtl - 0 + 85 + Forecast
- RTOFS-WestConus
7
@@ -147,10 +147,10 @@ RTOFS-WestConus - 0 + 85 + Forecast
- RTOFS-Atlantic
7
@@ -160,7 +160,6 @@ 45
- RTOFS-Atlantic-HiRes
7
@@ -169,8 +168,8 @@ 45 + Forecast
- RTOFS-GulfMaine
7
@@ -179,8 +178,8 @@ 45 + Forecast
- RTOFS-GulfMexico
7
@@ -189,8 +188,8 @@ 45 + Forecast
- RTOFS-GulfStream
7
@@ -199,5 +198,187 @@ 45 + Forecast +
+ + RTOFS-Now-Alaska +
7
+ 0 + + RTOFS-Alaska + + + 85 + + Nowcast +
+ + RTOFS-Now-Arctic +
7
+ 0 + + RTOFS-Arctic + + + 85 + + Nowcast +
+ + RTOFS-Now-Bering +
7
+ 0 + + RTOFS-Bering + + + 85 + + Nowcast +
+ + RTOFS-Now-Guam +
7
+ 0 + + RTOFS-Guam + + + 85 + + Nowcast +
+ + RTOFS-Now-GulfAlaska +
7
+ 0 + + RTOFS-GulfAlaska + + + 85 + + Nowcast +
+ + RTOFS-Now-Honolulu +
7
+ 0 + + RTOFS-Honolulu + + + 85 + + Nowcast +
+ + RTOFS-Now-HudsonBaffin +
7
+ 0 + + RTOFS-HudsonBaffin + + + 85 + + Nowcast +
+ + RTOFS-Now-Samoa +
7
+ 0 + + RTOFS-Samoa + + + 85 + + Nowcast +
+ + RTOFS-Now-TropPaciLowres +
7
+ 0 + + RTOFS-TropPaciLowres + + + 85 + + Nowcast +
+ + RTOFS-Now-WestAtl +
7
+ 0 + + RTOFS-WestAtl + + + 85 + + Nowcast +
+ + RTOFS-Now-WestConus +
7
+ 0 + + RTOFS-WestConus + + + 85 + + Nowcast +
+ + RTOFS-Now-Atlantic +
7
+ 0 + RTOFS-Atlantic + + 45 + +
+ + RTOFS-Now-Atlantic-HiRes +
7
+ 0 + RTOFS-Atlantic-HiRes + + 45 + + Nowcast +
+ + RTOFS-Now-GulfMaine +
7
+ 0 + RTOFS-GulfMaine + + 45 + + Nowcast +
+ + RTOFS-Now-GulfMexico +
7
+ 0 + RTOFS-GulfMexico + + 45 + + Nowcast +
+ + RTOFS-Now-GulfStream +
7
+ 0 + RTOFS-GulfStream + + 45 + + Nowcast
\ No newline at end of file diff --git a/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/tables/-1/-1/4.3.table b/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/tables/-1/-1/4.3.table index 63cd8820ba..b43ae2e620 100644 --- a/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/tables/-1/-1/4.3.table +++ b/edexOsgi/com.raytheon.edex.plugin.grib/utility/edex_static/base/grib/tables/-1/-1/4.3.table @@ -8,6 +8,11 @@ 6:6:Forecast error 7:7:Analysis error 8:8:Observation -# 9-191 Reserved +9:9:Climatological +10:10:Probability-Weighted Forecast +11:11:Bias-Corrected Ensemble Forecast +# 12-13 Reserved +14:14:Nowcast +# 15-191 Reserved # 192-254 Reserved for local use 255:255:Missing From d47a09530aace474e67a62c44862b2b15b682b3d Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Fri, 25 Apr 2014 14:19:46 -0500 Subject: [PATCH 110/188] Issue #2972 fix thin client startup Change-Id: I000da2e3dc289d1441f9df452a9f3e5f39fce5b4 Former-commit-id: 0b72fe025d46b92c125a1e36651b966bf9f00481 --- .../raytheon/uf/viz/thinclient/Activator.java | 27 +++++++++++-------- 1 file changed, 16 insertions(+), 11 deletions(-) diff --git a/cave/com.raytheon.uf.viz.thinclient/src/com/raytheon/uf/viz/thinclient/Activator.java b/cave/com.raytheon.uf.viz.thinclient/src/com/raytheon/uf/viz/thinclient/Activator.java index 2be4438732..8a76814c4b 100644 --- a/cave/com.raytheon.uf.viz.thinclient/src/com/raytheon/uf/viz/thinclient/Activator.java +++ b/cave/com.raytheon.uf.viz.thinclient/src/com/raytheon/uf/viz/thinclient/Activator.java @@ -28,7 +28,7 @@ import org.osgi.framework.BundleContext; import com.raytheon.uf.viz.core.localization.HierarchicalPreferenceStore; /** - * TODO Add Description + * Activator class for the thinclient * *
  * 
@@ -37,7 +37,8 @@ import com.raytheon.uf.viz.core.localization.HierarchicalPreferenceStore;
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
  * Oct 20, 2011            mschenke    Initial creation
- * Mar  3, 2014 2861       mschenke    Create preference store immediately
+ * Mar 03, 2014 2861       mschenke    Create preference store immediately
+ * Apr 25, 2014 2972       njensen     Fixed prefs so thinclient can start
  * 
  * 
  * 
@@ -56,12 +57,17 @@ public class Activator extends AbstractUIPlugin { private BundleContext ctx; - // General preference store - private IPersistentPreferenceStore prefs = new HierarchicalPreferenceStore( - this); + /** + * General preference store. This must NOT be a HierarchicalPreferenceStore + * as those store to the server and this preference store contains the + * server addresses. + */ + private ScopedPreferenceStore prefs = new ScopedPreferenceStore( + InstanceScope.INSTANCE, PLUGIN_ID); // Preferences for UI - private HierarchicalPreferenceStore uiPrefs; + private HierarchicalPreferenceStore uiPrefs = new HierarchicalPreferenceStore( + PLUGIN_ID); private IThinClientComponent component; @@ -78,6 +84,7 @@ public class Activator extends AbstractUIPlugin { * org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext * ) */ + @Override public void start(BundleContext context) throws Exception { super.start(context); this.ctx = context; @@ -95,6 +102,7 @@ public class Activator extends AbstractUIPlugin { * org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext * ) */ + @Override public void stop(BundleContext context) throws Exception { plugin = null; super.stop(context); @@ -121,15 +129,12 @@ public class Activator extends AbstractUIPlugin { */ @Override public IPersistentPreferenceStore getPreferenceStore() { - if (prefs == null) { - prefs = new ScopedPreferenceStore(new InstanceScope(), PLUGIN_ID); - } - return prefs; } /** - * Get the Ui preference store + * Get the UI preference store. This only contains the options for the + * refresh intervals that are shown on the preference page. * * @return */ From de249decabb8463e67f5eb4dc856f72deb17840d Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Fri, 25 Apr 2014 14:41:55 -0500 Subject: [PATCH 111/188] Issue #2629: Update capture to grab Xorg log files. Change-Id: Ic6d4806bee75894805fb7fa5882d3b454418c26d Former-commit-id: 38ad09697f3e618b6c9edb6592913b2d50014d14 --- .../com.raytheon.uf.tools.cli/impl/capture | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/edexOsgi/com.raytheon.uf.tools.cli/impl/capture b/edexOsgi/com.raytheon.uf.tools.cli/impl/capture index 9c6ef5af9b..ad48d8995c 100644 --- a/edexOsgi/com.raytheon.uf.tools.cli/impl/capture +++ b/edexOsgi/com.raytheon.uf.tools.cli/impl/capture @@ -7,6 +7,8 @@ grepString="(/awips2/cave/cave|/usr/local/viz/cave)" edexGrepString="edex.run.mode=" +xorgLogPath="/var/log" + # the remote servers to grab top on. Use to get general state of servers REMOTE_SERVERS_TO_CHECK="${DX_SERVERS}" @@ -30,6 +32,7 @@ GRAB_REMOTE_VMSTAT="Y" GRAB_CAVE_AND_ALERTVIZ_LOGS="Y" GRAB_SCREENSHOT="Y" GRAB_CURRENT_QUERIES="Y" +GRAB_XORG_LOG="Y" EDEX_MODE="N" FORCE="N" TGZ_OUTPUT="Y" @@ -150,6 +153,16 @@ grabScreenShot() { fi } +# runs import to grab screen shot of users desktop +grabXorgLog() { + if [ "$GRAB_XORG_LOG" == "y" ]; then + echo "Capturing Xorg logs" + t1=`date "+%Y%m%d %H:%M:%S"` + echo "${t1}: Capturing Xorg logs" >> $processFile + cp ${xorgLogPath}/Xorg*.log* ${dataPath} >> $processFile 2>&1 & + fi +} + # runs ssh command to grab top on a remote server, requires auto login to be setup grabRemoteTop() { if [ "$GRAB_REMOTE_TOP" == "y" ]; then @@ -433,6 +446,7 @@ checkYes TGZ_OUTPUT $TGZ_OUTPUT checkYes ACCCUM $ACCCUM checkYes RUN_VERSIONS $RUN_VERSIONS checkYes GRAB_SCREENSHOT $GRAB_SCREENSHOT +checkYes GRAB_XORG_LOG $GRAB_XORG_LOG # if PID mode don't grab other hs_err_pids if [ ! -z $cavePid ]; then @@ -451,6 +465,7 @@ if [ "$EDEX_MODE" == "y" ]; then MOVE_ALL_HS_ERR_PID="n" GRAB_REMOTE_TOP="n" GRAB_REMOTE_VMSTAT="n" + GRAB_XORG_LOG="n" fi umask 0002 @@ -553,6 +568,9 @@ else echo "" >> $processFile fi +# grab Xorg logs +grabXorgLog + # grab top for servers grabRemoteTop From deda54488f7eaedb47b896a518ee3501a5b7d91b Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Fri, 25 Apr 2014 14:45:07 -0500 Subject: [PATCH 112/188] Issue #3000 fix common.dataplugin.bufrmos manifest Change-Id: I4f414ad2cc3d147badb0196a03ba152c9a74dccf Former-commit-id: c91c2477aeff207ff253bce22b4fea57a7172d5c --- .../META-INF/MANIFEST.MF | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/META-INF/MANIFEST.MF index a1f2ab3d49..ed84f2694a 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.bufrmos/META-INF/MANIFEST.MF @@ -3,10 +3,8 @@ Bundle-ManifestVersion: 2 Bundle-Name: Bufrmos Bundle-SymbolicName: com.raytheon.uf.common.dataplugin.bufrmos Bundle-Version: 1.14.0.qualifier -Bundle-Activator: com.raytheon.uf.common.dataplugin.bufrmos.Activator Bundle-Vendor: RAYTHEON -Require-Bundle: org.eclipse.core.runtime, - org.hibernate;bundle-version="3.5.6", +Require-Bundle: org.hibernate;bundle-version="3.5.6", javax.persistence;bundle-version="1.0.0", com.raytheon.uf.common.dataplugin;bundle-version="1.12.1174", com.raytheon.uf.common.serialization;bundle-version="1.12.1174", From 36742a30f3b8d064a2628251dfa8c8c4f7dff85f Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Fri, 25 Apr 2014 14:53:14 -0500 Subject: [PATCH 113/188] Issue #2726: Make SmartInit shutdown more gracefully Change-Id: I1a5514e75645083a1d8fa8a771ac33ea8fd39fe7 Former-commit-id: 93f8af097d2a04e054e1c3d0ae0b7d62ca30892e --- .../com/raytheon/edex/plugin/gfe/smartinit/SmartInitSrv.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/SmartInitSrv.java b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/SmartInitSrv.java index 6e8f75ddfb..6837385b77 100644 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/SmartInitSrv.java +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/src/com/raytheon/edex/plugin/gfe/smartinit/SmartInitSrv.java @@ -38,6 +38,7 @@ import com.raytheon.uf.common.localization.PathManagerFactory; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.util.FileUtil; +import com.raytheon.uf.edex.core.EDEXUtil; import com.raytheon.uf.edex.core.EdexTimerBasedThread; /** @@ -88,7 +89,7 @@ public class SmartInitSrv extends EdexTimerBasedThread { if (record != null) { runSmartInit(record); } - } while (record != null); + } while ((record != null) && !EDEXUtil.isShuttingDown()); } @Override From e0b6f674f3dcd3685ccb7ccea439b2e11526d77f Mon Sep 17 00:00:00 2001 From: "steve.naples" Date: Mon, 28 Apr 2014 13:55:21 +0000 Subject: [PATCH 114/188] ASM #528 Updated DrawPolygonDlg to remember location when opened and closed. Change-Id: I19ec2f2e1898506387d053b8ada80d2d2d67cf7c Former-commit-id: ae0616b0b71e0d1952f2c3e8f461a4d8e79e934f --- .../ui/dialogs/polygon/DrawPolygonDlg.java | 38 ++++++++++++++++++- 1 file changed, 37 insertions(+), 1 deletion(-) diff --git a/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/dialogs/polygon/DrawPolygonDlg.java b/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/dialogs/polygon/DrawPolygonDlg.java index ea313817a8..e011b4dc25 100644 --- a/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/dialogs/polygon/DrawPolygonDlg.java +++ b/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/dialogs/polygon/DrawPolygonDlg.java @@ -24,6 +24,8 @@ import java.util.Date; import java.util.List; import org.eclipse.swt.SWT; +import org.eclipse.swt.events.ControlAdapter; +import org.eclipse.swt.events.ControlEvent; import org.eclipse.swt.events.SelectionAdapter; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.graphics.Cursor; @@ -60,6 +62,7 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * Sep 11, 2013 #2353 lvenable Fixed cursor memory leak. * Jan 29, 2014 16561 snaples Updated processDrawPrecipValue to remove polygon wireframe after setting value. * Feb 2, 2014 16201 snaples Added saved data flag support + * Apr 28, 2014 16707 snaples Added code to save and set location of dialog box when moved. * * * @@ -113,6 +116,12 @@ public class DrawPolygonDlg extends CaveSWTDialog { /** The polygon resource */ private final MPEPolygonResource resource; + + /** Point to hold location of dialog */ + private static org.eclipse.swt.graphics.Point dlgLoc = null; + + /** Status of dialog opened or not */ + private boolean dialogOpened = false; /** * Constructor. @@ -144,13 +153,28 @@ public class DrawPolygonDlg extends CaveSWTDialog { } @Override - protected void initializeComponents(Shell shell) { + protected void initializeComponents(final Shell shell) { setReturnValue(false); boldFont = new Font(shell.getDisplay(), "Monospace", 10, SWT.BOLD); font = new Font(shell.getDisplay(), "Monospace", 10, SWT.NORMAL); // Initialize all of the controls and layoutsendCal initializeComponents(); + shell.addControlListener(new ControlAdapter() { + @Override + public void controlMoved(ControlEvent e) { + if (!dialogOpened) { + return; + } + + if (dlgLoc == null) { + return; + } + + dlgLoc.x = shell.getBounds().x; + dlgLoc.y = shell.getBounds().y; + } + }); } /** @@ -162,6 +186,18 @@ public class DrawPolygonDlg extends CaveSWTDialog { createCloseBtn(); } + @Override + protected void opened() { + if (dlgLoc == null) { + dlgLoc = new org.eclipse.swt.graphics.Point(shell.getBounds().x, shell.getBounds().y); + } + else { + shell.setLocation(dlgLoc); + } + dialogOpened = true; + } + + /** * Create the persistent group. */ From 9585fc8077f7d553dc4589537334e13e30970c29 Mon Sep 17 00:00:00 2001 From: "Loubna.Bousaidi" Date: Mon, 28 Apr 2014 14:16:50 +0000 Subject: [PATCH 115/188] ASM #578 apply gross range check to the adjusted value Change-Id: Ia90bc10e6e1e1baa8f3842ade56d7551ca405e34 Former-commit-id: 598700ad6ca6cb7881d68f8e7703327f7c58c19c --- .../src/com/raytheon/edex/plugin/shef/database/PostShef.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/edexOsgi/com.raytheon.edex.plugin.shef/src/com/raytheon/edex/plugin/shef/database/PostShef.java b/edexOsgi/com.raytheon.edex.plugin.shef/src/com/raytheon/edex/plugin/shef/database/PostShef.java index 286691d226..dec3078fbd 100644 --- a/edexOsgi/com.raytheon.edex.plugin.shef/src/com/raytheon/edex/plugin/shef/database/PostShef.java +++ b/edexOsgi/com.raytheon.edex.plugin.shef/src/com/raytheon/edex/plugin/shef/database/PostShef.java @@ -111,7 +111,7 @@ import com.raytheon.uf.edex.decodertools.time.TimeTools; * data can be posted to appropriate pe-based tables only if the data * type is not READING like in A1 code. * 02/18/2014 16572 l. Bousaidi only apply adjust factor to non missing values. - * + * 04/24/2014 16904 lbousaidi gross check should be applied to adjusted value. * * * @author mduff @@ -646,6 +646,8 @@ public class PostShef { if (!dataValue.equals(ShefConstants.SHEF_MISSING)) { adjustRawValue(locId, data); } + + dataValue = data.getStringValue(); /* * multiply non-missing values of discharge values and unspecified From 2f4c0cd3647476a642f85aae84a395de9d5cd363 Mon Sep 17 00:00:00 2001 From: Dave Hladky Date: Thu, 3 Apr 2014 16:55:12 -0500 Subject: [PATCH 116/188] Issue #2940 Better error message for bad XMRG config in FFMP Former-commit-id: dfa3f534b96852975afcd13a6bed653b0f3b8f40 --- .../uf/edex/plugin/ffmp/FFMPGenerator.java | 5 +-- .../plugin/ffmp/common/FFMPProcessor.java | 32 +++++++++++++++---- 2 files changed, 28 insertions(+), 9 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/FFMPGenerator.java b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/FFMPGenerator.java index 3d3fca512b..071eaebb8b 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/FFMPGenerator.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/FFMPGenerator.java @@ -136,6 +136,7 @@ import com.raytheon.uf.edex.plugin.ffmp.common.FFTIRatioDiff; * re-query with every update. * Jul 15, 2013 2184 dhladky Remove all HUC's for storage except ALL * Aug 30, 2013 2298 rjpeter Make getPluginName abstract + * Apr 24, 2014 2940 dhladky Prevent storage of bad records. * * * @author dhladky @@ -697,10 +698,10 @@ public class FFMPGenerator extends CompositeProductGenerator implements FFMPProcessor ffmp = new FFMPProcessor(config, generator, ffmpRec, template); ffmpRec = ffmp.processFFMP(ffmpProduct); - ffmpRec.constructDataURI(); - + if (ffmpRec != null) { + ffmpRec.constructDataURI(); persistRecord(ffmpRec); processDataContainer(ffmpRec, siteKey); // Now that we have the data container, diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java index c996d429b3..be1166159b 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java @@ -37,6 +37,7 @@ import org.opengis.referencing.crs.ProjectedCRS; import org.opengis.referencing.datum.PixelInCell; import org.opengis.referencing.operation.TransformException; +import com.raytheon.uf.common.dataplugin.exception.MalformedDataException; import com.raytheon.uf.common.dataplugin.ffmp.FFMPBasin; import com.raytheon.uf.common.dataplugin.ffmp.FFMPBasinData; import com.raytheon.uf.common.dataplugin.ffmp.FFMPDataContainer; @@ -260,9 +261,7 @@ public class FFMPProcessor { try { xmrg = (XmrgFile) config.getSourceData( source.getSourceName()).get(dataKey); - this.extent = getExtents(source.getHrapGridFactor()); - setHRAPSubGrid(extent, source.getHrapGridFactor()); - xmrgData = xmrg.getData(extent); + xmrgData = getXMRGData(); } catch (Exception e) { fireBadConfigMessage(type, e); return; @@ -610,6 +609,7 @@ public class FFMPProcessor { } catch (Exception e) { + ffmpRec = null; throw new Exception( "FFMPProcessor: Failed to process source domain: " + source.getSourceName() + ": " @@ -704,6 +704,7 @@ public class FFMPProcessor { } } catch (Exception e) { + ffmpRec = null; throw new Exception("FFMPProcessor: Failed to process source: " + source.getSourceName()); } @@ -735,9 +736,7 @@ public class FFMPProcessor { try { xmrg = (XmrgFile) config.getSourceData(source.getSourceName()).get( dataKey); - this.extent = getExtents(source.getHrapGridFactor()); - setHRAPSubGrid(extent, source.getHrapGridFactor()); - xmrgData = xmrg.getData(extent); + xmrgData = getXMRGData(); recdate = xmrg.getHeader().getValidDate(); } catch (Exception e) { fireBadConfigMessage(type, e); @@ -804,6 +803,7 @@ public class FFMPProcessor { } } catch (Exception e) { + ffmpRec = null; statusHandler.error("Unable to process VGB: "+type, e); } } @@ -1820,8 +1820,26 @@ public class FFMPProcessor { sb.append("Record: " + gribRec.getDataURI() + " \n"); } } - + // null out the record it is garbage. + ffmpRec = null; statusHandler.handle(Priority.ERROR, sb.toString(), e); } + /** + * Gets the XMRG data array + * + * @return + */ + private short[][] getXMRGData() throws Exception { + + this.extent = getExtents(source.getHrapGridFactor()); + setHRAPSubGrid(extent, source.getHrapGridFactor()); + if (xmrg.getHrapExtent() != null) { + xmrgData = xmrg.getData(extent); + } else { + throw new MalformedDataException("The XMRG data is malformed or the file is non-readable."); + } + + return xmrgData; + } } From 812eebdd7211f026acbccae07ff70bc846872cea Mon Sep 17 00:00:00 2001 From: Ben Steffensmeier Date: Mon, 28 Apr 2014 13:00:39 -0500 Subject: [PATCH 117/188] Issue #2947 ensure consistent interpolation levels for derived satellite. Former-commit-id: 33d87894c4385cb8f6982c1833f6956fd60d7368 --- .../viz/satellite/inventory/DerivedSatelliteRecord.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/DerivedSatelliteRecord.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/DerivedSatelliteRecord.java index 185de0e49b..713a6a4694 100644 --- a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/DerivedSatelliteRecord.java +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/DerivedSatelliteRecord.java @@ -73,13 +73,9 @@ public class DerivedSatelliteRecord extends SatelliteRecord { Set base = findBaseRecords(requestableData); Set creatingEntities = new HashSet(); - int interpolationLevels = 1; for (SatelliteRecord record : base) { creatingEntities.add(record.getCreatingEntity()); - interpolationLevels = Math.max(interpolationLevels, - record.getInterpolationLevels()); } - setInterpolationLevels(interpolationLevels); if (creatingEntities.size() == 1) { setCreatingEntity(creatingEntities.iterator().next()); } else { @@ -92,6 +88,10 @@ public class DerivedSatelliteRecord extends SatelliteRecord { setCoverage(((ComparableSatMapCoverage) requestableData.getSpace()) .getCoverage()); } + Rectangle[] levels = GridDownscaler + .getDownscaleSizes(getGridGeometry()); + setInterpolationLevels(levels.length - 1); + } /** From 573465f316dc4f471ed86f70d050abf9c47f8e68 Mon Sep 17 00:00:00 2001 From: Lee Venable Date: Mon, 28 Apr 2014 15:24:26 -0500 Subject: [PATCH 118/188] Issue #3053 - added check for selected items. Change-Id: Iba7dff4291679524b03518790b0e183c3a980934 Former-commit-id: ca47394d9578aac17d1696bd78c0fbcee5fe3f8f --- .../src/com/raytheon/viz/ui/dialogs/ListSelectionDlg.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/ListSelectionDlg.java b/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/ListSelectionDlg.java index 7f8e167813..be2f94b43c 100644 --- a/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/ListSelectionDlg.java +++ b/cave/com.raytheon.viz.ui/src/com/raytheon/viz/ui/dialogs/ListSelectionDlg.java @@ -311,9 +311,11 @@ public class ListSelectionDlg extends CaveSWTDialog { */ private void action() { - int choice = displayConfirmationBox(); - if (choice == SWT.CANCEL) { - return; + if (selectList.getSelectionCount() == 0) { + int choice = displayConfirmationBox(); + if (choice == SWT.CANCEL) { + return; + } } if (returnAsArray == ReturnArray.ARRAY_STRING_ITEMS) { From 5beb3be2e8d2275c20af59137ea0ea8784ddd60b Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Tue, 29 Apr 2014 12:48:24 -0500 Subject: [PATCH 119/188] Issue #2906 added close to BUFR parser close netcdf file to solve NFS clean issue Former-commit-id: 9675e997369e39455aacadcd72d0d8476f6c7ffc --- .../com/raytheon/uf/common/nc/bufr/BufrParser.java | 10 ++++++++++ .../uf/edex/plugin/bufrobs/BufrObsProcessor.java | 14 ++++++++++++-- 2 files changed, 22 insertions(+), 2 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.nc.bufr/src/com/raytheon/uf/common/nc/bufr/BufrParser.java b/edexOsgi/com.raytheon.uf.common.nc.bufr/src/com/raytheon/uf/common/nc/bufr/BufrParser.java index d717ac9031..1d115c6168 100644 --- a/edexOsgi/com.raytheon.uf.common.nc.bufr/src/com/raytheon/uf/common/nc/bufr/BufrParser.java +++ b/edexOsgi/com.raytheon.uf.common.nc.bufr/src/com/raytheon/uf/common/nc/bufr/BufrParser.java @@ -58,6 +58,7 @@ import com.raytheon.uf.common.status.UFStatus; * Mar 26, 2014 2905 bclement fixed types, added scale/offset * Apr 01, 2014 2905 bclement moved splitter functionality to separate utility * added scanForStructField() + * Apr 29, 2014 2906 bclement added close() * * * @@ -827,4 +828,13 @@ public class BufrParser { return structStack.size(); } + /** + * Release resources associated with BUFR file. + * + * @throws IOException + */ + public void close() throws IOException { + this.ncfile.close(); + } + } diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/src/com/raytheon/uf/edex/plugin/bufrobs/BufrObsProcessor.java b/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/src/com/raytheon/uf/edex/plugin/bufrobs/BufrObsProcessor.java index 9cf61cd242..46017bc3f3 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/src/com/raytheon/uf/edex/plugin/bufrobs/BufrObsProcessor.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.bufrobs/src/com/raytheon/uf/edex/plugin/bufrobs/BufrObsProcessor.java @@ -44,7 +44,8 @@ import com.raytheon.uf.edex.plugin.bufrobs.category.CategoryKey; * * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Apr 1, 2014 2906 bclement Initial creation + * Apr 01, 2014 2906 bclement Initial creation + * Apr 29, 2014 2906 bclement close parser when finished * * * @@ -69,9 +70,10 @@ public class BufrObsProcessor { */ public PluginDataObject[] process(File bufrFile) throws BufrObsDecodeException { + BufrParser parser = null; PluginDataObject[] rval; try { - BufrParser parser = new BufrParser(bufrFile); + parser = new BufrParser(bufrFile); CategoryKey key = getBufrCategory(parser); AbstractBufrSfcObsDecoder decoder = getDecoder(key); if (decoder == null) { @@ -86,6 +88,14 @@ public class BufrObsProcessor { } catch (IOException e) { throw new BufrObsDecodeException("Unable to read BUFR file: " + bufrFile, e); + } finally { + if (parser != null) + try { + parser.close(); + } catch (IOException e) { + throw new BufrObsDecodeException( + "Unable to close parser for file: " + bufrFile, e); + } } return rval; } From 7a2775ecbc134bce7b8572110e3dbce6f89729ef Mon Sep 17 00:00:00 2001 From: Roger Ferrel Date: Tue, 29 Apr 2014 14:14:20 -0500 Subject: [PATCH 120/188] Issue #3036 Added check for archive's root directories. Former-commit-id: f344acf3572150c7470ab1e3c3bbb356166c78ff --- .../archive/config/ArchiveConfigManager.java | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/ArchiveConfigManager.java b/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/ArchiveConfigManager.java index ff861e8d5b..f41a09128b 100644 --- a/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/ArchiveConfigManager.java +++ b/edexOsgi/com.raytheon.uf.common.archive/src/com/raytheon/uf/common/archive/config/ArchiveConfigManager.java @@ -96,6 +96,7 @@ import com.raytheon.uf.common.util.FileUtil; * Mar 21, 2014 2835 rjpeter Optimized getDisplayData to only scan directories to the depth required to * populate the display label. * Apr 01, 2014 2862 rferrel Moved purge only routines to ArchivePurgeManager. + * Apr 29, 2014 3036 rferrel Check for missing archive root directories. * * * @author rferrel @@ -578,7 +579,12 @@ public class ArchiveConfigManager { List dirList = polledDirs.get(dir); if (dirList == null) { File[] list = dir.listFiles(); - dirList = Arrays.asList(list); + // Missing directory. + if (list == null) { + dirList = new ArrayList(0); + } else { + dirList = Arrays.asList(list); + } polledDirs.put(dir, dirList); } @@ -732,6 +738,13 @@ public class ArchiveConfigManager { } File rootFile = new File(rootDirName); + if (!(rootFile.isDirectory() && rootFile.canRead())) { + statusHandler.handle( + Priority.ERROR, + "Unable to access archive directory: " + + rootFile.getAbsolutePath()); + } + TreeMap>> displays = new TreeMap>>(); Map> dirMap = getDirs(rootFile, categoryConfig, maxDepth); From 156c25fb9cce9c423c65f17d8001ddea6d4da77b Mon Sep 17 00:00:00 2001 From: Ben Steffensmeier Date: Tue, 29 Apr 2014 15:35:29 -0500 Subject: [PATCH 121/188] Issue #3080 add NaN conversion to Slice.py Former-commit-id: 084a209f64cf9deb527414500c368ea397b9e3a4 --- .../base/derivedParameters/functions/Slice.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Slice.py b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Slice.py index 4992833a44..3a81630819 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Slice.py +++ b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Slice.py @@ -19,7 +19,9 @@ ## import gridslice -from numpy import ndarray +from numpy import ndarray, NaN + +gridslice_maskval = 1e37 def execute(*args): #defineNumpySlice(vc, param, targetLevel, sense) @@ -39,16 +41,18 @@ def execute(*args): if type(args[1]) == ndarray: # target level is 2d grid rval = gridslice.createNumpySlice(args[0][1], args[0][0], args[1], int(args[2])) - + rval[rval == gridslice_maskval] = NaN return rval else: # target level is single value rval = gridslice.defineNumpySlice(args[0][1], args[0][0], args[1], int(args[2])) + rval[rval == gridslice_maskval] = NaN return rval else: if type(args[2]) == ndarray: # cube, cube, grid, sense rval = gridslice.createNumpySlice(args[0][0], args[1][0], args[2], int(args[3])) + rval[rval == gridslice_maskval] = NaN return rval else: # cube, cube, level, sense @@ -62,6 +66,6 @@ def execute(*args): rval = gridslice.defineNumpySlice(args[0][1], args[0][0], args[2], levelSense) rval = gridslice.createNumpySlice(args[1][1], args[1][0], rval, int(args[3])) - + rval[rval == gridslice_maskval] = NaN return rval \ No newline at end of file From 1d38fb2df19f761c84b84cdeb05b52ccf6da6d1c Mon Sep 17 00:00:00 2001 From: Ben Steffensmeier Date: Tue, 29 Apr 2014 15:42:50 -0500 Subject: [PATCH 122/188] Issue #3081 Use alias in derived paraemters less. Former-commit-id: cdbfab27991a9536e48436c084801eb507322e7c --- .../derivparam/tree/DerivedLevelNode.java | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.derivparam/src/com/raytheon/uf/common/derivparam/tree/DerivedLevelNode.java b/edexOsgi/com.raytheon.uf.common.derivparam/src/com/raytheon/uf/common/derivparam/tree/DerivedLevelNode.java index 10ddadd30b..c736917242 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam/src/com/raytheon/uf/common/derivparam/tree/DerivedLevelNode.java +++ b/edexOsgi/com.raytheon.uf.common.derivparam/src/com/raytheon/uf/common/derivparam/tree/DerivedLevelNode.java @@ -61,6 +61,9 @@ import com.raytheon.uf.common.time.DataTime; * ------------- -------- ----------- -------------------------- * Dec 14, 2009 rjpeter Initial creation * Apr 11, 2014 2947 bsteffen Don't check units until data is requested. + * Apr 29, 2014 3081 bsteffen Undo change for 2947 because it prevents + * multiple level derivation from happening + * simultaneously in the function adapter. * * * @@ -401,11 +404,15 @@ public class DerivedLevelNode extends AbstractDerivedDataNode { Set newRecs = new HashSet( records.size()); for (AbstractRequestableData record : records) { - /* Wrap in an alias to perform unit conversion when necessary. */ - AbstractRequestableData alias = new AliasRequestableData(record); - alias.setUnit(field.getUnit()); - newRecs.add(alias); - + if (record.getUnit() != null + && !record.getUnit().equals(field.getUnit()) + && record.getUnit().isCompatible(field.getUnit())) { + AbstractRequestableData alias = new AliasRequestableData(record); + alias.setUnit(field.getUnit()); + newRecs.add(alias); + } else { + newRecs.add(record); + } } return newRecs; } From 760ee964d6597b100e786af4e628f1ceac877bd7 Mon Sep 17 00:00:00 2001 From: "Loubna.Bousaidi" Date: Tue, 29 Apr 2014 21:09:34 +0000 Subject: [PATCH 123/188] ASM #511 changes to transmit_rfc_bias calls from MPE Change-Id: I40c582b8d2c97e16593b8abbf8a8051e21c93004 Former-commit-id: a6033a982c80e822d9f4cb62a70b9722d79432c6 --- .../viz/mpe/ui/actions/SaveBestEstimate.java | 25 +++++++++++++------ .../raytheon/viz/mpe/core/RegenHrFlds.java | 20 +++++++++++++++ .../precip_proc/bin/rerun_mpe_fieldgen | 7 +++++- .../precip_proc/bin/transmit_rfc_bias | 4 +-- 4 files changed, 46 insertions(+), 10 deletions(-) diff --git a/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/actions/SaveBestEstimate.java b/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/actions/SaveBestEstimate.java index 0a0ff218c9..342cf0281c 100644 --- a/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/actions/SaveBestEstimate.java +++ b/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/actions/SaveBestEstimate.java @@ -22,6 +22,7 @@ package com.raytheon.viz.mpe.ui.actions; import java.awt.image.BufferedImage; import java.io.File; import java.io.IOException; +import java.text.SimpleDateFormat; import java.util.Arrays; import java.util.Date; import java.util.Iterator; @@ -58,6 +59,8 @@ import com.raytheon.viz.mpe.ui.MPEDisplayManager; * Dec 11, 2012 mschenke Initial creation * Feb 2, 2014 16201 snaples Added saved data flag support * + * Apr29, 2014 16308 lbousaidi transmit RFC Bias when an hour + * MPE is saved via the GUI. * * * @author mschenke @@ -256,13 +259,21 @@ public class SaveBestEstimate { boolean transmit_bias_on_save = appsDefaults.getBoolean( "transmit_bias_on_save", true); if (transmit_rfc_bias && transmit_bias_on_save) { - // sprintf ( command_string, "%s/transmit_rfc_bias %s", - // precip_proc_bin_dir, cdate ); - // UFStatus.handle(Priority.VERBOSE, Activator.PLUGIN_ID, - // StatusConstants.CATEGORY_MPE, null, - // String.format("Invoking transmit_rfc_bias script using command:\n" - // "%s\n", command_string )); - // system ( command_string ); + + Date currentDate = MPEDisplayManager.getCurrent().getCurrentEditDate(); + SimpleDateFormat formatter = new SimpleDateFormat("yyyyMMddHH"); + String transmitDate = formatter.format(currentDate); + String scriptDir = appsDefaults.getToken("pproc_bin"); + String scriptName = "transmit_rfc_bias"; + ProcessBuilder pb = new ProcessBuilder(scriptDir + "/" + scriptName, + transmitDate); + try { + pb.start(); + } catch (IOException e) { + e.printStackTrace(); + } + + } MPEDisplayManager.getCurrent().setSavedData(true); } diff --git a/cave/com.raytheon.viz.mpe/src/com/raytheon/viz/mpe/core/RegenHrFlds.java b/cave/com.raytheon.viz.mpe/src/com/raytheon/viz/mpe/core/RegenHrFlds.java index 0bbe63a515..a9883bba40 100644 --- a/cave/com.raytheon.viz.mpe/src/com/raytheon/viz/mpe/core/RegenHrFlds.java +++ b/cave/com.raytheon.viz.mpe/src/com/raytheon/viz/mpe/core/RegenHrFlds.java @@ -19,6 +19,7 @@ **/ package com.raytheon.viz.mpe.core; +import java.io.IOException; import java.text.SimpleDateFormat; import java.util.Calendar; import java.util.Date; @@ -38,6 +39,7 @@ import com.raytheon.uf.common.dataplugin.shef.tables.Hourlypp; import com.raytheon.uf.common.dataplugin.shef.tables.Pseudogageval; import com.raytheon.uf.common.dataplugin.shef.tables.Rawpp; import com.raytheon.uf.common.dataplugin.shef.util.ShefConstants; +import com.raytheon.uf.common.ohd.AppsDefaults; import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.viz.hydrocommon.whfslib.GagePPOptions; import com.raytheon.viz.hydrocommon.whfslib.GagePPOptions.shef_dup; @@ -56,6 +58,8 @@ import com.raytheon.viz.mpe.core.MPEDataManager.MPEGageData; * Jan 02, 2013 15565 snaples Fixed problem with wrong time being sent to mpe_fieldgen * Mar 14, 2013 1457 mpduff Fixed memory leak. * Jun 18, 2013 16053 snaples Removed check for Radar Edit flag + * Apr 24, 2014 16308 lbousaidi added the ability to send RFC Bias across the WAN + * after Mpe fieldgen run. * * * @author snaples @@ -293,6 +297,22 @@ public class RegenHrFlds { e.printStackTrace(); } + /*-------------------------------------------------------------------------*/ + /* send RFC Bias across the WAN if the tokens TRANSMIT_BIAS_ON_RERUN + * and MPE_TRANSMIT_BIAS are both ON. The script rerun_mpe_fieldgen + * only run transmit_rfc_bias but it doesn't rerun mpe_fieldgen + /*-------------------------------------------------------------------------*/ + AppsDefaults appsDefaults = AppsDefaults.getInstance(); + String scriptDir = appsDefaults.getToken("pproc_bin"); + String scriptName ="rerun_mpe_fieldgen"; + String transmitRun= dr.format(datetime); + ProcessBuilder pb = new ProcessBuilder(scriptDir + "/" + scriptName ,hour, + transmitRun); + try { + pb.start(); + } catch (IOException e) { + e.printStackTrace(); + } MPEDataManager.getInstance().clearEditGages(); shell.setCursor(null); } diff --git a/nativeLib/files.native/awipsShare/hydroapps/precip_proc/bin/rerun_mpe_fieldgen b/nativeLib/files.native/awipsShare/hydroapps/precip_proc/bin/rerun_mpe_fieldgen index c047ad068f..8c471b9e8d 100755 --- a/nativeLib/files.native/awipsShare/hydroapps/precip_proc/bin/rerun_mpe_fieldgen +++ b/nativeLib/files.native/awipsShare/hydroapps/precip_proc/bin/rerun_mpe_fieldgen @@ -12,8 +12,11 @@ # This allows you to call this script from outside of ./standard/bin RUN_FROM_DIR=`dirname $0` +. $RUN_FROM_DIR/../../set_hydro_env +export MPE_TRANSMIT_BIAS=$(get_apps_defaults mpe_transmit_bias) +export TRANSMIT_BIAS_ON_RERUN=$(get_apps_defaults transmit_bias_on_rerun) +export PPROC_BIN=$(get_apps_defaults pproc_bin) -# # Transmit the RFC bias message if the user has # elected to do so on reruns. # @@ -21,6 +24,8 @@ if [[ "$MPE_TRANSMIT_BIAS" = "ON" && "$TRANSMIT_BIAS_ON_RERUN" = "YES" ]] then year=`echo $2 | cut -c5-8` monthday=`echo $2 | cut -c1-4` + hour=`echo $1` + echo $year$monthday$1 $PPROC_BIN/transmit_rfc_bias $year$monthday$1 fi diff --git a/nativeLib/files.native/awipsShare/hydroapps/precip_proc/bin/transmit_rfc_bias b/nativeLib/files.native/awipsShare/hydroapps/precip_proc/bin/transmit_rfc_bias index 17f2448b5a..8c0023a9cf 100755 --- a/nativeLib/files.native/awipsShare/hydroapps/precip_proc/bin/transmit_rfc_bias +++ b/nativeLib/files.native/awipsShare/hydroapps/precip_proc/bin/transmit_rfc_bias @@ -43,13 +43,13 @@ RUN_FROM_DIR=`dirname $0` # These lines are commented out because this script will be run # from mpe_editor using mpe_editor's environment. If this script # is run stand alone, these lines must be uncommented. -export FXA_HOME=/awips/fxa -. $FXA_HOME/readenv.sh . $RUN_FROM_DIR/../../set_hydro_env export RFC_BIAS_OUTPUT_DIR=$(get_apps_defaults rfc_bias_output_dir) export PROCESS_BIAS_LOG_DIR=$(get_apps_defaults process_bias_log_dir) export MPE_TRANSMIT_BIAS=$(get_apps_defaults mpe_transmit_bias) export PPROC_BIN=$(get_apps_defaults pproc_bin) +export FXA_LOCAL_SITE=$(get_apps_defaults fxa_local_site) +export SYS_JAVA_DIR=$(get_apps_defaults sys_java_dir) # set java classpath export CLASSPATH=$DB_DRIVER_PATH:$PPROC_BIN/bias_trans.jar From 60bfadd865445a2a7216cae612ceeafa54b3c029 Mon Sep 17 00:00:00 2001 From: Mike Duff Date: Wed, 30 Apr 2014 10:17:56 -0500 Subject: [PATCH 124/188] Issue #2860 - Fix to not create empty substitution tags Change-Id: I6734c61103b5bf9db3c27adfe0305cb5eb60d4ff Former-commit-id: ecd5428e2adad5a0b8022d4a89a13a5a4d549dc1 --- .../uf/edex/plugin/redbook/menu/RedbookMenuUtil.java | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMenuUtil.java b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMenuUtil.java index d70eb3da38..79512a1008 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMenuUtil.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.redbook/src/com/raytheon/uf/edex/plugin/redbook/menu/RedbookMenuUtil.java @@ -54,6 +54,7 @@ import com.raytheon.uf.edex.plugin.redbook.ingest.xml.RedbookMenusXML; * Mar 07, 2014 2858 mpduff Initial creation * Mar 14, 2014 2855 mpduff Refactored common code. * Mar 19, 2014 2860 mpduff Implemented Redbook UpperAir. + * Apr 30, 2014 2860 mpduff Fixed instances of empty substitution tags. * * * @@ -168,15 +169,8 @@ public abstract class RedbookMenuUtil extends AbstractMenuUtil { commonBundleMenuContribution.id = menuEntry.getId(); commonBundleMenuContribution.text = menuEntry.getText(); - if (menuEntry.getMenuEntryList().size() > 0) { + if (!menuEntry.getMenuEntryList().isEmpty()) { List subList = new ArrayList(); - for (MenuEntry substitute : menuEntry.getMenuEntryList()) { - VariableSubstitution var = new VariableSubstitution(); - var.key = substitute.getKey(); - var.value = substitute.getValue(); - subList.add(var); - } - List dataUriList = new ArrayList(); for (MenuEntry me : menuEntry.getMenuEntryList()) { @@ -190,7 +184,6 @@ public abstract class RedbookMenuUtil extends AbstractMenuUtil { } else if (MenuEntryType.DataUri == me.getType()) { dataUriList.add(me.getDataUri()); } - } commonBundleMenuContribution.substitutions = subList From 56745c942edb40559204f10d820060b52802cdbf Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Wed, 30 Apr 2014 13:03:44 -0500 Subject: [PATCH 125/188] Issue #2854: Reorganize deltaScripts Former-commit-id: 469c2c597b80fd725f474e0d645656e4054fd69a --- deltaScripts/14.3.1/{ => DR2060}/dropGridDataURI.sh | 0 .../14.3.1/{ => DR2667}/renameLightningSourceInBundles.sh | 0 deltaScripts/14.3.1/{ => DR2667}/renameLightningSourceInDB.sh | 0 .../14.3.1/{ => DR2667}/renameLightningSourceInProcedures.sh | 0 deltaScripts/14.3.1/{ => DR2667}/utility/replaceAttributeInXML.py | 0 .../14.3.1/{ => DR2667}/utility/updateLightningNameInXML.sh | 0 deltaScripts/14.3.1/{ => DR2701}/removeLocalGroupsLocalization.sh | 0 deltaScripts/14.3.1/{ => DR2725}/moveDerivedParameters.sh | 0 deltaScripts/14.3.1/{ => DR2864}/subsetRelocator.sh | 0 deltaScripts/{ => archived}/11.9.0-1/db/create_index.sh | 0 deltaScripts/{ => archived}/11.9.0-1/db/remove_bufrua.sh | 0 deltaScripts/{ => archived}/11.9.0-1/db/update_gfehistory.sh | 0 deltaScripts/{ => archived}/11.9.0-1/db/update_stdtextproducts.sh | 0 .../{ => archived}/11.9.0-2/db/airmet_convsigmet_add_indices.sql | 0 deltaScripts/{ => archived}/11.9.0-3/db/create_sfcobs_index.sh | 0 deltaScripts/{ => archived}/11.9.0-3/db/drop_warning_tables.sh | 0 deltaScripts/{ => archived}/11.9.0-3/db/fog_update.sh | 0 deltaScripts/{ => archived}/11.9.0-4/db/gfe_update.sh | 0 deltaScripts/{ => archived}/11.9.0-4/edex/removeSampleId.sh | 0 deltaScripts/{ => archived}/11.9.0-5/db/removeGridData.sh | 0 deltaScripts/{ => archived}/11.9.0-6/db/removePurgeRules.sh | 0 deltaScripts/{ => archived}/11.9.0-6/edex/gfeRemove_vcmodule.sh | 0 .../{ => archived}/11.9.0-6/edex/removePurgeConfiguration.sh | 0 deltaScripts/{ => archived}/11.9.0-7/cleanGFESuiteLogs.sh | 0 deltaScripts/{ => archived}/11.9.0-7/db/updateGrib.sh | 0 deltaScripts/{ => archived}/11.9.0-7/db/updateSatellite.sh | 0 deltaScripts/{ => archived}/11.9.0-7/db/updateSatelliteGeo.sh | 0 deltaScripts/{ => archived}/11.9.0-7/db/update_afos_to_awips.sh | 0 .../{ => archived}/12.10.1/edex/UpdateMakeHazardConfig.py | 0 .../{ => archived}/12.11.1/edex/removeObeGribParamInfoFiles.py | 0 deltaScripts/{ => archived}/12.12.1/reformatPurgeRules.sh | 0 deltaScripts/{ => archived}/12.5.1/addgfelockindex.sh | 0 deltaScripts/{ => archived}/12.5.1/drop_gfe_tables.sh | 0 deltaScripts/{ => archived}/12.6.1/edex/removeMonitorAreaFiles.sh | 0 deltaScripts/{ => archived}/13.1.2/createEventsSchema.sql | 0 deltaScripts/{ => archived}/13.1.2/eventsSchemaDelta.sh | 0 .../{ => archived}/13.2.1/aggregateRecordGroupingLength.sh | 0 .../{ => archived}/13.2.1/convertAggregateRecordGroupToXml.sh | 0 .../{ => archived}/13.2.1/convertAggregateRecordGroupToXml.sql | 0 deltaScripts/{ => archived}/13.2.1/fixParameterUnits.sh | 0 deltaScripts/{ => archived}/13.2.1/fixParameterUnits.sql | 0 .../13.2.1/increaseAggregateRecordGroupingLength.sql | 0 deltaScripts/{ => archived}/13.3.1/addRouteToSubscriptionSlots.sh | 0 .../{ => archived}/13.3.1/addRouteToSubscriptionSlots.sql | 0 deltaScripts/{ => archived}/13.3.1/convertPluginNameToDataType.sh | 0 .../{ => archived}/13.3.1/convertPluginNameToDataType.sql | 0 deltaScripts/{ => archived}/13.3.1/lightsourcecolumn.sql | 0 deltaScripts/{ => archived}/13.3.1/reftimeIndexUpdate.sh | 0 deltaScripts/{ => archived}/13.3.1/removeDataURIIndex.sh | 0 deltaScripts/{ => archived}/13.4.1/alterWarningTables.sql | 0 deltaScripts/{ => archived}/13.4.1/createNewGfeTables.sql | 0 .../{ => archived}/13.4.1/createPluginDataObjectSequences.sh | 0 deltaScripts/{ => archived}/13.4.1/createScanIndexes.sh | 0 deltaScripts/{ => archived}/13.4.1/determineRefTimeDirectory.py | 0 deltaScripts/{ => archived}/13.4.1/modelsoundingFileName.py | 0 deltaScripts/{ => archived}/13.4.1/normalizeGfe.sh | 0 deltaScripts/{ => archived}/13.4.1/parseParmIds.py | 0 deltaScripts/{ => archived}/13.4.1/parseUgcZones.py | 0 deltaScripts/{ => archived}/13.4.1/removeHdffileidColumn.sh | 0 deltaScripts/{ => archived}/13.4.1/removeOldStatAggregates.sh | 0 deltaScripts/{ => archived}/13.4.1/resetNtransTable.sh | 0 deltaScripts/{ => archived}/13.4.1/sequences.txt | 0 .../{ => archived}/13.4.1/updateGfeConstraintsAndIndexes.sql | 0 deltaScripts/{ => archived}/13.4.1/updateModelSoundingPaths.sh | 0 deltaScripts/{ => archived}/13.4.1/updateWarningTables.sh | 0 deltaScripts/{ => archived}/13.4.1/upgradeGribLocalization.sh | 0 .../{ => archived}/13.5.1/changeDataTypeEnumToUppercase.sh | 0 .../{ => archived}/13.5.1/changeDataTypeEnumToUppercase.sql | 0 .../{ => archived}/13.5.1/convertSubscriptionSitesToCollection.sh | 0 .../13.5.1/convertSubscriptionSitesToCollection.sql | 0 deltaScripts/{ => archived}/13.5.1/dropDataURI.sh | 0 deltaScripts/{ => archived}/13.5.1/ebxmlSchemaChange.sh | 0 deltaScripts/{ => archived}/13.5.1/ebxmlSchemaDefinition.sql | 0 deltaScripts/{ => archived}/13.5.1/getSubscriptionSite.sql | 0 deltaScripts/{ => archived}/13.5.1/removeDeliveryOptions.sql | 0 deltaScripts/{ => archived}/13.5.1/removeDeliveryOptionsDb.sh | 0 .../{ => archived}/13.5.1/removeDeliveryOptionsLocalization.sh | 0 deltaScripts/{ => archived}/13.5.1/removeRegistryBackupTags.sh | 0 .../{ => archived}/13.5.1/renameSubscriptionToSiteSubscription.sh | 0 .../13.5.1/renameSubscriptionToSiteSubscription.sql | 0 deltaScripts/{ => archived}/13.5.1/resetNtransTable.sh | 0 deltaScripts/{ => archived}/13.5.1/tableNameUpdate.sql | 0 deltaScripts/{ => archived}/13.5.1/updateProviderType.xsl | 0 deltaScripts/{ => archived}/13.5.1/updateProviderTypeDb.sh | 0 .../{ => archived}/13.5.1/updateProviderTypeLocalization.sh | 0 deltaScripts/{ => archived}/13.5.1/update_svcbu_props.sh | 0 deltaScripts/{ => archived}/13.5.2/addBufrmosDataURI.sh | 0 deltaScripts/{ => archived}/future/alterTextProductsTables.sh | 0 deltaScripts/{ => archived}/future/combineH5Files.py | 0 deltaScripts/{ => archived}/future/relocateTextUtilities.py | 0 deltaScripts/{ => archived}/future/removeHdfFileId.sh | 0 deltaScripts/{ => archived}/unified_grid/README.txt | 0 deltaScripts/{ => archived}/unified_grid/convert_grib_data.py | 0 deltaScripts/{ => archived}/unified_grid/copy_grib_purge_rules.sh | 0 deltaScripts/{ => archived}/unified_grid/create_grid_tables.sh | 0 .../{ => archived}/unified_grid/register_grid_coverage.sh | 0 deltaScripts/{ => archived}/unified_grid/update_D2D_bundles.sh | 0 deltaScripts/{ => archived}/unified_grid/update_D2D_procedures.sh | 0 deltaScripts/{ => archived}/unified_grid/update_FFMP_Source.sh | 0 deltaScripts/{ => archived}/unified_grid/update_saved_display.sh | 0 .../{ => archived}/unified_grid_rollback/convert_grib_data.py | 0 .../{ => archived}/unified_grid_rollback/copy_grib_purge_rules.sh | 0 .../{ => archived}/unified_grid_rollback/create_grid_tables.sh | 0 .../unified_grid_rollback/register_grid_coverage.sh | 0 .../{ => archived}/unified_grid_rollback/update_D2D_bundles.sh | 0 .../{ => archived}/unified_grid_rollback/update_D2D_procedures.sh | 0 .../{ => archived}/unified_grid_rollback/update_FFMP_Source.sh | 0 .../{ => archived}/unified_grid_rollback/update_saved_display.sh | 0 108 files changed, 0 insertions(+), 0 deletions(-) rename deltaScripts/14.3.1/{ => DR2060}/dropGridDataURI.sh (100%) rename deltaScripts/14.3.1/{ => DR2667}/renameLightningSourceInBundles.sh (100%) rename deltaScripts/14.3.1/{ => DR2667}/renameLightningSourceInDB.sh (100%) rename deltaScripts/14.3.1/{ => DR2667}/renameLightningSourceInProcedures.sh (100%) rename deltaScripts/14.3.1/{ => DR2667}/utility/replaceAttributeInXML.py (100%) rename deltaScripts/14.3.1/{ => DR2667}/utility/updateLightningNameInXML.sh (100%) rename deltaScripts/14.3.1/{ => DR2701}/removeLocalGroupsLocalization.sh (100%) rename deltaScripts/14.3.1/{ => DR2725}/moveDerivedParameters.sh (100%) rename deltaScripts/14.3.1/{ => DR2864}/subsetRelocator.sh (100%) rename deltaScripts/{ => archived}/11.9.0-1/db/create_index.sh (100%) rename deltaScripts/{ => archived}/11.9.0-1/db/remove_bufrua.sh (100%) rename deltaScripts/{ => archived}/11.9.0-1/db/update_gfehistory.sh (100%) rename deltaScripts/{ => archived}/11.9.0-1/db/update_stdtextproducts.sh (100%) rename deltaScripts/{ => archived}/11.9.0-2/db/airmet_convsigmet_add_indices.sql (100%) rename deltaScripts/{ => archived}/11.9.0-3/db/create_sfcobs_index.sh (100%) rename deltaScripts/{ => archived}/11.9.0-3/db/drop_warning_tables.sh (100%) rename deltaScripts/{ => archived}/11.9.0-3/db/fog_update.sh (100%) rename deltaScripts/{ => archived}/11.9.0-4/db/gfe_update.sh (100%) rename deltaScripts/{ => archived}/11.9.0-4/edex/removeSampleId.sh (100%) rename deltaScripts/{ => archived}/11.9.0-5/db/removeGridData.sh (100%) rename deltaScripts/{ => archived}/11.9.0-6/db/removePurgeRules.sh (100%) rename deltaScripts/{ => archived}/11.9.0-6/edex/gfeRemove_vcmodule.sh (100%) rename deltaScripts/{ => archived}/11.9.0-6/edex/removePurgeConfiguration.sh (100%) rename deltaScripts/{ => archived}/11.9.0-7/cleanGFESuiteLogs.sh (100%) rename deltaScripts/{ => archived}/11.9.0-7/db/updateGrib.sh (100%) rename deltaScripts/{ => archived}/11.9.0-7/db/updateSatellite.sh (100%) rename deltaScripts/{ => archived}/11.9.0-7/db/updateSatelliteGeo.sh (100%) rename deltaScripts/{ => archived}/11.9.0-7/db/update_afos_to_awips.sh (100%) rename deltaScripts/{ => archived}/12.10.1/edex/UpdateMakeHazardConfig.py (100%) rename deltaScripts/{ => archived}/12.11.1/edex/removeObeGribParamInfoFiles.py (100%) rename deltaScripts/{ => archived}/12.12.1/reformatPurgeRules.sh (100%) rename deltaScripts/{ => archived}/12.5.1/addgfelockindex.sh (100%) rename deltaScripts/{ => archived}/12.5.1/drop_gfe_tables.sh (100%) rename deltaScripts/{ => archived}/12.6.1/edex/removeMonitorAreaFiles.sh (100%) rename deltaScripts/{ => archived}/13.1.2/createEventsSchema.sql (100%) rename deltaScripts/{ => archived}/13.1.2/eventsSchemaDelta.sh (100%) rename deltaScripts/{ => archived}/13.2.1/aggregateRecordGroupingLength.sh (100%) rename deltaScripts/{ => archived}/13.2.1/convertAggregateRecordGroupToXml.sh (100%) rename deltaScripts/{ => archived}/13.2.1/convertAggregateRecordGroupToXml.sql (100%) rename deltaScripts/{ => archived}/13.2.1/fixParameterUnits.sh (100%) rename deltaScripts/{ => archived}/13.2.1/fixParameterUnits.sql (100%) rename deltaScripts/{ => archived}/13.2.1/increaseAggregateRecordGroupingLength.sql (100%) rename deltaScripts/{ => archived}/13.3.1/addRouteToSubscriptionSlots.sh (100%) rename deltaScripts/{ => archived}/13.3.1/addRouteToSubscriptionSlots.sql (100%) rename deltaScripts/{ => archived}/13.3.1/convertPluginNameToDataType.sh (100%) rename deltaScripts/{ => archived}/13.3.1/convertPluginNameToDataType.sql (100%) rename deltaScripts/{ => archived}/13.3.1/lightsourcecolumn.sql (100%) rename deltaScripts/{ => archived}/13.3.1/reftimeIndexUpdate.sh (100%) rename deltaScripts/{ => archived}/13.3.1/removeDataURIIndex.sh (100%) rename deltaScripts/{ => archived}/13.4.1/alterWarningTables.sql (100%) rename deltaScripts/{ => archived}/13.4.1/createNewGfeTables.sql (100%) rename deltaScripts/{ => archived}/13.4.1/createPluginDataObjectSequences.sh (100%) rename deltaScripts/{ => archived}/13.4.1/createScanIndexes.sh (100%) rename deltaScripts/{ => archived}/13.4.1/determineRefTimeDirectory.py (100%) rename deltaScripts/{ => archived}/13.4.1/modelsoundingFileName.py (100%) rename deltaScripts/{ => archived}/13.4.1/normalizeGfe.sh (100%) rename deltaScripts/{ => archived}/13.4.1/parseParmIds.py (100%) rename deltaScripts/{ => archived}/13.4.1/parseUgcZones.py (100%) rename deltaScripts/{ => archived}/13.4.1/removeHdffileidColumn.sh (100%) rename deltaScripts/{ => archived}/13.4.1/removeOldStatAggregates.sh (100%) rename deltaScripts/{ => archived}/13.4.1/resetNtransTable.sh (100%) rename deltaScripts/{ => archived}/13.4.1/sequences.txt (100%) rename deltaScripts/{ => archived}/13.4.1/updateGfeConstraintsAndIndexes.sql (100%) rename deltaScripts/{ => archived}/13.4.1/updateModelSoundingPaths.sh (100%) rename deltaScripts/{ => archived}/13.4.1/updateWarningTables.sh (100%) rename deltaScripts/{ => archived}/13.4.1/upgradeGribLocalization.sh (100%) rename deltaScripts/{ => archived}/13.5.1/changeDataTypeEnumToUppercase.sh (100%) rename deltaScripts/{ => archived}/13.5.1/changeDataTypeEnumToUppercase.sql (100%) rename deltaScripts/{ => archived}/13.5.1/convertSubscriptionSitesToCollection.sh (100%) rename deltaScripts/{ => archived}/13.5.1/convertSubscriptionSitesToCollection.sql (100%) rename deltaScripts/{ => archived}/13.5.1/dropDataURI.sh (100%) rename deltaScripts/{ => archived}/13.5.1/ebxmlSchemaChange.sh (100%) rename deltaScripts/{ => archived}/13.5.1/ebxmlSchemaDefinition.sql (100%) rename deltaScripts/{ => archived}/13.5.1/getSubscriptionSite.sql (100%) rename deltaScripts/{ => archived}/13.5.1/removeDeliveryOptions.sql (100%) rename deltaScripts/{ => archived}/13.5.1/removeDeliveryOptionsDb.sh (100%) rename deltaScripts/{ => archived}/13.5.1/removeDeliveryOptionsLocalization.sh (100%) rename deltaScripts/{ => archived}/13.5.1/removeRegistryBackupTags.sh (100%) rename deltaScripts/{ => archived}/13.5.1/renameSubscriptionToSiteSubscription.sh (100%) rename deltaScripts/{ => archived}/13.5.1/renameSubscriptionToSiteSubscription.sql (100%) rename deltaScripts/{ => archived}/13.5.1/resetNtransTable.sh (100%) rename deltaScripts/{ => archived}/13.5.1/tableNameUpdate.sql (100%) rename deltaScripts/{ => archived}/13.5.1/updateProviderType.xsl (100%) rename deltaScripts/{ => archived}/13.5.1/updateProviderTypeDb.sh (100%) rename deltaScripts/{ => archived}/13.5.1/updateProviderTypeLocalization.sh (100%) rename deltaScripts/{ => archived}/13.5.1/update_svcbu_props.sh (100%) rename deltaScripts/{ => archived}/13.5.2/addBufrmosDataURI.sh (100%) rename deltaScripts/{ => archived}/future/alterTextProductsTables.sh (100%) rename deltaScripts/{ => archived}/future/combineH5Files.py (100%) rename deltaScripts/{ => archived}/future/relocateTextUtilities.py (100%) rename deltaScripts/{ => archived}/future/removeHdfFileId.sh (100%) rename deltaScripts/{ => archived}/unified_grid/README.txt (100%) rename deltaScripts/{ => archived}/unified_grid/convert_grib_data.py (100%) rename deltaScripts/{ => archived}/unified_grid/copy_grib_purge_rules.sh (100%) rename deltaScripts/{ => archived}/unified_grid/create_grid_tables.sh (100%) rename deltaScripts/{ => archived}/unified_grid/register_grid_coverage.sh (100%) rename deltaScripts/{ => archived}/unified_grid/update_D2D_bundles.sh (100%) rename deltaScripts/{ => archived}/unified_grid/update_D2D_procedures.sh (100%) rename deltaScripts/{ => archived}/unified_grid/update_FFMP_Source.sh (100%) rename deltaScripts/{ => archived}/unified_grid/update_saved_display.sh (100%) rename deltaScripts/{ => archived}/unified_grid_rollback/convert_grib_data.py (100%) rename deltaScripts/{ => archived}/unified_grid_rollback/copy_grib_purge_rules.sh (100%) rename deltaScripts/{ => archived}/unified_grid_rollback/create_grid_tables.sh (100%) rename deltaScripts/{ => archived}/unified_grid_rollback/register_grid_coverage.sh (100%) rename deltaScripts/{ => archived}/unified_grid_rollback/update_D2D_bundles.sh (100%) rename deltaScripts/{ => archived}/unified_grid_rollback/update_D2D_procedures.sh (100%) rename deltaScripts/{ => archived}/unified_grid_rollback/update_FFMP_Source.sh (100%) rename deltaScripts/{ => archived}/unified_grid_rollback/update_saved_display.sh (100%) diff --git a/deltaScripts/14.3.1/dropGridDataURI.sh b/deltaScripts/14.3.1/DR2060/dropGridDataURI.sh similarity index 100% rename from deltaScripts/14.3.1/dropGridDataURI.sh rename to deltaScripts/14.3.1/DR2060/dropGridDataURI.sh diff --git a/deltaScripts/14.3.1/renameLightningSourceInBundles.sh b/deltaScripts/14.3.1/DR2667/renameLightningSourceInBundles.sh similarity index 100% rename from deltaScripts/14.3.1/renameLightningSourceInBundles.sh rename to deltaScripts/14.3.1/DR2667/renameLightningSourceInBundles.sh diff --git a/deltaScripts/14.3.1/renameLightningSourceInDB.sh b/deltaScripts/14.3.1/DR2667/renameLightningSourceInDB.sh similarity index 100% rename from deltaScripts/14.3.1/renameLightningSourceInDB.sh rename to deltaScripts/14.3.1/DR2667/renameLightningSourceInDB.sh diff --git a/deltaScripts/14.3.1/renameLightningSourceInProcedures.sh b/deltaScripts/14.3.1/DR2667/renameLightningSourceInProcedures.sh similarity index 100% rename from deltaScripts/14.3.1/renameLightningSourceInProcedures.sh rename to deltaScripts/14.3.1/DR2667/renameLightningSourceInProcedures.sh diff --git a/deltaScripts/14.3.1/utility/replaceAttributeInXML.py b/deltaScripts/14.3.1/DR2667/utility/replaceAttributeInXML.py similarity index 100% rename from deltaScripts/14.3.1/utility/replaceAttributeInXML.py rename to deltaScripts/14.3.1/DR2667/utility/replaceAttributeInXML.py diff --git a/deltaScripts/14.3.1/utility/updateLightningNameInXML.sh b/deltaScripts/14.3.1/DR2667/utility/updateLightningNameInXML.sh similarity index 100% rename from deltaScripts/14.3.1/utility/updateLightningNameInXML.sh rename to deltaScripts/14.3.1/DR2667/utility/updateLightningNameInXML.sh diff --git a/deltaScripts/14.3.1/removeLocalGroupsLocalization.sh b/deltaScripts/14.3.1/DR2701/removeLocalGroupsLocalization.sh similarity index 100% rename from deltaScripts/14.3.1/removeLocalGroupsLocalization.sh rename to deltaScripts/14.3.1/DR2701/removeLocalGroupsLocalization.sh diff --git a/deltaScripts/14.3.1/moveDerivedParameters.sh b/deltaScripts/14.3.1/DR2725/moveDerivedParameters.sh similarity index 100% rename from deltaScripts/14.3.1/moveDerivedParameters.sh rename to deltaScripts/14.3.1/DR2725/moveDerivedParameters.sh diff --git a/deltaScripts/14.3.1/subsetRelocator.sh b/deltaScripts/14.3.1/DR2864/subsetRelocator.sh similarity index 100% rename from deltaScripts/14.3.1/subsetRelocator.sh rename to deltaScripts/14.3.1/DR2864/subsetRelocator.sh diff --git a/deltaScripts/11.9.0-1/db/create_index.sh b/deltaScripts/archived/11.9.0-1/db/create_index.sh similarity index 100% rename from deltaScripts/11.9.0-1/db/create_index.sh rename to deltaScripts/archived/11.9.0-1/db/create_index.sh diff --git a/deltaScripts/11.9.0-1/db/remove_bufrua.sh b/deltaScripts/archived/11.9.0-1/db/remove_bufrua.sh similarity index 100% rename from deltaScripts/11.9.0-1/db/remove_bufrua.sh rename to deltaScripts/archived/11.9.0-1/db/remove_bufrua.sh diff --git a/deltaScripts/11.9.0-1/db/update_gfehistory.sh b/deltaScripts/archived/11.9.0-1/db/update_gfehistory.sh similarity index 100% rename from deltaScripts/11.9.0-1/db/update_gfehistory.sh rename to deltaScripts/archived/11.9.0-1/db/update_gfehistory.sh diff --git a/deltaScripts/11.9.0-1/db/update_stdtextproducts.sh b/deltaScripts/archived/11.9.0-1/db/update_stdtextproducts.sh similarity index 100% rename from deltaScripts/11.9.0-1/db/update_stdtextproducts.sh rename to deltaScripts/archived/11.9.0-1/db/update_stdtextproducts.sh diff --git a/deltaScripts/11.9.0-2/db/airmet_convsigmet_add_indices.sql b/deltaScripts/archived/11.9.0-2/db/airmet_convsigmet_add_indices.sql similarity index 100% rename from deltaScripts/11.9.0-2/db/airmet_convsigmet_add_indices.sql rename to deltaScripts/archived/11.9.0-2/db/airmet_convsigmet_add_indices.sql diff --git a/deltaScripts/11.9.0-3/db/create_sfcobs_index.sh b/deltaScripts/archived/11.9.0-3/db/create_sfcobs_index.sh similarity index 100% rename from deltaScripts/11.9.0-3/db/create_sfcobs_index.sh rename to deltaScripts/archived/11.9.0-3/db/create_sfcobs_index.sh diff --git a/deltaScripts/11.9.0-3/db/drop_warning_tables.sh b/deltaScripts/archived/11.9.0-3/db/drop_warning_tables.sh similarity index 100% rename from deltaScripts/11.9.0-3/db/drop_warning_tables.sh rename to deltaScripts/archived/11.9.0-3/db/drop_warning_tables.sh diff --git a/deltaScripts/11.9.0-3/db/fog_update.sh b/deltaScripts/archived/11.9.0-3/db/fog_update.sh similarity index 100% rename from deltaScripts/11.9.0-3/db/fog_update.sh rename to deltaScripts/archived/11.9.0-3/db/fog_update.sh diff --git a/deltaScripts/11.9.0-4/db/gfe_update.sh b/deltaScripts/archived/11.9.0-4/db/gfe_update.sh similarity index 100% rename from deltaScripts/11.9.0-4/db/gfe_update.sh rename to deltaScripts/archived/11.9.0-4/db/gfe_update.sh diff --git a/deltaScripts/11.9.0-4/edex/removeSampleId.sh b/deltaScripts/archived/11.9.0-4/edex/removeSampleId.sh similarity index 100% rename from deltaScripts/11.9.0-4/edex/removeSampleId.sh rename to deltaScripts/archived/11.9.0-4/edex/removeSampleId.sh diff --git a/deltaScripts/11.9.0-5/db/removeGridData.sh b/deltaScripts/archived/11.9.0-5/db/removeGridData.sh similarity index 100% rename from deltaScripts/11.9.0-5/db/removeGridData.sh rename to deltaScripts/archived/11.9.0-5/db/removeGridData.sh diff --git a/deltaScripts/11.9.0-6/db/removePurgeRules.sh b/deltaScripts/archived/11.9.0-6/db/removePurgeRules.sh similarity index 100% rename from deltaScripts/11.9.0-6/db/removePurgeRules.sh rename to deltaScripts/archived/11.9.0-6/db/removePurgeRules.sh diff --git a/deltaScripts/11.9.0-6/edex/gfeRemove_vcmodule.sh b/deltaScripts/archived/11.9.0-6/edex/gfeRemove_vcmodule.sh similarity index 100% rename from deltaScripts/11.9.0-6/edex/gfeRemove_vcmodule.sh rename to deltaScripts/archived/11.9.0-6/edex/gfeRemove_vcmodule.sh diff --git a/deltaScripts/11.9.0-6/edex/removePurgeConfiguration.sh b/deltaScripts/archived/11.9.0-6/edex/removePurgeConfiguration.sh similarity index 100% rename from deltaScripts/11.9.0-6/edex/removePurgeConfiguration.sh rename to deltaScripts/archived/11.9.0-6/edex/removePurgeConfiguration.sh diff --git a/deltaScripts/11.9.0-7/cleanGFESuiteLogs.sh b/deltaScripts/archived/11.9.0-7/cleanGFESuiteLogs.sh similarity index 100% rename from deltaScripts/11.9.0-7/cleanGFESuiteLogs.sh rename to deltaScripts/archived/11.9.0-7/cleanGFESuiteLogs.sh diff --git a/deltaScripts/11.9.0-7/db/updateGrib.sh b/deltaScripts/archived/11.9.0-7/db/updateGrib.sh similarity index 100% rename from deltaScripts/11.9.0-7/db/updateGrib.sh rename to deltaScripts/archived/11.9.0-7/db/updateGrib.sh diff --git a/deltaScripts/11.9.0-7/db/updateSatellite.sh b/deltaScripts/archived/11.9.0-7/db/updateSatellite.sh similarity index 100% rename from deltaScripts/11.9.0-7/db/updateSatellite.sh rename to deltaScripts/archived/11.9.0-7/db/updateSatellite.sh diff --git a/deltaScripts/11.9.0-7/db/updateSatelliteGeo.sh b/deltaScripts/archived/11.9.0-7/db/updateSatelliteGeo.sh similarity index 100% rename from deltaScripts/11.9.0-7/db/updateSatelliteGeo.sh rename to deltaScripts/archived/11.9.0-7/db/updateSatelliteGeo.sh diff --git a/deltaScripts/11.9.0-7/db/update_afos_to_awips.sh b/deltaScripts/archived/11.9.0-7/db/update_afos_to_awips.sh similarity index 100% rename from deltaScripts/11.9.0-7/db/update_afos_to_awips.sh rename to deltaScripts/archived/11.9.0-7/db/update_afos_to_awips.sh diff --git a/deltaScripts/12.10.1/edex/UpdateMakeHazardConfig.py b/deltaScripts/archived/12.10.1/edex/UpdateMakeHazardConfig.py similarity index 100% rename from deltaScripts/12.10.1/edex/UpdateMakeHazardConfig.py rename to deltaScripts/archived/12.10.1/edex/UpdateMakeHazardConfig.py diff --git a/deltaScripts/12.11.1/edex/removeObeGribParamInfoFiles.py b/deltaScripts/archived/12.11.1/edex/removeObeGribParamInfoFiles.py similarity index 100% rename from deltaScripts/12.11.1/edex/removeObeGribParamInfoFiles.py rename to deltaScripts/archived/12.11.1/edex/removeObeGribParamInfoFiles.py diff --git a/deltaScripts/12.12.1/reformatPurgeRules.sh b/deltaScripts/archived/12.12.1/reformatPurgeRules.sh similarity index 100% rename from deltaScripts/12.12.1/reformatPurgeRules.sh rename to deltaScripts/archived/12.12.1/reformatPurgeRules.sh diff --git a/deltaScripts/12.5.1/addgfelockindex.sh b/deltaScripts/archived/12.5.1/addgfelockindex.sh similarity index 100% rename from deltaScripts/12.5.1/addgfelockindex.sh rename to deltaScripts/archived/12.5.1/addgfelockindex.sh diff --git a/deltaScripts/12.5.1/drop_gfe_tables.sh b/deltaScripts/archived/12.5.1/drop_gfe_tables.sh similarity index 100% rename from deltaScripts/12.5.1/drop_gfe_tables.sh rename to deltaScripts/archived/12.5.1/drop_gfe_tables.sh diff --git a/deltaScripts/12.6.1/edex/removeMonitorAreaFiles.sh b/deltaScripts/archived/12.6.1/edex/removeMonitorAreaFiles.sh similarity index 100% rename from deltaScripts/12.6.1/edex/removeMonitorAreaFiles.sh rename to deltaScripts/archived/12.6.1/edex/removeMonitorAreaFiles.sh diff --git a/deltaScripts/13.1.2/createEventsSchema.sql b/deltaScripts/archived/13.1.2/createEventsSchema.sql similarity index 100% rename from deltaScripts/13.1.2/createEventsSchema.sql rename to deltaScripts/archived/13.1.2/createEventsSchema.sql diff --git a/deltaScripts/13.1.2/eventsSchemaDelta.sh b/deltaScripts/archived/13.1.2/eventsSchemaDelta.sh similarity index 100% rename from deltaScripts/13.1.2/eventsSchemaDelta.sh rename to deltaScripts/archived/13.1.2/eventsSchemaDelta.sh diff --git a/deltaScripts/13.2.1/aggregateRecordGroupingLength.sh b/deltaScripts/archived/13.2.1/aggregateRecordGroupingLength.sh similarity index 100% rename from deltaScripts/13.2.1/aggregateRecordGroupingLength.sh rename to deltaScripts/archived/13.2.1/aggregateRecordGroupingLength.sh diff --git a/deltaScripts/13.2.1/convertAggregateRecordGroupToXml.sh b/deltaScripts/archived/13.2.1/convertAggregateRecordGroupToXml.sh similarity index 100% rename from deltaScripts/13.2.1/convertAggregateRecordGroupToXml.sh rename to deltaScripts/archived/13.2.1/convertAggregateRecordGroupToXml.sh diff --git a/deltaScripts/13.2.1/convertAggregateRecordGroupToXml.sql b/deltaScripts/archived/13.2.1/convertAggregateRecordGroupToXml.sql similarity index 100% rename from deltaScripts/13.2.1/convertAggregateRecordGroupToXml.sql rename to deltaScripts/archived/13.2.1/convertAggregateRecordGroupToXml.sql diff --git a/deltaScripts/13.2.1/fixParameterUnits.sh b/deltaScripts/archived/13.2.1/fixParameterUnits.sh similarity index 100% rename from deltaScripts/13.2.1/fixParameterUnits.sh rename to deltaScripts/archived/13.2.1/fixParameterUnits.sh diff --git a/deltaScripts/13.2.1/fixParameterUnits.sql b/deltaScripts/archived/13.2.1/fixParameterUnits.sql similarity index 100% rename from deltaScripts/13.2.1/fixParameterUnits.sql rename to deltaScripts/archived/13.2.1/fixParameterUnits.sql diff --git a/deltaScripts/13.2.1/increaseAggregateRecordGroupingLength.sql b/deltaScripts/archived/13.2.1/increaseAggregateRecordGroupingLength.sql similarity index 100% rename from deltaScripts/13.2.1/increaseAggregateRecordGroupingLength.sql rename to deltaScripts/archived/13.2.1/increaseAggregateRecordGroupingLength.sql diff --git a/deltaScripts/13.3.1/addRouteToSubscriptionSlots.sh b/deltaScripts/archived/13.3.1/addRouteToSubscriptionSlots.sh similarity index 100% rename from deltaScripts/13.3.1/addRouteToSubscriptionSlots.sh rename to deltaScripts/archived/13.3.1/addRouteToSubscriptionSlots.sh diff --git a/deltaScripts/13.3.1/addRouteToSubscriptionSlots.sql b/deltaScripts/archived/13.3.1/addRouteToSubscriptionSlots.sql similarity index 100% rename from deltaScripts/13.3.1/addRouteToSubscriptionSlots.sql rename to deltaScripts/archived/13.3.1/addRouteToSubscriptionSlots.sql diff --git a/deltaScripts/13.3.1/convertPluginNameToDataType.sh b/deltaScripts/archived/13.3.1/convertPluginNameToDataType.sh similarity index 100% rename from deltaScripts/13.3.1/convertPluginNameToDataType.sh rename to deltaScripts/archived/13.3.1/convertPluginNameToDataType.sh diff --git a/deltaScripts/13.3.1/convertPluginNameToDataType.sql b/deltaScripts/archived/13.3.1/convertPluginNameToDataType.sql similarity index 100% rename from deltaScripts/13.3.1/convertPluginNameToDataType.sql rename to deltaScripts/archived/13.3.1/convertPluginNameToDataType.sql diff --git a/deltaScripts/13.3.1/lightsourcecolumn.sql b/deltaScripts/archived/13.3.1/lightsourcecolumn.sql similarity index 100% rename from deltaScripts/13.3.1/lightsourcecolumn.sql rename to deltaScripts/archived/13.3.1/lightsourcecolumn.sql diff --git a/deltaScripts/13.3.1/reftimeIndexUpdate.sh b/deltaScripts/archived/13.3.1/reftimeIndexUpdate.sh similarity index 100% rename from deltaScripts/13.3.1/reftimeIndexUpdate.sh rename to deltaScripts/archived/13.3.1/reftimeIndexUpdate.sh diff --git a/deltaScripts/13.3.1/removeDataURIIndex.sh b/deltaScripts/archived/13.3.1/removeDataURIIndex.sh similarity index 100% rename from deltaScripts/13.3.1/removeDataURIIndex.sh rename to deltaScripts/archived/13.3.1/removeDataURIIndex.sh diff --git a/deltaScripts/13.4.1/alterWarningTables.sql b/deltaScripts/archived/13.4.1/alterWarningTables.sql similarity index 100% rename from deltaScripts/13.4.1/alterWarningTables.sql rename to deltaScripts/archived/13.4.1/alterWarningTables.sql diff --git a/deltaScripts/13.4.1/createNewGfeTables.sql b/deltaScripts/archived/13.4.1/createNewGfeTables.sql similarity index 100% rename from deltaScripts/13.4.1/createNewGfeTables.sql rename to deltaScripts/archived/13.4.1/createNewGfeTables.sql diff --git a/deltaScripts/13.4.1/createPluginDataObjectSequences.sh b/deltaScripts/archived/13.4.1/createPluginDataObjectSequences.sh similarity index 100% rename from deltaScripts/13.4.1/createPluginDataObjectSequences.sh rename to deltaScripts/archived/13.4.1/createPluginDataObjectSequences.sh diff --git a/deltaScripts/13.4.1/createScanIndexes.sh b/deltaScripts/archived/13.4.1/createScanIndexes.sh similarity index 100% rename from deltaScripts/13.4.1/createScanIndexes.sh rename to deltaScripts/archived/13.4.1/createScanIndexes.sh diff --git a/deltaScripts/13.4.1/determineRefTimeDirectory.py b/deltaScripts/archived/13.4.1/determineRefTimeDirectory.py similarity index 100% rename from deltaScripts/13.4.1/determineRefTimeDirectory.py rename to deltaScripts/archived/13.4.1/determineRefTimeDirectory.py diff --git a/deltaScripts/13.4.1/modelsoundingFileName.py b/deltaScripts/archived/13.4.1/modelsoundingFileName.py similarity index 100% rename from deltaScripts/13.4.1/modelsoundingFileName.py rename to deltaScripts/archived/13.4.1/modelsoundingFileName.py diff --git a/deltaScripts/13.4.1/normalizeGfe.sh b/deltaScripts/archived/13.4.1/normalizeGfe.sh similarity index 100% rename from deltaScripts/13.4.1/normalizeGfe.sh rename to deltaScripts/archived/13.4.1/normalizeGfe.sh diff --git a/deltaScripts/13.4.1/parseParmIds.py b/deltaScripts/archived/13.4.1/parseParmIds.py similarity index 100% rename from deltaScripts/13.4.1/parseParmIds.py rename to deltaScripts/archived/13.4.1/parseParmIds.py diff --git a/deltaScripts/13.4.1/parseUgcZones.py b/deltaScripts/archived/13.4.1/parseUgcZones.py similarity index 100% rename from deltaScripts/13.4.1/parseUgcZones.py rename to deltaScripts/archived/13.4.1/parseUgcZones.py diff --git a/deltaScripts/13.4.1/removeHdffileidColumn.sh b/deltaScripts/archived/13.4.1/removeHdffileidColumn.sh similarity index 100% rename from deltaScripts/13.4.1/removeHdffileidColumn.sh rename to deltaScripts/archived/13.4.1/removeHdffileidColumn.sh diff --git a/deltaScripts/13.4.1/removeOldStatAggregates.sh b/deltaScripts/archived/13.4.1/removeOldStatAggregates.sh similarity index 100% rename from deltaScripts/13.4.1/removeOldStatAggregates.sh rename to deltaScripts/archived/13.4.1/removeOldStatAggregates.sh diff --git a/deltaScripts/13.4.1/resetNtransTable.sh b/deltaScripts/archived/13.4.1/resetNtransTable.sh similarity index 100% rename from deltaScripts/13.4.1/resetNtransTable.sh rename to deltaScripts/archived/13.4.1/resetNtransTable.sh diff --git a/deltaScripts/13.4.1/sequences.txt b/deltaScripts/archived/13.4.1/sequences.txt similarity index 100% rename from deltaScripts/13.4.1/sequences.txt rename to deltaScripts/archived/13.4.1/sequences.txt diff --git a/deltaScripts/13.4.1/updateGfeConstraintsAndIndexes.sql b/deltaScripts/archived/13.4.1/updateGfeConstraintsAndIndexes.sql similarity index 100% rename from deltaScripts/13.4.1/updateGfeConstraintsAndIndexes.sql rename to deltaScripts/archived/13.4.1/updateGfeConstraintsAndIndexes.sql diff --git a/deltaScripts/13.4.1/updateModelSoundingPaths.sh b/deltaScripts/archived/13.4.1/updateModelSoundingPaths.sh similarity index 100% rename from deltaScripts/13.4.1/updateModelSoundingPaths.sh rename to deltaScripts/archived/13.4.1/updateModelSoundingPaths.sh diff --git a/deltaScripts/13.4.1/updateWarningTables.sh b/deltaScripts/archived/13.4.1/updateWarningTables.sh similarity index 100% rename from deltaScripts/13.4.1/updateWarningTables.sh rename to deltaScripts/archived/13.4.1/updateWarningTables.sh diff --git a/deltaScripts/13.4.1/upgradeGribLocalization.sh b/deltaScripts/archived/13.4.1/upgradeGribLocalization.sh similarity index 100% rename from deltaScripts/13.4.1/upgradeGribLocalization.sh rename to deltaScripts/archived/13.4.1/upgradeGribLocalization.sh diff --git a/deltaScripts/13.5.1/changeDataTypeEnumToUppercase.sh b/deltaScripts/archived/13.5.1/changeDataTypeEnumToUppercase.sh similarity index 100% rename from deltaScripts/13.5.1/changeDataTypeEnumToUppercase.sh rename to deltaScripts/archived/13.5.1/changeDataTypeEnumToUppercase.sh diff --git a/deltaScripts/13.5.1/changeDataTypeEnumToUppercase.sql b/deltaScripts/archived/13.5.1/changeDataTypeEnumToUppercase.sql similarity index 100% rename from deltaScripts/13.5.1/changeDataTypeEnumToUppercase.sql rename to deltaScripts/archived/13.5.1/changeDataTypeEnumToUppercase.sql diff --git a/deltaScripts/13.5.1/convertSubscriptionSitesToCollection.sh b/deltaScripts/archived/13.5.1/convertSubscriptionSitesToCollection.sh similarity index 100% rename from deltaScripts/13.5.1/convertSubscriptionSitesToCollection.sh rename to deltaScripts/archived/13.5.1/convertSubscriptionSitesToCollection.sh diff --git a/deltaScripts/13.5.1/convertSubscriptionSitesToCollection.sql b/deltaScripts/archived/13.5.1/convertSubscriptionSitesToCollection.sql similarity index 100% rename from deltaScripts/13.5.1/convertSubscriptionSitesToCollection.sql rename to deltaScripts/archived/13.5.1/convertSubscriptionSitesToCollection.sql diff --git a/deltaScripts/13.5.1/dropDataURI.sh b/deltaScripts/archived/13.5.1/dropDataURI.sh similarity index 100% rename from deltaScripts/13.5.1/dropDataURI.sh rename to deltaScripts/archived/13.5.1/dropDataURI.sh diff --git a/deltaScripts/13.5.1/ebxmlSchemaChange.sh b/deltaScripts/archived/13.5.1/ebxmlSchemaChange.sh similarity index 100% rename from deltaScripts/13.5.1/ebxmlSchemaChange.sh rename to deltaScripts/archived/13.5.1/ebxmlSchemaChange.sh diff --git a/deltaScripts/13.5.1/ebxmlSchemaDefinition.sql b/deltaScripts/archived/13.5.1/ebxmlSchemaDefinition.sql similarity index 100% rename from deltaScripts/13.5.1/ebxmlSchemaDefinition.sql rename to deltaScripts/archived/13.5.1/ebxmlSchemaDefinition.sql diff --git a/deltaScripts/13.5.1/getSubscriptionSite.sql b/deltaScripts/archived/13.5.1/getSubscriptionSite.sql similarity index 100% rename from deltaScripts/13.5.1/getSubscriptionSite.sql rename to deltaScripts/archived/13.5.1/getSubscriptionSite.sql diff --git a/deltaScripts/13.5.1/removeDeliveryOptions.sql b/deltaScripts/archived/13.5.1/removeDeliveryOptions.sql similarity index 100% rename from deltaScripts/13.5.1/removeDeliveryOptions.sql rename to deltaScripts/archived/13.5.1/removeDeliveryOptions.sql diff --git a/deltaScripts/13.5.1/removeDeliveryOptionsDb.sh b/deltaScripts/archived/13.5.1/removeDeliveryOptionsDb.sh similarity index 100% rename from deltaScripts/13.5.1/removeDeliveryOptionsDb.sh rename to deltaScripts/archived/13.5.1/removeDeliveryOptionsDb.sh diff --git a/deltaScripts/13.5.1/removeDeliveryOptionsLocalization.sh b/deltaScripts/archived/13.5.1/removeDeliveryOptionsLocalization.sh similarity index 100% rename from deltaScripts/13.5.1/removeDeliveryOptionsLocalization.sh rename to deltaScripts/archived/13.5.1/removeDeliveryOptionsLocalization.sh diff --git a/deltaScripts/13.5.1/removeRegistryBackupTags.sh b/deltaScripts/archived/13.5.1/removeRegistryBackupTags.sh similarity index 100% rename from deltaScripts/13.5.1/removeRegistryBackupTags.sh rename to deltaScripts/archived/13.5.1/removeRegistryBackupTags.sh diff --git a/deltaScripts/13.5.1/renameSubscriptionToSiteSubscription.sh b/deltaScripts/archived/13.5.1/renameSubscriptionToSiteSubscription.sh similarity index 100% rename from deltaScripts/13.5.1/renameSubscriptionToSiteSubscription.sh rename to deltaScripts/archived/13.5.1/renameSubscriptionToSiteSubscription.sh diff --git a/deltaScripts/13.5.1/renameSubscriptionToSiteSubscription.sql b/deltaScripts/archived/13.5.1/renameSubscriptionToSiteSubscription.sql similarity index 100% rename from deltaScripts/13.5.1/renameSubscriptionToSiteSubscription.sql rename to deltaScripts/archived/13.5.1/renameSubscriptionToSiteSubscription.sql diff --git a/deltaScripts/13.5.1/resetNtransTable.sh b/deltaScripts/archived/13.5.1/resetNtransTable.sh similarity index 100% rename from deltaScripts/13.5.1/resetNtransTable.sh rename to deltaScripts/archived/13.5.1/resetNtransTable.sh diff --git a/deltaScripts/13.5.1/tableNameUpdate.sql b/deltaScripts/archived/13.5.1/tableNameUpdate.sql similarity index 100% rename from deltaScripts/13.5.1/tableNameUpdate.sql rename to deltaScripts/archived/13.5.1/tableNameUpdate.sql diff --git a/deltaScripts/13.5.1/updateProviderType.xsl b/deltaScripts/archived/13.5.1/updateProviderType.xsl similarity index 100% rename from deltaScripts/13.5.1/updateProviderType.xsl rename to deltaScripts/archived/13.5.1/updateProviderType.xsl diff --git a/deltaScripts/13.5.1/updateProviderTypeDb.sh b/deltaScripts/archived/13.5.1/updateProviderTypeDb.sh similarity index 100% rename from deltaScripts/13.5.1/updateProviderTypeDb.sh rename to deltaScripts/archived/13.5.1/updateProviderTypeDb.sh diff --git a/deltaScripts/13.5.1/updateProviderTypeLocalization.sh b/deltaScripts/archived/13.5.1/updateProviderTypeLocalization.sh similarity index 100% rename from deltaScripts/13.5.1/updateProviderTypeLocalization.sh rename to deltaScripts/archived/13.5.1/updateProviderTypeLocalization.sh diff --git a/deltaScripts/13.5.1/update_svcbu_props.sh b/deltaScripts/archived/13.5.1/update_svcbu_props.sh similarity index 100% rename from deltaScripts/13.5.1/update_svcbu_props.sh rename to deltaScripts/archived/13.5.1/update_svcbu_props.sh diff --git a/deltaScripts/13.5.2/addBufrmosDataURI.sh b/deltaScripts/archived/13.5.2/addBufrmosDataURI.sh similarity index 100% rename from deltaScripts/13.5.2/addBufrmosDataURI.sh rename to deltaScripts/archived/13.5.2/addBufrmosDataURI.sh diff --git a/deltaScripts/future/alterTextProductsTables.sh b/deltaScripts/archived/future/alterTextProductsTables.sh similarity index 100% rename from deltaScripts/future/alterTextProductsTables.sh rename to deltaScripts/archived/future/alterTextProductsTables.sh diff --git a/deltaScripts/future/combineH5Files.py b/deltaScripts/archived/future/combineH5Files.py similarity index 100% rename from deltaScripts/future/combineH5Files.py rename to deltaScripts/archived/future/combineH5Files.py diff --git a/deltaScripts/future/relocateTextUtilities.py b/deltaScripts/archived/future/relocateTextUtilities.py similarity index 100% rename from deltaScripts/future/relocateTextUtilities.py rename to deltaScripts/archived/future/relocateTextUtilities.py diff --git a/deltaScripts/future/removeHdfFileId.sh b/deltaScripts/archived/future/removeHdfFileId.sh similarity index 100% rename from deltaScripts/future/removeHdfFileId.sh rename to deltaScripts/archived/future/removeHdfFileId.sh diff --git a/deltaScripts/unified_grid/README.txt b/deltaScripts/archived/unified_grid/README.txt similarity index 100% rename from deltaScripts/unified_grid/README.txt rename to deltaScripts/archived/unified_grid/README.txt diff --git a/deltaScripts/unified_grid/convert_grib_data.py b/deltaScripts/archived/unified_grid/convert_grib_data.py similarity index 100% rename from deltaScripts/unified_grid/convert_grib_data.py rename to deltaScripts/archived/unified_grid/convert_grib_data.py diff --git a/deltaScripts/unified_grid/copy_grib_purge_rules.sh b/deltaScripts/archived/unified_grid/copy_grib_purge_rules.sh similarity index 100% rename from deltaScripts/unified_grid/copy_grib_purge_rules.sh rename to deltaScripts/archived/unified_grid/copy_grib_purge_rules.sh diff --git a/deltaScripts/unified_grid/create_grid_tables.sh b/deltaScripts/archived/unified_grid/create_grid_tables.sh similarity index 100% rename from deltaScripts/unified_grid/create_grid_tables.sh rename to deltaScripts/archived/unified_grid/create_grid_tables.sh diff --git a/deltaScripts/unified_grid/register_grid_coverage.sh b/deltaScripts/archived/unified_grid/register_grid_coverage.sh similarity index 100% rename from deltaScripts/unified_grid/register_grid_coverage.sh rename to deltaScripts/archived/unified_grid/register_grid_coverage.sh diff --git a/deltaScripts/unified_grid/update_D2D_bundles.sh b/deltaScripts/archived/unified_grid/update_D2D_bundles.sh similarity index 100% rename from deltaScripts/unified_grid/update_D2D_bundles.sh rename to deltaScripts/archived/unified_grid/update_D2D_bundles.sh diff --git a/deltaScripts/unified_grid/update_D2D_procedures.sh b/deltaScripts/archived/unified_grid/update_D2D_procedures.sh similarity index 100% rename from deltaScripts/unified_grid/update_D2D_procedures.sh rename to deltaScripts/archived/unified_grid/update_D2D_procedures.sh diff --git a/deltaScripts/unified_grid/update_FFMP_Source.sh b/deltaScripts/archived/unified_grid/update_FFMP_Source.sh similarity index 100% rename from deltaScripts/unified_grid/update_FFMP_Source.sh rename to deltaScripts/archived/unified_grid/update_FFMP_Source.sh diff --git a/deltaScripts/unified_grid/update_saved_display.sh b/deltaScripts/archived/unified_grid/update_saved_display.sh similarity index 100% rename from deltaScripts/unified_grid/update_saved_display.sh rename to deltaScripts/archived/unified_grid/update_saved_display.sh diff --git a/deltaScripts/unified_grid_rollback/convert_grib_data.py b/deltaScripts/archived/unified_grid_rollback/convert_grib_data.py similarity index 100% rename from deltaScripts/unified_grid_rollback/convert_grib_data.py rename to deltaScripts/archived/unified_grid_rollback/convert_grib_data.py diff --git a/deltaScripts/unified_grid_rollback/copy_grib_purge_rules.sh b/deltaScripts/archived/unified_grid_rollback/copy_grib_purge_rules.sh similarity index 100% rename from deltaScripts/unified_grid_rollback/copy_grib_purge_rules.sh rename to deltaScripts/archived/unified_grid_rollback/copy_grib_purge_rules.sh diff --git a/deltaScripts/unified_grid_rollback/create_grid_tables.sh b/deltaScripts/archived/unified_grid_rollback/create_grid_tables.sh similarity index 100% rename from deltaScripts/unified_grid_rollback/create_grid_tables.sh rename to deltaScripts/archived/unified_grid_rollback/create_grid_tables.sh diff --git a/deltaScripts/unified_grid_rollback/register_grid_coverage.sh b/deltaScripts/archived/unified_grid_rollback/register_grid_coverage.sh similarity index 100% rename from deltaScripts/unified_grid_rollback/register_grid_coverage.sh rename to deltaScripts/archived/unified_grid_rollback/register_grid_coverage.sh diff --git a/deltaScripts/unified_grid_rollback/update_D2D_bundles.sh b/deltaScripts/archived/unified_grid_rollback/update_D2D_bundles.sh similarity index 100% rename from deltaScripts/unified_grid_rollback/update_D2D_bundles.sh rename to deltaScripts/archived/unified_grid_rollback/update_D2D_bundles.sh diff --git a/deltaScripts/unified_grid_rollback/update_D2D_procedures.sh b/deltaScripts/archived/unified_grid_rollback/update_D2D_procedures.sh similarity index 100% rename from deltaScripts/unified_grid_rollback/update_D2D_procedures.sh rename to deltaScripts/archived/unified_grid_rollback/update_D2D_procedures.sh diff --git a/deltaScripts/unified_grid_rollback/update_FFMP_Source.sh b/deltaScripts/archived/unified_grid_rollback/update_FFMP_Source.sh similarity index 100% rename from deltaScripts/unified_grid_rollback/update_FFMP_Source.sh rename to deltaScripts/archived/unified_grid_rollback/update_FFMP_Source.sh diff --git a/deltaScripts/unified_grid_rollback/update_saved_display.sh b/deltaScripts/archived/unified_grid_rollback/update_saved_display.sh similarity index 100% rename from deltaScripts/unified_grid_rollback/update_saved_display.sh rename to deltaScripts/archived/unified_grid_rollback/update_saved_display.sh From 8cbea21f32f19644a37ba8d171df7f4238d861d3 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Wed, 30 Apr 2014 13:08:26 -0500 Subject: [PATCH 126/188] Issue #2060 fix FFG processing Change-Id: I2338c4b311e1d660bc53933633c645e07a1687b0 Former-commit-id: 14ce9854abc51b2791b5f93756ae12cbe69b8589 --- .../monitor/ffmp/ui/rsc/FFMPRowGenerator.java | 40 +++---- .../raytheon/uf/edex/dat/utils/DATUtils.java | 112 ------------------ .../edex/plugin/ffmp/common/FFMPConfig.java | 7 +- .../edex/plugin/scan/process/ScanProduct.java | 41 +------ 4 files changed, 26 insertions(+), 174 deletions(-) diff --git a/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPRowGenerator.java b/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPRowGenerator.java index 61f3df4581..71d694bf21 100644 --- a/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPRowGenerator.java +++ b/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPRowGenerator.java @@ -59,7 +59,8 @@ import com.raytheon.uf.viz.monitor.ffmp.ui.dialogs.FfmpTableConfigData; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Jun 11, 2013 2085 njensen Initial creation - * Jul 15, 2013 2184 dhladky Remove all HUC's for storage except ALL + * Jul 15, 2013 2184 dhladky Remove all HUC's for storage except ALL + * Apr 30, 2014 2060 njensen Safety checks for null guidance * * * @@ -200,7 +201,7 @@ public class FFMPRowGenerator implements Runnable { mouseOverText = metabasin.getBasinId() + "\n" + lid + "-" + fvgmbd.getName(); - + if (!huc.equals(FFMPRecord.ALL)) { sb.append("-").append(fvgmbd.getName()); } @@ -905,26 +906,25 @@ public class FFMPRowGenerator implements Runnable { forced = forceResult.isForced(); } - if (!forcedPfafs.isEmpty() || forced || !pfafList.isEmpty()) { - // Recalculate guidance using the forced value(s) - guidance = guidRecords - .get(guidType) - .getBasinData() - .getAverageGuidanceValue(pfafList, - resource.getGuidanceInterpolators().get(guidType), - guidance, forcedPfafs, - resource.getGuidSourceExpiration(guidType)); - } else { + FFMPRecord grec = guidRecords.get(guidType); + if (grec != null) { + if (!forcedPfafs.isEmpty() || forced || !pfafList.isEmpty()) { + // Recalculate guidance using the forced value(s) + guidance = grec.getBasinData().getAverageGuidanceValue( + pfafList, + resource.getGuidanceInterpolators().get(guidType), + guidance, forcedPfafs, + resource.getGuidSourceExpiration(guidType)); + } else { + FFMPGuidanceBasin ffmpGuidBasin = (FFMPGuidanceBasin) grec + .getBasinData().get(cBasinPfaf); + guidance = resource.getGuidanceValue(ffmpGuidBasin, + paintRefTime, guidType); - FFMPGuidanceBasin ffmpGuidBasin = (FFMPGuidanceBasin) guidRecords - .get(guidType).getBasinData().get(cBasinPfaf); - guidance = resource.getGuidanceValue(ffmpGuidBasin, paintRefTime, - guidType); - - if (guidance < 0.0f) { - guidance = Float.NaN; + if (guidance < 0.0f) { + guidance = Float.NaN; + } } - } return new FFMPTableCellData(FIELDS.GUIDANCE, guidance, forced); diff --git a/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/DATUtils.java b/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/DATUtils.java index 3143b8f76a..ca488bd958 100644 --- a/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/DATUtils.java +++ b/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/DATUtils.java @@ -19,26 +19,19 @@ **/ package com.raytheon.uf.edex.dat.utils; -import java.text.SimpleDateFormat; -import java.util.ArrayList; - import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.common.dataplugin.PluginException; -import com.raytheon.uf.common.dataplugin.ffmp.FFMPVirtualGageBasin; import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataplugin.persist.IPersistable; -import com.raytheon.uf.common.dataplugin.shef.util.ShefConstants; import com.raytheon.uf.common.datastorage.IDataStore; import com.raytheon.uf.common.datastorage.records.FloatDataRecord; import com.raytheon.uf.common.datastorage.records.IDataRecord; import com.raytheon.uf.common.monitor.processing.IMonitorProcessing; import com.raytheon.uf.common.monitor.xml.SCANModelParameterXML; import com.raytheon.uf.common.monitor.xml.SourceXML; -import com.raytheon.uf.edex.database.dao.CoreDao; -import com.raytheon.uf.edex.database.dao.DaoConfig; import com.raytheon.uf.edex.database.plugin.PluginDao; import com.raytheon.uf.edex.database.plugin.PluginFactory; @@ -97,16 +90,9 @@ public class DATUtils { * @return */ public static GridRecord getGridRecord(String uri) throws PluginException { - GridRecord gr = new GridRecord(uri); - PluginDao gd = PluginFactory.getInstance().getPluginDao( - gr.getPluginName()); - gr = (GridRecord) gd.getMetadata(uri); - if (gr != null) { populateGridRecord(gr); - } else { - logger.error("URI: " + uri + " Not in Database..."); } return gr; @@ -136,104 +122,6 @@ public class DATUtils { } } - /** - * Gets the value for an accumulating Virtual Gage Basin - * - * @param lid - * @param startTime - * @param endTime - * @return - * @deprecated Nothing seems to be calling this.... - */ - @Deprecated - public static FFMPVirtualGageBasin getVirtualBasinData(String lid, - FFMPVirtualGageBasin vgb, String endTime, String startTime) { - - // According to the AWIPS I code - - SimpleDateFormat dateFmt = new SimpleDateFormat("MMM dd yy HH:mm:ss"); - CoreDao dao = new CoreDao(DaoConfig.forDatabase(ShefConstants.IHFS)); - - String sql1 = "SELECT dur, value, ts FROM curpc WHERE lid = '" + lid - + "' AND obstime >= '" + startTime + "' AND obstime < '" - + endTime + "' AND pe = 'PC' ORDER BY obstime DESC, ts ASC"; - String sql2 = "SELECT dur, value, ts FROM curpp WHERE lid = '" - + lid - + "' AND obstime >= '" - + startTime - + "' AND obstime < '" - + endTime - + "' AND pe = 'PP' AND dur <= 1001 AND value >=0 ORDER BY dur ASC, obstime DESC, ts ASC"; - - dao = new CoreDao(DaoConfig.forDatabase(ShefConstants.IHFS)); - - try { - // 15 min accumulation - Object[] results = dao.executeSQLQuery(sql1.toString()); - Object[] tsresults = null; - String ts = null; - - if (results.length > 0) { - if (results.length > 1) { - // Gets the highest ranked - String sql3 = "SELECT ts, ts_rank FROM ingestfilter WHERE lid = '" - + lid - + "' AND pe = 'PC' ORDER BY ts_rank ASC limit 1"; - tsresults = dao.executeSQLQuery(sql3.toString()); - } - } else { - results = dao.executeSQLQuery(sql2.toString()); - - if (results.length > 0) { - if (results.length > 1) { - String sql3 = "SELECT ts, ts_rank FROM ingestfilter WHERE lid = '" - + lid - + "' AND pe = 'PP' ORDER BY ts_rank ASC limit 1"; - tsresults = dao.executeSQLQuery(sql3.toString()); - } - } - } - - // parse through getting rid of undesireable types - if (tsresults != null && tsresults.length > 0) { - ArrayList durations = new ArrayList(); - ArrayList values = new ArrayList(); - - for (int i = 0; i < results.length; i++) { - Object[] obs = (Object[]) tsresults[i]; - - if (obs[2] != null) { - if (((String) obs[2]).equals(ts)) { - - if (obs[0] != null) { - durations.add((Integer) obs[0]); - } - if (obs[1] != null) { - values.add(((Number) obs[1]).floatValue()); - } - } - } - } - - float totalVals = 0.0f; - for (float val : values) { - totalVals += val; - } - - float avVal = totalVals / values.size(); - - vgb.setValue(dateFmt.parse(endTime), avVal); - } else { - vgb.setValue(dateFmt.parse(endTime), 0.0f); - } - } catch (Exception e) { - logger.error("No Virual Gage Basin found....."); - } - - return vgb; - - } - /** * Check status of cached model data * diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPConfig.java b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPConfig.java index 44031e4278..f26c2ffae9 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPConfig.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPConfig.java @@ -428,9 +428,10 @@ public class FFMPConfig { } } catch (Exception e) { sources = null; - statusHandler.handle(Priority.PROBLEM, - "Couldn't create FFMP Config... Improper source configuration detected." - + e); + statusHandler + .handle(Priority.PROBLEM, + "Couldn't create FFMP Config... Improper source configuration detected.", + e); } } diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/ScanProduct.java b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/ScanProduct.java index 10e5aeea04..9a2fde5bb6 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/ScanProduct.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.scan/src/com/raytheon/uf/edex/plugin/scan/process/ScanProduct.java @@ -27,10 +27,8 @@ import java.util.List; import org.geotools.referencing.GeodeticCalculator; -import com.raytheon.uf.common.dataplugin.PluginException; import com.raytheon.uf.common.dataplugin.binlightning.BinLightningRecord; import com.raytheon.uf.common.dataplugin.binlightning.impl.LtgStrikeType; -import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataplugin.persist.PersistableDataObject; import com.raytheon.uf.common.dataplugin.persist.PersistablePluginDataObject; import com.raytheon.uf.common.dataplugin.radar.RadarRecord; @@ -38,9 +36,6 @@ import com.raytheon.uf.common.dataplugin.radar.util.RadarConstants; import com.raytheon.uf.common.dataplugin.scan.data.CellTableDataRow; import com.raytheon.uf.common.dataplugin.scan.data.ScanTableData; import com.raytheon.uf.common.dataplugin.scan.data.ScanTableDataRow; -import com.raytheon.uf.common.datastorage.IDataStore; -import com.raytheon.uf.common.datastorage.records.FloatDataRecord; -import com.raytheon.uf.common.datastorage.records.IDataRecord; import com.raytheon.uf.common.geospatial.ISpatialQuery; import com.raytheon.uf.common.geospatial.SpatialException; import com.raytheon.uf.common.geospatial.SpatialQueryFactory; @@ -49,8 +44,6 @@ import com.raytheon.uf.common.monitor.scan.ScanUtils; import com.raytheon.uf.common.monitor.scan.config.SCANConfigEnums.ScanTables; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; -import com.raytheon.uf.edex.database.plugin.PluginDao; -import com.raytheon.uf.edex.database.plugin.PluginFactory; import com.raytheon.uf.edex.plugin.scan.ScanURIFilter; import com.vividsolutions.jts.geom.Coordinate; import com.vividsolutions.jts.geom.GeometryFactory; @@ -63,7 +56,8 @@ import com.vividsolutions.jts.geom.GeometryFactory; * SOFTWARE HISTORY * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * 05/07/2009 2037 dhladky Initial Creation. + * 05/07/2009 2037 dhladky Initial Creation. + * Apr 30, 2014 2060 njensen Updates for removal of grid dataURI column * * * @@ -72,9 +66,6 @@ import com.vividsolutions.jts.geom.GeometryFactory; */ public abstract class ScanProduct implements Serializable { - /** - * - */ private static final long serialVersionUID = 1L; public String dataType = null; @@ -244,34 +235,6 @@ public abstract class ScanProduct implements Serializable { return cwa; } - /** - * get Populated grib record - * - * @param uri - * @return - */ - public static GridRecord getGridRecord(String uri) throws PluginException { - - GridRecord gr = new GridRecord(uri); - PluginDao gd = PluginFactory.getInstance().getPluginDao( - gr.getPluginName()); - gr = (GridRecord) gd.getMetadata(uri); - IDataStore dataStore = gd.getDataStore(gr); - - try { - IDataRecord[] dataRec = dataStore.retrieve(uri); - for (int i = 0; i < dataRec.length; i++) { - if (dataRec[i] instanceof FloatDataRecord) { - gr.setMessageData(dataRec[i]); - } - } - } catch (Exception se) { - se.printStackTrace(); - } - - return gr; - } - /** * process lightning * From 2850d8061018cb018fbcb308b81678aa2ed6bbdd Mon Sep 17 00:00:00 2001 From: Ben Steffensmeier Date: Wed, 30 Apr 2014 14:38:02 -0500 Subject: [PATCH 127/188] Issue #2946 Fix auxillary purge rules. Former-commit-id: a62bdff82f96e79737269686598687ecef746c01 --- .../src/com/raytheon/uf/edex/database/plugin/PluginDao.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/PluginDao.java b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/PluginDao.java index 2ecbb96417..8229fb5795 100644 --- a/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/PluginDao.java +++ b/edexOsgi/com.raytheon.uf.edex.database/src/com/raytheon/uf/edex/database/plugin/PluginDao.java @@ -1777,7 +1777,7 @@ public abstract class PluginDao extends CoreDao { * specifically if defining 0 keys. */ if (auxRules.getKeys().equals(purgeRules.getKeys())) { - purgeRules.getRules().addAll(purgeRules.getRules()); + purgeRules.getRules().addAll(auxRules.getRules()); } else { PurgeLogger.logError( "Ignoring purge rules in " From 4981b6a43852a668c4a20d66332b5af12d6075ab Mon Sep 17 00:00:00 2001 From: Greg Armendariz Date: Wed, 30 Apr 2014 15:42:42 -0500 Subject: [PATCH 128/188] Issue #2571 - Update maps.db snapshot and lake shapefile Former-commit-id: c223bac540568492253cf70a7c7d7521eda3a62d --- rpms/common/static.versions/LATEST.maps | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rpms/common/static.versions/LATEST.maps b/rpms/common/static.versions/LATEST.maps index e2e574437b..5907e7a315 100644 --- a/rpms/common/static.versions/LATEST.maps +++ b/rpms/common/static.versions/LATEST.maps @@ -1 +1 @@ -20130305 \ No newline at end of file +20140430 From 57f5ac701ca7f199fa08a5f9ae90141500bd1a53 Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Wed, 30 Apr 2014 16:41:14 -0500 Subject: [PATCH 129/188] Issue #3089 fixed init.d script for collaboration dataserver RPM Former-commit-id: 9cdef44104a7453a4b968afd1f3845b1ba69ba06 --- .../component.spec | 19 +++++++++++++++++++ .../etc/init.d/collab-dataserver | 6 ++++-- 2 files changed, 23 insertions(+), 2 deletions(-) diff --git a/rpms/awips2.core/Installer.collab-dataserver/component.spec b/rpms/awips2.core/Installer.collab-dataserver/component.spec index 145527b4fe..4c86e31dde 100644 --- a/rpms/awips2.core/Installer.collab-dataserver/component.spec +++ b/rpms/awips2.core/Installer.collab-dataserver/component.spec @@ -45,6 +45,8 @@ if [ $? -ne 0 ]; then fi %install +dataserver_project="%{_baseline_workspace}/rpms/awips2.core/Installer.collab-dataserver" +config_directory="${dataserver_project}/configuration" cd %{_baseline_workspace}/collaboration.dataserver export ANT_OPTS="%{_ant_opts}" /awips2/ant/bin/ant -f build.xml deploy @@ -52,9 +54,23 @@ if [ $? -ne 0 ]; then exit 1 fi +cp -r ${config_directory}/etc ${RPM_BUILD_ROOT} + %pre %post +chmod ug+x /awips2/collab-dataserver/bin/*.sh +chmod 755 /etc/init.d/collab-dataserver +/sbin/chkconfig --add collab-dataserver + %preun +# Remove and unregister the collab-dataserver service. +if [ -f /etc/init.d/collab-dataserver ]; then + /sbin/chkconfig collab-dataserver off + /sbin/chkconfig --del collab-dataserver + + rm -f /etc/init.d/collab-dataserver +fi + %postun %clean @@ -82,3 +98,6 @@ rm -rf ${RPM_BUILD_ROOT} /awips2/collab-dataserver/lib/foss/* %dir /awips2/collab-dataserver/config /awips2/collab-dataserver/config/* + +%defattr(755,root,root,755) +/etc/init.d/collab-dataserver diff --git a/rpms/awips2.core/Installer.collab-dataserver/configuration/etc/init.d/collab-dataserver b/rpms/awips2.core/Installer.collab-dataserver/configuration/etc/init.d/collab-dataserver index 5f701adc5f..b28547c85d 100644 --- a/rpms/awips2.core/Installer.collab-dataserver/configuration/etc/init.d/collab-dataserver +++ b/rpms/awips2.core/Installer.collab-dataserver/configuration/etc/init.d/collab-dataserver @@ -14,7 +14,7 @@ COLLAB_BIN=/awips2/collab-dataserver/bin PROG=`basename $0` start() { - echo -n $"Starting HTTP Collaboration Dataserver" + echo $"Starting HTTP Collaboration Dataserver" # start.sh script starts the service using nohup. ${COLLAB_BIN}/start.sh return $? @@ -26,7 +26,7 @@ status() { } stop() { - echo -n $"Stopping HTTP Collaboration Dataserver" + echo $"Stopping HTTP Collaboration Dataserver" ${COLLAB_BIN}/stop.sh return } @@ -50,8 +50,10 @@ case "$1" in start RETVAL=$? ;; + *) echo $"Usage: $PROG {start|stop|restart|status}" exit 1 + ;; esac exit $RETVAL From c352643c794865ebe9ab008e012fdc3c681f764e Mon Sep 17 00:00:00 2001 From: Dave Hladky Date: Wed, 30 Apr 2014 13:33:03 -0500 Subject: [PATCH 130/188] Issue #2992 Updated DD list of active registries Change-Id: Iaef7dc76442d1e101cf9865a542a777afe1722ca Former-commit-id: a34955102d1316135c4151210daba0e5807ff6c9 --- .../datadelivery/utils/DataDeliveryUtils.java | 30 ++++++++++----- deltaScripts/14.3.1/datadelivery/README | 12 ++++++ .../14.3.1/datadelivery/deleteBackupSubs.sh | 9 +++++ .../datadelivery/updateSubscriptionOwners.sh | 28 ++++++++++++++ ...idthRequest.java => BandwidthRequest.java} | 5 ++- .../bandwidth/BandwidthService.java | 23 ++++++------ .../common/registry/ebxml/RegistryUtil.java | 10 +++-- .../META-INF/MANIFEST.MF | 7 ++-- .../MonolithicBandwidthManagerCreator.java | 8 +++- .../ncf/NcfBandwidthManagerCreator.java | 8 +++- .../bandwidth/sbn/SbnSimulator.java | 4 +- .../META-INF/MANIFEST.MF | 3 +- .../res/spring/bandwidth-datadelivery.xml | 5 ++- .../res/spring/thrift-bandwidth.xml | 2 +- .../bandwidth/BandwidthManager.java | 27 ++++++++++---- .../EdexBandwidthContextFactory.java | 8 +++- .../bandwidth/EdexBandwidthManager.java | 14 ++++--- .../InMemoryBandwidthContextFactory.java | 6 ++- .../bandwidth/InMemoryBandwidthManager.java | 7 +++- .../bandwidth/WfoBandwidthManagerCreator.java | 12 ++++-- .../dao/BandwidthContextFactory.java | 5 ++- .../handler/LocalSiteSubscriptionHandler.java | 4 +- .../HibernateBandwidthInitializer.java | 4 +- .../feature.xml | 7 ---- .../META-INF/MANIFEST.MF | 1 - .../federation/FederationProperties.java | 22 +++++------ .../federation/RegistryFederationManager.java | 18 ++++----- .../META-INF/MANIFEST.MF | 1 - .../overlap/SubscriptionOverlapHandler.java | 4 +- .../.classpath | 7 ---- .../.project | 28 -------------- .../.settings/org.eclipse.jdt.core.prefs | 8 ---- .../META-INF/MANIFEST.MF | 11 ------ .../build.properties | 4 -- .../src/.gitignore | 1 - .../res/spring/ebxml-impl.xml | 7 ++++ .../edex/registry/ebxml/dao/RegistryDao.java | 2 +- .../registry/ebxml/dao/RegistryObjectDao.java | 20 ++++++++++ .../registry/ebxml/util/RegistryIdUtil.java} | 37 ++++++++++++++++--- tests/.classpath | 1 + .../IntegrationTestWfoBandwidthManager.java | 4 +- ...grationTestWfoBandwidthManagerCreator.java | 4 +- .../bandwidth/WfoBandwidthManagerIntTest.java | 6 +-- .../WfoNcfBandwidthManagerIntTest.java | 8 ++-- .../IntegrationTestNcfBandwidthManager.java | 4 +- ...grationTestNcfBandwidthManagerCreator.java | 4 +- .../ncf/NcfBandwidthManagerIntTest.java | 6 +-- .../auth/RemoteServerRequestRouterTest.java | 4 +- .../uf/edex/auth/ServerRequestRouterTest.java | 4 +- .../ServerPrivilegedRequestHandlerTest.java | 6 +-- .../adapters/MockGridMetaDataAdapter.java | 2 +- 51 files changed, 285 insertions(+), 187 deletions(-) create mode 100644 deltaScripts/14.3.1/datadelivery/README create mode 100644 deltaScripts/14.3.1/datadelivery/deleteBackupSubs.sh create mode 100644 deltaScripts/14.3.1/datadelivery/updateSubscriptionOwners.sh rename edexOsgi/com.raytheon.uf.common.datadelivery.bandwidth/src/com/raytheon/uf/common/datadelivery/bandwidth/{IBandwidthRequest.java => BandwidthRequest.java} (94%) delete mode 100644 edexOsgi/com.raytheon.uf.edex.datadelivery/.classpath delete mode 100644 edexOsgi/com.raytheon.uf.edex.datadelivery/.project delete mode 100644 edexOsgi/com.raytheon.uf.edex.datadelivery/.settings/org.eclipse.jdt.core.prefs delete mode 100644 edexOsgi/com.raytheon.uf.edex.datadelivery/META-INF/MANIFEST.MF delete mode 100644 edexOsgi/com.raytheon.uf.edex.datadelivery/build.properties delete mode 100644 edexOsgi/com.raytheon.uf.edex.datadelivery/src/.gitignore rename edexOsgi/{com.raytheon.uf.edex.datadelivery/src/com/raytheon/uf/edex/datadelivery/util/DataDeliveryIdUtil.java => com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/util/RegistryIdUtil.java} (57%) diff --git a/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/utils/DataDeliveryUtils.java b/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/utils/DataDeliveryUtils.java index 04e2e64aac..20bfe2c73c 100644 --- a/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/utils/DataDeliveryUtils.java +++ b/cave/com.raytheon.uf.viz.datadelivery/src/com/raytheon/uf/viz/datadelivery/utils/DataDeliveryUtils.java @@ -35,8 +35,8 @@ import org.eclipse.swt.widgets.MessageBox; import org.eclipse.swt.widgets.Shell; import com.raytheon.uf.common.auth.resp.SuccessfulExecution; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest.RequestType; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest.RequestType; import com.raytheon.uf.common.datadelivery.registry.Coverage; import com.raytheon.uf.common.datadelivery.registry.DataLevelType; import com.raytheon.uf.common.datadelivery.registry.DataType; @@ -47,9 +47,8 @@ import com.raytheon.uf.common.datadelivery.registry.PointTime; import com.raytheon.uf.common.datadelivery.registry.Subscription; import com.raytheon.uf.common.datadelivery.registry.Time; import com.raytheon.uf.common.datadelivery.request.DataDeliveryConstants; +import com.raytheon.uf.common.registry.ebxml.RegistryUtil; import com.raytheon.uf.common.serialization.comm.RequestRouter; -import com.raytheon.uf.common.site.SiteData; -import com.raytheon.uf.common.site.SiteMap; import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.common.util.CollectionUtil; import com.raytheon.uf.common.util.SizeUtil; @@ -93,6 +92,7 @@ import com.vividsolutions.jts.geom.Coordinate; * Nov 07, 2013 2291 skorolev Added showText() method for messages with many lines. * Feb 11, 2014 2771 bgonzale Added Data Delivery ID, getter, and retrieval method. * Apr 2, 2014 2974 dhladky DD ID added to list for dropdowns in DD. + * Apr 22, 2014 2992 dhladky Unique list of all registries with data in this node. * * * @author mpduff @@ -849,7 +849,7 @@ public class DataDeliveryUtils { } private static String retrieveDataDeliveryId() { - IBandwidthRequest request = new IBandwidthRequest(); + BandwidthRequest request = new BandwidthRequest(); request.setRequestType(RequestType.GET_DATADELIVERY_ID); try { SuccessfulExecution response = (SuccessfulExecution) RequestRouter @@ -865,16 +865,28 @@ public class DataDeliveryUtils { * Gets the DD id containing site List. * @return */ + @SuppressWarnings("unchecked") public static List getDataDeliverySiteList() { - Map siteData = SiteMap.getInstance().getSiteData(); - Set sites = siteData.keySet(); - List siteList = new ArrayList(sites); - String DDid = DataDeliveryUtils.getDataDeliveryId(); + BandwidthRequest request = new BandwidthRequest(); + List siteList = null; + request.setRequestType(RequestType.GET_DATADELIVERY_REGISTRIES); + try { + SuccessfulExecution response = (SuccessfulExecution) RequestRouter + .route(request, DataDeliveryConstants.DATA_DELIVERY_SERVER); + siteList = (List) response.getResponse(); + } catch (Exception e) { + throw new RuntimeException( + "Unable to retrieve Data Delivery Registry list from EDEX.", e); + } + // Should return itself, but just in case. + String DDid = getDataDeliveryId(); if (!siteList.contains(DDid)) { siteList.add(DDid); Collections.sort(siteList); } + // remove "NCF", CAVE users don't care about things owned by NCF + siteList.remove(RegistryUtil.defaultUser); return siteList; } diff --git a/deltaScripts/14.3.1/datadelivery/README b/deltaScripts/14.3.1/datadelivery/README new file mode 100644 index 0000000000..3cebb6e265 --- /dev/null +++ b/deltaScripts/14.3.1/datadelivery/README @@ -0,0 +1,12 @@ +# README, DO NOT RUN THIS SCRIPT UNLESS YOU READ THIS!!!!!!!!!!!!!!! +# This update needs to be performed with build 14.3.1. +# This update is only for edex servers which have run DD and have subscriptions loaded. + +1.) Backup your subscriptions from the Registry Web Interface, + http://$REGISTRY_HOST:8082/registry/RegistryInterface.html. + hit the button. +2.) Then run this update script, updateSubscriptionOwners.sh +3.) If you are satisfied the subs are correct, either clean up the backup files by running + the deleteBackupSubs.sh or move them to a different directory for storage. +3.) After script runs, hit the button + That will update the subscriptions will reflect the correct ownership at the registry level. \ No newline at end of file diff --git a/deltaScripts/14.3.1/datadelivery/deleteBackupSubs.sh b/deltaScripts/14.3.1/datadelivery/deleteBackupSubs.sh new file mode 100644 index 0000000000..5e76269c59 --- /dev/null +++ b/deltaScripts/14.3.1/datadelivery/deleteBackupSubs.sh @@ -0,0 +1,9 @@ +#!/bin/bash +# +# Deletes the backuped up subscriptions *.bak files + +echo "" +echo "Press Enter to perform the updates Ctrl-C to quit." +read done + +rm -rf /awips2/edex/data/registrySubscriptionBackup/*.bak diff --git a/deltaScripts/14.3.1/datadelivery/updateSubscriptionOwners.sh b/deltaScripts/14.3.1/datadelivery/updateSubscriptionOwners.sh new file mode 100644 index 0000000000..ce2452be40 --- /dev/null +++ b/deltaScripts/14.3.1/datadelivery/updateSubscriptionOwners.sh @@ -0,0 +1,28 @@ +#!/bin/bash +# +# DO NOT RUN THIS SCRIPT UNLESS YOU READ THIS!!!!!!!!!!!!!!! +# This update needs to be performed with build 14.3.1. +# This update is only for edex servers which have run DD and have subscriptions loaded. +# FIRST! Backup your subscriptions from the Registry Web Interface, +# http://$REGISTRY_HOST:8082/registry/RegistryInterface.html. +# Then run this update script, after script runs, +# That will update the subscriptions to reflect the correct ownership at the registry level. + +echo "" +echo "Press Enter to perform the updates Ctrl-C to quit." +read done + +files=`find /awips2/edex/data/registrySubscriptionBackup -iname \*-RECURRING` + +if [[ -z "$files" ]]; then +echo "FATAL: Update Subscriptions has Failed, No subscription backup files found!" +exit 1 +fi + +for f in $files; do + echo Updating $f + bf=$f.bak.`date +%m%d%y` + cp $f $bf + perl updateSubscriptionOwners.pl $f; + done + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.bandwidth/src/com/raytheon/uf/common/datadelivery/bandwidth/IBandwidthRequest.java b/edexOsgi/com.raytheon.uf.common.datadelivery.bandwidth/src/com/raytheon/uf/common/datadelivery/bandwidth/BandwidthRequest.java similarity index 94% rename from edexOsgi/com.raytheon.uf.common.datadelivery.bandwidth/src/com/raytheon/uf/common/datadelivery/bandwidth/IBandwidthRequest.java rename to edexOsgi/com.raytheon.uf.common.datadelivery.bandwidth/src/com/raytheon/uf/common/datadelivery/bandwidth/BandwidthRequest.java index 80ebe75dab..acd65cd78e 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.bandwidth/src/com/raytheon/uf/common/datadelivery/bandwidth/IBandwidthRequest.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.bandwidth/src/com/raytheon/uf/common/datadelivery/bandwidth/BandwidthRequest.java @@ -28,6 +28,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; * Jul 18, 2013 1653 mpduff Add GET_SUBSCRIPTION_STATUS. * Oct 2 2013 1797 dhladky generic attempt * Feb 11, 2014 2771 bgonzale Added GET_DATADELIVERY_ID to RequestTypes. + * Apr 22, 2014 2992 dhladky This is not an interface, changed to be correct naming. * * * @@ -35,7 +36,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; * @version 1.0 */ @DynamicSerialize -public class IBandwidthRequest extends AbstractPrivilegedRequest { +public class BandwidthRequest extends AbstractPrivilegedRequest { public static enum RequestType { // Get the current retrieval plan for the @@ -48,7 +49,7 @@ public class IBandwidthRequest extends Abstr /** * Request information. */ - GET_ESTIMATED_COMPLETION, GET_BANDWIDTH_GRAPH_DATA, GET_SUBSCRIPTION_STATUS, GET_DATADELIVERY_ID + GET_ESTIMATED_COMPLETION, GET_BANDWIDTH_GRAPH_DATA, GET_SUBSCRIPTION_STATUS, GET_DATADELIVERY_ID, GET_DATADELIVERY_REGISTRIES } @DynamicSerializeElement diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.bandwidth/src/com/raytheon/uf/common/datadelivery/bandwidth/BandwidthService.java b/edexOsgi/com.raytheon.uf.common.datadelivery.bandwidth/src/com/raytheon/uf/common/datadelivery/bandwidth/BandwidthService.java index d91588ecab..1f8dd2b3b9 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.bandwidth/src/com/raytheon/uf/common/datadelivery/bandwidth/BandwidthService.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.bandwidth/src/com/raytheon/uf/common/datadelivery/bandwidth/BandwidthService.java @@ -26,7 +26,7 @@ import java.util.List; import java.util.Set; import com.raytheon.uf.common.auth.req.BasePrivilegedServerService; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest.RequestType; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest.RequestType; import com.raytheon.uf.common.datadelivery.bandwidth.data.BandwidthGraphData; import com.raytheon.uf.common.datadelivery.bandwidth.data.SubscriptionStatusSummary; import com.raytheon.uf.common.datadelivery.registry.AdhocSubscription; @@ -57,6 +57,7 @@ import com.raytheon.uf.common.util.LogUtil; * Oct 2, 2013 1797 dhladky Generics * Oct 01, 2013 2267 bgonzale Log error response from proposed scheduling. * Dec 11, 2013 2625 mpduff Fix error handling to not return null. + * Apr 22, 2014 2992 dhladky renamed BandwidthRequest * * * @@ -64,7 +65,7 @@ import com.raytheon.uf.common.util.LogUtil; * @version 1.0 */ public abstract class BandwidthService - extends BasePrivilegedServerService> implements + extends BasePrivilegedServerService> implements IBandwidthService { private static final IUFStatusHandler statusHandler = UFStatus @@ -84,7 +85,7 @@ public abstract class BandwidthService */ @Override public final int getBandwidthForNetworkInKilobytes(Network network) { - IBandwidthRequest request = new IBandwidthRequest(); + BandwidthRequest request = new BandwidthRequest(); request.setRequestType(RequestType.GET_BANDWIDTH); request.setNetwork(network); @@ -105,7 +106,7 @@ public abstract class BandwidthService @SuppressWarnings("unchecked") public Set proposeBandwidthForNetworkInKilobytes(Network network, int bandwidth) { - IBandwidthRequest request = new IBandwidthRequest(); + BandwidthRequest request = new BandwidthRequest(); request.setRequestType(RequestType.PROPOSE_SET_BANDWIDTH); request.setNetwork(network); request.setBandwidth(bandwidth); @@ -126,7 +127,7 @@ public abstract class BandwidthService @Override public final boolean setBandwidthForNetworkInKilobytes(Network network, int bandwidth) { - IBandwidthRequest request = new IBandwidthRequest(); + BandwidthRequest request = new BandwidthRequest(); request.setRequestType(RequestType.FORCE_SET_BANDWIDTH); request.setNetwork(network); request.setBandwidth(bandwidth); @@ -161,7 +162,7 @@ public abstract class BandwidthService */ @Override public Set schedule(List> subscriptions) { - IBandwidthRequest request = new IBandwidthRequest(); + BandwidthRequest request = new BandwidthRequest(); request.setRequestType(RequestType.SCHEDULE_SUBSCRIPTION); request.setSubscriptions(subscriptions); @@ -195,7 +196,7 @@ public abstract class BandwidthService @Override public IProposeScheduleResponse proposeSchedule( List> subscriptions) { - IBandwidthRequest request = new IBandwidthRequest(); + BandwidthRequest request = new BandwidthRequest(); request.setRequestType(RequestType.PROPOSE_SCHEDULE_SUBSCRIPTION); request.setSubscriptions(subscriptions); @@ -217,7 +218,7 @@ public abstract class BandwidthService */ @Override public void reinitialize() { - IBandwidthRequest request = new IBandwidthRequest(); + BandwidthRequest request = new BandwidthRequest(); request.setRequestType(RequestType.REINITIALIZE); try { @@ -234,7 +235,7 @@ public abstract class BandwidthService @SuppressWarnings("unchecked") @Override public Date getEstimatedCompletionTime(AdhocSubscription sub) { - IBandwidthRequest request = new IBandwidthRequest(); + BandwidthRequest request = new BandwidthRequest(); request.setSubscriptions(Arrays.> asList(sub)); request.setRequestType(RequestType.GET_ESTIMATED_COMPLETION); try { @@ -253,7 +254,7 @@ public abstract class BandwidthService */ @Override public BandwidthGraphData getBandwidthGraphData() { - IBandwidthRequest request = new IBandwidthRequest(); + BandwidthRequest request = new BandwidthRequest(); request.setRequestType(RequestType.GET_BANDWIDTH_GRAPH_DATA); try { return sendRequest(request, BandwidthGraphData.class); @@ -268,7 +269,7 @@ public abstract class BandwidthService @Override public SubscriptionStatusSummary getSubscriptionStatusSummary( Subscription subscription) { - IBandwidthRequest request = new IBandwidthRequest(); + BandwidthRequest request = new BandwidthRequest(); request.setSubscriptions(Arrays .> asList(subscription)); request.setRequestType(RequestType.GET_SUBSCRIPTION_STATUS); diff --git a/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/RegistryUtil.java b/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/RegistryUtil.java index 114c69a6d0..8801a167b4 100644 --- a/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/RegistryUtil.java +++ b/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/RegistryUtil.java @@ -54,6 +54,7 @@ import com.raytheon.uf.common.registry.ebxml.slots.SlotConverter; import com.raytheon.uf.common.registry.ebxml.slots.StringSlotConverter; import com.raytheon.uf.common.serialization.SerializationException; import com.raytheon.uf.common.time.util.ImmutableDate; +import com.raytheon.uf.common.util.ClusterIdUtil; import com.raytheon.uf.common.util.CollectionUtil; import com.raytheon.uf.common.util.ReflectionException; import com.raytheon.uf.common.util.ReflectionUtil; @@ -79,7 +80,8 @@ import com.raytheon.uf.common.util.ReflectionUtil; * Jun 03, 2013 2038 djohnson Allow setting the same encoder strategy. * Jun 24, 2013 2106 djohnson Remove encoder strategy from instance variables. * Dec 04, 2013 2584 dhladky Versions for Registry objects - * Mar 31, 2014 2889 dhladky Added username for notification center tracking. + * Mar 31, 2014 2889 dhladky Added username for notification center tracking. + * Apr 24, 2014 2992 dhladky fixed all objects in ebxml owned by NCF, bad. * * * @@ -99,6 +101,8 @@ public final class RegistryUtil { public static final String registryObjectDefaultVersion = "1.0"; public static final String registryUser = "Registry"; + + public static final String defaultUser = "NCF"; static { if (System.getenv("EBXML_REGISTRY_HOST") != null @@ -113,9 +117,9 @@ public final class RegistryUtil { public static final String CALLING_REGISTRY_SOAP_HEADER_NAME = "Calling_Registry"; /** - * The default internal owner + * The default internal owner is the local registry ID */ - public static final String DEFAULT_OWNER = "NCF"; + public static final String DEFAULT_OWNER = ClusterIdUtil.getId(); // A private mapping of attribute types to slot types, used when storing an // object to the registry to map QueryableAttributes to SlotConverters. diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/META-INF/MANIFEST.MF index c574d10d32..1ea2fc5447 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/META-INF/MANIFEST.MF @@ -17,7 +17,8 @@ Require-Bundle: com.raytheon.uf.common.datadelivery.bandwidth;bundle-version="1. com.google.guava;bundle-version="1.0.0", com.raytheon.uf.edex.core;bundle-version="1.12.1174", com.raytheon.uf.common.registry.ebxml;bundle-version="1.0.0", - com.raytheon.uf.common.datadelivery.service;bundle-version="1.0.0" + com.raytheon.uf.common.datadelivery.service;bundle-version="1.0.0", + com.raytheon.uf.edex.registry.ebxml;bundle-version="1.0.0" Import-Package: com.raytheon.edex.site, - com.raytheon.uf.common.event, - com.raytheon.uf.edex.datadelivery.util + com.raytheon.uf.common.event + diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/src/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/MonolithicBandwidthManagerCreator.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/src/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/MonolithicBandwidthManagerCreator.java index ed144881a9..b7e2f5d3b2 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/src/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/MonolithicBandwidthManagerCreator.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/src/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/MonolithicBandwidthManagerCreator.java @@ -33,6 +33,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.dao.IBandwidthDbInit; import com.raytheon.uf.edex.datadelivery.bandwidth.hibernate.IFindSubscriptionsForScheduling; import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalManager; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; +import com.raytheon.uf.edex.registry.ebxml.util.RegistryIdUtil; /** * {@link IEdexBandwidthManagerCreator} A bandwidth manager creator for @@ -53,6 +54,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; * Dec 04, 2013 2566 bgonzale use bandwidthmanager method to retrieve spring files. * Jan 14, 2014 2692 dhladky AdhocSubscription handler * Jan 30, 2014 2636 mpduff Scheduling refactor. + * Apr 22, 2014 2992 dhladky Added IdUtil for siteList * * * @@ -85,12 +87,13 @@ public class MonolithicBandwidthManagerCreator bandwidthDao, RetrievalManager retrievalManager, BandwidthDaoUtil bandwidthDaoUtil, + RegistryIdUtil idUtil, IDataSetMetaDataHandler dataSetMetaDataHandler, ISubscriptionHandler subscriptionHandler, IAdhocSubscriptionHandler adhocSubscriptionHandler, ISubscriptionNotificationService subscriptionNotificationService, IFindSubscriptionsForScheduling findSubscriptionsStrategy) { - super(dbInit, bandwidthDao, retrievalManager, bandwidthDaoUtil, + super(dbInit, bandwidthDao, retrievalManager, bandwidthDaoUtil, idUtil, dataSetMetaDataHandler, subscriptionHandler, adhocSubscriptionHandler, subscriptionNotificationService, findSubscriptionsStrategy); @@ -110,13 +113,14 @@ public class MonolithicBandwidthManagerCreator getBandwidthManager(IBandwidthDbInit dbInit, IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, BandwidthDaoUtil bandwidthDaoUtil, + RegistryIdUtil idUtil, IDataSetMetaDataHandler dataSetMetaDataHandler, ISubscriptionHandler subscriptionHandler, IAdhocSubscriptionHandler adhocSubscriptionHandler, ISubscriptionNotificationService subscriptionNotificationService, IFindSubscriptionsForScheduling findSubscriptionsStrategy) { return new MonolithicBandwidthManager(dbInit, bandwidthDao, - retrievalManager, bandwidthDaoUtil, dataSetMetaDataHandler, + retrievalManager, bandwidthDaoUtil, idUtil, dataSetMetaDataHandler, subscriptionHandler, adhocSubscriptionHandler, subscriptionNotificationService, findSubscriptionsStrategy); } diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/src/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/NcfBandwidthManagerCreator.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/src/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/NcfBandwidthManagerCreator.java index 76e94e6929..89ba693a61 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/src/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/NcfBandwidthManagerCreator.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/src/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/NcfBandwidthManagerCreator.java @@ -44,6 +44,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.dao.IBandwidthDbInit; import com.raytheon.uf.edex.datadelivery.bandwidth.hibernate.IFindSubscriptionsForScheduling; import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalManager; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; +import com.raytheon.uf.edex.registry.ebxml.util.RegistryIdUtil; /** * {@link IEdexBandwidthManagerCreator} for an NCF bandwidth manager. @@ -65,6 +66,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; * Reschedule updated shared subscriptions. * Dec 04, 2013 2566 bgonzale use bandwidthmanager method to retrieve spring files. * Jan 14, 2014 2692 dhladky AdhocSubscription handler + * Apr 22, 2014 2992 dhladky Added IdUtil for siteList * * * @@ -97,12 +99,13 @@ public class NcfBandwidthManagerCreator IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, BandwidthDaoUtil bandwidthDaoUtil, + RegistryIdUtil idUtil, IDataSetMetaDataHandler dataSetMetaDataHandler, ISubscriptionHandler subscriptionHandler, IAdhocSubscriptionHandler adhocSubscriptionHandler, ISubscriptionNotificationService subscriptionNotificationService, IFindSubscriptionsForScheduling findSubscriptionsStrategy) { - super(dbInit, bandwidthDao, retrievalManager, bandwidthDaoUtil, + super(dbInit, bandwidthDao, retrievalManager, bandwidthDaoUtil, idUtil, dataSetMetaDataHandler, subscriptionHandler, adhocSubscriptionHandler, subscriptionNotificationService, findSubscriptionsStrategy); @@ -160,13 +163,14 @@ public class NcfBandwidthManagerCreator public IBandwidthManager getBandwidthManager(IBandwidthDbInit dbInit, IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, BandwidthDaoUtil bandwidthDaoUtil, + RegistryIdUtil idUtil, IDataSetMetaDataHandler dataSetMetaDataHandler, ISubscriptionHandler subscriptionHandler, IAdhocSubscriptionHandler adhocSubscriptionHandler, ISubscriptionNotificationService subscriptionNotificationService, IFindSubscriptionsForScheduling findSubscriptionsStrategy) { return new NcfBandwidthManager(dbInit, bandwidthDao, retrievalManager, - bandwidthDaoUtil, dataSetMetaDataHandler, subscriptionHandler, + bandwidthDaoUtil, idUtil, dataSetMetaDataHandler, subscriptionHandler, adhocSubscriptionHandler, subscriptionNotificationService, findSubscriptionsStrategy); } diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/src/com/raytheon/uf/edex/datadelivery/bandwidth/sbn/SbnSimulator.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/src/com/raytheon/uf/edex/datadelivery/bandwidth/sbn/SbnSimulator.java index e0b1d8ca53..0b21e2f38b 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/src/com/raytheon/uf/edex/datadelivery/bandwidth/sbn/SbnSimulator.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth.ncf/src/com/raytheon/uf/edex/datadelivery/bandwidth/sbn/SbnSimulator.java @@ -29,7 +29,7 @@ import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.util.FileUtil; import com.raytheon.uf.common.util.file.FilenameFilters; import com.raytheon.uf.edex.core.EDEXUtil; -import com.raytheon.uf.edex.datadelivery.util.DataDeliveryIdUtil; +import com.raytheon.uf.edex.registry.ebxml.util.RegistryIdUtil; /** * The SBN simulator. Reads files from a configured directory, and then places @@ -103,7 +103,7 @@ public class SbnSimulator { */ public SbnSimulator() { this(new File(System.getProperty("sbn.retrieval.transfer.directory")), - new CopyFileToManualIngest(), DataDeliveryIdUtil.getId()); + new CopyFileToManualIngest(), RegistryIdUtil.getId()); } /** diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/META-INF/MANIFEST.MF index 9d3f5605c9..49bf6012a4 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/META-INF/MANIFEST.MF @@ -45,5 +45,4 @@ Export-Package: com.raytheon.uf.edex.datadelivery.bandwidth, com.raytheon.uf.edex.datadelivery.bandwidth.util Import-Package: com.raytheon.uf.common.datadelivery.event.retrieval, com.raytheon.uf.common.datadelivery.registry, - com.raytheon.uf.common.stats, - com.raytheon.uf.edex.datadelivery.util + com.raytheon.uf.common.stats diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/res/spring/bandwidth-datadelivery.xml b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/res/spring/bandwidth-datadelivery.xml index 316759038f..ea435c54b9 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/res/spring/bandwidth-datadelivery.xml +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/res/spring/bandwidth-datadelivery.xml @@ -31,7 +31,7 @@ - + @@ -39,10 +39,11 @@ + - + diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/res/spring/thrift-bandwidth.xml b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/res/spring/thrift-bandwidth.xml index 286d6764dc..a4f34019a3 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/res/spring/thrift-bandwidth.xml +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/res/spring/thrift-bandwidth.xml @@ -7,7 +7,7 @@ + value="com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest" /> diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/BandwidthManager.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/BandwidthManager.java index 9a66c98561..b708c44fee 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/BandwidthManager.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/BandwidthManager.java @@ -22,8 +22,8 @@ import com.google.common.collect.Sets; import com.raytheon.edex.util.Util; import com.raytheon.uf.common.auth.exception.AuthorizationException; import com.raytheon.uf.common.auth.user.IUser; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest.RequestType; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest.RequestType; import com.raytheon.uf.common.datadelivery.bandwidth.IProposeScheduleResponse; import com.raytheon.uf.common.datadelivery.bandwidth.ProposeScheduleResponse; import com.raytheon.uf.common.datadelivery.bandwidth.data.BandwidthGraphData; @@ -80,8 +80,8 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalPlan; import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalStatus; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthUtil; -import com.raytheon.uf.edex.datadelivery.util.DataDeliveryIdUtil; import com.raytheon.uf.edex.registry.ebxml.exception.EbxmlRegistryException; +import com.raytheon.uf.edex.registry.ebxml.util.RegistryIdUtil; /** * Abstract {@link IBandwidthManager} implementation which provides core @@ -148,6 +148,7 @@ import com.raytheon.uf.edex.registry.ebxml.exception.EbxmlRegistryException; * Feb 11, 2014 2771 bgonzale Added handler for GET_DATADELIVERY_ID request. * Feb 10, 2014 2636 mpduff Changed how retrieval plan is updated over time. * Apr 02, 2014 2810 dhladky Priority sorting of subscriptions. + * Apr 22, 2014 2992 dhladky Ability to get list of all registry nodes containing data. * * * @@ -155,13 +156,16 @@ import com.raytheon.uf.edex.registry.ebxml.exception.EbxmlRegistryException; * @version 1.0 */ public abstract class BandwidthManager - extends AbstractPrivilegedRequestHandler> + extends AbstractPrivilegedRequestHandler> implements IBandwidthManager { protected static final IUFStatusHandler statusHandler = UFStatus .getHandler(BandwidthManager.class); private static final Pattern RES_PATTERN = Pattern.compile("^res"); + + /** used to query for registry subscription object owners **/ + private static final String objectType = "'urn:oasis:names:tc:ebxml-regrep:ObjectType:RegistryObject:com.raytheon.uf.common.datadelivery.registry.%Subscription'"; // Requires package access so it can be accessed from the maintenance task final IBandwidthDao bandwidthDao; @@ -173,6 +177,8 @@ public abstract class BandwidthManager protected final BandwidthDaoUtil bandwidthDaoUtil; private final IBandwidthDbInit dbInit; + + private final RegistryIdUtil idUtil; // Instance variable and not static, because there are multiple child // implementation classes which should each have a unique prefix @@ -185,11 +191,13 @@ public abstract class BandwidthManager public BandwidthManager(IBandwidthDbInit dbInit, IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, - BandwidthDaoUtil bandwidthDaoUtil) { + BandwidthDaoUtil bandwidthDaoUtil, + RegistryIdUtil idUtil) { this.dbInit = dbInit; this.bandwidthDao = bandwidthDao; this.retrievalManager = retrievalManager; this.bandwidthDaoUtil = bandwidthDaoUtil; + this.idUtil = idUtil; } /** @@ -878,7 +886,7 @@ public abstract class BandwidthManager * {@inheritDoc} */ @Override - public Object handleRequest(IBandwidthRequest request) + public Object handleRequest(BandwidthRequest request) throws Exception { ITimer timer = TimeUtil.getTimer(); @@ -982,7 +990,10 @@ public abstract class BandwidthManager response = getBandwidthGraphData(); break; case GET_DATADELIVERY_ID: - response = DataDeliveryIdUtil.getId(); + response = RegistryIdUtil.getId(); + break; + case GET_DATADELIVERY_REGISTRIES: + response = idUtil.getUniqueRegistries(objectType); break; case GET_SUBSCRIPTION_STATUS: Subscription sub = null; @@ -1440,7 +1451,7 @@ public abstract class BandwidthManager */ @Override public AuthorizationResponse authorized(IUser user, - IBandwidthRequest request) throws AuthorizationException { + BandwidthRequest request) throws AuthorizationException { return new AuthorizationResponse(true); } diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/EdexBandwidthContextFactory.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/EdexBandwidthContextFactory.java index 193fe7521f..fc8a88469a 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/EdexBandwidthContextFactory.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/EdexBandwidthContextFactory.java @@ -41,6 +41,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.hibernate.IFindSubscriptionsF import com.raytheon.uf.edex.datadelivery.bandwidth.interfaces.BandwidthInitializer; import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalManager; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; +import com.raytheon.uf.edex.registry.ebxml.util.RegistryIdUtil; /** * {@link BandwidthContextFactory} for running in EDEX. Intentionally @@ -59,6 +60,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; * Nov 07, 2013 2506 bgonzale Added notification handler to bandwidth context. * Jan 14, 2014 2692 dhladky AdhocSubscription handler * Jan 30, 2014 2636 mpduff Scheduling refactor. + * Apr 22, 2014 2992 dhladky Added IdUtil for siteList * * * @@ -81,6 +83,7 @@ public class EdexBandwidthContextFactory * @param bandwidthDao * @param retrievalManager * @param bandwidthDaoUtil + * @param idUtil * @param dataSetMetaDataHandler * @param subscriptionHandler * @return the bandwidth manager @@ -89,6 +92,7 @@ public class EdexBandwidthContextFactory IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, BandwidthDaoUtil bandwidthDaoUtil, + RegistryIdUtil idUtil, IDataSetMetaDataHandler dataSetMetaDataHandler, ISubscriptionHandler subscriptionHandler, IAdhocSubscriptionHandler adhocSubscriptionHandler, @@ -253,9 +257,9 @@ public class EdexBandwidthContextFactory @Override public IBandwidthManager getBandwidthManager(IBandwidthDbInit dbInit, IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, - BandwidthDaoUtil bandwidthDaoUtil) { + BandwidthDaoUtil bandwidthDaoUtil,RegistryIdUtil idUtil) { return bandwidthManagerCreator.getBandwidthManager(dbInit, - bandwidthDao, retrievalManager, bandwidthDaoUtil, + bandwidthDao, retrievalManager, bandwidthDaoUtil, idUtil, dataSetMetaDataHandler, subscriptionHandler, adhocSubscriptionHandler, notificationService, findSubscriptionsStrategy); diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/EdexBandwidthManager.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/EdexBandwidthManager.java index d3d446965f..b6eb345463 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/EdexBandwidthManager.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/EdexBandwidthManager.java @@ -40,8 +40,8 @@ import com.google.common.annotations.VisibleForTesting; import com.google.common.collect.Lists; import com.google.common.eventbus.AllowConcurrentEvents; import com.google.common.eventbus.Subscribe; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest.RequestType; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest.RequestType; import com.raytheon.uf.common.datadelivery.bandwidth.ProposeScheduleResponse; import com.raytheon.uf.common.datadelivery.registry.AdhocSubscription; import com.raytheon.uf.common.datadelivery.registry.Coverage; @@ -87,7 +87,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalStatus; import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.SubscriptionRetrievalFulfilled; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthUtil; -import com.raytheon.uf.edex.datadelivery.util.DataDeliveryIdUtil; +import com.raytheon.uf.edex.registry.ebxml.util.RegistryIdUtil; /** * Implementation of {@link BandwidthManager} that isolates EDEX specific @@ -128,6 +128,7 @@ import com.raytheon.uf.edex.datadelivery.util.DataDeliveryIdUtil; * Feb 10, 2014 2636 mpduff Pass Network map to be scheduled. * Feb 21, 2014, 2636 dhladky Try catch to keep MaintTask from dying. * Mar 31, 2014 2889 dhladky Added username for notification center tracking. + * Apr 22, 2014 2992 dhladky Added IdUtil for siteList * * * @author djohnson @@ -177,12 +178,13 @@ public abstract class EdexBandwidthManager IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, BandwidthDaoUtil bandwidthDaoUtil, + RegistryIdUtil idUtil, IDataSetMetaDataHandler dataSetMetaDataHandler, ISubscriptionHandler subscriptionHandler, IAdhocSubscriptionHandler adhocSubscriptionHandler, ISubscriptionNotificationService subscriptionNotificationService, IFindSubscriptionsForScheduling findSubscriptionsStrategy) { - super(dbInit, bandwidthDao, retrievalManager, bandwidthDaoUtil); + super(dbInit, bandwidthDao, retrievalManager, bandwidthDaoUtil, idUtil); this.dataSetMetaDataHandler = dataSetMetaDataHandler; this.subscriptionHandler = subscriptionHandler; @@ -401,7 +403,7 @@ public abstract class EdexBandwidthManager if (DataDeliveryRegistryObjectTypes.isRecurringSubscription(objectType)) { if (sub != null) { boolean isApplicableForTheLocalSite = sub.getOfficeIDs() - .contains(DataDeliveryIdUtil.getId()); + .contains(RegistryIdUtil.getId()); if (isApplicableForTheLocalSite) { switch (event.getAction()) { case UPDATE: @@ -798,7 +800,7 @@ public abstract class EdexBandwidthManager * reinitialize operation. */ private void bandwidthMapConfigurationUpdated() { - IBandwidthRequest request = new IBandwidthRequest(); + BandwidthRequest request = new BandwidthRequest(); request.setRequestType(RequestType.REINITIALIZE); try { diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/InMemoryBandwidthContextFactory.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/InMemoryBandwidthContextFactory.java index 3396acc151..c58424c202 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/InMemoryBandwidthContextFactory.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/InMemoryBandwidthContextFactory.java @@ -33,6 +33,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.dao.IBandwidthDbInit; import com.raytheon.uf.edex.datadelivery.bandwidth.interfaces.BandwidthInitializer; import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalManager; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; +import com.raytheon.uf.edex.registry.ebxml.util.RegistryIdUtil; /** * Implementation of {@link BandwidthContextFactory} that returns DAO classes @@ -47,6 +48,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; * ------------ ---------- ----------- -------------------------- * Oct 24, 2012 1286 djohnson Initial creation * Jun 24, 2013 2106 djohnson Add {@link #getBandwidthBucketDao()}. + * Apr 22, 2014 2992 dhladky Added IdUtil for siteList * * * @@ -123,9 +125,9 @@ class InMemoryBandwidthContextFactory implements BandwidthContextFactory { @Override public IBandwidthManager getBandwidthManager(IBandwidthDbInit dbInit, IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, - BandwidthDaoUtil bandwidthDaoUtil) { + BandwidthDaoUtil bandwidthDaoUtil, RegistryIdUtil idUtil) { return new InMemoryBandwidthManager(dbInit, bandwidthDao, - retrievalManager, bandwidthDaoUtil); + retrievalManager, bandwidthDaoUtil, idUtil); } /** diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/InMemoryBandwidthManager.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/InMemoryBandwidthManager.java index 3e42fc482d..f0e920fd23 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/InMemoryBandwidthManager.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/InMemoryBandwidthManager.java @@ -38,6 +38,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.dao.IBandwidthDbInit; import com.raytheon.uf.edex.datadelivery.bandwidth.interfaces.BandwidthInitializer; import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalManager; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; +import com.raytheon.uf.edex.registry.ebxml.util.RegistryIdUtil; /** * An in-memory {@link IBandwidthManager} that does not communicate with an @@ -59,6 +60,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; * Dec 04, 2013 2566 bgonzale use bandwidthmanager method to retrieve spring files. * Feb 06, 2014 2636 bgonzale added initializeScheduling method. * Feb 12, 2014 2636 mpduff Override getSubscriptionsToSchedule + * Apr 22, 2014 2992 dhladky Added IdUtil for siteList * * * @@ -122,11 +124,12 @@ class InMemoryBandwidthManager extends * @param bandwidthDao * @param retrievalManager * @param bandwidthDaoUtil + * @param IdUtil */ public InMemoryBandwidthManager(IBandwidthDbInit dbInit, IBandwidthDao bandwidthDao, - RetrievalManager retrievalManager, BandwidthDaoUtil bandwidthDaoUtil) { - super(dbInit, bandwidthDao, retrievalManager, bandwidthDaoUtil); + RetrievalManager retrievalManager, BandwidthDaoUtil bandwidthDaoUtil, RegistryIdUtil idUtil) { + super(dbInit, bandwidthDao, retrievalManager, bandwidthDaoUtil, idUtil); } /** diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/WfoBandwidthManagerCreator.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/WfoBandwidthManagerCreator.java index 193edf93ef..cdd3507cf8 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/WfoBandwidthManagerCreator.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/WfoBandwidthManagerCreator.java @@ -43,7 +43,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.dao.IBandwidthDbInit; import com.raytheon.uf.edex.datadelivery.bandwidth.hibernate.IFindSubscriptionsForScheduling; import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalManager; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; -import com.raytheon.uf.edex.datadelivery.util.DataDeliveryIdUtil; +import com.raytheon.uf.edex.registry.ebxml.util.RegistryIdUtil; /** * {@link IEdexBandwidthManagerCreator} for a WFO bandwidth manager. @@ -70,6 +70,7 @@ import com.raytheon.uf.edex.datadelivery.util.DataDeliveryIdUtil; * Jan 14, 2014 2692 dhladky AdhocSubscription handler * Jan 30, 2014 2636 mpduff Scheduling refactor. * Feb 11, 2014 2771 bgonzale Use Data Delivery ID instead of Site. + * Apr 22, 2014 2992 dhladky Added IdUtil for siteList * * * @@ -99,6 +100,7 @@ public class WfoBandwidthManagerCreator * @param bandwidthDao * @param retrievalManager * @param bandwidthDaoUtil + * @param idUtil * @param dataSetMetaDataHandler * @param subscriptionHandler * @param adhocSubscriptionHandler @@ -110,12 +112,13 @@ public class WfoBandwidthManagerCreator IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, BandwidthDaoUtil bandwidthDaoUtil, + RegistryIdUtil idUtil, IDataSetMetaDataHandler dataSetMetaDataHandler, ISubscriptionHandler subscriptionHandler, IAdhocSubscriptionHandler adhocSubscriptionHandler, ISubscriptionNotificationService subscriptionNotificationService, IFindSubscriptionsForScheduling findSubscriptionsStrategy) { - super(dbInit, bandwidthDao, retrievalManager, bandwidthDaoUtil, + super(dbInit, bandwidthDao, retrievalManager, bandwidthDaoUtil, idUtil, dataSetMetaDataHandler, subscriptionHandler, adhocSubscriptionHandler, subscriptionNotificationService, findSubscriptionsStrategy); @@ -137,7 +140,7 @@ public class WfoBandwidthManagerCreator Subscription subscription = getRegistryObjectById( getSubscriptionHandler(), event.getId()); boolean isLocalOrigination = subscription.getOriginatingSite() - .equals(DataDeliveryIdUtil.getId()); + .equals(RegistryIdUtil.getId()); if (isLocalOrigination) { subscriptionUpdated(subscription); @@ -204,13 +207,14 @@ public class WfoBandwidthManagerCreator public IBandwidthManager getBandwidthManager(IBandwidthDbInit dbInit, IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, BandwidthDaoUtil bandwidthDaoUtil, + RegistryIdUtil idUtil, IDataSetMetaDataHandler dataSetMetaDataHandler, ISubscriptionHandler subscriptionHandler, IAdhocSubscriptionHandler adhocSubscriptionHandler, ISubscriptionNotificationService subscriptionNotificationService, IFindSubscriptionsForScheduling findSubscriptionsStrategy) { return new WfoBandwidthManager(dbInit, bandwidthDao, - retrievalManager, bandwidthDaoUtil, dataSetMetaDataHandler, + retrievalManager, bandwidthDaoUtil, idUtil, dataSetMetaDataHandler, subscriptionHandler, adhocSubscriptionHandler, subscriptionNotificationService, findSubscriptionsStrategy); } diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/dao/BandwidthContextFactory.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/dao/BandwidthContextFactory.java index fd16ca21d1..80d8d58da0 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/dao/BandwidthContextFactory.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/dao/BandwidthContextFactory.java @@ -28,6 +28,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.hibernate.HibernateBandwidthD import com.raytheon.uf.edex.datadelivery.bandwidth.interfaces.BandwidthInitializer; import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalManager; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; +import com.raytheon.uf.edex.registry.ebxml.util.RegistryIdUtil; /** * Factory used to produce contextual differences in the @@ -44,6 +45,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; * ------------ ---------- ----------- -------------------------- * Oct 24, 2012 1286 djohnson Initial creation * Jun 24, 2013 2106 djohnson Add {@link #getBandwidthBucketDao()}. + * Apr 22, 2014 2992 dhladky Added IdUtil for siteList * * * @@ -98,9 +100,10 @@ public interface BandwidthContextFactory { * the retrieval manager * @param bandwidthDaoUtil * the dao util instance + * @param RegistryIdUtil finds DD server nodes * @return the {@link BandwidthManager} reference */ IBandwidthManager getBandwidthManager(IBandwidthDbInit dbInit, IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, - BandwidthDaoUtil bandwidthDaoUtil); + BandwidthDaoUtil bandwidthDaoUtil, RegistryIdUtil idUtil); } diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/handler/LocalSiteSubscriptionHandler.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/handler/LocalSiteSubscriptionHandler.java index 830b901dab..dc327e7330 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/handler/LocalSiteSubscriptionHandler.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/handler/LocalSiteSubscriptionHandler.java @@ -23,7 +23,7 @@ import com.raytheon.uf.common.datadelivery.registry.SiteSubscription; import com.raytheon.uf.common.datadelivery.registry.ebxml.SiteSubscriptionQuery; import com.raytheon.uf.common.datadelivery.registry.handlers.SiteSubscriptionHandler; import com.raytheon.uf.common.registry.handler.IRegistryObjectHandler; -import com.raytheon.uf.edex.datadelivery.util.DataDeliveryIdUtil; +import com.raytheon.uf.edex.registry.ebxml.util.RegistryIdUtil; /** * {@link IRegistryObjectHandler} implementation for {@link SiteSubscription}. @@ -52,7 +52,7 @@ public class LocalSiteSubscriptionHandler extends SiteSubscriptionHandler { * Default Constructor. */ public LocalSiteSubscriptionHandler() { - this(DataDeliveryIdUtil.getId()); + this(RegistryIdUtil.getId()); } /** diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/hibernate/HibernateBandwidthInitializer.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/hibernate/HibernateBandwidthInitializer.java index c0c8d6fb46..e8629dac0b 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/hibernate/HibernateBandwidthInitializer.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.bandwidth/src/com/raytheon/uf/edex/datadelivery/bandwidth/hibernate/HibernateBandwidthInitializer.java @@ -13,7 +13,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.IBandwidthManager; import com.raytheon.uf.edex.datadelivery.bandwidth.dao.IBandwidthDbInit; import com.raytheon.uf.edex.datadelivery.bandwidth.interfaces.BandwidthInitializer; import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalManager; -import com.raytheon.uf.edex.datadelivery.util.DataDeliveryIdUtil; +import com.raytheon.uf.edex.registry.ebxml.util.RegistryIdUtil; /** * @@ -60,7 +60,7 @@ public class HibernateBandwidthInitializer implements BandwidthInitializer { */ public HibernateBandwidthInitializer( IFindSubscriptionsForScheduling findSubscriptionsStrategy) { - this(findSubscriptionsStrategy, DataDeliveryIdUtil.getId()); + this(findSubscriptionsStrategy, RegistryIdUtil.getId()); } /** diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.core.feature/feature.xml b/edexOsgi/com.raytheon.uf.edex.datadelivery.core.feature/feature.xml index fc13101211..39a7af36bd 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.core.feature/feature.xml +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.core.feature/feature.xml @@ -88,13 +88,6 @@ version="0.0.0" unpack="false"/> - - subscriptions = request.getSubscriptionList(); List duplicateList = new LinkedList(); SubscriptionOverlapResponse response = new SubscriptionOverlapResponse(); diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery/.classpath b/edexOsgi/com.raytheon.uf.edex.datadelivery/.classpath deleted file mode 100644 index ad32c83a78..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery/.classpath +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery/.project b/edexOsgi/com.raytheon.uf.edex.datadelivery/.project deleted file mode 100644 index 5923a1fb1a..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery/.project +++ /dev/null @@ -1,28 +0,0 @@ - - - com.raytheon.uf.edex.datadelivery - - - - - - org.eclipse.jdt.core.javabuilder - - - - - org.eclipse.pde.ManifestBuilder - - - - - org.eclipse.pde.SchemaBuilder - - - - - - org.eclipse.pde.PluginNature - org.eclipse.jdt.core.javanature - - diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery/.settings/org.eclipse.jdt.core.prefs b/edexOsgi/com.raytheon.uf.edex.datadelivery/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index f13006b4b2..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,8 +0,0 @@ -#Thu Apr 11 12:14:11 CDT 2013 -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 -org.eclipse.jdt.core.compiler.compliance=1.6 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.source=1.6 diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.datadelivery/META-INF/MANIFEST.MF deleted file mode 100644 index 5f539fcc27..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery/META-INF/MANIFEST.MF +++ /dev/null @@ -1,11 +0,0 @@ -Manifest-Version: 1.0 -Bundle-ManifestVersion: 2 -Bundle-Name: Registry -Bundle-SymbolicName: com.raytheon.uf.edex.datadelivery -Bundle-Version: 1.0.0.qualifier -Bundle-Vendor: RAYTHEON -Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -Import-Package: com.raytheon.edex.site, - com.raytheon.uf.common.site, - com.raytheon.uf.common.util -Export-Package: com.raytheon.uf.edex.datadelivery.util diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery/build.properties b/edexOsgi/com.raytheon.uf.edex.datadelivery/build.properties deleted file mode 100644 index 34d2e4d2da..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery/build.properties +++ /dev/null @@ -1,4 +0,0 @@ -source.. = src/ -output.. = bin/ -bin.includes = META-INF/,\ - . diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery/src/.gitignore b/edexOsgi/com.raytheon.uf.edex.datadelivery/src/.gitignore deleted file mode 100644 index d14dd1cd51..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery/src/.gitignore +++ /dev/null @@ -1 +0,0 @@ -# Required to keep the empty directory present \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/res/spring/ebxml-impl.xml b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/res/spring/ebxml-impl.xml index 717407dfbd..0df075866c 100644 --- a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/res/spring/ebxml-impl.xml +++ b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/res/spring/ebxml-impl.xml @@ -56,5 +56,12 @@ + + + + + + diff --git a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/dao/RegistryDao.java b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/dao/RegistryDao.java index b20d05f41b..dc8f2efdc0 100644 --- a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/dao/RegistryDao.java +++ b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/dao/RegistryDao.java @@ -35,7 +35,7 @@ import org.springframework.transaction.annotation.Transactional; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * 5/21/2013 2022 bphillip Initial implementation - * + * * * @author bphillip * @version 1 diff --git a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/dao/RegistryObjectDao.java b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/dao/RegistryObjectDao.java index 3836d3f030..5b60dc71dd 100644 --- a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/dao/RegistryObjectDao.java +++ b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/dao/RegistryObjectDao.java @@ -45,6 +45,7 @@ import com.raytheon.uf.edex.registry.ebxml.exception.EbxmlRegistryException; * 8/1/2013 1693 bphillip Added methods to facilitate implementation of the lifecyclemanager according to the 4.0 spec * 2/13/2014 2769 bphillip Added read only flags to query methods * 4/11/2014 3011 bphillip Changed merge to not delete unused slots + * 4/21/2014 2992 dhladky General list of Registry server nodes. * * * @@ -57,6 +58,9 @@ public class RegistryObjectDao extends /** Delete object type parameterized statement */ private static final String GET_IDS_BY_OBJECT_TYPE = "SELECT regObj.id FROM RegistryObjectType regObj WHERE regObj.objectType=:objectType"; + /** Get the unique list of registry nodes with subscriptions **/ + private static final String QUERY_UNIQUE_REGISTRIES = "SELECT DISTINCT regObj.owner FROM RegistryObjectType regObj WHERE regObj.objectType LIKE "; + /** Query to determine if an object id exists in the registry */ private static final String ID_EXISTS_QUERY = "select count(obj.id) from RegistryObjectType obj where id=:id"; @@ -66,6 +70,8 @@ public class RegistryObjectDao extends /** Query to get all sub versions beneath the given version */ private static String GET_SUB_VERSION_QUERY = "select obj.versionInfo.versionName from RegistryObjectType obj where obj.lid=:lid and obj.versionInfo.versionName like :version"; + private SlotTypeDao slotDao; + /** * Creates a new RegistryObjectDao */ @@ -191,4 +197,18 @@ public class RegistryObjectDao extends return RegistryObjectType.class; } + public void setSlotDao(SlotTypeDao slotDao) { + this.slotDao = slotDao; + } + + /** + * Gets a list of unique registry ID's with data on this node for this objectType. + * @param objectType + * @return + */ + @Transactional(propagation = Propagation.REQUIRED, readOnly = true) + public List getUniqueRegistries(String objectType) { + return this.executeHQLQuery(QUERY_UNIQUE_REGISTRIES+" "+objectType); + } + } diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery/src/com/raytheon/uf/edex/datadelivery/util/DataDeliveryIdUtil.java b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/util/RegistryIdUtil.java similarity index 57% rename from edexOsgi/com.raytheon.uf.edex.datadelivery/src/com/raytheon/uf/edex/datadelivery/util/DataDeliveryIdUtil.java rename to edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/util/RegistryIdUtil.java index 55ce7da142..fca39b1817 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery/src/com/raytheon/uf/edex/datadelivery/util/DataDeliveryIdUtil.java +++ b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/util/RegistryIdUtil.java @@ -17,12 +17,15 @@ * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ -package com.raytheon.uf.edex.datadelivery.util; +package com.raytheon.uf.edex.registry.ebxml.util; + +import java.util.List; import com.raytheon.uf.common.util.ClusterIdUtil; +import com.raytheon.uf.edex.registry.ebxml.dao.RegistryObjectDao; /** - * Common Utility class specifically for Data Delivery that currently just + * Common Utility class specifically for Registry that currently just * returns the Cluster ID. * *
@@ -32,21 +35,43 @@ import com.raytheon.uf.common.util.ClusterIdUtil;
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
  * Feb 06, 2014 2771       bgonzale     Initial creation
+ * Apr 23, 2014 2992       dhladky      General way to get all registries.
  * 
  * 
* * @author bgonzale * @version 1.0 */ -public class DataDeliveryIdUtil { +public class RegistryIdUtil { + // connection to the registry DAO object + private RegistryObjectDao rdo; + + // public constructor + public RegistryIdUtil() { + + } + + // public spring constructor + public RegistryIdUtil(RegistryObjectDao rdo) { + this.rdo = rdo; + } + /** - * Return the Data Delivery ID for this running instance of Data Delivery. + * Return the Registry ID for this running instance of Registry. * - * @return Data Delivery ID. + * @return Registry ID. */ public static String getId() { return ClusterIdUtil.getId(); } - + + /** + * Gets the list of unique registry nodes that have data in this node. + * @return + */ + public List getUniqueRegistries(String objectType) { + return rdo.getUniqueRegistries(objectType); + } + } diff --git a/tests/.classpath b/tests/.classpath index 497a20cda6..a9b0fefae7 100644 --- a/tests/.classpath +++ b/tests/.classpath @@ -162,5 +162,6 @@ + diff --git a/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/IntegrationTestWfoBandwidthManager.java b/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/IntegrationTestWfoBandwidthManager.java index 79c52878c2..3d4ab619f9 100644 --- a/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/IntegrationTestWfoBandwidthManager.java +++ b/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/IntegrationTestWfoBandwidthManager.java @@ -31,6 +31,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.dao.IBandwidthDbInit; import com.raytheon.uf.edex.datadelivery.bandwidth.hibernate.IFindSubscriptionsForScheduling; import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalManager; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; +import com.raytheon.uf.edex.datadelivery.util.DataDeliveryIdUtil; /** * A WFO {@link IBandwidthManager} that runs as an integration test, outside of @@ -76,12 +77,13 @@ public class IntegrationTestWfoBandwidthManager extends WfoBandwidthManager { public IntegrationTestWfoBandwidthManager(IBandwidthDbInit dbInit, IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, BandwidthDaoUtil bandwidthDaoUtil, + DataDeliveryIdUtil idUtil, IDataSetMetaDataHandler dataSetMetaDataHandler, ISubscriptionHandler subscriptionHandler, IAdhocSubscriptionHandler adhocSubscriptionHandler, ISubscriptionNotificationService subscriptionNotificationService, IFindSubscriptionsForScheduling findSubscriptionStrategy) { - super(dbInit, bandwidthDao, retrievalManager, bandwidthDaoUtil, + super(dbInit, bandwidthDao, retrievalManager, bandwidthDaoUtil, idUtil, dataSetMetaDataHandler, subscriptionHandler, adhocSubscriptionHandler, subscriptionNotificationService, findSubscriptionStrategy); diff --git a/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/IntegrationTestWfoBandwidthManagerCreator.java b/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/IntegrationTestWfoBandwidthManagerCreator.java index 74d211bbaa..2439b7e880 100644 --- a/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/IntegrationTestWfoBandwidthManagerCreator.java +++ b/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/IntegrationTestWfoBandwidthManagerCreator.java @@ -29,6 +29,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.dao.IBandwidthDbInit; import com.raytheon.uf.edex.datadelivery.bandwidth.hibernate.IFindSubscriptionsForScheduling; import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalManager; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; +import com.raytheon.uf.edex.datadelivery.util.DataDeliveryIdUtil; /** * Creates {@link IntegrationTestWfoBandwidthManager} instances. @@ -60,13 +61,14 @@ public class IntegrationTestWfoBandwidthManagerCreator implements public IBandwidthManager getBandwidthManager(IBandwidthDbInit dbInit, IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, BandwidthDaoUtil bandwidthDaoUtil, + DataDeliveryIdUtil idUtil, IDataSetMetaDataHandler dataSetMetaDataHandler, ISubscriptionHandler subscriptionHandler, IAdhocSubscriptionHandler adhocSubscriptionHandler, ISubscriptionNotificationService subscriptionNotificationService, IFindSubscriptionsForScheduling findSubscriptionStrategy) { return new IntegrationTestWfoBandwidthManager(dbInit, bandwidthDao, - retrievalManager, bandwidthDaoUtil, dataSetMetaDataHandler, + retrievalManager, bandwidthDaoUtil, idUtil, dataSetMetaDataHandler, subscriptionHandler, adhocSubscriptionHandler, subscriptionNotificationService, findSubscriptionStrategy); } diff --git a/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/WfoBandwidthManagerIntTest.java b/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/WfoBandwidthManagerIntTest.java index 00eb2795f5..e33008f84d 100644 --- a/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/WfoBandwidthManagerIntTest.java +++ b/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/WfoBandwidthManagerIntTest.java @@ -21,8 +21,8 @@ package com.raytheon.uf.edex.datadelivery.bandwidth; import org.junit.Test; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest.RequestType; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest.RequestType; import com.raytheon.uf.common.datadelivery.registry.Network; import com.raytheon.uf.common.datadelivery.registry.Subscription; @@ -80,7 +80,7 @@ public class WfoBandwidthManagerIntTest extends @Test public void testReinitializeUsesCorrectSpringFiles() throws Exception { - final IBandwidthRequest request = new IBandwidthRequest(); + final BandwidthRequest request = new BandwidthRequest(); request.setRequestType(RequestType.REINITIALIZE); bandwidthManager.handleRequest(request); diff --git a/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/WfoNcfBandwidthManagerIntTest.java b/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/WfoNcfBandwidthManagerIntTest.java index 240fefe26d..728fe9f288 100644 --- a/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/WfoNcfBandwidthManagerIntTest.java +++ b/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/WfoNcfBandwidthManagerIntTest.java @@ -31,8 +31,8 @@ import org.junit.Test; import org.springframework.context.ApplicationContext; import org.springframework.context.support.ClassPathXmlApplicationContext; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest.RequestType; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest.RequestType; import com.raytheon.uf.common.datadelivery.registry.Network; import com.raytheon.uf.common.datadelivery.registry.Subscription; import com.raytheon.uf.common.datadelivery.request.DataDeliveryConstants; @@ -101,7 +101,7 @@ public class WfoNcfBandwidthManagerIntTest extends public Object route(IServerRequest request) throws Exception { return ncfBandwidthManager - .handleRequest((IBandwidthRequest) request); + .handleRequest((BandwidthRequest) request); } }); } catch (RegistryException e) { @@ -217,7 +217,7 @@ public class WfoNcfBandwidthManagerIntTest extends */ private void scheduleSbnSubscription(Subscription subscription, RequestType requestType) throws Exception { - IBandwidthRequest request = new IBandwidthRequest(); + BandwidthRequest request = new BandwidthRequest(); request.setRequestType(requestType); request.setNetwork(subscription.getRoute()); request.setSubscriptions(Arrays.asList(subscription)); diff --git a/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/IntegrationTestNcfBandwidthManager.java b/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/IntegrationTestNcfBandwidthManager.java index a71ce1b6f2..8a5eb559bc 100644 --- a/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/IntegrationTestNcfBandwidthManager.java +++ b/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/IntegrationTestNcfBandwidthManager.java @@ -32,6 +32,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.hibernate.IFindSubscriptionsF import com.raytheon.uf.edex.datadelivery.bandwidth.ncf.NcfBandwidthManagerCreator.NcfBandwidthManager; import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalManager; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; +import com.raytheon.uf.edex.datadelivery.util.DataDeliveryIdUtil; /** * An NCF {@link IBandwidthManager} that runs as an integration test, outside of @@ -76,12 +77,13 @@ public class IntegrationTestNcfBandwidthManager extends NcfBandwidthManager { public IntegrationTestNcfBandwidthManager(IBandwidthDbInit dbInit, IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, BandwidthDaoUtil bandwidthDaoUtil, + DataDeliveryIdUtil idUtil, IDataSetMetaDataHandler dataSetMetaDataHandler, ISubscriptionHandler subscriptionHandler, IAdhocSubscriptionHandler adhocSubscriptionHandler, ISubscriptionNotificationService subscriptionNotificationService, IFindSubscriptionsForScheduling findSubscriptionStrategy) { - super(dbInit, bandwidthDao, retrievalManager, bandwidthDaoUtil, + super(dbInit, bandwidthDao, retrievalManager, bandwidthDaoUtil, idUtil, dataSetMetaDataHandler, subscriptionHandler, adhocSubscriptionHandler, subscriptionNotificationService, findSubscriptionStrategy); diff --git a/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/IntegrationTestNcfBandwidthManagerCreator.java b/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/IntegrationTestNcfBandwidthManagerCreator.java index 1be425b45e..f02cd083e2 100644 --- a/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/IntegrationTestNcfBandwidthManagerCreator.java +++ b/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/IntegrationTestNcfBandwidthManagerCreator.java @@ -30,6 +30,7 @@ import com.raytheon.uf.edex.datadelivery.bandwidth.dao.IBandwidthDbInit; import com.raytheon.uf.edex.datadelivery.bandwidth.hibernate.IFindSubscriptionsForScheduling; import com.raytheon.uf.edex.datadelivery.bandwidth.retrieval.RetrievalManager; import com.raytheon.uf.edex.datadelivery.bandwidth.util.BandwidthDaoUtil; +import com.raytheon.uf.edex.datadelivery.util.DataDeliveryIdUtil; /** * Creates {@link IntegrationTestNcfBandwidthManager} instances. @@ -61,13 +62,14 @@ public class IntegrationTestNcfBandwidthManagerCreator implements public IBandwidthManager getBandwidthManager(IBandwidthDbInit dbInit, IBandwidthDao bandwidthDao, RetrievalManager retrievalManager, BandwidthDaoUtil bandwidthDaoUtil, + DataDeliveryIdUtil idUtil, IDataSetMetaDataHandler dataSetMetaDataHandler, ISubscriptionHandler subscriptionHandler, IAdhocSubscriptionHandler adhocSubscriptionHandler, ISubscriptionNotificationService subscriptionNotificationService, IFindSubscriptionsForScheduling findSubscriptionStrategy) { return new IntegrationTestNcfBandwidthManager(dbInit, bandwidthDao, - retrievalManager, bandwidthDaoUtil, dataSetMetaDataHandler, + retrievalManager, bandwidthDaoUtil, idUtil, dataSetMetaDataHandler, subscriptionHandler, adhocSubscriptionHandler, subscriptionNotificationService, findSubscriptionStrategy); } diff --git a/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/NcfBandwidthManagerIntTest.java b/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/NcfBandwidthManagerIntTest.java index 31fcc278c6..b0d16e5d56 100644 --- a/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/NcfBandwidthManagerIntTest.java +++ b/tests/integration/com/raytheon/uf/edex/datadelivery/bandwidth/ncf/NcfBandwidthManagerIntTest.java @@ -22,8 +22,8 @@ package com.raytheon.uf.edex.datadelivery.bandwidth.ncf; import org.junit.Test; import org.springframework.test.context.ContextConfiguration; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest.RequestType; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest.RequestType; import com.raytheon.uf.common.datadelivery.registry.Network; import com.raytheon.uf.common.datadelivery.registry.Subscription; import com.raytheon.uf.common.util.SpringFiles; @@ -82,7 +82,7 @@ public class NcfBandwidthManagerIntTest extends AbstractBandwidthManagerIntTest @Test public void testReinitializeUsesCorrectSpringFiles() throws Exception { - final IBandwidthRequest request = new IBandwidthRequest(); + final BandwidthRequest request = new BandwidthRequest(); request.setRequestType(RequestType.REINITIALIZE); bandwidthManager.handleRequest(request); diff --git a/tests/unit/com/raytheon/uf/edex/auth/RemoteServerRequestRouterTest.java b/tests/unit/com/raytheon/uf/edex/auth/RemoteServerRequestRouterTest.java index a105279e4a..4eb7cf5d9d 100644 --- a/tests/unit/com/raytheon/uf/edex/auth/RemoteServerRequestRouterTest.java +++ b/tests/unit/com/raytheon/uf/edex/auth/RemoteServerRequestRouterTest.java @@ -25,7 +25,7 @@ import static org.junit.Assert.assertNotNull; import org.junit.Test; import com.raytheon.uf.common.comm.CommunicationException; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest; import com.raytheon.uf.common.localization.msgs.GetServersRequest; import com.raytheon.uf.common.serialization.SerializationUtil; import com.raytheon.uf.edex.auth.req.ServerPrivilegedRequestHandler.ServerPrivilegedRequest; @@ -48,7 +48,7 @@ import com.raytheon.uf.edex.auth.req.ServerPrivilegedRequestHandler.ServerPrivil */ public class RemoteServerRequestRouterTest { - private static final IBandwidthRequest PRIVILEGED_REQUEST = new IBandwidthRequest(); + private static final BandwidthRequest PRIVILEGED_REQUEST = new BandwidthRequest(); private static final GetServersRequest UNPRIVILEGED_REQUEST = new GetServersRequest(); diff --git a/tests/unit/com/raytheon/uf/edex/auth/ServerRequestRouterTest.java b/tests/unit/com/raytheon/uf/edex/auth/ServerRequestRouterTest.java index a7ce6867c3..9c981430ed 100644 --- a/tests/unit/com/raytheon/uf/edex/auth/ServerRequestRouterTest.java +++ b/tests/unit/com/raytheon/uf/edex/auth/ServerRequestRouterTest.java @@ -27,7 +27,7 @@ import static org.mockito.Mockito.when; import org.junit.Before; import org.junit.Test; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest; import com.raytheon.uf.common.localization.msgs.GetServersRequest; import com.raytheon.uf.common.serialization.comm.IRequestHandler; import com.raytheon.uf.edex.auth.req.ServerPrivilegedRequestHandler; @@ -54,7 +54,7 @@ public class ServerRequestRouterTest { private static final ServerRequestRouter ROUTER = new ServerRequestRouter(); - private static final IBandwidthRequest PRIVILEGED_REQUEST = new IBandwidthRequest(); + private static final BandwidthRequest PRIVILEGED_REQUEST = new BandwidthRequest(); private static final GetServersRequest UNPRIVILEGED_REQUEST = new GetServersRequest(); diff --git a/tests/unit/com/raytheon/uf/edex/auth/req/ServerPrivilegedRequestHandlerTest.java b/tests/unit/com/raytheon/uf/edex/auth/req/ServerPrivilegedRequestHandlerTest.java index ead193d916..30c6a70945 100644 --- a/tests/unit/com/raytheon/uf/edex/auth/req/ServerPrivilegedRequestHandlerTest.java +++ b/tests/unit/com/raytheon/uf/edex/auth/req/ServerPrivilegedRequestHandlerTest.java @@ -31,7 +31,7 @@ import org.junit.Before; import org.junit.Test; import com.raytheon.uf.common.auth.resp.SuccessfulExecution; -import com.raytheon.uf.common.datadelivery.bandwidth.IBandwidthRequest; +import com.raytheon.uf.common.datadelivery.bandwidth.BandwidthRequest; import com.raytheon.uf.common.localization.msgs.GetServersRequest; import com.raytheon.uf.common.serialization.comm.IRequestHandler; import com.raytheon.uf.common.serialization.comm.IServerRequest; @@ -58,7 +58,7 @@ import com.raytheon.uf.edex.auth.req.ServerPrivilegedRequestHandler.ServerPrivil @SuppressWarnings({ "unchecked", "rawtypes" }) public class ServerPrivilegedRequestHandlerTest { - private static final IBandwidthRequest BANDWIDTH_REQUEST = new IBandwidthRequest(); + private static final BandwidthRequest BANDWIDTH_REQUEST = new BandwidthRequest(); private final HandlerRegistry registry = mock(HandlerRegistry.class); @@ -72,7 +72,7 @@ public class ServerPrivilegedRequestHandlerTest { RemoteRequestServer.getInstance().setRegistry(registry); when( - registry.getRequestHandler(IBandwidthRequest.class + registry.getRequestHandler(BandwidthRequest.class .getCanonicalName())).thenReturn(bandwidthHandler); } diff --git a/tests/unit/com/raytheon/uf/edex/datadelivery/retrieval/metadata/adapters/MockGridMetaDataAdapter.java b/tests/unit/com/raytheon/uf/edex/datadelivery/retrieval/metadata/adapters/MockGridMetaDataAdapter.java index 0afbcce386..9a96c6d452 100644 --- a/tests/unit/com/raytheon/uf/edex/datadelivery/retrieval/metadata/adapters/MockGridMetaDataAdapter.java +++ b/tests/unit/com/raytheon/uf/edex/datadelivery/retrieval/metadata/adapters/MockGridMetaDataAdapter.java @@ -58,7 +58,7 @@ public class MockGridMetaDataAdapter extends GridMetadataAdapter { /** * {@inheritDoc} */ - @Override + GridCoverage getCoverageFromCache(GridCoverage coverage) { return GriddedCoverageFixture.INSTANCE.get().getGridCoverage(); } From 873efa1c64c48e5c03bf6034888c91970d680852 Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Wed, 30 Apr 2014 17:49:10 -0500 Subject: [PATCH 131/188] Issue #2903 set commons.lang to unpack in feature to fix odd bug collaboration gets in a state where commons.lang is no longer found setting unpack to true might help Former-commit-id: b27a714c2cbdf2f13eb0c494ace4cbd016ef8132 --- cave/com.raytheon.uf.viz.feature.alertviz/feature.xml | 2 +- edexOsgi/com.raytheon.uf.common.base.feature/feature.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cave/com.raytheon.uf.viz.feature.alertviz/feature.xml b/cave/com.raytheon.uf.viz.feature.alertviz/feature.xml index 4d855cc26d..03f21489d5 100644 --- a/cave/com.raytheon.uf.viz.feature.alertviz/feature.xml +++ b/cave/com.raytheon.uf.viz.feature.alertviz/feature.xml @@ -453,7 +453,7 @@ download-size="0" install-size="0" version="0.0.0" - unpack="false"/> + unpack="true"/> + unpack="true"/> Date: Thu, 1 May 2014 08:48:38 -0500 Subject: [PATCH 132/188] Issue #2992 Missed perl script Former-commit-id: b2c19dd8cfa3eee138f2b9abf7289d464d94ef46 --- .../datadelivery/updateSubscriptionOwners.pl | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 deltaScripts/14.3.1/datadelivery/updateSubscriptionOwners.pl diff --git a/deltaScripts/14.3.1/datadelivery/updateSubscriptionOwners.pl b/deltaScripts/14.3.1/datadelivery/updateSubscriptionOwners.pl new file mode 100644 index 0000000000..5c4ef198ae --- /dev/null +++ b/deltaScripts/14.3.1/datadelivery/updateSubscriptionOwners.pl @@ -0,0 +1,24 @@ +#!/usr/bin/perl + +open (IN, $ARGV[0]); +print $ARGV[0]; +@lines = ; +close IN; +$site = ""; +foreach $line (@lines) { + if ($line =~ /originatingSite="([\w]+)"/) { + $site = $1; + } +} + +foreach $line (@lines) { +if ($line =~ s/owner="([\w]+)"/owner="$site"/g) { +print $line; +} +} +$OUTFILE = "TEMP"; +open (OUT, ">>TEMP"); +foreach $line (@lines) { +print OUT $line; +} +rename $OUTFILE, $ARGV[0] \ No newline at end of file From 74dc7a5d7c2dfa500f233187464fec74eca15e4a Mon Sep 17 00:00:00 2001 From: "Gang.Zhang" Date: Thu, 1 May 2014 15:44:44 +0100 Subject: [PATCH 133/188] ASM #507 - Fix incorrect FFMP gap calculation Change-Id: Iecfdcaa07aca79b0e17396a794851cec0e6cba25 Former-commit-id: 9b33d5187b4535d5500762e15e35e89ccbf5f5da --- .../uf/viz/monitor/ffmp/ui/rsc/FFMPResource.java | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPResource.java b/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPResource.java index c778f99e98..0cc2ae4b1c 100644 --- a/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPResource.java +++ b/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPResource.java @@ -176,6 +176,7 @@ import com.vividsolutions.jts.geom.Point; * Jan 21, 2014 DR 15874 gzhang Use getValue() for QPFSCAN independent. * Feb 19, 2014 2819 randerso Removed unnecessary .clone() call * Mar 3, 2014 2804 mschenke Set back up clipping pane + * Apr 30, 2014 DR 16148 gzhang Filter Basin Dates for Trend and Table Gap. * * * @author dhladky @@ -3102,6 +3103,9 @@ public class FFMPResource extends boolean guid = false; Date oldestRefTime = getOldestTime(); Date mostRecentRefTime = getPaintTime().getRefTime(); + + Date barrierTime = getTableTime();// DR 16148 + Date minUriTime = getTimeOrderedKeys().get(0);// DR 16148 // grabs the basins we need try { @@ -3114,7 +3118,10 @@ public class FFMPResource extends if (rateBasin != null) { for (Date date : rateBasin.getValues().keySet()) { - + + if (date.before(minUriTime) || date.before(barrierTime) || date.after(mostRecentRefTime)) + continue;// DR 16148 + double dtime = FFMPGuiUtils.getTimeDiff(mostRecentRefTime, date); fgd.setRate(dtime, (double) rateBasin.getValue(date)); @@ -3139,6 +3146,9 @@ public class FFMPResource extends if (qpeBasin != null) { for (Date date : qpeBasin.getValues().keySet()) { + + if (date.before(minUriTime) || date.before(barrierTime) || date.after(mostRecentRefTime)) + continue;// DR 16148 double dtime = FFMPGuiUtils.getTimeDiff(mostRecentRefTime, date); From 2a0775e748a7f4c44c8950333bde07e3bdb8d242 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Thu, 1 May 2014 11:01:37 -0500 Subject: [PATCH 134/188] Issue #3101 safe cast numpy shape values to Number Change-Id: Ie81917cf19819e159195a50d6ad786d20c32136c Former-commit-id: 8df8db0d9b9cc0848bf73a09bcedb8cb7947a4bb --- .../uf/common/derivparam/python/MasterDerivScript.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.derivparam.python/src/com/raytheon/uf/common/derivparam/python/MasterDerivScript.java b/edexOsgi/com.raytheon.uf.common.derivparam.python/src/com/raytheon/uf/common/derivparam/python/MasterDerivScript.java index c79002c7d5..b15aed389a 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam.python/src/com/raytheon/uf/common/derivparam/python/MasterDerivScript.java +++ b/edexOsgi/com.raytheon.uf.common.derivparam.python/src/com/raytheon/uf/common/derivparam/python/MasterDerivScript.java @@ -51,6 +51,7 @@ import com.raytheon.uf.common.python.PythonInterpreter; * Nov 21, 2009 3576 rjpeter Refactored to populate DerivParamDesc. * Oct 29, 2013 2476 njensen Renamed numeric methods to numpy * Apr 11, 2014 2947 bsteffen Allow returning NaN + * May 01, 2014 3101 njensen Safe cast result shape values to Number * * * @@ -370,8 +371,8 @@ public class MasterDerivScript extends PythonInterpreter { long[] dims = new long[nDims]; for (int i = 0; i < nDims; i++) { - dims[i] = ((Integer) jep.getValue("numpy.shape(" + RESULT + ")[" - + i + "]")).longValue(); + dims[i] = ((Number) jep.getValue("numpy.shape(" + RESULT + ")[" + i + + "]")).longValue(); } if (dims.length == 2) { From 5eac78f0e08e0c682c0271a75355180ba4a71b51 Mon Sep 17 00:00:00 2001 From: Bryan Kowal Date: Thu, 1 May 2014 12:12:02 -0500 Subject: [PATCH 135/188] Issue #3099 - handle empty location name lists in the data request Former-commit-id: 79603ec579d6ebcd1ef707f637e1b207ae18f803 --- .../dataplugin/ffmp/dataaccess/FFMPGeometryFactory.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.ffmp/src/com/raytheon/uf/common/dataplugin/ffmp/dataaccess/FFMPGeometryFactory.java b/edexOsgi/com.raytheon.uf.common.dataplugin.ffmp/src/com/raytheon/uf/common/dataplugin/ffmp/dataaccess/FFMPGeometryFactory.java index 9618dfee52..51862f783c 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.ffmp/src/com/raytheon/uf/common/dataplugin/ffmp/dataaccess/FFMPGeometryFactory.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.ffmp/src/com/raytheon/uf/common/dataplugin/ffmp/dataaccess/FFMPGeometryFactory.java @@ -66,6 +66,8 @@ import com.vividsolutions.jts.geom.Geometry; * Jul 15, 2013 2184 dhladky Remove all HUC's for storage except ALL * Aug,20, 2013 2250 mnash Change some methods that were not working in all cases * Jan,14, 2014 2667 mnash Remove getGridData method + * May 1, 2014 3099 bkowal No longer use an empty pfaf list when the + * data request locationNames list is empty. * * * @@ -219,7 +221,7 @@ public class FFMPGeometryFactory extends AbstractDataPluginFactory { String[] locationNames = request.getLocationNames(); List pfafList = null; - if (locationNames != null) { + if (locationNames != null && locationNames.length > 0) { pfafList = convertLocations(locationNames); } From 3ca4f8cc52fa6e956a260ca43d0f6e570c0105e7 Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Thu, 1 May 2014 12:34:09 -0500 Subject: [PATCH 136/188] Issue #2903 changed commons.lang to match other unpacking foss Former-commit-id: ee24eaf54704dcfdf698089a8269e055f7856c80 --- cave/com.raytheon.uf.viz.feature.alertviz/feature.xml | 3 +-- edexOsgi/com.raytheon.uf.common.base.feature/feature.xml | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/cave/com.raytheon.uf.viz.feature.alertviz/feature.xml b/cave/com.raytheon.uf.viz.feature.alertviz/feature.xml index 03f21489d5..f2c6542a38 100644 --- a/cave/com.raytheon.uf.viz.feature.alertviz/feature.xml +++ b/cave/com.raytheon.uf.viz.feature.alertviz/feature.xml @@ -452,8 +452,7 @@ id="org.apache.commons.lang" download-size="0" install-size="0" - version="0.0.0" - unpack="true"/> + version="0.0.0"/> + version="2.3.0"/> Date: Thu, 1 May 2014 14:41:23 -0500 Subject: [PATCH 137/188] Issue #2854: Fix features. Change-Id: Iab5371d51b5a582387bfd9a8ef8bdd595d1dd0fe Former-commit-id: 0d675fd5b0fdb0adceef0052adaf31c1c9a7911b --- cave/com.raytheon.uf.viz.application.feature/feature.xml | 7 ------- cave/com.raytheon.uf.viz.archive.feature/feature.xml | 3 +-- 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/cave/com.raytheon.uf.viz.application.feature/feature.xml b/cave/com.raytheon.uf.viz.application.feature/feature.xml index 4d17db91fa..d324c28ec6 100644 --- a/cave/com.raytheon.uf.viz.application.feature/feature.xml +++ b/cave/com.raytheon.uf.viz.application.feature/feature.xml @@ -209,11 +209,4 @@ version="0.0.0" unpack="false"/> - - diff --git a/cave/com.raytheon.uf.viz.archive.feature/feature.xml b/cave/com.raytheon.uf.viz.archive.feature/feature.xml index 6b25bdef69..69a8103635 100644 --- a/cave/com.raytheon.uf.viz.archive.feature/feature.xml +++ b/cave/com.raytheon.uf.viz.archive.feature/feature.xml @@ -40,7 +40,6 @@ id="org.apache.commons.compress" download-size="0" install-size="0" - version="0.0.0" - unpack="false"/> + version="0.0.0"/> From 137818d03ae29182303bb4d7f959a80811caf7cc Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Thu, 1 May 2014 16:20:35 -0500 Subject: [PATCH 138/188] Issue #2956 remove unsafe glMultiDrawArrays(), undo previous change Change-Id: I25bd1305568d26940b69565f53a06661955f240b Former-commit-id: 6f8ef50f7cf8f245f749bf8ff9dbcc33a1d64d64 --- .../core/gl/internal/GLShadedShapeBase.java | 25 ++++--------------- .../viz/core/gl/internal/GLTarget.java | 3 +-- 2 files changed, 6 insertions(+), 22 deletions(-) diff --git a/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLShadedShapeBase.java b/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLShadedShapeBase.java index 75c7c8c6b6..0961b96f03 100644 --- a/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLShadedShapeBase.java +++ b/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLShadedShapeBase.java @@ -41,7 +41,6 @@ import org.opengis.referencing.operation.TransformException; import com.raytheon.uf.common.geospatial.TransformFactory; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.viz.core.drawables.IShape; -import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.viz.core.gl.Activator; import com.vividsolutions.jts.geom.Coordinate; import com.vividsolutions.jts.geom.LineString; @@ -61,6 +60,7 @@ import com.vividsolutions.jts.geom.LineString; * Apr 25, 2013 1954 bsteffen Speed up creation of * GLColormapShadedShapes. * Apr 15, 2014 2956 njensen Safety check of buffers before glMultiDrawArray + * May 01, 2014 2956 njensen Removed unsafe glMultiDrawArrays() * * * @@ -318,8 +318,7 @@ public class GLShadedShapeBase implements IShape { } protected synchronized void paint(GL gl, - boolean cardSupportsHighEndFeatures, float brightness) - throws VizException { + boolean cardSupportsHighEndFeatures, float brightness) { if (!polygons.isEmpty()) { compile(); } @@ -357,23 +356,9 @@ public class GLShadedShapeBase implements IShape { } else { contourLengthBuffer.rewind(); contourStartBuffer.rewind(); - if (cardSupportsHighEndFeatures) { - if (contourStartBuffer.capacity() > 0 - && contourLengthBuffer.capacity() > 0) { - gl.glMultiDrawArrays(GL.GL_POLYGON, contourStartBuffer, - contourLengthBuffer, contourLengthBuffer.capacity()); - } else { - throw new VizException( - "Dangerous parameters passed to glMultiDrawArrays: contourStartBufferCapacity=" - + contourStartBuffer.capacity() - + ", contourLengthBufferCapacity=" - + contourLengthBuffer.capacity()); - } - } else { - while (contourLengthBuffer.hasRemaining()) { - gl.glDrawArrays(GL.GL_POLYGON, contourStartBuffer.get(), - contourLengthBuffer.get()); - } + while (contourLengthBuffer.hasRemaining()) { + gl.glDrawArrays(GL.GL_POLYGON, contourStartBuffer.get(), + contourLengthBuffer.get()); } } diff --git a/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLTarget.java b/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLTarget.java index 19a06fe834..5ba729b223 100644 --- a/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLTarget.java +++ b/cave/com.raytheon.viz.core.gl/src/com/raytheon/viz/core/gl/internal/GLTarget.java @@ -144,7 +144,6 @@ import com.sun.opengl.util.j2d.TextRenderer; * if changed * Apr 04, 2014 2920 bsteffen Allow strings to use mulitple styles. * Apr 08, 2014 2950 bsteffen Reduce oversized colormaps. - * Apr 15, 2014 2956 njensen Throw VizException from drawShadedShapesInternal * * * @@ -837,7 +836,7 @@ public class GLTarget extends AbstractGraphicsTarget implements IGLTarget { } private void drawShadedShapesInternal(List shapes, - float alpha, float brightness) throws VizException { + float alpha, float brightness) { brightness = Math.max(brightness, 0.0f); brightness = Math.min(brightness, 1.0f); From f4d20c41f4716e63ebe2ced0f7ebc5d1998d7019 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Thu, 1 May 2014 16:28:16 -0500 Subject: [PATCH 139/188] Issue #2956 more safety checks Change-Id: I3984fa2b534b16b2e4485e1f66d65f8df48b2e4e Former-commit-id: a24190f35b87351a5f699ac05041bec7a13a1cdb --- .../ui/editor/CollaborationPaneManager.java | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/editor/CollaborationPaneManager.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/editor/CollaborationPaneManager.java index fb0b40c538..8b88ba67e1 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/editor/CollaborationPaneManager.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/editor/CollaborationPaneManager.java @@ -53,6 +53,7 @@ import com.raytheon.viz.ui.panes.VizDisplayPane; * ------------ ---------- ----------- -------------------------- * Jun 07, 2012 mschenke Initial creation * Apr 23, 2014 3060 njensen Safety checks for SWT widgets disposed + * May 01, 2014 2956 njensen More safety checks for SWT widgets disposed * * * @@ -242,7 +243,9 @@ public class CollaborationPaneManager extends PaneManager { public void setCanvasSize(IRenderableDisplay display, Rectangle bounds) { DisplayData data = displayMap.get(display); - if (data == null) { + if (data == null || data.canvasComp.isDisposed() + || data.scrollable.isDisposed() + || data.wrapperComp.isDisposed()) { return; } data.canvasBounds = bounds; @@ -273,9 +276,11 @@ public class CollaborationPaneManager extends PaneManager { } private void setExclude(DisplayData data, boolean exclude) { - GridData gd = (GridData) data.scrollable.getLayoutData(); - data.scrollable.setVisible(!exclude); - gd.exclude = exclude; + if (!data.scrollable.isDisposed()) { + GridData gd = (GridData) data.scrollable.getLayoutData(); + data.scrollable.setVisible(!exclude); + gd.exclude = exclude; + } } } From a9b088146ca3c5abb3f714e3cbd940405c3d9272 Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Thu, 1 May 2014 16:27:48 -0500 Subject: [PATCH 140/188] Issue #2854: Pack commons.lang for alertviz Change-Id: Ib6eb59c6cbdb5b52acc051aec4339445fdc14166 Former-commit-id: 7d69b9fdc60b0c07121eab0119cf45b1624653cd --- cave/com.raytheon.uf.viz.feature.alertviz/feature.xml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cave/com.raytheon.uf.viz.feature.alertviz/feature.xml b/cave/com.raytheon.uf.viz.feature.alertviz/feature.xml index f2c6542a38..4d855cc26d 100644 --- a/cave/com.raytheon.uf.viz.feature.alertviz/feature.xml +++ b/cave/com.raytheon.uf.viz.feature.alertviz/feature.xml @@ -452,7 +452,8 @@ id="org.apache.commons.lang" download-size="0" install-size="0" - version="0.0.0"/> + version="0.0.0" + unpack="false"/> Date: Thu, 1 May 2014 15:15:16 -0500 Subject: [PATCH 141/188] Issue #3095 Update JGridData for creation of numeric java package. Former-commit-id: a3081bf46908788e78c707bf51e08f6c98d997bc --- .../base/python/time/DataTime.py | 7 +++-- .../base/python/dataaccess/JGridData.py | 28 +++++++++++-------- 2 files changed, 21 insertions(+), 14 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.time/utility/common_static/base/python/time/DataTime.py b/edexOsgi/com.raytheon.uf.common.time/utility/common_static/base/python/time/DataTime.py index 0bedba6203..e0130d5049 100644 --- a/edexOsgi/com.raytheon.uf.common.time/utility/common_static/base/python/time/DataTime.py +++ b/edexOsgi/com.raytheon.uf.common.time/utility/common_static/base/python/time/DataTime.py @@ -28,6 +28,7 @@ # Date Ticket# Engineer Description # ------------ ---------- ----------- -------------------------- # 12/12/12 njensen Initial Creation. +# 05/01/14 3095 bsteffen Don't default fcstTime to 0 in init. # # # @@ -38,7 +39,7 @@ from com.raytheon.uf.common.time import DataTime as JavaDataTime class DataTime(JUtil.JavaWrapperClass): - def __init__(self, dtime, fcstTime=0): + def __init__(self, dtime, fcstTime=None): if isinstance(dtime, AbsTime.AbsTime): self.__dt = JavaDataTime(dtime.toJavaObj()) elif isinstance(dtime, str): @@ -47,8 +48,8 @@ class DataTime(JUtil.JavaWrapperClass): # assuming Java object self.__dt = dtime # TODO add support for other possible types of dtime? - - self.__dt.setFcstTime(fcstTime) + if fcstTime is not None: + self.__dt.setFcstTime(fcstTime) def __eq__(self, other): return self.__dt.equals(other.toJavaObj()) diff --git a/edexOsgi/com.raytheon.uf.edex.dataaccess/utility/common_static/base/python/dataaccess/JGridData.py b/edexOsgi/com.raytheon.uf.edex.dataaccess/utility/common_static/base/python/dataaccess/JGridData.py index c8ee7ff32b..1901b10349 100644 --- a/edexOsgi/com.raytheon.uf.edex.dataaccess/utility/common_static/base/python/dataaccess/JGridData.py +++ b/edexOsgi/com.raytheon.uf.edex.dataaccess/utility/common_static/base/python/dataaccess/JGridData.py @@ -28,14 +28,19 @@ # Date Ticket# Engineer Description # ------------ ---------- ----------- -------------------------- # 12/10/12 njensen Initial Creation. +# 05/01/14 3095 bsteffen Move numeric data access to new plugin. + # # # from ufpy.dataaccess import IGridData import JData +from jep import jarray -from com.raytheon.uf.common.geospatial.interpolation.data import FloatArrayWrapper, UnitConvertingDataDestination +from com.raytheon.uf.common.numeric.buffer import FloatBufferWrapper +from com.raytheon.uf.common.geospatial.data import UnitConvertingDataFilter +from com.raytheon.uf.common.numeric.dest import FilteredDataDestination from com.raytheon.uf.common.python import PythonNumpyFloatArray from com.raytheon.uf.common.geospatial import LatLonReprojection from javax.measure.unit import UnitFormat @@ -64,21 +69,22 @@ class JGridData(IGridData, JData.JData): return str(self.jobj.getUnit()) def getRawData(self, unit=None): - dest = FloatArrayWrapper(self.jobj.getGridGeometry()) + nx = self.jobj.getGridGeometry().getGridRange().getSpan(0) + ny = self.jobj.getGridGeometry().getGridRange().getSpan(1) + dest = FloatBufferWrapper(nx, ny) pnfa = None if unit: unitObj = UnitFormat.getUCUMInstance().parseObject(unit) converter = self.jobj.getUnit().getConverterTo(unitObj) - unitDest = UnitConvertingDataDestination(converter, dest) - filledDest = self.jobj.populateData(unitDest) - nx = self.jobj.getGridGeometry().getGridRange().getSpan(0) - ny = self.jobj.getGridGeometry().getGridRange().getSpan(1) - pnfa = PythonNumpyFloatArray(filledDest.getWrappedDestination().getArray(), nx, ny) + filter = UnitConvertingDataFilter(converter) + filter = UnitConvertingDataFilter(converter) + filters = jarray(1, UnitConvertingDataFilter) + filters[0] = filter + unitDest = FilteredDataDestination.addFilters(dest, filters) + self.jobj.populateData(unitDest) else: - filledDest = self.jobj.populateData(dest) - nx = self.jobj.getGridGeometry().getGridRange().getSpan(0); - ny = self.jobj.getGridGeometry().getGridRange().getSpan(1); - pnfa = PythonNumpyFloatArray(dest.getArray(), nx, ny) + self.jobj.populateData(dest) + pnfa = PythonNumpyFloatArray(dest.getBuffer().array(), nx, ny) return pnfa.__numpy__[0] def getLatLonCoords(self): From b58b7d3d5a18331db9c2969bbc29bd47624071cb Mon Sep 17 00:00:00 2001 From: "steve.naples" Date: Fri, 2 May 2014 16:15:04 +0000 Subject: [PATCH 142/188] ASM #253 Update MPE Bias Table to allow reverting modified bias, back to original value. Change-Id: I1f84133404e14f7debb66e66735aa0d96a92b316 Former-commit-id: 2f608451c941efcc5372f0d0870ac72409f518e3 --- .../mpe/ui/dialogs/RadarBiasTableDialog.java | 90 ++++++++++++------- 1 file changed, 57 insertions(+), 33 deletions(-) diff --git a/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/dialogs/RadarBiasTableDialog.java b/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/dialogs/RadarBiasTableDialog.java index 98514b0d00..0f854758ed 100644 --- a/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/dialogs/RadarBiasTableDialog.java +++ b/cave/com.raytheon.viz.mpe.ui/src/com/raytheon/viz/mpe/ui/dialogs/RadarBiasTableDialog.java @@ -23,6 +23,7 @@ import java.text.SimpleDateFormat; import java.util.ArrayList; import java.util.Date; import java.util.HashMap; +import java.util.Iterator; import java.util.Map; import java.util.TimeZone; @@ -32,10 +33,10 @@ import org.eclipse.swt.events.ControlAdapter; import org.eclipse.swt.events.ControlEvent; import org.eclipse.swt.events.ModifyEvent; import org.eclipse.swt.events.ModifyListener; -import org.eclipse.swt.graphics.Rectangle; import org.eclipse.swt.events.SelectionAdapter; import org.eclipse.swt.events.SelectionEvent; import org.eclipse.swt.graphics.Font; +import org.eclipse.swt.graphics.Rectangle; import org.eclipse.swt.layout.GridData; import org.eclipse.swt.layout.GridLayout; import org.eclipse.swt.widgets.Button; @@ -72,6 +73,7 @@ import com.raytheon.viz.mpe.ui.radartable.ReadBiasTableParam; * Feb 2, 2014 16201 snaples Added saved data flag support * Apr 4, 2014 17223 snaples Updated other_office_id and rfc_bias to object * array so that called procedure can update and return values properly. + * May 1, 2014 16626 snaples Updated the Manual Bias button to allow revert to original value. * * * @@ -147,6 +149,10 @@ public class RadarBiasTableDialog extends Dialog { Button mbiasBtn = null; Button[] manEdit = null; + + Text[] lbTxts = null; + + private final Map biasChgs = new HashMap(); static { sdf.setTimeZone(TimeZone.getTimeZone("GMT")); @@ -343,7 +349,7 @@ public class RadarBiasTableDialog extends Dialog { dt = pgsdf.format(dt3); rsList = new HashMap(radIds.length); rsList = MPEDataManager.getInstance().readRadarData(dt3); - Text[] lbTxts = new Text[radIds.length]; + lbTxts = new Text[radIds.length]; manEdit = new Button[radIds.length]; for (int i = 0; i < radIds.length; i++) { @@ -398,9 +404,10 @@ public class RadarBiasTableDialog extends Dialog { }); - bias = String.format("%-1.2f", radarresultdata.getRwBiasValUsed()); oldbias[i] = (float) radarresultdata.getRwBiasValUsed(); - editbias[i] = 0.0f; + editbias[i] = 0.0f; + editbias[i] = oldbias[i]; + bias = String.format("%-1.2f", editbias[i]); gd = new GridData(SWT.FILL, SWT.CENTER, true, true); final Text lbiasTxt = new Text(biasListComp, SWT.SINGLE @@ -419,17 +426,16 @@ public class RadarBiasTableDialog extends Dialog { lbiasTxt.setData(i); lbiasTxt.addModifyListener(new ModifyListener() { - - @Override - public void modifyText(ModifyEvent e) { + @Override + public void modifyText(ModifyEvent e) { final int ei = (Integer) lbiasTxt.getData(); try { float parsedFloat = Float.parseFloat(lbiasTxt.getText()); editbias[ei] = parsedFloat; - manEdit[ei].setSelection(!mbiasBtn.getSelection()); manEdit[ei].setText("YES"); lbiasTxt.setBackground(getParent().getDisplay() .getSystemColor(SWT.COLOR_WHITE)); + biasChgs.put(radIds[ei], ei); applyBtn.setEnabled(true); } catch (NumberFormatException e1) { lbiasTxt.setBackground(getParent().getDisplay() @@ -442,16 +448,36 @@ public class RadarBiasTableDialog extends Dialog { lbTxts[i] = lbiasTxt; gd = new GridData(SWT.FILL, SWT.CENTER, true, true); - mbiasBtn = new Button(biasListComp, SWT.TOGGLE | SWT.READ_ONLY); - // mbiasBtn.setEnabled(false); + final Button mbiasBtn = new Button(biasListComp, SWT.TOGGLE); mbias = ("n".equalsIgnoreCase(radarresultdata.getEditBias()) || radarresultdata .getEditBias() == null) ? "NO" : "YES"; mbiasBtn.setText(mbias); mbiasBtn.setLayoutData(gd); mbiasBtn.setData(i); - mbiasBtn.setSelection(false); manEdit[i] = mbiasBtn; + mbiasBtn.addSelectionListener(new SelectionAdapter() { + /** + * (non-Javadoc) + * + * @see + * org.eclipse.swt.events.SelectionAdapter#widgetSelected(org.eclipse + * .swt.events.SelectionEvent) + */ + @Override + public void widgetSelected(SelectionEvent e) { + final int ai = (Integer) mbiasBtn.getData(); + if ("YES".equalsIgnoreCase(mbiasBtn.getText())) { + manEdit[ai].setSelection(false); + editbias[ai] = oldbias[ai]; + lbTxts[ai].setText(String.format("%-1.2f", editbias[ai])); + biasChgs.put(radIds[ai], ai); + applyBtn.setEnabled(false); + manEdit[ai].setText("NO"); + } + } + }); + gd = new GridData(SWT.FILL, SWT.CENTER, true, true); Label acoefLbl = new Label(biasListComp, SWT.CENTER); if (abzerocoef.mlt_zrcoef == 0.0) { @@ -515,29 +541,27 @@ public class RadarBiasTableDialog extends Dialog { final float memspan = -99.0f; ArrayList rwr = new ArrayList(); Rwradarresult rwrr = new Rwradarresult(); - for (int i = 0; i < radIds.length; i++) { - if (radIds[i].equals("ZZZ")) { - continue; - } - if (manEdit[i] != null - && "YES".equalsIgnoreCase(manEdit[i].getText())) { - where = String.format("WHERE radid='%s' AND obstime='%s'", - radIds[i], obstime); - rwr = (ArrayList) IHFSDbGenerated - .GetRWRadarResult(where); - if (rwr.size() != 0) { - rwrr = rwr.get(0); - } else { - continue; - } - rwrr.setEditBias("y"); - rwrr.setMemSpanUsed((double) memspan); - rwrr.setRwBiasValUsed((double) editbias[i]); - IHFSDbGenerated.UpdateRWRadarResult(rwrr); - } else { - continue; - } + Iterator bi = biasChgs.keySet().iterator(); + while (bi.hasNext()) { + String rid = bi.next(); + where = String.format("WHERE radid='%s' AND obstime='%s'",rid, obstime); + rwr = (ArrayList) IHFSDbGenerated.GetRWRadarResult(where); + if (rwr.size() != 0) { + rwrr = rwr.get(0); + } else { + continue; + } + int indexval = biasChgs.get(rid); + if("YES".equalsIgnoreCase(manEdit[indexval].getText())){ + rwrr.setEditBias("y"); + rwrr.setMemSpanUsed((double) memspan); + } else { + rwrr.setEditBias("n"); + } + rwrr.setRwBiasValUsed((double) editbias[indexval]); + IHFSDbGenerated.UpdateRWRadarResult(rwrr); } + biasChgs.clear(); return; } } From c4fc2f169b2b42ce012175453b8825b0c33df31f Mon Sep 17 00:00:00 2001 From: "Xuezhi.Wei" Date: Fri, 2 May 2014 16:54:38 +0000 Subject: [PATCH 143/188] ASM #545 Hydrobase IngestFilter GUI fixes Change-Id: I368113a8ccb0356198a52a9d5c8a39247dce68e8 Former-commit-id: a8710a68e4aa28861c03c5d988bc36a553704c31 --- .../viz/hydrobase/dialogs/DataIngestFilterDlg.java | 9 +++++++-- .../datamanager/DataIngestFilterDataManager.java | 4 +++- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/cave/com.raytheon.viz.hydrobase/src/com/raytheon/viz/hydrobase/dialogs/DataIngestFilterDlg.java b/cave/com.raytheon.viz.hydrobase/src/com/raytheon/viz/hydrobase/dialogs/DataIngestFilterDlg.java index 4858d27cbf..12136a893b 100644 --- a/cave/com.raytheon.viz.hydrobase/src/com/raytheon/viz/hydrobase/dialogs/DataIngestFilterDlg.java +++ b/cave/com.raytheon.viz.hydrobase/src/com/raytheon/viz/hydrobase/dialogs/DataIngestFilterDlg.java @@ -71,10 +71,13 @@ import com.raytheon.viz.ui.dialogs.CaveSWTDialog; * SOFTWARE HISTORY * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Sep 4, 2008 lvenable Initial creation + * Sep 4, 2008 lvenable Initial creation * Dec 11, 2008 1787 askripsk Connect to DB * Apr 18, 2013 1790 rferrel Make dialog non-blocking. * Mar 31, 2014 #2970 lvenable Put dispose checks in the runAsync calls. + * May 1, 2014 17096 xwei By default the first item of the data + * list is selected + * * * * @@ -642,7 +645,7 @@ public class DataIngestFilterDlg extends CaveSWTDialog { typeSrcLbl.setEnabled(false); typeSrcLbl.setLayoutData(gd); - gd = new GridData(); + gd = new GridData(SWT.FILL, SWT.CENTER, false, true); gd.horizontalSpan = 3; typeSrcFilterCbo = new Combo(filterGroup, SWT.DROP_DOWN | SWT.READ_ONLY); typeSrcFilterCbo.select(0); @@ -1045,6 +1048,8 @@ public class DataIngestFilterDlg extends CaveSWTDialog { if (ingestDataList.getItemCount() > 0) { updateDialogState(DialogStates.DATA_AVAILABLE); + ingestDataList.select(0); + updateSelectedInformation(); } else { updateDialogState(DialogStates.NO_DATA); } diff --git a/cave/com.raytheon.viz.hydrocommon/src/com/raytheon/viz/hydrocommon/datamanager/DataIngestFilterDataManager.java b/cave/com.raytheon.viz.hydrocommon/src/com/raytheon/viz/hydrocommon/datamanager/DataIngestFilterDataManager.java index 8548345ea1..2bc537bf78 100644 --- a/cave/com.raytheon.viz.hydrocommon/src/com/raytheon/viz/hydrocommon/datamanager/DataIngestFilterDataManager.java +++ b/cave/com.raytheon.viz.hydrocommon/src/com/raytheon/viz/hydrocommon/datamanager/DataIngestFilterDataManager.java @@ -37,6 +37,8 @@ import com.raytheon.viz.hydrocommon.data.DataIngestFilterData; * ------------ ---------- ----------- -------------------------- * Dec 11, 2008 1787 askripsky Initial Creation * Apr 18, 2013 1790 rferrel Code clean up with non-blocking dialogs. + * May 1, 2014 17096 xwei Updated the filter list SQL statement + * * * * @@ -220,7 +222,7 @@ public class DataIngestFilterDataManager { StringBuffer whereClause = new StringBuffer(); if (filterByLocation) { - whereClause.append("lid like '%" + selectedLocation + "%'"); + whereClause.append( "lid='" + selectedLocation + "'" ); } if (filterByPE && (selectedPE.size() > 0)) { From fb359316c828a674c2d185af26236978220bafd9 Mon Sep 17 00:00:00 2001 From: "Xuezhi.Wei" Date: Fri, 2 May 2014 19:48:46 +0000 Subject: [PATCH 144/188] ASM #579 Shef Ingest ProcessUtil configuration update Change-Id: Idc121a2b4b303e53ac2f9a7fc0dc2cb045b08150 Former-commit-id: ddda775e85dd8cba5f4342de330d1446647c621c --- .../com.raytheon.edex.plugin.shef/res/spring/shef-ingest.xml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/edexOsgi/com.raytheon.edex.plugin.shef/res/spring/shef-ingest.xml b/edexOsgi/com.raytheon.edex.plugin.shef/res/spring/shef-ingest.xml index cbeb83d0e8..badf98afdf 100644 --- a/edexOsgi/com.raytheon.edex.plugin.shef/res/spring/shef-ingest.xml +++ b/edexOsgi/com.raytheon.edex.plugin.shef/res/spring/shef-ingest.xml @@ -132,6 +132,7 @@ + java.lang.Throwable @@ -151,6 +152,7 @@ + java.lang.Throwable From 18e92f03c1407eff6dfd057d90c3ab039f70c8d6 Mon Sep 17 00:00:00 2001 From: "Qinglu.Lin" Date: Mon, 5 May 2014 11:54:32 -0400 Subject: [PATCH 145/188] ASM #514 - Line of Storms functionality behaving oddly in WarnGen Change-Id: I0bd2b9e4200b5acbb19a06caa45f18d36346de39 Former-commit-id: 66a6c50cd501358e0c8c993631b288aa78dfdc97 --- .../common/stormtrack/StormTrackDisplay.java | 33 ++++++++++++++++++- .../common/stormtrack/StormTrackState.java | 12 +++++++ .../viz/warngen/gui/WarngenDialog.java | 5 +++ .../viz/warngen/gui/WarngenLayer.java | 21 +++++++++++- 4 files changed, 69 insertions(+), 2 deletions(-) diff --git a/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/common/stormtrack/StormTrackDisplay.java b/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/common/stormtrack/StormTrackDisplay.java index c6ca1beba3..56ff25cd9c 100644 --- a/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/common/stormtrack/StormTrackDisplay.java +++ b/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/common/stormtrack/StormTrackDisplay.java @@ -101,6 +101,8 @@ import com.vividsolutions.jts.geom.LineString; * 01-28-2014 DR16465 mgamazaychikov Fixed the problem with anchor point when frame * count changes; made line width configurable. * 04-07-2014 DR 17232 D. Friedman Make sure pivot indexes are valid. + * 04-24-2014 DR 16356 Qinglu Lin Updated generateTrackInfo(), generateNewTrackInfo(), + * and createTrack(). * * * @@ -691,6 +693,14 @@ public class StormTrackDisplay implements IRenderable { if (cachedTrack != null) { cachedTrack.dispose(); } + if (StormTrackState.trackType.equals("lineOfStorms") && state.justSwitchedToLOS) { + GeodeticCalculator gc = new GeodeticCalculator(); + Coordinate[] coords = state.dragMeGeom.getCoordinates(); + gc.setStartingGeographicPoint(coords[0].x, coords[0].y); + gc.setDestinationGeographicPoint(coords[coords.length - 1].x, + coords[coords.length - 1].y); + state.angle = adjustAngle(gc.getAzimuth() - 90); + } generateTrackInfo(state, paintProps); if (state.mode == Mode.TRACK) { createTrack(target, paintProps); @@ -703,6 +713,9 @@ public class StormTrackDisplay implements IRenderable { state.lineWidth, state.lineStyle); paintLabels(target, paintProps); } + if (StormTrackState.trackType.equals("lineOfStorms") && state.justSwitchedToLOS) { + state.angle = StormTrackState.oneStormAngle; + } } /** @@ -781,6 +794,10 @@ public class StormTrackDisplay implements IRenderable { currentState.pointMoved = false; currentState.originalTrack = false; moved = true; + if (StormTrackState.trackType.equals("lineOfStorms") && + currentState.justSwitchedToLOS) { + currentState.justSwitchedToLOS = false; + } } currentDisplayedTimes = trackUtil.getDataTimes(paintProps @@ -959,6 +976,7 @@ public class StormTrackDisplay implements IRenderable { state.futurePoints = futurePoints; state.angle = angle; + StormTrackState.oneStormAngle = angle; state.speed = speed; postData(state); @@ -995,7 +1013,11 @@ public class StormTrackDisplay implements IRenderable { coords[coords.length - 1].y); angle = adjustAngle(gc.getAzimuth() - 90); } else { - angle = adjustAngle(std.getMotionDirection()); + if (state.justSwitchedToOS) { + angle = StormTrackState.oneStormAngle; + } else { + angle = adjustAngle(std.getMotionDirection()); + } } state.angle = angle; state.speed = speed; @@ -1182,6 +1204,11 @@ public class StormTrackDisplay implements IRenderable { compiler.handle(gf.createLineString(coords)); double angle = state.angle; + if(!state.justSwitchedToOS) { + if (StormTrackState.trackType.equals("oneStorm")) { + StormTrackState.oneStormAngle = angle; + } + } // Draw ticks, X and Arrow for (int i = 0; i < orig.length - 1; ++i) { GeodeticCalculator gc = new GeodeticCalculator(); @@ -1189,6 +1216,10 @@ public class StormTrackDisplay implements IRenderable { gc.setDestinationGeographicPoint(orig[i + 1].x, orig[i + 1].y); angle = gc.getAzimuth(); + if (state.justSwitchedToLOS) { + angle = 90.0; + state.justSwitchedToLOS = false; + } if (i == state.displayedPivotIndex) { double tickLen = SQRT_2 * tickLengthInMeters; diff --git a/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/common/stormtrack/StormTrackState.java b/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/common/stormtrack/StormTrackState.java index ca7e783654..1128e73ca3 100644 --- a/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/common/stormtrack/StormTrackState.java +++ b/cave/com.raytheon.viz.awipstools/src/com/raytheon/viz/awipstools/common/stormtrack/StormTrackState.java @@ -47,6 +47,8 @@ import com.vividsolutions.jts.geom.Point; * 11/29/2012 15571 Qinglu Lin Added compuateCurrentStormCenter(); * 15Mar2013 15693 mgamazaychikov Added magnification. * 06-24-2013 DR 16317 D. Friedman Handle "motionless" track. + * 04-24-2014 DR 16356 Qinglu Lin Added newWarnGen, oneStormAngle, justSwitchedToLOS, + * justSwitchedToOS, and trackType. * * * @@ -198,6 +200,16 @@ public class StormTrackState { private boolean initiallyMotionless; + public static boolean newWarnGen = true; + + public static double oneStormAngle = Double.NaN; + + public boolean justSwitchedToLOS = false; + + public boolean justSwitchedToOS = false; + + public static String trackType = null; + /** Compute the coordinate of the storm center at the time defined by dataTime via interpolation. */ public boolean compuateCurrentStormCenter(Coordinate coord, DataTime dateTime) { if (futurePoints == null) return false; diff --git a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenDialog.java b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenDialog.java index 3d40222b40..6c9c28ff36 100644 --- a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenDialog.java +++ b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenDialog.java @@ -152,6 +152,7 @@ import com.vividsolutions.jts.geom.Polygon; * Sep 24, 2013 #2401 lvenable Fixed font memory leak. * Oct 01, 2013 DR16612 m.gamazaychikov Fixed inconsistencies with track locking and updateListSelected method * Oct 29, 2013 DR 16734 D. Friedman If redraw-from-hatched-area fails, don't allow the polygon the be used. + * Apr 24, 2014 DR 16356 Qinglu Lin Updated selectOneStorm() and selectLineOfStorms(). * * * @author chammack @@ -1323,6 +1324,8 @@ public class WarngenDialog extends CaveSWTDialog implements */ private void selectOneStorm() { if (warngenLayer.state.followupData == null) { + warngenLayer.resetState(); + warngenLayer.reset("oneStorm"); warngenLayer.clearWarningGeometries(); warngenLayer.getStormTrackState().dragMeLine = null; warngenLayer.getStormTrackState().dragMeGeom = null; @@ -1338,6 +1341,8 @@ public class WarngenDialog extends CaveSWTDialog implements */ private void selectLineOfStorms() { if (warngenLayer.state.followupData == null) { + warngenLayer.resetState(); + warngenLayer.reset("lineOfStorms"); warngenLayer.clearWarningGeometries(); warngenLayer.getStormTrackState().dragMeLine = null; warngenLayer.getStormTrackState().dragMeGeom = null; diff --git a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java index 380d883d7d..2a2c247618 100644 --- a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java +++ b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenLayer.java @@ -205,10 +205,11 @@ import com.vividsolutions.jts.io.WKTReader; * 02/07/2014 DR16090 m.gamazaychikov Added GeomMetaDataUpdateNotificationObserver class to get notification * when geometry file get updated to re-read them in. * 02/19/2014 2819 randerso Removed unnecessary .clone() call - * 03/17/2014 DR16309 Qinglu Lin Updated getWarningAreaFromPolygon(); changed searchCountyGeospatialDataAccessor) to + * 03/17/2014 DR 16309 Qinglu Lin Updated getWarningAreaFromPolygon(); changed searchCountyGeospatialDataAccessor) to * searchGeospatialDataAccessor() and updated it; changed getCountyGeospatialDataAcessor() * to getGeospatialDataAcessor(); changed getAllCountyUgcs() to getAllUgcs(); changed * getUgcsForWatches() to getUgcsForCountyWatches(). + * 04/23/2014 DR 16356 Qinglu Lin Updated initializeState() and added reset(). * * * @author mschenke @@ -737,6 +738,11 @@ public class WarngenLayer extends AbstractStormTrackResource { // Default angle for POINT displayState.labelMode = LabelMode.TIME; state.angle = 60; + if (StormTrackState.newWarnGen) { + StormTrackState.oneStormAngle = state.angle; + StormTrackState.trackType = "oneStorm"; + StormTrackState.newWarnGen = false; + } state.speed = 35; state.dragMePoint = null; state.resetAnchor = true; @@ -3493,4 +3499,17 @@ public class WarngenLayer extends AbstractStormTrackResource { return hatchedArea; } } + + public void reset(String trackType) { + if (trackType.equals("oneStorm")) { + getStormTrackState().justSwitchedToOS = true; + getStormTrackState().justSwitchedToLOS = false; + StormTrackState.trackType = "oneStorm"; + getStormTrackState().angle = StormTrackState.oneStormAngle; + } else if (trackType.equals("lineOfStorms")) { + getStormTrackState().justSwitchedToOS = false; + getStormTrackState().justSwitchedToLOS = true; + StormTrackState.trackType = "lineOfStorms"; + } + } } From 0cf0f724f492657ac0816501caaaa9922620092e Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Mon, 5 May 2014 13:04:06 -0500 Subject: [PATCH 146/188] Issue #2060 fix sat precip for grid data URI removal Change-Id: Iaa5144a63ff455f5c12a060a9daad0dd0bd04e58 Former-commit-id: cf0bb31583f0ec0b2135aa9101f3247e88e877d0 --- .../uf/edex/ohd/pproc/SatPreURIFilter.java | 33 +-- .../edex/ohd/pproc/SatPrecipFileBuilder.java | 194 ++++++++---------- 2 files changed, 97 insertions(+), 130 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/SatPreURIFilter.java b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/SatPreURIFilter.java index 44aa25f548..6e26ea1b1f 100644 --- a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/SatPreURIFilter.java +++ b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/SatPreURIFilter.java @@ -19,10 +19,13 @@ **/ package com.raytheon.uf.edex.ohd.pproc; +import com.raytheon.uf.common.dataplugin.annotations.DataURI; +import com.raytheon.uf.common.dataplugin.grid.GridConstants; import com.raytheon.uf.common.dataplugin.message.DataURINotificationMessage; /** - * TODO Add Description + * Filters URIs for Satellite Precip and generates an xmrg file if the filter + * matches. * *
  * 
@@ -30,8 +33,9 @@ import com.raytheon.uf.common.dataplugin.message.DataURINotificationMessage;
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
  * Sep 10, 2009            snaples     Initial creation
- * Feb 12, 2010  4635      snaples     Updated to match more generically.
+ * Feb 12, 2010 4635       snaples     Updated to match more generically.
  * Feb 15, 2013 1638       mschenke    Moved DataURINotificationMessage to uf.common.dataplugin
+ * May 05, 2014 2060       njensen     Cleanup
  * 
  * 
* @@ -41,22 +45,22 @@ import com.raytheon.uf.common.dataplugin.message.DataURINotificationMessage; public class SatPreURIFilter { - DataURINotificationMessage message; + private static final String AUTOSPE = "AUTOSPE"; - String outpath = ""; + private String startFilter; - static final String AUTOSPE = "AUTOSPE"; + private SatPrecipFileBuilder builder; - public SatPreURIFilter() { + public SatPreURIFilter() throws Exception { + startFilter = DataURI.SEPARATOR + GridConstants.GRID; + builder = new SatPrecipFileBuilder(); } - public void matchURI(DataURINotificationMessage msg) { - message = msg; - - if (message instanceof DataURINotificationMessage) { + public void matchURI(DataURINotificationMessage msg) throws Exception { + if (msg instanceof DataURINotificationMessage) { String uri = ""; - for (String data : message.getDataURIs()) { - if (data.startsWith("/grid")) { + for (String data : msg.getDataURIs()) { + if (data.startsWith(startFilter)) { if (data.contains(AUTOSPE)) { uri = data; break; @@ -68,10 +72,7 @@ public class SatPreURIFilter { } } if (uri.length() > 1) { - SatPrecipFileBuilder sb = new SatPrecipFileBuilder(uri); - sb.createSatPre(); - } else { - return; + builder.createSatPre(uri); } } } diff --git a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/SatPrecipFileBuilder.java b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/SatPrecipFileBuilder.java index 61b2715eb3..a23aa8d668 100644 --- a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/SatPrecipFileBuilder.java +++ b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/SatPrecipFileBuilder.java @@ -22,42 +22,43 @@ package com.raytheon.uf.edex.ohd.pproc; import java.awt.Rectangle; import java.io.File; import java.io.IOException; -import java.text.ParseException; import java.text.SimpleDateFormat; import java.util.Date; -import java.util.TimeZone; import javax.measure.converter.UnitConverter; import javax.measure.unit.SI; import javax.measure.unit.Unit; -import com.raytheon.uf.common.dataplugin.PluginException; import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.datastorage.IDataStore; import com.raytheon.uf.common.datastorage.Request; import com.raytheon.uf.common.datastorage.records.FloatDataRecord; import com.raytheon.uf.common.datastorage.records.IDataRecord; -import com.raytheon.uf.common.datastorage.records.ShortDataRecord; import com.raytheon.uf.common.hydro.spatial.HRAP; import com.raytheon.uf.common.hydro.spatial.HRAPCoordinates; import com.raytheon.uf.common.mpe.util.XmrgFile; import com.raytheon.uf.common.mpe.util.XmrgFile.XmrgHeader; import com.raytheon.uf.common.ohd.AppsDefaults; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.common.units.UnitConv; import com.raytheon.uf.edex.database.plugin.PluginDao; import com.raytheon.uf.edex.database.plugin.PluginFactory; /** - * TODO Add Description + * Builder for xmrg files that contain satellite precip data. * *
  * 
  * SOFTWARE HISTORY
  * Date         Ticket#    Engineer    Description
  * ------------ ---------- ----------- --------------------------
- * Sep 8, 2009            snaples     Initial creation
+ * Sep 08, 2009            snaples     Initial creation
  * Feb 15, 2013 1638       mschenke    Moved DataURINotificationMessage to uf.common.dataplugin
- * Mar 19, 2014 17109     snaples     Removed code that adds 1 hour to grid reftime, was not needed.
+ * Mar 19, 2014 17109      snaples     Removed code that adds 1 hour to grid reftime, was not needed.
+ * May 05, 2014 2060       njensen     Major cleanup and remove dependency on grid dataURI
+ * 
  * 
  * 
* @@ -67,25 +68,8 @@ import com.raytheon.uf.edex.database.plugin.PluginFactory; public class SatPrecipFileBuilder { - Rectangle extent = null; - - XmrgFile xmfile = null; - - GridRecord gr = null; - - private IDataRecord dataRec; - - private String uri = ""; - - private String outputPath = ""; - - private short[] data; - - private static final SimpleDateFormat sdf = new SimpleDateFormat( - "yyyyMMddHH"); - static { - sdf.setTimeZone(TimeZone.getTimeZone("GMT")); - } + private static final IUFStatusHandler logger = UFStatus + .getHandler(SatPrecipFileBuilder.class); private static final String FILEPRE = "SATPRE"; @@ -99,70 +83,81 @@ public class SatPrecipFileBuilder { private static final String USER = "SANmdY"; - private Date grReftime = null; + private Rectangle extent = null; private int height; private int width; - private static int minX; + private int minX; - private static int minY; + private int minY; - private static int maxX; + private int maxY; - private static int maxY; + private SimpleDateFormat sdf; - public SatPrecipFileBuilder(String datauri) { - uri = datauri; - } + private String outputPath; - public void createSatPre() { - try { - getGridRecord(); - } catch (PluginException e) { - e.printStackTrace(); - } - float[] fa = null; - fa = new float[((float[]) gr.getMessageData()).length]; - fa = (float[]) gr.getMessageData(); - String gribUnit = gr.getParameter().getUnitString(); - UnitConverter cv = null; - Unit gi = Unit.ONE; - try { - gi = UnitConv.deserializer(gribUnit); - } catch (ParseException e) { - e.printStackTrace(); - } - Unit xOut = SI.MILLIMETER; - cv = gi.getConverterTo(xOut); - data = new short[fa.length]; - int k = 0; - for (int i = 0; i < height; i++) { - for (int j = 0; j < width; j++) { - if (fa[k] < 0) { - fa[k] = 0; - } - data[(i * width) + j] = (short) (cv.convert(fa[k]) * 100.0); - k++; - } - } - fa = null; - createXmrgFile(); - } + public SatPrecipFileBuilder() throws Exception { + extent = HRAPCoordinates.getHRAPCoordinates(); + maxY = (int) (HRAP.getInstance().getNy() - extent.getMinY()); + minY = (int) (maxY - extent.getHeight()); + minX = (int) extent.getMinX(); + width = (int) (extent.getWidth()); + height = (int) (extent.getHeight()); - private void createXmrgFile() { + sdf = new SimpleDateFormat("yyyyMMddHH"); + sdf.setTimeZone(TimeUtil.GMT_TIME_ZONE); AppsDefaults appsDefaults = AppsDefaults.getInstance(); outputPath = appsDefaults.getToken("mpe_satpre_dir"); - File op = new File(outputPath); - if (op.exists() == false) { - op.mkdir(); + File outputDir = new File(outputPath); + if (!outputDir.exists()) { + outputDir.mkdirs(); } - op = null; + } + + /** + * Retrieves a grid record, converts the data to millimeters, and stores it + * to an xmrg file. + * + * @param uri + * the data URI of the grid record + */ + public void createSatPre(String uri) { + try { + GridRecord gr = getGridRecord(uri); + float[] fa = (float[]) gr.getMessageData(); + String gribUnit = gr.getParameter().getUnitString(); + UnitConverter cv = null; + Unit gi = UnitConv.deserializer(gribUnit); + Unit xOut = SI.MILLIMETER; + cv = gi.getConverterTo(xOut); + short[] data = new short[fa.length]; + int k = 0; + for (int i = 0; i < height; i++) { + for (int j = 0; j < width; j++) { + if (fa[k] < 0) { + fa[k] = 0; + } + data[(i * width) + j] = (short) (cv.convert(fa[k]) * 100.0); + k++; + } + } + fa = null; + createXmrgFile(data, gr.getDataTime().getRefTime()); + } catch (Exception e) { + logger.error("Error creating sat precip xmrg file for URI " + uri, + e); + } + } + + private void createXmrgFile(short[] data, Date grReftime) + throws IOException { String fname = outputPath + File.separatorChar + FILEPRE + sdf.format(grReftime) + "z"; - xmfile = new XmrgFile(fname); + XmrgFile xmfile = new XmrgFile(fname); XmrgHeader xmhead = new XmrgHeader(); xmhead.setValidDate(grReftime); xmhead.setSaveDate(grReftime); @@ -174,63 +169,34 @@ public class SatPrecipFileBuilder { xmfile.setHeader(xmhead); xmfile.setHrapExtent(extent); xmfile.setData(data); - try { - xmfile.save(fname); - } catch (IOException e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } + xmfile.save(fname); } /** - * get Populated grib record + * Get Populated grid record * * @param uri + * the uri of the grid record * @return */ - public void getGridRecord() throws PluginException { - try { - extent = HRAPCoordinates.getHRAPCoordinates(); - } catch (Exception e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } - HRAP hr = HRAP.getInstance(); - - maxY = (int) (hr.getNy() - extent.getMinY()); - minY = (int) (maxY - extent.getHeight()); - minX = (int) extent.getMinX(); - maxX = (int) extent.getMaxX(); - width = (int) (extent.getWidth()); - height = (int) (extent.getHeight()); + private GridRecord getGridRecord(String uri) throws Exception { + GridRecord gr = new GridRecord(uri); + PluginDao gd = PluginFactory.getInstance().getPluginDao( + gr.getPluginName()); + IDataStore dataStore = gd.getDataStore(gr); int[] minIndex = { minX, minY }; int[] maxIndex = { minX + width, minY + height }; - - gr = new GridRecord(uri); - PluginDao gd = PluginFactory.getInstance().getPluginDao( - gr.getPluginName()); - gr = (GridRecord) gd.getMetadata(uri); - IDataStore dataStore = gd.getDataStore(gr); - - try { - dataRec = dataStore.retrieve(uri, "Data", - Request.buildSlab(minIndex, maxIndex)); - } catch (Exception se) { - se.printStackTrace(); - } + IDataRecord dataRec = dataStore.retrieve(uri, "Data", + Request.buildSlab(minIndex, maxIndex)); if (dataRec instanceof FloatDataRecord) { gr.setMessageData(((FloatDataRecord) dataRec).getFloatData()); - } else if (dataRec instanceof ShortDataRecord) { - gr.setMessageData(((ShortDataRecord) dataRec).getShortData()); } else { gr.setMessageData(dataRec); } - // this get the reftime of the record - grReftime = gr.getDataTime().getRefTime(); - long millis = grReftime.getTime(); - grReftime.setTime(millis); + + return gr; } } From 42c36a5e80b064ceb52fa784fdd4f3ff886ea17a Mon Sep 17 00:00:00 2001 From: Melissa Porricel Date: Mon, 5 May 2014 14:56:45 -0400 Subject: [PATCH 147/188] ASM #481 - Add Guam GFSDNG to AWIPS Change-Id: Iebf45e4b94fcf25aa32554f4363d0dc25f3e47ca Former-commit-id: 012fa438f085498027402c1cd0897dd13c0d4edc --- .../localization/volumebrowser/LevelMappingFile.xml | 1 + .../localization/volumebrowser/VbSources.xml | 1 + .../base/grid/datasetInfo/gribDatasets_NCEP-7.xml | 4 ++-- .../uf/common/dataplugin/grid/util/GridLevelTranslator.java | 4 +++- .../common_static/base/grid/dataset/alias/d2d-title.xml | 2 +- .../common_static/base/styleRules/d2dContourStyleRules.xml | 1 + .../common_static/base/styleRules/gridImageryStyleRules.xml | 1 + .../common_static/base/derivedParameters/definitions/GH.xml | 3 +++ .../common_static/base/derivedParameters/definitions/RH.xml | 3 +++ .../src/com/raytheon/uf/common/style/level/Level.java | 3 ++- .../utility/common_static/base/purge/gridPurgeRules.xml | 6 ++++++ 11 files changed, 24 insertions(+), 5 deletions(-) diff --git a/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/LevelMappingFile.xml b/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/LevelMappingFile.xml index b39d3e1cb9..693aa8b14c 100644 --- a/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/LevelMappingFile.xml +++ b/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/LevelMappingFile.xml @@ -1198,6 +1198,7 @@ + diff --git a/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/VbSources.xml b/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/VbSources.xml index 5fdfc623a8..2182cad02c 100644 --- a/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/VbSources.xml +++ b/cave/com.raytheon.viz.volumebrowser/localization/volumebrowser/VbSources.xml @@ -66,6 +66,7 @@ + diff --git a/edexOsgi/com.raytheon.edex.plugin.grib/utility/common_static/base/grid/datasetInfo/gribDatasets_NCEP-7.xml b/edexOsgi/com.raytheon.edex.plugin.grib/utility/common_static/base/grid/datasetInfo/gribDatasets_NCEP-7.xml index 516afb5ee1..811f956cba 100644 --- a/edexOsgi/com.raytheon.edex.plugin.grib/utility/common_static/base/grid/datasetInfo/gribDatasets_NCEP-7.xml +++ b/edexOsgi/com.raytheon.edex.plugin.grib/utility/common_static/base/grid/datasetInfo/gribDatasets_NCEP-7.xml @@ -342,9 +342,9 @@
6
- Guam-GFS + Guam-GFSDNG GFS199 -
6
+
3
RAP13 diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/util/GridLevelTranslator.java b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/util/GridLevelTranslator.java index 3932bd1603..ff122d4a68 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/util/GridLevelTranslator.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/util/GridLevelTranslator.java @@ -40,7 +40,7 @@ import com.raytheon.uf.common.style.level.SingleLevel; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Jul 30, 2007 chammack Initial Creation. - * + * May 1, 2014 DCS 027 MPorricelli Add WBZ level * * * @author chammack @@ -83,6 +83,8 @@ public class GridLevelTranslator { level = new SingleLevel(Level.LevelType.TEMP); } else if (levelType.equalsIgnoreCase("FRZ")) { level = new SingleLevel(Level.LevelType.FRZ); + } else if (levelType.equalsIgnoreCase("WBZ")) { + level = new SingleLevel(Level.LevelType.WBZ); } else { return new SingleLevel(Level.LevelType.DEFAULT); } diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/grid/dataset/alias/d2d-title.xml b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/grid/dataset/alias/d2d-title.xml index 4affe5f5fe..63611a4de6 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/grid/dataset/alias/d2d-title.xml +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/grid/dataset/alias/d2d-title.xml @@ -70,7 +70,7 @@ NAM80 AK-GFS SJU-GFS - Guam-GFS + Guam-GFSDNG GFS360 GFS40 GFS90 diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/d2dContourStyleRules.xml b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/d2dContourStyleRules.xml index 388d48284e..fbe4a1718a 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/d2dContourStyleRules.xml +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/d2dContourStyleRules.xml @@ -4174,6 +4174,7 @@ in | .03937 | 0 | 4 | | |..|8000F0FF| | 16 | \ GH + ft diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/gridImageryStyleRules.xml b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/gridImageryStyleRules.xml index d3052b9921..b7e5127458 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/gridImageryStyleRules.xml +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/utility/common_static/base/styleRules/gridImageryStyleRules.xml @@ -4907,6 +4907,7 @@ GH + ft diff --git a/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/GH.xml b/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/GH.xml index 015a571c8a..636a4d13fc 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/GH.xml +++ b/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/GH.xml @@ -183,4 +183,7 @@ + + + diff --git a/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/RH.xml b/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/RH.xml index 6e82f13d44..7f2e1e6e6f 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/RH.xml +++ b/edexOsgi/com.raytheon.uf.common.derivparam/utility/common_static/base/derivedParameters/definitions/RH.xml @@ -77,4 +77,7 @@ + + + diff --git a/edexOsgi/com.raytheon.uf.common.style/src/com/raytheon/uf/common/style/level/Level.java b/edexOsgi/com.raytheon.uf.common.style/src/com/raytheon/uf/common/style/level/Level.java index af73b7f48b..973210ba5f 100644 --- a/edexOsgi/com.raytheon.uf.common.style/src/com/raytheon/uf/common/style/level/Level.java +++ b/edexOsgi/com.raytheon.uf.common.style/src/com/raytheon/uf/common/style/level/Level.java @@ -36,6 +36,7 @@ import javax.xml.bind.annotation.XmlAttribute; * ------------ ---------- ----------- -------------------------- * Sep 24, 2007 njensen Initial creation * Nov 14, 2013 2361 njensen Remove ISerializableObject + * May 1, 2014 DCS 027 MPorricelli Add WBZ level * * * @@ -45,7 +46,7 @@ import javax.xml.bind.annotation.XmlAttribute; public abstract class Level { public static enum LevelType { - THETA, HEIGHT_AGL, HEIGHT_MSL, PRESSURE, SURFACE, TILT, MB_AGL, MAXW, TW0, TEMP, FRZ, DEFAULT + THETA, HEIGHT_AGL, HEIGHT_MSL, PRESSURE, SURFACE, TILT, MB_AGL, MAXW, TW0, TEMP, FRZ, DEFAULT, WBZ }; protected LevelType type; diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.grid/utility/common_static/base/purge/gridPurgeRules.xml b/edexOsgi/com.raytheon.uf.edex.plugin.grid/utility/common_static/base/purge/gridPurgeRules.xml index d0c1625e11..ac1bde3d03 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.grid/utility/common_static/base/purge/gridPurgeRules.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.grid/utility/common_static/base/purge/gridPurgeRules.xml @@ -732,4 +732,10 @@ 5 00-00:15:00 + + + GFS199 + 4 + 00-01:00:00 + From a6c2260dd14a7d6d351229bd41c72b7241b67389 Mon Sep 17 00:00:00 2001 From: Lee Venable Date: Mon, 5 May 2014 16:12:24 -0500 Subject: [PATCH 148/188] Issue #3109 - removed code that sets the Cave cursor. Change-Id: I1d6d640c5abafffdea29f1e2e835142fe6598470 Former-commit-id: d875f73ff44986b2c7862f0dee06504d576fd96b --- .../uf/viz/monitor/ffmp/fffg/FFFGDlg.java | 20 ++++++------------- 1 file changed, 6 insertions(+), 14 deletions(-) diff --git a/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/fffg/FFFGDlg.java b/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/fffg/FFFGDlg.java index 3eb5d8d52f..32de4c553f 100644 --- a/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/fffg/FFFGDlg.java +++ b/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/fffg/FFFGDlg.java @@ -91,6 +91,8 @@ import com.raytheon.viz.ui.dialogs.ICloseCallback; * Changes for non-blocking LoadSaveDeleteSelectDlg. * Mar 28, 2013 #1790 rferrel Bug fix for non-blocking dialogs. * Apr, 15, 2013 #1911 dhladky dialog wouldn't open every time to retrieve file. + * May 05, 2014 #3109 lvenable Removed code that sets the cursor on Cave because it doesn't need + * to be set. * * * @@ -310,8 +312,7 @@ public class FFFGDlg extends CaveSWTDialog implements ISourceCompAction, public FFFGDlg(Shell parentShell) { super(parentShell, SWT.DIALOG_TRIM, CAVE.INDEPENDENT_SHELL | CAVE.DO_NOT_BLOCK); - this.getParent().setCursor( - this.getParent().getDisplay().getSystemCursor(SWT.CURSOR_WAIT)); + setText("Forced Flash Flood Guidance"); sourceCompArray = new ArrayList(); @@ -808,15 +809,9 @@ public class FFFGDlg extends CaveSWTDialog implements ISourceCompAction, applyBtn.addSelectionListener(new SelectionAdapter() { @Override public void widgetSelected(SelectionEvent e) { - getParent().setCursor( - getParent().getDisplay().getSystemCursor( - SWT.CURSOR_WAIT)); shell.setCursor(getDisplay().getSystemCursor(SWT.CURSOR_WAIT)); applyDataAction(); updateFileStatusLabel(false); - getParent().setCursor( - getParent().getDisplay().getSystemCursor( - SWT.CURSOR_ARROW)); shell.setCursor(getDisplay().getSystemCursor(SWT.CURSOR_ARROW)); saveFileAs(); @@ -886,6 +881,7 @@ public class FFFGDlg extends CaveSWTDialog implements ISourceCompAction, * -1 = error, 0 = information message * @param message */ + @Override public void setStatusMsg(int status, String message) { if (message == null) { statusLbl.setText(""); @@ -1609,8 +1605,8 @@ public class FFFGDlg extends CaveSWTDialog implements ISourceCompAction, } if (isDialogClear() && (fileNameLbl.getText().trim().length() == 0)) { - getRetrieveFilename(RetrieveMergeAction.RETRIEVE); - } else { + getRetrieveFilename(RetrieveMergeAction.RETRIEVE); + } else { if (retMergeDlg == null) { retMergeDlg = new RetrieveMergeDlg(shell); retMergeDlg.setCloseCallback(new ICloseCallback() { @@ -2223,10 +2219,6 @@ public class FFFGDlg extends CaveSWTDialog implements ISourceCompAction, sc.populateSourceComp(); statusLbl.setText(""); - this.getParent() - .setCursor( - this.getParent().getDisplay() - .getSystemCursor(SWT.CURSOR_ARROW)); } /* From f545c548cc2a536f20fc7c3a8f9c8121ba85f8fa Mon Sep 17 00:00:00 2001 From: Brian Clements Date: Mon, 5 May 2014 12:52:46 -0500 Subject: [PATCH 149/188] Issue #3076 added clear all to shared display sessions Former-commit-id: 9e4a518f2ecbe86fed87fbb6dac7fad08ffb33eb --- .../CollaborationDrawingEvent.java | 3 +- .../CollaborationDrawingResource.java | 41 +++++++++- .../icons/clear_all.gif | Bin 0 -> 223 bytes .../ui/session/CollaborationSessionView.java | 72 ++++++++++++++++-- .../uf/viz/drawing/DrawingToolLayer.java | 35 ++++++--- 5 files changed, 130 insertions(+), 21 deletions(-) create mode 100644 cave/com.raytheon.uf.viz.collaboration.ui/icons/clear_all.gif diff --git a/cave/com.raytheon.uf.viz.collaboration.display/src/com/raytheon/uf/viz/collaboration/display/rsc/telestrator/CollaborationDrawingEvent.java b/cave/com.raytheon.uf.viz.collaboration.display/src/com/raytheon/uf/viz/collaboration/display/rsc/telestrator/CollaborationDrawingEvent.java index 0c138412c9..ec07161cbd 100644 --- a/cave/com.raytheon.uf.viz.collaboration.display/src/com/raytheon/uf/viz/collaboration/display/rsc/telestrator/CollaborationDrawingEvent.java +++ b/cave/com.raytheon.uf.viz.collaboration.display/src/com/raytheon/uf/viz/collaboration/display/rsc/telestrator/CollaborationDrawingEvent.java @@ -37,6 +37,7 @@ import com.vividsolutions.jts.geom.Coordinate; * ------------ ---------- ----------- -------------------------- * Apr 3, 2012 mnash Initial creation * Jan 30, 2014 2698 bclement changed UserId to VenueParticipant + * May 05, 2014 3076 bclement added DISPOSE_ALL * * * @@ -48,7 +49,7 @@ import com.vividsolutions.jts.geom.Coordinate; public class CollaborationDrawingEvent { public static enum CollaborationEventType { - DRAW, ERASE, REDO, UNDO, CLEAR, LOCK_USERS, UNLOCK_USERS, CLEAR_ALL, NEW_USER_ARRIVED; + DRAW, ERASE, REDO, UNDO, CLEAR, CLEAR_ALL, LOCK_USERS, UNLOCK_USERS, DISPOSE_ALL, NEW_USER_ARRIVED; } @DynamicSerializeElement diff --git a/cave/com.raytheon.uf.viz.collaboration.display/src/com/raytheon/uf/viz/collaboration/display/rsc/telestrator/CollaborationDrawingResource.java b/cave/com.raytheon.uf.viz.collaboration.display/src/com/raytheon/uf/viz/collaboration/display/rsc/telestrator/CollaborationDrawingResource.java index 48dd9259fe..e9cd38f8b7 100644 --- a/cave/com.raytheon.uf.viz.collaboration.display/src/com/raytheon/uf/viz/collaboration/display/rsc/telestrator/CollaborationDrawingResource.java +++ b/cave/com.raytheon.uf.viz.collaboration.display/src/com/raytheon/uf/viz/collaboration/display/rsc/telestrator/CollaborationDrawingResource.java @@ -19,6 +19,9 @@ **/ package com.raytheon.uf.viz.collaboration.display.rsc.telestrator; +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; import java.util.HashMap; import java.util.List; import java.util.Map; @@ -64,6 +67,8 @@ import com.vividsolutions.jts.geom.Coordinate; * Jan 30, 2014 2698 bclement changed UserId to VenueParticipant * Feb 13, 2014 2751 bclement VenueParticipant refactor * Mar 18, 2014 2895 njensen Fix concurrent mod exception on dispose + * May 05, 2014 3076 bclement old CLEAR_ALL is now DISPOSE_ALL, + * added clearLayers() and getAllDrawingLayers() * * * @@ -129,7 +134,7 @@ public class CollaborationDrawingResource extends CollaborationDrawingEvent event = new CollaborationDrawingEvent( resourceData.getDisplayId()); event.setUserName(myUser); - event.setType(CollaborationEventType.CLEAR_ALL); + event.setType(CollaborationEventType.DISPOSE_ALL); sendEvent(event); } @@ -205,6 +210,18 @@ public class CollaborationDrawingResource extends } } + /** + * Clear all drawing layers. Does not generate any collaboration events. + * This is not "undoable". + */ + private void clearLayers() { + synchronized (layerMap) { + for (DrawingToolLayer layer : layerMap.values()) { + layer.clearAllDrawingData(); + } + } + } + /** * @return the myUser */ @@ -249,6 +266,23 @@ public class CollaborationDrawingResource extends return null; } + /** + * A collection of drawing layers for resource + * + * @return empty collection if there are no layers + */ + public Collection getAllDrawingLayers() { + Collection rval; + if (layerMap != null) { + synchronized (layerMap) { + rval = new ArrayList(layerMap.values()); + } + } else { + rval = Collections.emptyList(); + } + return rval; + } + /* * (non-Javadoc) * @@ -377,9 +411,12 @@ public class CollaborationDrawingResource extends case UNDO: layer.undo(); break; - case CLEAR_ALL: + case DISPOSE_ALL: disposeLayers(); break; + case CLEAR_ALL: + clearLayers(); + break; case NEW_USER_ARRIVED: CollaborationDrawingToolLayer myLayer = (CollaborationDrawingToolLayer) getDrawingLayerFor(getMyUser()); InitialCollaborationData dataBundle = new InitialCollaborationData( diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/icons/clear_all.gif b/cave/com.raytheon.uf.viz.collaboration.ui/icons/clear_all.gif new file mode 100644 index 0000000000000000000000000000000000000000..3baa1c7a858fb5673ed4f2ff1f9e81019896f547 GIT binary patch literal 223 zcmZ?wbhEHb6krfwc+AJJhk@Z71H(NAhBpih|A2^>_rJ9Ce_7f8y1M`E?f?1u{`2?$ z9~=9B?b`ofp!iSFxhOTUBsE2$JhLQ2!QIn0fI;ym3nK#qKZ6bf5P%G3U@8A#yLd_H zv8dt~PiLl?@E$K&axlZoQHj+_Z0a`|mX*Toxq^!s4>@d5V4HS$fuRBi``*Q$x5e-X zbv`@P>8dxAgON$CqgAlqk@1%T3tvIS0*yp(rdNlo9!wTsU}ujl;YB$Y(vLJ&s09xKr+5i9m literal 0 HcmV?d00001 diff --git a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/CollaborationSessionView.java b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/CollaborationSessionView.java index a27ce5e13c..a1b08ae7e0 100644 --- a/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/CollaborationSessionView.java +++ b/cave/com.raytheon.uf.viz.collaboration.ui/src/com/raytheon/uf/viz/collaboration/ui/session/CollaborationSessionView.java @@ -21,6 +21,7 @@ package com.raytheon.uf.viz.collaboration.ui.session; **/ import java.util.Collection; +import java.util.Collections; import java.util.IdentityHashMap; import java.util.Map; @@ -101,6 +102,7 @@ import com.raytheon.viz.ui.input.EditableManager; * Mar 11, 2014 2865 lvenable Added null checks in threads * Mar 18, 2014 2895 njensen Fix lockAction enable/disable logic * Apr 15, 2014 2822 bclement only allow transfer leader if participant is using shared display + * May 05, 2014 3076 bclement added clear all action * * * @@ -140,6 +142,8 @@ public class CollaborationSessionView extends SessionView implements private ActionContributionItem lockAction; + private ActionContributionItem clearAllAction; + private ControlContribution noEditorAction; private ISharedDisplaySession session; @@ -181,6 +185,21 @@ public class CollaborationSessionView extends SessionView implements return null; } + /** + * @see CollaborationDrawingResource#getAllDrawingLayers() + * @return empty collection if no layers are found + */ + private Collection getAllLayers() { + Collection rval; + CollaborationDrawingResource resource = getCurrentDrawingResource(); + if (resource != null) { + rval = resource.getAllDrawingLayers(); + } else { + rval = Collections.emptyList(); + } + return rval; + } + /* * (non-Javadoc) * @@ -354,7 +373,15 @@ public class CollaborationSessionView extends SessionView implements lockAction.getAction().setImageDescriptor( IconUtil.getImageDescriptor(Activator.getDefault().getBundle(), "lock.gif")); - + clearAllAction = new ActionContributionItem(new Action("Clear All") { + @Override + public void run() { + clearAllDrawingLayers(); + } + }); + clearAllAction.getAction().setImageDescriptor( + IconUtil.getImageDescriptor(Activator.getDefault().getBundle(), + "clear_all.gif")); noEditorAction = new ControlContribution("noEditorAction") { @Override @@ -383,12 +410,30 @@ public class CollaborationSessionView extends SessionView implements mgr.insert(mgr.getSize() - 1, redoAction); mgr.insert(mgr.getSize() - 1, clearAction); mgr.insert(mgr.getSize() - 1, eraseAction); + mgr.insert(mgr.getSize() - 1, new Separator()); mgr.insert(mgr.getSize() - 1, lockAction); + mgr.insert(mgr.getSize() - 1, clearAllAction); mgr.insert(mgr.getSize() - 1, new Separator()); updateToolItems(); } + /** + * Clear all drawing layers and send clear all event + */ + private void clearAllDrawingLayers() { + for (DrawingToolLayer layer : getAllLayers()) { + layer.clearAllDrawingData(); + } + CollaborationDrawingResource resource = getCurrentDrawingResource(); + CollaborationDrawingEvent event = new CollaborationDrawingEvent( + resource.getResourceData().getDisplayId()); + event.setType(CollaborationEventType.CLEAR_ALL); + event.setUserName(resource.getMyUser()); + resource.sendEvent(event); + updateToolItems(); + } + private void toggleDrawMode(DrawMode mode) { if (mode != DrawMode.NONE) { CollaborationDrawingResource resource = getCurrentDrawingResource(); @@ -411,6 +456,20 @@ public class CollaborationSessionView extends SessionView implements } } + /** + * @return true if any drawing layer has been drawn on + */ + private boolean anyLayerHasDrawing() { + boolean anyCanClear = false; + for (DrawingToolLayer dtl : getAllLayers()) { + if (dtl.hasDrawing()) { + anyCanClear = true; + break; + } + } + return anyCanClear; + } + public void updateToolItems() { ToolBarManager mgr = (ToolBarManager) getViewSite().getActionBars() .getToolBarManager(); @@ -419,24 +478,21 @@ public class CollaborationSessionView extends SessionView implements mgr.insert(0, noEditorAction); } CollaborationDrawingResource currentResource = getCurrentDrawingResource(); - DrawingToolLayer layer = null; - if (currentResource != null) { - layer = currentResource.getDrawingLayerFor(currentResource - .getMyUser()); - } + DrawingToolLayer layer = getCurrentLayer(); if (layer != null && currentResource.isSessionLeader()) { lockAction.getAction().setEnabled(true); + clearAllAction.getAction().setEnabled(anyLayerHasDrawing()); } else { lockAction.getAction().setEnabled(false); + clearAllAction.getAction().setEnabled(false); } - // enable/disable toolbar buttons based on locked if (layer != null && (locked == false || currentResource.isSessionLeader())) { drawAction.getAction().setEnabled(true); undoAction.getAction().setEnabled(layer.canUndo()); redoAction.getAction().setEnabled(layer.canRedo()); - clearAction.getAction().setEnabled(layer.canClear()); + clearAction.getAction().setEnabled(layer.hasDrawing()); eraseAction.getAction().setEnabled(true); switch (layer.getDrawMode()) { case DRAW: diff --git a/cave/com.raytheon.uf.viz.drawing/src/com/raytheon/uf/viz/drawing/DrawingToolLayer.java b/cave/com.raytheon.uf.viz.drawing/src/com/raytheon/uf/viz/drawing/DrawingToolLayer.java index bd549a3665..8112d33860 100644 --- a/cave/com.raytheon.uf.viz.drawing/src/com/raytheon/uf/viz/drawing/DrawingToolLayer.java +++ b/cave/com.raytheon.uf.viz.drawing/src/com/raytheon/uf/viz/drawing/DrawingToolLayer.java @@ -65,6 +65,8 @@ import com.vividsolutions.jts.geom.TopologyException; * May 23, 2012 mschenke Initial creation * May 23, 2012 2646 bsteffen Fix NPE in project. * Apr 03, 2014 2967 njensen Fix error when erasing the last part of a line + * May 05, 2014 3076 bclement added clearAllDrawingData() and disposeWireframeShape() + * renamed canClear() to hasDrawing() * * * @@ -331,15 +333,7 @@ public class DrawingToolLayer implements IRenderable { * Disposes the data in the layer */ public void dispose() { - synchronized (currentData) { - if (wireframeShape != null) { - wireframeShape.dispose(); - } - currentData.geometries.clear(); - currentDrawingLine = null; - undoStack.clear(); - redoStack.clear(); - } + clearAllDrawingData(); } /** @@ -503,7 +497,7 @@ public class DrawingToolLayer implements IRenderable { * * @return */ - public boolean canClear() { + public boolean hasDrawing() { return currentData.geometries.size() > 0 || redoStack.size() > 0; } @@ -535,6 +529,20 @@ public class DrawingToolLayer implements IRenderable { } } + /** + * Clears the current display and the undo and redo stacks. This operation + * is not "undoable" + */ + public void clearAllDrawingData() { + synchronized (currentData) { + disposeWireframeShape(); + currentData.geometries.clear(); + currentDrawingLine = null; + undoStack.clear(); + redoStack.clear(); + } + } + /** * Pushes currentData on pushStack and pops next frame from popStack and * puts in currentData @@ -568,6 +576,13 @@ public class DrawingToolLayer implements IRenderable { StackFrame oldData = new StackFrame(new ArrayList( currentData.geometries)); stack.push(oldData); + disposeWireframeShape(); + } + + /** + * disposes and sets wireframeShape to null if not already null + */ + private void disposeWireframeShape() { if (wireframeShape != null) { wireframeShape.dispose(); wireframeShape = null; From b148d11ec9018f4d4ff965b39436152d3501aa96 Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Mon, 5 May 2014 19:30:20 -0500 Subject: [PATCH 150/188] Issue #2726: Autoset route startup order. Change-Id: I1f4165b6eab12207cf6b6d31964e8170ebe1bddc Former-commit-id: 9b9d2b475f4777febf125e4013cba0d971eaf8e8 --- .../res/spring/text-ingest.xml | 54 +++++++------ .../esb/camel/context/ContextManager.java | 80 +++++++++++++++---- .../res/spring/persist-ingest.xml | 4 + .../res/spring/modelsounding-ingest.xml | 5 +- 4 files changed, 101 insertions(+), 42 deletions(-) diff --git a/edexOsgi/com.raytheon.edex.plugin.text/res/spring/text-ingest.xml b/edexOsgi/com.raytheon.edex.plugin.text/res/spring/text-ingest.xml index ba7acf67c8..09c6394bcd 100644 --- a/edexOsgi/com.raytheon.edex.plugin.text/res/spring/text-ingest.xml +++ b/edexOsgi/com.raytheon.edex.plugin.text/res/spring/text-ingest.xml @@ -86,8 +86,35 @@ --> + + + + text + + + + + + + + + + + + + + + + java.lang.Throwable + + + + + @@ -134,31 +161,6 @@
- - - - text - - - - - - - - - - - - - - - - java.lang.Throwable - - - - - diff --git a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java index 7490a1e673..a7ce7b3bc0 100644 --- a/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java +++ b/edexOsgi/com.raytheon.uf.edex.esb.camel/src/com/raytheon/uf/edex/esb/camel/context/ContextManager.java @@ -20,6 +20,7 @@ package com.raytheon.uf.edex.esb.camel.context; import java.util.ArrayList; +import java.util.Collections; import java.util.HashMap; import java.util.HashSet; import java.util.Iterator; @@ -38,6 +39,7 @@ import javax.naming.ConfigurationException; import org.apache.camel.CamelContext; import org.apache.camel.Route; import org.apache.camel.impl.DefaultCamelContext; +import org.apache.camel.model.RouteDefinition; import org.springframework.beans.BeansException; import org.springframework.beans.factory.config.BeanFactoryPostProcessor; import org.springframework.beans.factory.config.ConfigurableListableBeanFactory; @@ -78,6 +80,21 @@ public class ContextManager implements ApplicationContextAware, private static ContextManager instance = new ContextManager(); + /** + * Endpoint types that are internal only. Mainly used at shutdown time to + * designate routes that shouldn't be shutdown immediately. + */ + private static final Set INTERNAL_ENDPOINT_TYPES; + + static { + HashSet set = new HashSet( + ContextDependencyMapping.DEPENDENCY_ENDPOINT_TYPES); + set.add("timer"); + set.add("quartz"); + set.add("direct"); + INTERNAL_ENDPOINT_TYPES = Collections.unmodifiableSet(set); + } + /** * Service used for start up and shut down threading. */ @@ -102,12 +119,6 @@ public class ContextManager implements ApplicationContextAware, */ private ApplicationContext springCtx = null; - /** - * Endpoint types that are internal only. Mainly used at shutdown time to - * designate routes that shouldn't be shutdown immediately. - */ - private final Set internalEndpointTypes = new HashSet(); - /** * Map of context processors that have been registered for a given context. * Used to allow contexts to do custom worn on startup/shutdown. @@ -147,15 +158,19 @@ public class ContextManager implements ApplicationContextAware, } /** - * Private constructor. Sets up internal types for prioritized stopping of - * routes on shutdown. + * Private constructor. */ private ContextManager() { - internalEndpointTypes - .addAll(ContextDependencyMapping.DEPENDENCY_ENDPOINT_TYPES); - internalEndpointTypes.add("timer"); - internalEndpointTypes.add("quartz"); - internalEndpointTypes.add("direct"); + } + + /** + * Returns a set of endpoint types that are considered internal for routing + * purposes. + * + * @return + */ + public Set getInternalEndpointTypes() { + return INTERNAL_ENDPOINT_TYPES; } /** @@ -242,6 +257,31 @@ public class ContextManager implements ApplicationContextAware, List>> callbacks = new LinkedList>>(); for (final CamelContext context : cxtData.getContexts()) { + /* + * Enforce startup order so that internal endpoints start first + * and shutdown last. Each route must have a unique number under + * 1000. Camel documentation doesn't state if numbers can be + * negative or not. Order is reverse of how they are found in + * the file with internal types going first followed by external + * types. + */ + int externalCount = 999; + int internalCount = externalCount - context.getRoutes().size(); + + for (Route route : context.getRoutes()) { + String uri = route.getEndpoint().getEndpointUri(); + Pair typeAndName = ContextData + .getEndpointTypeAndName(uri); + String type = typeAndName.getFirst(); + RouteDefinition def = route.getRouteContext().getRoute(); + + if (INTERNAL_ENDPOINT_TYPES.contains(type)) { + def.setStartupOrder(internalCount--); + } else { + def.setStartupOrder(externalCount--); + } + } + final IContextStateManager stateManager = getStateManager(context); if (stateManager.isContextStartable(context)) { /* @@ -410,7 +450,7 @@ public class ContextManager implements ApplicationContextAware, Pair typeAndName = ContextData .getEndpointTypeAndName(uri); String type = typeAndName.getFirst(); - if (!internalEndpointTypes.contains(type)) { + if (!INTERNAL_ENDPOINT_TYPES.contains(type)) { try { statusHandler.info("Stopping route [" + route.getId() + "]"); @@ -531,7 +571,7 @@ public class ContextManager implements ApplicationContextAware, } /** - * Update all camel beans to have autoStartup to false and handles quart + * Update all camel beans to have autoStartup to false and handles quartz * workaround when JMX is disabled. */ @Override @@ -539,8 +579,18 @@ public class ContextManager implements ApplicationContextAware, ConfigurableListableBeanFactory beanFactory) throws BeansException { for (CamelContext ctx : beanFactory.getBeansOfType(CamelContext.class) .values()) { + /* + * set contexts to not auto start to enforce dependency order + * correctly. + */ ctx.setAutoStartup(false); + /* + * Quartz work around to set management name. + * + * TODO: Remove with camel 2.12.3 upgrade: + * https://issues.apache.org/jira/browse/CAMEL-7132 + */ if ((ctx instanceof DefaultCamelContext) && (ctx.getManagementName() == null)) { ((DefaultCamelContext) ctx).setManagementName(ctx.getName()); diff --git a/edexOsgi/com.raytheon.uf.edex.ingest/res/spring/persist-ingest.xml b/edexOsgi/com.raytheon.uf.edex.ingest/res/spring/persist-ingest.xml index b14c671dbc..6045f19ea7 100644 --- a/edexOsgi/com.raytheon.uf.edex.ingest/res/spring/persist-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.ingest/res/spring/persist-ingest.xml @@ -51,6 +51,10 @@ + diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/res/spring/modelsounding-ingest.xml b/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/res/spring/modelsounding-ingest.xml index 518b24d3c4..f1e08678f6 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/res/spring/modelsounding-ingest.xml +++ b/edexOsgi/com.raytheon.uf.edex.plugin.modelsounding/res/spring/modelsounding-ingest.xml @@ -86,7 +86,10 @@ - + From 71b422706132e75fb83ae6ec2229f480d2892648 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Tue, 6 May 2014 10:47:50 -0500 Subject: [PATCH 151/188] Issue #2060 fill in units on GridRecords created from URIs Change-Id: Ic7c1594c1442d8463c5050bdefb434995ffc7f8a Former-commit-id: 949d132cf3260db5f75ea665f21601ab91440958 --- .../viz/satellite/rsc/SatResource.java | 3 +- .../dataplugin/grid/GridInfoRecord.java | 3 +- .../uf/common/parameter/Parameter.java | 2 - .../common/parameter/ParameterConverter.java | 59 +++++++++++++++++++ .../META-INF/MANIFEST.MF | 10 ++-- .../uf/edex/dat/utils/FreezingLevel.java | 5 +- 6 files changed, 70 insertions(+), 12 deletions(-) create mode 100644 edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/ParameterConverter.java diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResource.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResource.java index 55204a29b3..41f30e9b68 100644 --- a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResource.java +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/rsc/SatResource.java @@ -100,6 +100,7 @@ import com.vividsolutions.jts.geom.Coordinate; * rules. * Apr 09, 2014 2947 bsteffen Improve flexibility of sat derived * parameters, implement ImageProvider + * May 06, 2014 njensen Improve error message * * * @@ -257,7 +258,7 @@ public class SatResource extends initializeFirstFrame((SatelliteRecord) pdo); } catch (VizException e) { throw new IllegalStateException( - "Unable to initialize the satellite resource"); + "Unable to initialize the satellite resource", e); } initialized = true; } diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridInfoRecord.java b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridInfoRecord.java index 7a40edd823..1ed01e29bb 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridInfoRecord.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridInfoRecord.java @@ -36,6 +36,7 @@ import com.raytheon.uf.common.dataplugin.persist.PersistableDataObject; import com.raytheon.uf.common.gridcoverage.GridCoverage; import com.raytheon.uf.common.gridcoverage.convert.GridCoverageConverter; import com.raytheon.uf.common.parameter.Parameter; +import com.raytheon.uf.common.parameter.ParameterConverter; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; @@ -106,7 +107,7 @@ public class GridInfoRecord extends PersistableDataObject { @ManyToOne @PrimaryKeyJoinColumn - @DataURI(position = 4, embedded = true) + @DataURI(position = 4, converter = ParameterConverter.class) @DynamicSerializeElement private Parameter parameter; diff --git a/edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/Parameter.java b/edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/Parameter.java index b7ecd7d3bb..6479a8a49b 100644 --- a/edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/Parameter.java +++ b/edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/Parameter.java @@ -34,7 +34,6 @@ import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlRootElement; -import com.raytheon.uf.common.dataplugin.annotations.DataURI; import com.raytheon.uf.common.dataplugin.persist.PersistableDataObject; import com.raytheon.uf.common.serialization.ISerializableObject; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; @@ -71,7 +70,6 @@ public class Parameter extends PersistableDataObject implements @Id @DynamicSerializeElement @XmlElement - @DataURI(position = 0) private String abbreviation; @Column(nullable = false) diff --git a/edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/ParameterConverter.java b/edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/ParameterConverter.java new file mode 100644 index 0000000000..7ebeab9c80 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/ParameterConverter.java @@ -0,0 +1,59 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.common.parameter; + +import com.raytheon.uf.common.dataplugin.annotations.DataURIFieldConverter; +import com.raytheon.uf.common.parameter.lookup.ParameterLookup; + +/** + * A DataURIFieldConverter that ensures that a String parameter abbreviation + * will be looked up to potentially contain all the fields. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * May 6, 2014  2060       njensen     Initial creation
+ * 
+ * 
+ * + * @author njensen + * @version 1.0 + */ + +public class ParameterConverter implements DataURIFieldConverter { + + @Override + public String toString(Parameter field) { + return field.getAbbreviation(); + } + + @Override + public Parameter fromString(String string) { + Parameter p = ParameterLookup.getInstance().getParameter(string); + if (p == null) { + p = new Parameter(string); + } + return p; + } + +} diff --git a/edexOsgi/com.raytheon.uf.edex.dat.utils/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.dat.utils/META-INF/MANIFEST.MF index c3cbd9a5dc..d74ea2f075 100644 --- a/edexOsgi/com.raytheon.uf.edex.dat.utils/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.dat.utils/META-INF/MANIFEST.MF @@ -2,11 +2,10 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: DatUtils Plug-in Bundle-SymbolicName: com.raytheon.uf.edex.dat.utils -Bundle-Version: 1.12.1174.qualifier +Bundle-Version: 1.14.0.qualifier Bundle-Vendor: RAYTHEON Bundle-RequiredExecutionEnvironment: JavaSE-1.6 -Import-Package: com.raytheon.uf.common.dataplugin.ffmp, - com.raytheon.uf.common.dataplugin.grid, +Import-Package: com.raytheon.uf.common.dataplugin.grid, com.raytheon.uf.common.dataplugin.scan.data, com.raytheon.uf.common.localization, com.raytheon.uf.common.monitor.xml, @@ -14,7 +13,6 @@ Import-Package: com.raytheon.uf.common.dataplugin.ffmp, org.apache.commons.logging Export-Package: com.raytheon.uf.edex.dat.utils Require-Bundle: com.raytheon.edex.common;bundle-version="1.12.2", - com.raytheon.uf.common.dataplugin.ffmp;bundle-version="1.12.2", com.raytheon.uf.common.monitor;bundle-version="1.12.2", - com.raytheon.uf.common.dataplugin.shef;bundle-version="1.12.1174", - com.raytheon.uf.edex.menus;bundle-version="1.0.0" + com.raytheon.uf.edex.menus;bundle-version="1.0.0", + com.raytheon.uf.common.parameter diff --git a/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java b/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java index 539109ba4c..b4703b2e96 100644 --- a/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java +++ b/edexOsgi/com.raytheon.uf.edex.dat.utils/src/com/raytheon/uf/edex/dat/utils/FreezingLevel.java @@ -1,5 +1,3 @@ -package com.raytheon.uf.edex.dat.utils; - /** * This software was developed and / or modified by Raytheon Company, * pursuant to Contract DG133W-05-CQ-1067 with the US Government. @@ -19,6 +17,9 @@ package com.raytheon.uf.edex.dat.utils; * See the AWIPS II Master Rights File ("Master Rights File.pdf") for * further licensing information. **/ + +package com.raytheon.uf.edex.dat.utils; + import java.util.ArrayList; import java.util.Calendar; import java.util.Date; From ff6c77420c800b974bb0b1e46c4514a40eb83182 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Tue, 6 May 2014 13:10:48 -0500 Subject: [PATCH 152/188] Issue #2060 genericize DataURIFieldConverter Change-Id: I885b0a8ec64eb69256c04fa2476814b1300fcdd4 Former-commit-id: 0a7265da59457e8dc6a122db81b134d6555d5276 --- .../dataplugin/annotations/DataURIFieldConverter.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/annotations/DataURIFieldConverter.java b/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/annotations/DataURIFieldConverter.java index 589161734a..cb539602d4 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/annotations/DataURIFieldConverter.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin/src/com/raytheon/uf/common/dataplugin/annotations/DataURIFieldConverter.java @@ -29,7 +29,8 @@ package com.raytheon.uf.common.dataplugin.annotations; * * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Oct 3, 2013 2081 mschenke Initial creation + * Oct 03, 2013 2081 mschenke Initial creation + * May 06, 2014 2060 njensen Added generics * * * @@ -37,7 +38,7 @@ package com.raytheon.uf.common.dataplugin.annotations; * @version 1.0 */ -public interface DataURIFieldConverter { +public interface DataURIFieldConverter { /** * Converts field object to a String for the DataURI @@ -45,7 +46,7 @@ public interface DataURIFieldConverter { * @param field * @return */ - public String toString(Object field); + public String toString(T field); /** * Converts String returned from {@link #toString()} back into a field @@ -54,6 +55,6 @@ public interface DataURIFieldConverter { * @param string * @return */ - public Object fromString(String string); + public T fromString(String string); } From 03ab7599deaeea51513bcecd8e22197e37d95feb Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Tue, 6 May 2014 15:54:23 -0500 Subject: [PATCH 153/188] Issue #2726: update smartInit threads to 1 Change-Id: Ic2d432087f66fd9f03b3d6f01fefce8af0d5b0b0 Former-commit-id: c12469d133558750e85049f7ce0f0a42b802c2b9 --- .../resources/com.raytheon.edex.plugin.gfe.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/edexOsgi/com.raytheon.edex.plugin.gfe/resources/com.raytheon.edex.plugin.gfe.properties b/edexOsgi/com.raytheon.edex.plugin.gfe/resources/com.raytheon.edex.plugin.gfe.properties index a5529c1a1c..da3c8dac1c 100644 --- a/edexOsgi/com.raytheon.edex.plugin.gfe/resources/com.raytheon.edex.plugin.gfe.properties +++ b/edexOsgi/com.raytheon.edex.plugin.gfe/resources/com.raytheon.edex.plugin.gfe.properties @@ -1,2 +1,2 @@ # The number of smart init threads to use -smartinit.threads=2 +smartinit.threads=1 From bbbf957ba88bada655413a58c6f3bf0a860dbced Mon Sep 17 00:00:00 2001 From: Ben Steffensmeier Date: Tue, 6 May 2014 16:15:37 -0500 Subject: [PATCH 154/188] Issue #3117 update satellite inventory for new sectors or elements. Former-commit-id: 35845fa63be35661893d31510f83e2d9ab6f60af --- .../META-INF/MANIFEST.MF | 3 +- .../inventory/SatelliteInventory.java | 33 ++++++++++++++++++- 2 files changed, 34 insertions(+), 2 deletions(-) diff --git a/cave/com.raytheon.viz.satellite/META-INF/MANIFEST.MF b/cave/com.raytheon.viz.satellite/META-INF/MANIFEST.MF index 3186ca34c3..7b2a3d75be 100644 --- a/cave/com.raytheon.viz.satellite/META-INF/MANIFEST.MF +++ b/cave/com.raytheon.viz.satellite/META-INF/MANIFEST.MF @@ -28,7 +28,8 @@ Require-Bundle: org.eclipse.ui, com.raytheon.uf.viz.datacube;bundle-version="1.14.0", com.raytheon.uf.common.dataplugin.level, com.raytheon.uf.common.comm, - com.raytheon.uf.common.numeric + com.raytheon.uf.common.numeric, + com.raytheon.viz.alerts Bundle-ActivationPolicy: lazy Export-Package: com.raytheon.viz.satellite, com.raytheon.viz.satellite.rsc diff --git a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteInventory.java b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteInventory.java index 6bfda8f9f8..3f94381331 100644 --- a/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteInventory.java +++ b/cave/com.raytheon.viz.satellite/src/com/raytheon/viz/satellite/inventory/SatelliteInventory.java @@ -53,6 +53,9 @@ import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.UFStatus; import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.time.DataTime; +import com.raytheon.uf.viz.core.alerts.AlertMessage; +import com.raytheon.viz.alerts.IAlertObserver; +import com.raytheon.viz.alerts.observers.ProductAlertObserver; /** * Inventory of available satellite data. sectorID is used for source and @@ -65,13 +68,15 @@ import com.raytheon.uf.common.time.DataTime; * Date Ticket# Engineer Description * ------------- -------- ----------- -------------------------- * Apr 09, 2014 2947 bsteffen Initial creation + * May 06, 2014 3117 bsteffen Update for new data. * * * * @author bsteffen * @version 1.0 */ -public class SatelliteInventory extends AbstractInventory { +public class SatelliteInventory extends AbstractInventory implements + IAlertObserver { private static final IUFStatusHandler statusHandler = UFStatus .getHandler(SatelliteInventory.class); @@ -88,6 +93,10 @@ public class SatelliteInventory extends AbstractInventory { private Level level; + public SatelliteInventory() { + ProductAlertObserver.addObserver(SATELLITE, this); + } + @Override public List timeAgnosticQuery(Map query) { /* Returning null means no data will be time agnostic. */ @@ -226,4 +235,26 @@ public class SatelliteInventory extends AbstractInventory { } } + @Override + public void alertArrived(Collection alertMessages) { + if (dataTree == null) { + return; + } + for (AlertMessage message : alertMessages) { + String sector = message.decodedAlert.get(SECTOR_ID).toString(); + String pe = message.decodedAlert.get(PHYSICALELEMENT).toString(); + if (dataTree.getParameterNode(sector, pe) == null) { + /* + * When a sector or element arrives that is not known reinit the + * tree to ensure no nodes are missing. + */ + try { + initTree(derParLibrary); + } catch (DataCubeException e) { + statusHandler.handle(Priority.PROBLEM, e.getLocalizedMessage(), e); + } + return; + } + } + } } From 5191b61b30f8e588052c95cdcd179c181ad61776 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Tue, 6 May 2014 17:08:04 -0500 Subject: [PATCH 155/188] Issue #3101 fix some derived parameters on win64 platform Change-Id: I9de1d31e7f7c19af437aef834aa84f163bf36d86 Former-commit-id: 4659c0240aa31b615bc50228906d514f47a72f94 --- .../base/derivedParameters/functions/Cape.py | 19 +++++++++++++------ .../base/derivedParameters/functions/Dcape.py | 4 +++- .../derivedParameters/functions/Filter.py | 10 +++++++++- 3 files changed, 25 insertions(+), 8 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Cape.py b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Cape.py index da98d5c111..d18b656da9 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Cape.py +++ b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Cape.py @@ -18,6 +18,14 @@ # further licensing information. ## +# SOFTWARE HISTORY +# +# Date Ticket# Engineer Description +# ------------ ---------- ----------- -------------------------- +# --/--/----- Initial creation +# May 06, 2014 3101 njensen Cast numpy shape values to int +# for cross platform compatibility + from com.raytheon.uf.common.derivparam.python.function import CapeFuncPythonAdapter as CapeFunc from numpy import zeros @@ -90,9 +98,8 @@ def __execute(*args): pressureValue = pressure pressure = zeros(temperatureValues.shape, temperatureValues.dtype) pressure[:] = pressureValue - if upperTerminationPressure is None: - threeDshape = pressureValues.shape - return CapeFunc.capeFunc(useVirtualTemp, pressureValues, temperatureValues, pressure, potentialTemperature, specificHumidity, threeDshape[1], threeDshape[2], threeDshape[0]).__numpy__ - else: - threeDshape = pressureValues.shape - return CapeFunc.capeFuncTop(useVirtualTemp, pressureValues, temperatureValues, pressure, potentialTemperature, specificHumidity, upperTerminationPressure, threeDshape[1], threeDshape[2], threeDshape[0]).__numpy__ + threeDshape = pressureValues.shape + if upperTerminationPressure is None: + return CapeFunc.capeFunc(useVirtualTemp, pressureValues, temperatureValues, pressure, potentialTemperature, specificHumidity, int(threeDshape[1]), int(threeDshape[2]), int(threeDshape[0])).__numpy__ + else: + return CapeFunc.capeFuncTop(useVirtualTemp, pressureValues, temperatureValues, pressure, potentialTemperature, specificHumidity, upperTerminationPressure, int(threeDshape[1]), int(threeDshape[2]), int(threeDshape[0])).__numpy__ diff --git a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Dcape.py b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Dcape.py index 778bab0f56..c8668c0b13 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Dcape.py +++ b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Dcape.py @@ -24,6 +24,8 @@ # ------------ ---------- ----------- -------------------------- # Feb 17, 2010 4502 jelkins Initial Creation. # Jun 05, 2013 2043 bsteffen Ported from meteolib C +# May 06, 2014 3101 njensen Cast numpy shape values to int +# for cross platform compatibility from numpy import zeros from com.raytheon.uf.common.derivparam.python.function import DCapeFuncPythonAdapter as DCapeFunc @@ -62,5 +64,5 @@ def execute(threeDtemperature, threeDdewpoint, pressure, potentialTemperature, s pressure = zeros(potentialTemperature.shape, potentialTemperature.dtype) pressure[:] = pressureValue threeDshape = threeDpressure.shape - return DCapeFunc.dcapeFunc(useVirtualTemp, threeDpressure, threeDtemperature[0], threeDdewpoint[0], pressure, potentialTemperature, specificHumidity, threeDshape[1], threeDshape[2], threeDshape[0], maxEvaporation, maxRelativeHumidity).__numpy__[0] + return DCapeFunc.dcapeFunc(useVirtualTemp, threeDpressure, threeDtemperature[0], threeDdewpoint[0], pressure, potentialTemperature, specificHumidity, int(threeDshape[1]), int(threeDshape[2]), int(threeDshape[0]), maxEvaporation, maxRelativeHumidity).__numpy__[0] diff --git a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Filter.py b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Filter.py index 3689fccf16..92f6e41ca8 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Filter.py +++ b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/Filter.py @@ -18,6 +18,14 @@ # further licensing information. ### +# SOFTWARE HISTORY +# +# Date Ticket# Engineer Description +# ------------ ---------- ----------- -------------------------- +# --/--/----- Initial creation +# May 06, 2014 3101 njensen Cast numpy shape values to int +# for cross platform compatibility + from numpy import ndarray, float32, NaN from numpy import sin, isnan, invert from com.raytheon.uf.common.derivparam.python.function import DistFilterPythonAdapter as DistFilter @@ -43,7 +51,7 @@ def execute(input, dist, dx, dy, times=1): #return executePython(input, npts, times) def executeJava(input, npts, times): - output = DistFilter.filter(input, npts, input.shape[1], input.shape[0], times).__numpy__[0] + output = DistFilter.filter(input, npts, int(input.shape[1]), int(input.shape[0]), times).__numpy__[0] output[output==1e37] = NaN return output From f06c77f5ad9f6fc82975ee7c42dcd153b19e7625 Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Wed, 7 May 2014 09:44:20 -0500 Subject: [PATCH 156/188] Issue #2060 log successful sat precip file creation Change-Id: I40df627645e0c0e089609f8dcc56b8351a4c56f1 Former-commit-id: b3158ae940ab59a7a96b4650f0f956c82b0c9d49 --- .../src/com/raytheon/uf/edex/ohd/pproc/SatPrecipFileBuilder.java | 1 + 1 file changed, 1 insertion(+) diff --git a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/SatPrecipFileBuilder.java b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/SatPrecipFileBuilder.java index a23aa8d668..6ba1a77223 100644 --- a/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/SatPrecipFileBuilder.java +++ b/edexOsgi/com.raytheon.uf.edex.ohd/src/com/raytheon/uf/edex/ohd/pproc/SatPrecipFileBuilder.java @@ -171,6 +171,7 @@ public class SatPrecipFileBuilder { xmfile.setData(data); xmfile.save(fname); + logger.info("Successfully created satellite precip xmrg file: " + fname); } /** From a2ef100bfc1b74082ab0fb70f7cce5bc599318e0 Mon Sep 17 00:00:00 2001 From: Dave Hladky Date: Wed, 7 May 2014 14:51:38 -0500 Subject: [PATCH 157/188] Issue #2940 More filenames printed, null from bad rec. Former-commit-id: 26bfd426965d208f92bcb1fcd650b5f2299724a4 --- .../plugin/ffmp/common/FFMPProcessor.java | 55 +++++++++++-------- 1 file changed, 31 insertions(+), 24 deletions(-) diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java index be1166159b..a841b1d811 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java @@ -95,12 +95,12 @@ import com.vividsolutions.jts.geom.Polygon; * ------------ ---------- ----------- -------------------------- * * 07/14/09 2152 D. Hladky Initial release - * 10/25/12 DR 15514 G. Zhang Fix ConcurrentModificationException + * 10/25/12 DR 15514 G. Zhang Fix ConcurrentModificationException * 02/01/13 1569 D. Hladky Added constants * 02/25/13 1660 D. Hladky FFTI design change to help mosaic processing. * 05/01/2013 15684 zhao Unlock when Exception caught * Jul 15, 2013 2184 dhladky Remove all HUC's for storage except ALL - * 09/03/2013 DR 13083 G. Zhang Added a fix in processRADAR(ArrayList). + * 09/03/2013 DR 13083 G. Zhang Added a fix in processRADAR(ArrayList). * 03 April 2014 2940 dhladky Better error message for bad configurations. * * @author dhladky @@ -218,7 +218,7 @@ public class FFMPProcessor { } statusHandler.handle(Priority.INFO, - "Processed Source: " + ffmpRec.getSourceName() + " sitekey: " + "Processed Source: " + source.getSourceName() + " sitekey: " + siteKey + " dataKey: " + dataKey + " time: " + (System.currentTimeMillis() - time)); @@ -637,12 +637,12 @@ public class FFMPProcessor { + source.getDisplayName(); } - Date backDate = new Date(ffmpRec.getDataTime().getRefTime() - .getTime()-(FFMPGenerator.SOURCE_CACHE_TIME * TimeUtil.MILLIS_PER_HOUR)); - - FFMPDataContainer ffgContainer = generator - .getFFMPDataContainer(sourceNameString, - backDate); + Date backDate = new Date(ffmpRec.getDataTime().getRefTime() + .getTime()-(FFMPGenerator.SOURCE_CACHE_TIME * TimeUtil.MILLIS_PER_HOUR)); + + FFMPDataContainer ffgContainer = generator + .getFFMPDataContainer(sourceNameString, + backDate); if (ffgContainer != null && ffgContainer.containsKey(source.getSourceName())) { @@ -1139,19 +1139,19 @@ public class FFMPProcessor { if (radarRec.getMnemonic().equals("DHR")) { for (int j = 0; j < dataVals.length; j++) { - try { - val += ScanUtils.getZRvalue2(dataVals[j],//fval,// DR 13083 - dhrMap.get(DHRValues.ZRMULTCOEFF), - dhrMap.get(DHRValues.MAXPRECIPRATEALLOW), - dhrMap.get(DHRValues.ZRPOWERCOEFF), - dhrMap.get(DHRValues.BIAS_TO_USE)) - * areas[j]; - area += areas[j]; - } catch (Exception e) { - statusHandler - .error("DHR parameters are NULL, can't process!" - + e.getMessage()); - } + try { + val += ScanUtils.getZRvalue2(dataVals[j],//fval,// DR 13083 + dhrMap.get(DHRValues.ZRMULTCOEFF), + dhrMap.get(DHRValues.MAXPRECIPRATEALLOW), + dhrMap.get(DHRValues.ZRPOWERCOEFF), + dhrMap.get(DHRValues.BIAS_TO_USE)) + * areas[j]; + area += areas[j]; + } catch (Exception e) { + statusHandler + .error("DHR parameters are NULL, can't process!" + + e.getMessage()); + } } } else if (radarRec.getMnemonic().equals("DPR")) { @@ -1826,18 +1826,25 @@ public class FFMPProcessor { } /** - * Gets the XMRG data array + * Gets the XMRG data array, checks HRAP/XMRG config for sanity. * * @return */ private short[][] getXMRGData() throws Exception { + String fileName = "MISSING"; + + if (xmrg.getFile() != null) { + fileName = xmrg.getFile().getAbsolutePath(); + } + this.extent = getExtents(source.getHrapGridFactor()); setHRAPSubGrid(extent, source.getHrapGridFactor()); + if (xmrg.getHrapExtent() != null) { xmrgData = xmrg.getData(extent); } else { - throw new MalformedDataException("The XMRG data is malformed or the file is non-readable."); + throw new MalformedDataException("The XMRG data is malformed or the file is non-readable. "+fileName); } return xmrgData; From e39378e5f0c8c6e75eed3037f933a30ed75092ba Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Wed, 7 May 2014 15:30:13 -0500 Subject: [PATCH 158/188] Issue #2060 fix grid updates and performance Change-Id: I0937d7360e456f08fb613be547f7b488ebe05b50 Former-commit-id: a430e85f283b3e41b8520d241f675eff3c6c32e3 --- .../dataplugin/grid/GridInfoRecord.java | 3 +- .../uf/common/dataplugin/grid/GridRecord.java | 10 ++++ .../uf/common/parameter/Parameter.java | 2 + .../common/parameter/ParameterConverter.java | 59 ------------------- 4 files changed, 13 insertions(+), 61 deletions(-) delete mode 100644 edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/ParameterConverter.java diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridInfoRecord.java b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridInfoRecord.java index 1ed01e29bb..7a40edd823 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridInfoRecord.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridInfoRecord.java @@ -36,7 +36,6 @@ import com.raytheon.uf.common.dataplugin.persist.PersistableDataObject; import com.raytheon.uf.common.gridcoverage.GridCoverage; import com.raytheon.uf.common.gridcoverage.convert.GridCoverageConverter; import com.raytheon.uf.common.parameter.Parameter; -import com.raytheon.uf.common.parameter.ParameterConverter; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; @@ -107,7 +106,7 @@ public class GridInfoRecord extends PersistableDataObject { @ManyToOne @PrimaryKeyJoinColumn - @DataURI(position = 4, converter = ParameterConverter.class) + @DataURI(position = 4, embedded = true) @DynamicSerializeElement private Parameter parameter; diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridRecord.java b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridRecord.java index eed4f41d18..807e7fa89e 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridRecord.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.grid/src/com/raytheon/uf/common/dataplugin/grid/GridRecord.java @@ -41,6 +41,7 @@ import com.raytheon.uf.common.geospatial.ISpatialEnabled; import com.raytheon.uf.common.geospatial.ISpatialObject; import com.raytheon.uf.common.gridcoverage.GridCoverage; import com.raytheon.uf.common.parameter.Parameter; +import com.raytheon.uf.common.parameter.lookup.ParameterLookup; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; @@ -66,6 +67,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; * Aug 30, 2013 2298 rjpeter Make getPluginName abstract * Dec 16, 2013 2574 bsteffen Remove getDecoderGettable. * Apr 15, 2014 2060 njensen Remove dataURI column + * May 07, 2014 2060 njensen GridRecord(String) will do parameter lookup * * * @@ -117,6 +119,14 @@ public class GridRecord extends PersistablePluginDataObject implements public GridRecord(String uri) { super(uri); + String abbrev = this.getInfo().getParameter().getAbbreviation(); + if (abbrev != null) { + Parameter paramWithUnits = ParameterLookup.getInstance() + .getParameter(abbrev); + if (paramWithUnits != null) { + this.getInfo().setParameter(paramWithUnits); + } + } } public GridInfoRecord getInfo() { diff --git a/edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/Parameter.java b/edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/Parameter.java index 6479a8a49b..b7ecd7d3bb 100644 --- a/edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/Parameter.java +++ b/edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/Parameter.java @@ -34,6 +34,7 @@ import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlElement; import javax.xml.bind.annotation.XmlRootElement; +import com.raytheon.uf.common.dataplugin.annotations.DataURI; import com.raytheon.uf.common.dataplugin.persist.PersistableDataObject; import com.raytheon.uf.common.serialization.ISerializableObject; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; @@ -70,6 +71,7 @@ public class Parameter extends PersistableDataObject implements @Id @DynamicSerializeElement @XmlElement + @DataURI(position = 0) private String abbreviation; @Column(nullable = false) diff --git a/edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/ParameterConverter.java b/edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/ParameterConverter.java deleted file mode 100644 index 7ebeab9c80..0000000000 --- a/edexOsgi/com.raytheon.uf.common.parameter/src/com/raytheon/uf/common/parameter/ParameterConverter.java +++ /dev/null @@ -1,59 +0,0 @@ -/** - * This software was developed and / or modified by Raytheon Company, - * pursuant to Contract DG133W-05-CQ-1067 with the US Government. - * - * U.S. EXPORT CONTROLLED TECHNICAL DATA - * This software product contains export-restricted data whose - * export/transfer/disclosure is restricted by U.S. law. Dissemination - * to non-U.S. persons whether in the United States or abroad requires - * an export license or other authorization. - * - * Contractor Name: Raytheon Company - * Contractor Address: 6825 Pine Street, Suite 340 - * Mail Stop B8 - * Omaha, NE 68106 - * 402.291.0100 - * - * See the AWIPS II Master Rights File ("Master Rights File.pdf") for - * further licensing information. - **/ -package com.raytheon.uf.common.parameter; - -import com.raytheon.uf.common.dataplugin.annotations.DataURIFieldConverter; -import com.raytheon.uf.common.parameter.lookup.ParameterLookup; - -/** - * A DataURIFieldConverter that ensures that a String parameter abbreviation - * will be looked up to potentially contain all the fields. - * - *
- * 
- * SOFTWARE HISTORY
- * 
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * May 6, 2014  2060       njensen     Initial creation
- * 
- * 
- * - * @author njensen - * @version 1.0 - */ - -public class ParameterConverter implements DataURIFieldConverter { - - @Override - public String toString(Parameter field) { - return field.getAbbreviation(); - } - - @Override - public Parameter fromString(String string) { - Parameter p = ParameterLookup.getInstance().getParameter(string); - if (p == null) { - p = new Parameter(string); - } - return p; - } - -} From e7341afe4d6afaef7ff66538e2ed66646e881957 Mon Sep 17 00:00:00 2001 From: Michael Gamazaychikov Date: Thu, 8 May 2014 13:51:38 +0100 Subject: [PATCH 159/188] ASM #526 - Duration menu disabled after creating text for a COR SVS. Change-Id: I23135a56247ba75c7ce980b5eddcf4e7dd30aebf Former-commit-id: f934537da168238e76f0be04fc518f6ad315637e --- .../src/com/raytheon/viz/warngen/gui/WarngenDialog.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenDialog.java b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenDialog.java index 6c9c28ff36..6a0d096ff7 100644 --- a/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenDialog.java +++ b/cave/com.raytheon.viz.warngen/src/com/raytheon/viz/warngen/gui/WarngenDialog.java @@ -153,6 +153,7 @@ import com.vividsolutions.jts.geom.Polygon; * Oct 01, 2013 DR16612 m.gamazaychikov Fixed inconsistencies with track locking and updateListSelected method * Oct 29, 2013 DR 16734 D. Friedman If redraw-from-hatched-area fails, don't allow the polygon the be used. * Apr 24, 2014 DR 16356 Qinglu Lin Updated selectOneStorm() and selectLineOfStorms(). + * May 09, 2014 DR16694 m.gamazaychikov Fixed disabled duration menu after creating text for a COR SVS. * * * @author chammack @@ -1251,6 +1252,7 @@ public class WarngenDialog extends CaveSWTDialog implements warngenLayer.resetState(); warngenLayer.getStormTrackState().duration = ((DurationData) durationList .getData(durationList.getItem(durationList.getSelectionIndex()))).minutes; + durationList.setEnabled(true); if (lineOfStorms.getSelection()) { selectLineOfStorms(); } else { From 24539708f941c74b1822a6cb90cbc18b334696c8 Mon Sep 17 00:00:00 2001 From: Richard Peter Date: Thu, 8 May 2014 10:14:30 -0500 Subject: [PATCH 160/188] Issue #2726: Fix GeospatialDataGenerator NPE Change-Id: I07213e17fcbbadea9a33471c390bb07472ba31e0 Former-commit-id: fdc542df454887a48f4a55ef6ea9594ff98b3345 --- .../warning/gis/GeospatialDataGenerator.java | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataGenerator.java b/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataGenerator.java index 4af2dce791..5e74490853 100644 --- a/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataGenerator.java +++ b/edexOsgi/com.raytheon.edex.plugin.warning/src/com/raytheon/edex/plugin/warning/gis/GeospatialDataGenerator.java @@ -741,14 +741,18 @@ public class GeospatialDataGenerator { private String getTimeStamp(GeospatialTime curTime, GeospatialTime lastRunTime) { long tmStampMs = 0; - if (curTime.getAreaSourceTime() != lastRunTime.getAreaSourceTime()) { + if (lastRunTime != null) { + if (curTime.getAreaSourceTime() != lastRunTime.getAreaSourceTime()) { + tmStampMs = curTime.getAreaSourceTime(); + } else if (curTime.getParentSourceTime() != lastRunTime + .getParentSourceTime()) { + tmStampMs = curTime.getParentSourceTime(); + } else if (curTime.getTimeZoneSourceTime() != lastRunTime + .getTimeZoneSourceTime()) { + tmStampMs = curTime.getTimeZoneSourceTime(); + } + } else { tmStampMs = curTime.getAreaSourceTime(); - } else if (curTime.getParentSourceTime() != lastRunTime - .getParentSourceTime()) { - tmStampMs = curTime.getParentSourceTime(); - } else if (curTime.getTimeZoneSourceTime() != lastRunTime - .getTimeZoneSourceTime()) { - tmStampMs = curTime.getTimeZoneSourceTime(); } SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss.SSS"); From 0308147ad41d765471002e15f36361f534307c5a Mon Sep 17 00:00:00 2001 From: Ben Steffensmeier Date: Thu, 8 May 2014 11:47:47 -0500 Subject: [PATCH 161/188] Issue #3080 Fix NaN handling of SliceSample. Former-commit-id: 9974018df428c84528cf98e9f868740accbabf58 --- .../base/derivedParameters/functions/SliceSample.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/SliceSample.py b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/SliceSample.py index 4c7988278b..3c42b7d19f 100644 --- a/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/SliceSample.py +++ b/edexOsgi/com.raytheon.uf.common.derivparam.python/utility/common_static/base/derivedParameters/functions/SliceSample.py @@ -19,7 +19,9 @@ ## import gridslice -from numpy import zeros, float32 +from numpy import zeros, float32, NaN + +gridslice_maskval = 1e37 def execute(*args): #createNumpySlice(vc, s3d, targetLevel, sense, hyb-optional) @@ -35,9 +37,11 @@ def execute(*args): grid = zeros((args[0][1].shape[1], args[0][1].shape[2]),float32) grid.fill(args[1]) rval = gridslice.createNumpySlice(args[0][1], args[0][0], grid, int(args[2]), int(args[3])) + rval[rval == gridslice_maskval] = NaN return rval else: # cube, cube, grid, sense, hybrid rval = gridslice.createNumpySlice(args[1][0], args[0][0], args[2], int(args[3]), int(args[4])) + rval[rval == gridslice_maskval] = NaN return rval \ No newline at end of file From f013b4928236bd8cce9446383f06771ff9e74adb Mon Sep 17 00:00:00 2001 From: "Kiran.Shrestha" Date: Thu, 8 May 2014 15:07:42 -0400 Subject: [PATCH 162/188] ASM #506 - TextWS: Unable to save unofficial text products from text editor. Change-Id: I27aab39c7af355f660d873b1a17b7d94209fb13b Former-commit-id: 1ac375914b05ea937439b6c0802291f49ff38938 --- .../dialogs/AWIPSHeaderBlockDlg.java | 8 +++- .../texteditor/dialogs/TextEditorDialog.java | 39 ++++++++++++++++++- 2 files changed, 44 insertions(+), 3 deletions(-) diff --git a/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/dialogs/AWIPSHeaderBlockDlg.java b/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/dialogs/AWIPSHeaderBlockDlg.java index e3e9098e01..57751394cb 100644 --- a/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/dialogs/AWIPSHeaderBlockDlg.java +++ b/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/dialogs/AWIPSHeaderBlockDlg.java @@ -99,6 +99,8 @@ import com.raytheon.viz.ui.dialogs.ICloseCallback; * 11/26/2012 14526 mgamazaychikov Added traverse listener for RETURN key * 10/07/2013 16664 mgamazaychikov Added padProdDesignatorText method * 11/21/2013 16633 mgamazaychikov Improved consistency between AFOS PIL and WMO Heading fields. + * 08May2014 16041 kshrestha Save unofficial text products from text editor. + * * * * @author lvenable @@ -646,6 +648,7 @@ public class AWIPSHeaderBlockDlg extends CaveSWTDialog implements return; } boolean sendEnabled = true; + boolean unOfficialProd = false; if (!isProductValid()) { // Notify the user that the product may not be valid. // @@ -665,6 +668,9 @@ public class AWIPSHeaderBlockDlg extends CaveSWTDialog implements } parentEditor.enableSend(false); sendEnabled = false; + if(isAfosPilComplete()) { + unOfficialProd = true; + } } else { parentEditor.enableSend(true); } @@ -672,7 +678,7 @@ public class AWIPSHeaderBlockDlg extends CaveSWTDialog implements // call the set methods parentEditor.setCurrentWmoId(wmoTtaaiiTF.getText()); parentEditor.setCurrentSiteId(ccccTF.getText()); - if (sendEnabled) { + if (sendEnabled || (sendEnabled == false && unOfficialProd == true)) { parentEditor.setCurrentWsfoId(wsfoIdTF.getText()); parentEditor.setCurrentProdCategory(prodCatTF.getText()); parentEditor.setCurrentProdDesignator(prodDesignatorTF.getText()); diff --git a/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/dialogs/TextEditorDialog.java b/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/dialogs/TextEditorDialog.java index e17f2bbd50..c1333b969f 100644 --- a/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/dialogs/TextEditorDialog.java +++ b/cave/com.raytheon.viz.texteditor/src/com/raytheon/viz/texteditor/dialogs/TextEditorDialog.java @@ -336,6 +336,8 @@ import com.raytheon.viz.ui.dialogs.SWTMessageBox; * 10Dec2013 2601 mpduff Fix NullPointerException. * 28Jan2014 DR14595 mgamazaychikov Added template loading and editing functionality. * 14Mar2014 DR 17175 D. Friedman Get correct time zone for MND header time sync. + * 08May2014 DR 16041 kshrestha Save unofficial text products from text editor. + * * * * @author lvenable @@ -4396,7 +4398,7 @@ public class TextEditorDialog extends CaveSWTDialog implements VerifyListener, .getProductCategory(token) + tdm.getProductDesignator(token); // Set the header text field. - if (bbbid.equals("NOR")) { + if (bbbid.equals("NOR") || tdm.getAfosPil(token) != null) { String wmoId = tdm.getWmoId(token); wmoId = (wmoId.length() > 0 ? wmoId : "-"); String siteId = tdm.getSiteId(token); @@ -5297,8 +5299,11 @@ public class TextEditorDialog extends CaveSWTDialog implements VerifyListener, if (!isAutoSave) { if (!resend) { // If not a resend, set the DDHHMM field to the current time + if (productText.startsWith("- -") && productText.contains("DDHHMM")) { + productText = getUnofficeProduct(currentDate); + } else { productText = replaceDDHHMM(productText, currentDate); - + } VtecObject vtecObj = VtecUtil.parseMessage(productText); if (warnGenFlag) { /* @@ -8628,4 +8633,34 @@ public class TextEditorDialog extends CaveSWTDialog implements VerifyListener, modifiedText = removeSoftReturns(modifiedText); return modifiedText; } + + private String getUnofficeProduct(String currDate) + { + StdTextProduct textProd = TextDisplayModel.getInstance().getStdTextProduct(token); + + String header = headerTF.getText(); + + String nnn = textProd.getNnnid(); + String xxx = textProd.getXxxid(); + String nnnXxx = nnn + xxx; + String site = SiteMap.getInstance().getSite4LetterId( + textProd.getCccid()); + String wmoId = textProd.getCccid() + nnnXxx + " " + + getAddressee() + "\nTTAA00 " + site; + + header = header.replaceFirst("\n" + nnnXxx, ""); + header = header.replaceFirst("-", "ZCZC"); + header = header.replaceFirst("-", wmoId); + + if (currDate != null) + header = header.replaceFirst("DDHHMM", currDate); + else + header = header.replaceFirst("DDHHMM", textProd.getHdrtime()); + + String body = textEditor.getText().toUpperCase(); + + header = header + "\n\n"+body +"\n!--not sent--!"; + + return header; + } } From 3e3035b6f163ca443ecd12c4e4f9a08a1e8e168e Mon Sep 17 00:00:00 2001 From: Nate Jensen Date: Thu, 8 May 2014 14:01:54 -0500 Subject: [PATCH 163/188] Issue #2060 fix auto-update errors with grids in non-map displays Change-Id: Id99693f6fd54d56a4a1255f7ee5e2308e2f5d9de Former-commit-id: a139113883f69be89a0e0a771f8d6f48d3948686 --- .../viz/d2d/nsharp/rsc/D2DNSharpResourceData.java | 3 +++ .../crosssection/rsc/CrossSectionResourceData.java | 6 ++++++ .../xy/timeseries/rsc/TimeSeriesResourceData.java | 8 ++++++++ .../xy/varheight/rsc/VarHeightResourceData.java | 14 +++++++++----- 4 files changed, 26 insertions(+), 5 deletions(-) diff --git a/cave/com.raytheon.uf.viz.d2d.nsharp/src/com/raytheon/uf/viz/d2d/nsharp/rsc/D2DNSharpResourceData.java b/cave/com.raytheon.uf.viz.d2d.nsharp/src/com/raytheon/uf/viz/d2d/nsharp/rsc/D2DNSharpResourceData.java index 0463297fdf..5d9e3e5c52 100644 --- a/cave/com.raytheon.uf.viz.d2d.nsharp/src/com/raytheon/uf/viz/d2d/nsharp/rsc/D2DNSharpResourceData.java +++ b/cave/com.raytheon.uf.viz.d2d.nsharp/src/com/raytheon/uf/viz/d2d/nsharp/rsc/D2DNSharpResourceData.java @@ -41,6 +41,7 @@ import javax.xml.bind.annotation.XmlElement; import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.common.time.DataTime; import com.raytheon.uf.common.time.DataTime.FLAG; +import com.raytheon.uf.viz.core.alerts.DataCubeAlertMessageParser; import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.uf.viz.core.rsc.AbstractRequestableResourceData; import com.raytheon.uf.viz.core.rsc.AbstractVizResource; @@ -60,6 +61,7 @@ import com.vividsolutions.jts.geom.Coordinate; * Apr 12, 2011 bsteffen Initial creation * May 31, 2013 1847 bsteffen D2D nsharp will now format Lat/Lons as * stationId like NC ncharp. + * May 08, 2014 2060 njensen Constructor sets alert parser * * * @@ -81,6 +83,7 @@ public abstract class D2DNSharpResourceData extends public D2DNSharpResourceData() { super(); + this.setAlertParser(new DataCubeAlertMessageParser()); } public D2DNSharpResourceData(String soundingType) { diff --git a/cave/com.raytheon.uf.viz.xy.crosssection/src/com/raytheon/uf/viz/xy/crosssection/rsc/CrossSectionResourceData.java b/cave/com.raytheon.uf.viz.xy.crosssection/src/com/raytheon/uf/viz/xy/crosssection/rsc/CrossSectionResourceData.java index a9a1ef4d2f..5d5296d1fe 100644 --- a/cave/com.raytheon.uf.viz.xy.crosssection/src/com/raytheon/uf/viz/xy/crosssection/rsc/CrossSectionResourceData.java +++ b/cave/com.raytheon.uf.viz.xy.crosssection/src/com/raytheon/uf/viz/xy/crosssection/rsc/CrossSectionResourceData.java @@ -40,6 +40,7 @@ import org.eclipse.core.runtime.Platform; import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.common.time.DataTime; import com.raytheon.uf.viz.core.RecordFactory; +import com.raytheon.uf.viz.core.alerts.DataCubeAlertMessageParser; import com.raytheon.uf.viz.core.drawables.IDescriptor; import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.uf.viz.core.rsc.AbstractRequestableResourceData; @@ -59,6 +60,7 @@ import com.raytheon.uf.viz.xy.crosssection.display.CrossSectionDescriptor; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Feb 17, 2009 njensen Initial creation + * May 08, 2014 2060 njensen Constructor sets alert parser * * * @@ -88,6 +90,10 @@ public class CrossSectionResourceData extends AbstractRequestableResourceData { private Set blackListedTimes = new HashSet(); + public CrossSectionResourceData() { + this.setAlertParser(new DataCubeAlertMessageParser()); + } + @Override public AbstractVizResource construct(LoadProperties loadProperties, IDescriptor descriptor) throws VizException { diff --git a/cave/com.raytheon.uf.viz.xy.timeseries/src/com/raytheon/uf/viz/xy/timeseries/rsc/TimeSeriesResourceData.java b/cave/com.raytheon.uf.viz.xy.timeseries/src/com/raytheon/uf/viz/xy/timeseries/rsc/TimeSeriesResourceData.java index c15aa1eab0..4018fd3dfe 100644 --- a/cave/com.raytheon.uf.viz.xy.timeseries/src/com/raytheon/uf/viz/xy/timeseries/rsc/TimeSeriesResourceData.java +++ b/cave/com.raytheon.uf.viz.xy.timeseries/src/com/raytheon/uf/viz/xy/timeseries/rsc/TimeSeriesResourceData.java @@ -35,6 +35,7 @@ import org.eclipse.core.runtime.Platform; import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.viz.core.RecordFactory; +import com.raytheon.uf.viz.core.alerts.DataCubeAlertMessageParser; import com.raytheon.uf.viz.core.drawables.IDescriptor; import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.uf.viz.core.rsc.AbstractRequestableResourceData; @@ -55,6 +56,7 @@ import com.vividsolutions.jts.geom.Coordinate; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Feb 23, 2009 njensen Initial creation + * May 08, 2014 2060 njensen Constructor sets alert parser * * * @@ -107,6 +109,10 @@ public class TimeSeriesResourceData extends AbstractRequestableResourceData private AbstractVizResource secondaryResource; + public TimeSeriesResourceData() { + this.setAlertParser(new DataCubeAlertMessageParser()); + } + /* * (non-Javadoc) * @@ -255,10 +261,12 @@ public class TimeSeriesResourceData extends AbstractRequestableResourceData this.source = source; } + @Override public String getPointLetter() { return pointLetter; } + @Override public void setPointLetter(String pointLetter) { this.pointLetter = pointLetter; } diff --git a/cave/com.raytheon.uf.viz.xy.varheight/src/com/raytheon/uf/viz/xy/varheight/rsc/VarHeightResourceData.java b/cave/com.raytheon.uf.viz.xy.varheight/src/com/raytheon/uf/viz/xy/varheight/rsc/VarHeightResourceData.java index 1d803ffc92..d87bcd841a 100644 --- a/cave/com.raytheon.uf.viz.xy.varheight/src/com/raytheon/uf/viz/xy/varheight/rsc/VarHeightResourceData.java +++ b/cave/com.raytheon.uf.viz.xy.varheight/src/com/raytheon/uf/viz/xy/varheight/rsc/VarHeightResourceData.java @@ -37,6 +37,7 @@ import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.common.geospatial.ISpatialEnabled; import com.raytheon.uf.common.time.DataTime; import com.raytheon.uf.viz.core.RecordFactory; +import com.raytheon.uf.viz.core.alerts.DataCubeAlertMessageParser; import com.raytheon.uf.viz.core.drawables.IDescriptor; import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.uf.viz.core.rsc.AbstractRequestableResourceData; @@ -49,7 +50,7 @@ import com.raytheon.viz.core.rsc.ICombinedResourceData; import com.vividsolutions.jts.geom.Coordinate; /** - * TODO Add Description + * Resource data for var height displays * *
  * 
@@ -59,6 +60,7 @@ import com.vividsolutions.jts.geom.Coordinate;
  * Feb 20, 2009            njensen     Initial creation
  * Aug 15, 2013 2258       bsteffen    Convert profiler sounding to var height
  *                                     with hodo.
+ * May 08, 2014 2060       njensen     Constructor sets alert parser
  * 
  * 
* @@ -95,6 +97,10 @@ public class VarHeightResourceData extends AbstractRequestableResourceData private AbstractVizResource secondaryResource; + public VarHeightResourceData() { + this.setAlertParser(new DataCubeAlertMessageParser()); + } + /* * (non-Javadoc) * @@ -155,10 +161,6 @@ public class VarHeightResourceData extends AbstractRequestableResourceData rsc.addRecord(rec); } return rsc; - } else { - throw new VizException( - "No resource type available for record type: " - + pdo.getClass().getName()); } } throw new VizException( @@ -351,10 +353,12 @@ public class VarHeightResourceData extends AbstractRequestableResourceData this.point = pointCoordinate; } + @Override public String getPointLetter() { return pointLetter; } + @Override public void setPointLetter(String pointLetter) { this.pointLetter = pointLetter; } From 8498235fd874a5c3c20e0173107db31e9a2a680c Mon Sep 17 00:00:00 2001 From: Mike Duff Date: Tue, 6 May 2014 10:28:55 -0500 Subject: [PATCH 164/188] Issue #3026 - Implement HPE bias source labels on FFMP and volume browser displays Change-Id: Ib17ff7cfcb5efcb1737804800a93ec4f82bc6f13 Former-commit-id: 57755db0d6d77f32d64b4b569bb0af88002a23da --- .../feature.xml | 6 + cave/com.raytheon.uf.viz.hpe/.classpath | 7 + cave/com.raytheon.uf.viz.hpe/.project | 28 ++ .../.settings/org.eclipse.jdt.core.prefs | 11 + .../META-INF/MANIFEST.MF | 22 ++ cave/com.raytheon.uf.viz.hpe/build.properties | 4 + cave/com.raytheon.uf.viz.hpe/plugin.xml | 30 ++ .../uf/viz/hpe/D2DHpeDisplayCustomizer.java | 265 +++++++++++++ .../uf/viz/hpe/rsc/HpeLabelResource.java | 225 +++++++++++ .../uf/viz/hpe/rsc/HpeLabelResourceData.java | 71 ++++ .../raytheon/uf/viz/hpe/util/HpeUtils.java | 69 ++++ .../META-INF/MANIFEST.MF | 3 +- .../viz/monitor/ffmp/ui/rsc/FFMPResource.java | 136 +++++-- .../viz/grid/rsc/general/GridResource.java | 5 +- .../feature.xml | 7 + .../14.3.1/DR3026/addMetadataColumnFFMP.sh | 16 + .../uf/common/dataplugin/ffmp/FFMPRecord.java | 20 + .../common_static/base/hydro/Apps_defaults | 3 + .../.classpath | 7 + .../.project | 28 ++ .../.settings/org.eclipse.jdt.core.prefs | 7 + .../META-INF/MANIFEST.MF | 17 + .../build.properties | 4 + .../common/plugin/hpe/data/BiasDynRecord.java | 204 ++++++++++ .../hpe/request/HpeLabelDataRequest.java | 120 ++++++ .../hpe/request/HpeLabelDataResponse.java | 65 ++++ .../feature.xml | 13 + .../META-INF/MANIFEST.MF | 3 +- .../plugin/ffmp/common/FFMPProcessor.java | 2 + .../.classpath | 7 + .../com.raytheon.uf.edex.plugin.hpe/.project | 28 ++ .../.settings/org.eclipse.jdt.core.prefs | 11 + .../META-INF/MANIFEST.MF | 18 + .../build.properties | 5 + .../res/spring/hpe-file-endpoint.xml | 38 ++ .../res/spring/hpe-request.xml | 15 + .../hpe/handler/HpeLabelDataHandler.java | 86 +++++ .../hpe/process/HpeGribFileNameProcessor.java | 62 +++ .../edex/plugin/hpe/util/HpeDataAccessor.java | 244 ++++++++++++ .../uf/edex/plugin/hpe/util/HpeEnums.java | 82 ++++ .../plugin/hpe/util/HpeLabelGenerator.java | 183 +++++++++ .../edex/plugin/hpe/util/HpeRadarResult.java | 181 +++++++++ .../precip_proc/bin/process_hpe_grib_files | 8 +- tests/.classpath | 2 + .../hpe/util/HpeLabelGeneratorTest.java | 364 ++++++++++++++++++ 45 files changed, 2702 insertions(+), 30 deletions(-) create mode 100644 cave/com.raytheon.uf.viz.hpe/.classpath create mode 100644 cave/com.raytheon.uf.viz.hpe/.project create mode 100644 cave/com.raytheon.uf.viz.hpe/.settings/org.eclipse.jdt.core.prefs create mode 100644 cave/com.raytheon.uf.viz.hpe/META-INF/MANIFEST.MF create mode 100644 cave/com.raytheon.uf.viz.hpe/build.properties create mode 100644 cave/com.raytheon.uf.viz.hpe/plugin.xml create mode 100644 cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/D2DHpeDisplayCustomizer.java create mode 100644 cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/rsc/HpeLabelResource.java create mode 100644 cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/rsc/HpeLabelResourceData.java create mode 100644 cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/util/HpeUtils.java create mode 100644 deltaScripts/14.3.1/DR3026/addMetadataColumnFFMP.sh create mode 100644 edexOsgi/com.raytheon.uf.common.plugin.hpe/.classpath create mode 100644 edexOsgi/com.raytheon.uf.common.plugin.hpe/.project create mode 100644 edexOsgi/com.raytheon.uf.common.plugin.hpe/.settings/org.eclipse.jdt.core.prefs create mode 100644 edexOsgi/com.raytheon.uf.common.plugin.hpe/META-INF/MANIFEST.MF create mode 100644 edexOsgi/com.raytheon.uf.common.plugin.hpe/build.properties create mode 100644 edexOsgi/com.raytheon.uf.common.plugin.hpe/src/com/raytheon/uf/common/plugin/hpe/data/BiasDynRecord.java create mode 100644 edexOsgi/com.raytheon.uf.common.plugin.hpe/src/com/raytheon/uf/common/plugin/hpe/request/HpeLabelDataRequest.java create mode 100644 edexOsgi/com.raytheon.uf.common.plugin.hpe/src/com/raytheon/uf/common/plugin/hpe/request/HpeLabelDataResponse.java create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.hpe/.classpath create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.hpe/.project create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.hpe/.settings/org.eclipse.jdt.core.prefs create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.hpe/META-INF/MANIFEST.MF create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.hpe/build.properties create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.hpe/res/spring/hpe-file-endpoint.xml create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.hpe/res/spring/hpe-request.xml create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/handler/HpeLabelDataHandler.java create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/process/HpeGribFileNameProcessor.java create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeDataAccessor.java create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeEnums.java create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeLabelGenerator.java create mode 100644 edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeRadarResult.java create mode 100644 tests/manual/com/raytheon/uf/edex/plugin/hpe/util/HpeLabelGeneratorTest.java diff --git a/cave/com.raytheon.uf.viz.dat.feature/feature.xml b/cave/com.raytheon.uf.viz.dat.feature/feature.xml index 7e473721cb..c1696c082b 100644 --- a/cave/com.raytheon.uf.viz.dat.feature/feature.xml +++ b/cave/com.raytheon.uf.viz.dat.feature/feature.xml @@ -169,4 +169,10 @@ version="0.0.0" unpack="false"/> + + diff --git a/cave/com.raytheon.uf.viz.hpe/.classpath b/cave/com.raytheon.uf.viz.hpe/.classpath new file mode 100644 index 0000000000..ad32c83a78 --- /dev/null +++ b/cave/com.raytheon.uf.viz.hpe/.classpath @@ -0,0 +1,7 @@ + + + + + + + diff --git a/cave/com.raytheon.uf.viz.hpe/.project b/cave/com.raytheon.uf.viz.hpe/.project new file mode 100644 index 0000000000..52f6993c01 --- /dev/null +++ b/cave/com.raytheon.uf.viz.hpe/.project @@ -0,0 +1,28 @@ + + + com.raytheon.uf.viz.hpe + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.pde.ManifestBuilder + + + + + org.eclipse.pde.SchemaBuilder + + + + + + org.eclipse.pde.PluginNature + org.eclipse.jdt.core.javanature + + diff --git a/cave/com.raytheon.uf.viz.hpe/.settings/org.eclipse.jdt.core.prefs b/cave/com.raytheon.uf.viz.hpe/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 0000000000..8000cd6ca6 --- /dev/null +++ b/cave/com.raytheon.uf.viz.hpe/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,11 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve +org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.debug.lineNumber=generate +org.eclipse.jdt.core.compiler.debug.localVariable=generate +org.eclipse.jdt.core.compiler.debug.sourceFile=generate +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.source=1.6 diff --git a/cave/com.raytheon.uf.viz.hpe/META-INF/MANIFEST.MF b/cave/com.raytheon.uf.viz.hpe/META-INF/MANIFEST.MF new file mode 100644 index 0000000000..0957b34c04 --- /dev/null +++ b/cave/com.raytheon.uf.viz.hpe/META-INF/MANIFEST.MF @@ -0,0 +1,22 @@ +Manifest-Version: 1.0 +Bundle-ManifestVersion: 2 +Bundle-Name: Hpe +Bundle-SymbolicName: com.raytheon.uf.viz.hpe; singleton:=true +Bundle-Version: 1.14.0.qualifier +Bundle-Vendor: RAYTHEON +Require-Bundle: org.eclipse.core.runtime, + com.raytheon.uf.common.dataplugin.shef;bundle-version="1.12.1174", + com.raytheon.uf.common.plugin.hpe;bundle-version="1.0.0", + com.raytheon.uf.common.status;bundle-version="1.12.1174", + com.raytheon.uf.common.time;bundle-version="1.12.1174", + com.raytheon.uf.common.util;bundle-version="1.14.0", + com.raytheon.uf.viz.core;bundle-version="1.14.2", + com.raytheon.viz.hydrocommon;bundle-version="1.12.1174", + com.raytheon.viz.ui;bundle-version="1.14.0", + com.raytheon.uf.viz.monitor.ffmp;bundle-version="1.12.1174", + com.raytheon.viz.grid;bundle-version="1.14.0", + com.raytheon.uf.common.dataplugin;bundle-version="1.12.1174", + com.raytheon.uf.common.geospatial;bundle-version="1.14.0", + com.raytheon.uf.viz.core.rsc;bundle-version="1.0.0" +Bundle-RequiredExecutionEnvironment: JavaSE-1.6 +Bundle-ActivationPolicy: lazy diff --git a/cave/com.raytheon.uf.viz.hpe/build.properties b/cave/com.raytheon.uf.viz.hpe/build.properties new file mode 100644 index 0000000000..34d2e4d2da --- /dev/null +++ b/cave/com.raytheon.uf.viz.hpe/build.properties @@ -0,0 +1,4 @@ +source.. = src/ +output.. = bin/ +bin.includes = META-INF/,\ + . diff --git a/cave/com.raytheon.uf.viz.hpe/plugin.xml b/cave/com.raytheon.uf.viz.hpe/plugin.xml new file mode 100644 index 0000000000..488e536235 --- /dev/null +++ b/cave/com.raytheon.uf.viz.hpe/plugin.xml @@ -0,0 +1,30 @@ + + + + + + + + + diff --git a/cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/D2DHpeDisplayCustomizer.java b/cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/D2DHpeDisplayCustomizer.java new file mode 100644 index 0000000000..e13442a35d --- /dev/null +++ b/cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/D2DHpeDisplayCustomizer.java @@ -0,0 +1,265 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.viz.hpe; + +import java.util.ArrayList; +import java.util.List; + +import com.raytheon.uf.common.dataplugin.grid.GridRecord; +import com.raytheon.uf.viz.core.drawables.IDescriptor; +import com.raytheon.uf.viz.core.drawables.IRenderableDisplay; +import com.raytheon.uf.viz.core.drawables.ResourcePair; +import com.raytheon.uf.viz.core.exception.VizException; +import com.raytheon.uf.viz.core.rsc.AbstractVizResource; +import com.raytheon.uf.viz.core.rsc.AbstractVizResource.ResourceStatus; +import com.raytheon.uf.viz.core.rsc.IInitListener; +import com.raytheon.uf.viz.core.rsc.IResourceDataChanged; +import com.raytheon.uf.viz.core.rsc.ResourceList; +import com.raytheon.uf.viz.core.rsc.ResourceList.AddListener; +import com.raytheon.uf.viz.core.rsc.ResourceList.RemoveListener; +import com.raytheon.uf.viz.hpe.rsc.HpeLabelResourceData; +import com.raytheon.uf.viz.hpe.util.HpeUtils; +import com.raytheon.viz.grid.rsc.general.D2DGridResource; +import com.raytheon.viz.ui.perspectives.IRenderableDisplayCustomizer; + +/** + * This class listens to existing resources and adds the HPE "legend" text as + * needed. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * May 5, 2014     3026    mpduff      Initial creation
+ * 
+ * 
+ * + * @author mpduff + * @version 1.0 + */ + +public class D2DHpeDisplayCustomizer implements IRenderableDisplayCustomizer { + + /** List of listeners we have for renderable displays */ + private final List listeners = new ArrayList(); + + @Override + public void customizeDisplay(IRenderableDisplay display) { + boolean add = true; + for (D2DHpeResourceListener listener : listeners) { + if (display == listener.getDisplay()) { + add = false; + break; + } + } + + if (add) { + listeners.add(new D2DHpeResourceListener(display)); + } + } + + @Override + public void uncustomizeDisplay(IRenderableDisplay display) { + D2DHpeResourceListener toRemove = null; + for (D2DHpeResourceListener listener : listeners) { + if (listener.getDisplay() == display) { + toRemove = listener; + break; + } + } + if (toRemove != null) { + toRemove.dispose(); + listeners.remove(toRemove); + } + } + + private static class D2DHpeResourceListener implements AddListener, + RemoveListener, IInitListener { + + private final IRenderableDisplay display; + + private boolean resourcesAdded = false; + + private ResourcePair hpeResourcePair; + + public D2DHpeResourceListener(IRenderableDisplay display) { + this.display = display; + IDescriptor descriptor = display.getDescriptor(); + ResourceList list = descriptor.getResourceList(); + if (hasCompatibleResource(list)) { + addResources(descriptor); + } + list.addPostAddListener(this); + list.addPostRemoveListener(this); + } + + public void dispose() { + ResourceList list = display.getDescriptor().getResourceList(); + list.removePostAddListener(this); + list.removePostRemoveListener(this); + } + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.viz.core.rsc.ResourceList.RemoveListener#notifyRemove + * (com.raytheon.uf.viz.core.drawables.ResourcePair) + */ + @Override + public synchronized void notifyRemove(ResourcePair rp) + throws VizException { + if (resourcesAdded) { + if (rp.getResource() != null) { + rp.getResource().unregisterListener(this); + } + if (isCompatibleResource(rp)) { + IDescriptor descriptor = display.getDescriptor(); + if (hasCompatibleResource(descriptor.getResourceList()) == false) { + removeResources(descriptor); + } + } + } + } + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.viz.core.rsc.ResourceList.AddListener#notifyAdd(com + * .raytheon .uf.viz.core.drawables.ResourcePair) + */ + @Override + public synchronized void notifyAdd(ResourcePair rp) throws VizException { + if (!resourcesAdded) { + AbstractVizResource rsc = rp.getResource(); + if (rsc != null) { + rsc.registerListener(this); + if (rsc.getStatus() == ResourceStatus.INITIALIZED + && isCompatibleResource(rp)) { + addResources(display.getDescriptor()); + } + } + } + } + + private boolean hasCompatibleResource(ResourceList list) { + for (ResourcePair rp : list) { + if (isCompatibleResource(rp)) { + return true; + } + } + return false; + } + + private boolean isCompatibleResource(ResourcePair rp) { + AbstractVizResource resource = rp.getResource(); + if (resource != null) { + if (resource instanceof D2DGridResource) { + D2DGridResource rsc = (D2DGridResource) resource; + return HpeUtils.isHpe(rsc.getCurrentGridRecord()); + } + } + return false; + } + + private synchronized void addResources(IDescriptor descriptor) { + if (!resourcesAdded) { + ResourceList list = descriptor.getResourceList(); + hpeResourcePair = constructHpeLabelResource(); + list.add(hpeResourcePair); + + list.instantiateResources(descriptor, true); + resourcesAdded = true; + + // add hpe resource as a listener + for (ResourcePair rp : list) { + AbstractVizResource resource = rp.getResource(); + if (resource != null) { + if (resource instanceof D2DGridResource) { + D2DGridResource rsc = (D2DGridResource) resource; + rsc.getResourceData().addChangeListener( + (IResourceDataChanged) hpeResourcePair + .getResource()); + return; + } + } + } + } + } + + private synchronized void removeResources(IDescriptor descriptor) { + if (resourcesAdded) { + if (hpeResourcePair != null) { + ResourceList list = descriptor.getResourceList(); + list.remove(hpeResourcePair); + for (ResourcePair rp : list) { + AbstractVizResource resource = rp.getResource(); + if (resource != null) { + if (resource instanceof D2DGridResource) { + D2DGridResource rsc = (D2DGridResource) resource; + rsc.getResourceData().removeChangeListener( + (IResourceDataChanged) hpeResourcePair + .getResource()); + } + } + } + + hpeResourcePair = null; + } + resourcesAdded = false; + } + } + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.viz.core.rsc.IInitListener#inited(com.raytheon.uf + * .viz.core.rsc.AbstractVizResource) + */ + @Override + public synchronized void inited(AbstractVizResource rsc) { + if (rsc instanceof D2DGridResource) { + GridRecord gridRec = ((D2DGridResource) rsc) + .getCurrentGridRecord(); + if (!resourcesAdded && HpeUtils.isHpe(gridRec)) { + addResources(rsc.getDescriptor()); + } + } + } + + /** + * Get the IRenderableDisplay + * + * @return the display + */ + public IRenderableDisplay getDisplay() { + return display; + } + } + + private static ResourcePair constructHpeLabelResource() { + return ResourcePair + .constructSystemResourcePair(new HpeLabelResourceData()); + } +} diff --git a/cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/rsc/HpeLabelResource.java b/cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/rsc/HpeLabelResource.java new file mode 100644 index 0000000000..1d89badae1 --- /dev/null +++ b/cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/rsc/HpeLabelResource.java @@ -0,0 +1,225 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.viz.hpe.rsc; + +import java.util.Collections; +import java.util.Date; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import org.eclipse.core.runtime.IProgressMonitor; +import org.eclipse.core.runtime.IStatus; +import org.eclipse.core.runtime.Status; +import org.eclipse.core.runtime.jobs.Job; +import org.eclipse.swt.graphics.RGB; + +import com.raytheon.uf.common.dataplugin.grid.GridRecord; +import com.raytheon.uf.common.plugin.hpe.request.HpeLabelDataRequest; +import com.raytheon.uf.common.plugin.hpe.request.HpeLabelDataResponse; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.time.DataTime; +import com.raytheon.uf.viz.core.DrawableString; +import com.raytheon.uf.viz.core.IGraphicsTarget; +import com.raytheon.uf.viz.core.IGraphicsTarget.HorizontalAlignment; +import com.raytheon.uf.viz.core.IGraphicsTarget.VerticalAlignment; +import com.raytheon.uf.viz.core.drawables.IFont; +import com.raytheon.uf.viz.core.drawables.PaintProperties; +import com.raytheon.uf.viz.core.exception.VizException; +import com.raytheon.uf.viz.core.map.MapDescriptor; +import com.raytheon.uf.viz.core.requests.ThriftClient; +import com.raytheon.uf.viz.core.rsc.AbstractVizResource; +import com.raytheon.uf.viz.core.rsc.IResourceDataChanged; +import com.raytheon.uf.viz.core.rsc.LoadProperties; +import com.raytheon.uf.viz.core.rsc.ResourceList; +import com.raytheon.uf.viz.core.rsc.capabilities.ColorableCapability; +import com.raytheon.uf.viz.core.rsc.capabilities.MagnificationCapability; +import com.raytheon.uf.viz.hpe.util.HpeUtils; +import com.raytheon.viz.grid.rsc.general.D2DGridResource; + +/** + * A resource to display HPE label text in the upper left corner of the display + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * May 5, 2014    3026     mpduff      Initial creation
+ * 
+ * 
+ * + * @author mpduff + * @version 1.0 + */ + +public class HpeLabelResource extends + AbstractVizResource implements + IResourceDataChanged { + + private final IUFStatusHandler logger = UFStatus + .getHandler(HpeLabelResource.class); + + private final Map hpeTextCache = Collections + .synchronizedMap(new HashMap()); + + private DrawableString drawableString = null; + + private IFont font = null; + + private final HpeSourceDataJob dataJob = new HpeSourceDataJob(); + + protected HpeLabelResource(HpeLabelResourceData resourceData, + LoadProperties loadProperties) { + super(resourceData, loadProperties); + } + + @Override + public void resourceChanged(ChangeType type, Object object) { + if (type == ChangeType.DATA_REMOVE) { + if (object instanceof DataTime) { + hpeTextCache.remove(((DataTime) object).getRefTime()); + } + } + } + + @Override + protected void disposeInternal() { + if (font != null) { + font.dispose(); + } + } + + @Override + protected void paintInternal(IGraphicsTarget target, + PaintProperties paintProps) throws VizException { + ResourceList rscList = this.descriptor.getResourceList(); + if (rscList != null) { + StringBuilder sb = new StringBuilder(); + + // Find all D2DGridResources + List list = rscList + .getResourcesByTypeAsType(D2DGridResource.class); + if (!list.isEmpty()) { + double[] pixel = paintProps.getView().getDisplayCoords( + new double[] { 125, 50 }, target); + RGB color = getCapability(ColorableCapability.class).getColor(); + for (D2DGridResource rsc : list) { + GridRecord currentGridRec = rsc.getCurrentGridRecord(); + color = rsc.getCapability(ColorableCapability.class) + .getColor(); + if (HpeUtils.isHpe(currentGridRec)) { + // this is HPE so display the bias information + String text = getText(currentGridRec.getDataTime() + .getRefTime(), currentGridRec.getSecondaryId()); + if (text != null) { + sb.append(text); + } + } + } + + if (sb.length() > 0) { + drawableString.setText(sb.toString(), color); + drawableString.setCoordinates(pixel[0], pixel[1]); + target.drawStrings(drawableString); + } + } + } + } + + @Override + protected void initInternal(IGraphicsTarget target) throws VizException { + if (font == null) { + font = target.initializeFont("Dialog", 11, null); + } + font.setMagnification(getCapability(MagnificationCapability.class) + .getMagnification().floatValue()); + + drawableString = new DrawableString("", getCapability( + ColorableCapability.class).getColor()); + drawableString.font = font; + drawableString.horizontalAlignment = HorizontalAlignment.CENTER; + drawableString.verticallAlignment = VerticalAlignment.MIDDLE; + } + + private String getText(Date date, String productId) { + String text = hpeTextCache.get(date); + if (text == null) { + dataJob.scheduleRetrieval(date, productId); + } + + return text; + } + + /* + * (non-Javadoc) + * + * @see + * com.raytheon.uf.viz.core.rsc.AbstractVizResource#resourceDataChanged( + * com.raytheon.uf.viz.core.rsc.IResourceDataChanged.ChangeType, + * java.lang.Object) + */ + @Override + protected void resourceDataChanged(ChangeType type, Object updateObject) { + super.resourceDataChanged(type, updateObject); + } + + private class HpeSourceDataJob extends Job { + private volatile String productId; + + private volatile Date date; + + public HpeSourceDataJob() { + super("Get HPE Source"); + } + + protected void scheduleRetrieval(Date date, String productId) { + this.productId = productId; + this.date = date; + if (this.getState() == Job.RUNNING + || this.getState() == Job.SLEEPING + || this.getState() == Job.WAITING) { + return; + } + this.schedule(); + } + + @Override + protected IStatus run(IProgressMonitor monitor) { + // Request the text from edex + try { + HpeLabelDataRequest req = new HpeLabelDataRequest(productId, + date); + HpeLabelDataResponse response = (HpeLabelDataResponse) ThriftClient + .sendRequest(req); + Map data = response.getData(); + for (Date d : data.keySet()) { + hpeTextCache.put(d, data.get(d)); + } + } catch (VizException e) { + statusHandler.error(e.getLocalizedMessage(), e); + } + + return Status.OK_STATUS; + } + } +} diff --git a/cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/rsc/HpeLabelResourceData.java b/cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/rsc/HpeLabelResourceData.java new file mode 100644 index 0000000000..d660dd27a7 --- /dev/null +++ b/cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/rsc/HpeLabelResourceData.java @@ -0,0 +1,71 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.viz.hpe.rsc; + +import com.raytheon.uf.viz.core.drawables.IDescriptor; +import com.raytheon.uf.viz.core.exception.VizException; +import com.raytheon.uf.viz.core.rsc.AbstractResourceData; +import com.raytheon.uf.viz.core.rsc.AbstractVizResource; +import com.raytheon.uf.viz.core.rsc.LoadProperties; + +/** + * Resource data object for the HpeLabelResource. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * May 5, 2014      3026   mpduff      Initial creation
+ * 
+ * 
+ * + * @author mpduff + * @version 1.0 + */ + +public class HpeLabelResourceData extends AbstractResourceData { + + @Override + public AbstractVizResource construct(LoadProperties loadProperties, + IDescriptor descriptor) throws VizException { + HpeLabelResource rsc = new HpeLabelResource(this, loadProperties); + addChangeListener(rsc); + return rsc; + } + + @Override + public void update(Object updateData) { + // No op + + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null || (!(obj instanceof HpeLabelResourceData))) { + return false; + } + return false; + } +} diff --git a/cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/util/HpeUtils.java b/cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/util/HpeUtils.java new file mode 100644 index 0000000000..7d38180a93 --- /dev/null +++ b/cave/com.raytheon.uf.viz.hpe/src/com/raytheon/uf/viz/hpe/util/HpeUtils.java @@ -0,0 +1,69 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.viz.hpe.util; + +import com.raytheon.uf.common.dataplugin.grid.GridRecord; +import com.raytheon.uf.common.dataplugin.grid.dataset.DatasetInfo; +import com.raytheon.uf.common.dataplugin.grid.dataset.DatasetInfoLookup; + +/** + * HPE Utilities + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * May 6, 2014     3026    mpduff      Initial creation
+ * 
+ * 
+ * + * @author mpduff + * @version 1.0 + */ + +public class HpeUtils { + private static final String HPE = "HPE"; + + /** + * Determine if this title represents an HPE model. + * + * @param gridRecord + * The gridRecord to check + * @return true if model is HPE, false otherwise + * + */ + public static boolean isHpe(GridRecord gridRecord) { + String title = null; + if (gridRecord != null) { + DatasetInfo info = DatasetInfoLookup.getInstance().getInfo( + gridRecord.getDatasetId()); + if (info != null) { + title = info.getTitle(); + } + } + + if (title == null) { + return false; + } + return HPE.equals(title); + } +} diff --git a/cave/com.raytheon.uf.viz.monitor.ffmp/META-INF/MANIFEST.MF b/cave/com.raytheon.uf.viz.monitor.ffmp/META-INF/MANIFEST.MF index 05f56b95ed..dcbff667ab 100644 --- a/cave/com.raytheon.uf.viz.monitor.ffmp/META-INF/MANIFEST.MF +++ b/cave/com.raytheon.uf.viz.monitor.ffmp/META-INF/MANIFEST.MF @@ -27,7 +27,8 @@ Require-Bundle: org.eclipse.ui, com.raytheon.uf.common.event;bundle-version="1.0.0", com.raytheon.uf.common.dataaccess;bundle-version="1.0.0", com.raytheon.uf.common.colormap;bundle-version="1.12.1174", - com.raytheon.uf.common.style;bundle-version="1.0.0" + com.raytheon.uf.common.style;bundle-version="1.0.0", + com.raytheon.uf.common.plugin.hpe;bundle-version="1.0.0" Bundle-RequiredExecutionEnvironment: JavaSE-1.6 Bundle-ActivationPolicy: lazy Import-Package: com.raytheon.uf.common.pointdata diff --git a/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPResource.java b/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPResource.java index c778f99e98..f826d1408f 100644 --- a/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPResource.java +++ b/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPResource.java @@ -22,6 +22,7 @@ package com.raytheon.uf.viz.monitor.ffmp.ui.rsc; import java.text.DecimalFormat; import java.util.ArrayList; import java.util.Collection; +import java.util.Collections; import java.util.Date; import java.util.HashMap; import java.util.HashSet; @@ -77,6 +78,8 @@ import com.raytheon.uf.common.monitor.config.FFMPSourceConfigurationManager; import com.raytheon.uf.common.monitor.xml.DomainXML; import com.raytheon.uf.common.monitor.xml.ProductXML; import com.raytheon.uf.common.monitor.xml.SourceXML; +import com.raytheon.uf.common.plugin.hpe.request.HpeLabelDataRequest; +import com.raytheon.uf.common.plugin.hpe.request.HpeLabelDataResponse; import com.raytheon.uf.common.status.IPerformanceStatusHandler; import com.raytheon.uf.common.status.IUFStatusHandler; import com.raytheon.uf.common.status.PerformanceStatus; @@ -85,6 +88,7 @@ import com.raytheon.uf.common.status.UFStatus.Priority; import com.raytheon.uf.common.time.DataTime; import com.raytheon.uf.common.time.util.ITimer; import com.raytheon.uf.common.time.util.TimeUtil; +import com.raytheon.uf.common.util.StringUtil; import com.raytheon.uf.viz.core.DrawableLine; import com.raytheon.uf.viz.core.DrawableString; import com.raytheon.uf.viz.core.IDisplayPaneContainer; @@ -105,6 +109,7 @@ import com.raytheon.uf.viz.core.drawables.ext.colormap.IColormapShadedShapeExten import com.raytheon.uf.viz.core.drawables.ext.colormap.IColormapShadedShapeExtension.IColormapShadedShape; import com.raytheon.uf.viz.core.exception.VizException; import com.raytheon.uf.viz.core.map.MapDescriptor; +import com.raytheon.uf.viz.core.requests.ThriftClient; import com.raytheon.uf.viz.core.rsc.AbstractVizResource; import com.raytheon.uf.viz.core.rsc.IInputHandler; import com.raytheon.uf.viz.core.rsc.IResourceDataChanged; @@ -176,6 +181,7 @@ import com.vividsolutions.jts.geom.Point; * Jan 21, 2014 DR 15874 gzhang Use getValue() for QPFSCAN independent. * Feb 19, 2014 2819 randerso Removed unnecessary .clone() call * Mar 3, 2014 2804 mschenke Set back up clipping pane + * May 05, 2014 3026 mpduff Display Hpe bias source. * * * @author dhladky @@ -187,7 +193,7 @@ public class FFMPResource extends IResourceDataChanged, IFFMPResourceListener, FFMPListener { /** Status handler */ - private static final IUFStatusHandler statusHandler = UFStatus + private final IUFStatusHandler statusHandler = UFStatus .getHandler(FFMPResource.class); /** Performance log statement prefix */ @@ -241,6 +247,9 @@ public class FFMPResource extends /** expansion of the window **/ private static final double EXPANSION_FACTOR = 1.0; + /** HPE Constant */ + private static final String HPE = "HPE"; + /** the stream cross hatched area **/ private IWireframeShape streamOutlineShape = null; @@ -412,6 +421,16 @@ public class FFMPResource extends /** Restore Table flag */ private boolean restoreTable = false; + /** HPE bias source legend cache */ + private final Map hpeLegendMap = Collections + .synchronizedMap(new HashMap()); + + /** Flag denoting data as HPE */ + private boolean isHpe; + + /** The job to get the HPE bias source info */ + private final HpeSourceDataJob dataJob = new HpeSourceDataJob(); + /** * FFMP resource * @@ -496,6 +515,12 @@ public class FFMPResource extends statusHandler.handle(Priority.PROBLEM, "Error updating record", ve); } + } else if (type.equals(ChangeType.DATA_REMOVE)) { + PluginDataObject[] pdos = (PluginDataObject[]) object; + for (PluginDataObject pdo : pdos) { + FFMPRecord ffmpRec = (FFMPRecord) pdo; + hpeLegendMap.remove(ffmpRec.getDataTime().getRefTime()); + } } } @@ -798,9 +823,10 @@ public class FFMPResource extends } else { switch (field) { case QPF: { - value = getBasin(key, field, recentTime, aggregate).getValue(recentTime);// DR 15874 - //.getAverageValue(recentTime, - //getQpfSourceExpiration()); + value = getBasin(key, field, recentTime, aggregate) + .getValue(recentTime);// DR 15874 + // .getAverageValue(recentTime, + // getQpfSourceExpiration()); break; } case GUIDANCE: { @@ -814,7 +840,7 @@ public class FFMPResource extends } } } catch (Exception e) { - e.printStackTrace(); + statusHandler.error("Problem getting basin value", e); } return value; } @@ -883,8 +909,8 @@ public class FFMPResource extends if (source.getSourceType().equals( FFMPSourceConfigurationManager.SOURCE_TYPE.GUIDANCE .getSourceType())) { - prefix.append(source.getDisplayName() + " " - + source.getDurationHour() + " HR"); + prefix.append(source.getDisplayName()).append(" ") + .append(source.getDurationHour()).append(" HR"); } else { prefix.append(source.getDisplayName()); } @@ -914,6 +940,8 @@ public class FFMPResource extends /** * Gets the record currently used * + * @param recentTime + * * @return FFMPCacheRecord */ public FFMPRecord getRateRecord(Date recentTime) { @@ -924,7 +952,8 @@ public class FFMPResource extends getDataKey(), getPrimarySource(), recentTime, false); isNewRate = false; } catch (Exception e) { - e.printStackTrace(); + statusHandler.error("Error retrieving the current rate record", + e); } } return rateRecord; @@ -944,9 +973,8 @@ public class FFMPResource extends isNewQpe = false; } } catch (Exception e) { - e.printStackTrace(); + statusHandler.error("Error retrieving the current QPE record", e); } - // System.out.println("FFMPResource.getQPERecord(): " + getTableTime()); return qpeRecord; } @@ -979,7 +1007,7 @@ public class FFMPResource extends } } catch (Exception e) { - e.printStackTrace(); + statusHandler.error("Error retrieving the current guid record", e); } return guidRecord; @@ -1008,7 +1036,7 @@ public class FFMPResource extends isNewQpf = false; } } catch (Exception e) { - e.printStackTrace(); + statusHandler.error("Error retrieving the current QPF record", e); } return qpfRecord; @@ -1029,7 +1057,8 @@ public class FFMPResource extends } } catch (Exception e) { - e.printStackTrace(); + statusHandler.error("Error retrieving the current virtual record", + e); } return virtualRecord; @@ -1039,6 +1068,8 @@ public class FFMPResource extends * General get record call * * @param pfield + * @param recentTime + * * @return FFMPCacheRecord */ public FFMPRecord getRecord(FIELDS pfield, Date recentTime) { @@ -1155,18 +1186,17 @@ public class FFMPResource extends @Override public void run() { - if (/* this. */font == null) { - /* this. */font = target.initializeFont("Dialog", 11, null); + if (font == null) { + font = target.initializeFont("Dialog", 11, null); } font.setMagnification(getCapability( MagnificationCapability.class).getMagnification() .floatValue()); - if (/* this. */xfont == null) { + if (xfont == null) { IFont.Style[] styles = new IFont.Style[] { IFont.Style.BOLD }; - /* this. */xfont = target.initializeFont("Monospace", 12, - styles); + xfont = target.initializeFont("Monospace", 12, styles); } xfont.setMagnification(getCapability( @@ -1189,6 +1219,9 @@ public class FFMPResource extends basinLocatorString.textStyle = TextStyle.BLANKED; } }); + + // Set flag for HPE data + isHpe = resourceData.siteKey.equalsIgnoreCase(HPE); } /** @@ -1427,13 +1460,24 @@ public class FFMPResource extends PaintProperties paintProps) throws VizException { double[] pixel = paintProps.getView().getDisplayCoords( new double[] { 110, 50 }, target); - + StringBuilder sb = new StringBuilder(); if (isAutoRefresh || isQuery) { - fieldDescString.setText("FFMP " + df.format(getTime()) + " hour " - + FFMPRecord.getFieldLongDescription(getField()), - getCapability(ColorableCapability.class).getColor()); + sb.append("FFMP ").append(df.format(getTime())).append(" hour ") + .append(FFMPRecord.getFieldLongDescription(getField())); } + // Paint the HPE bias source text if HPE + if (isHpe) { + String text = getText(paintTime.getRefTime(), + qpeRecord.getMetaData()); + if (text != null) { + sb.append(StringUtil.NEWLINE); + sb.append(text); + } + } + + fieldDescString.setText(sb.toString(), + getCapability(ColorableCapability.class).getColor()); fieldDescString.setCoordinates(pixel[0], pixel[1]); target.drawStrings(fieldDescString); } @@ -4081,4 +4125,52 @@ public class FFMPResource extends return dataTimes; } + private String getText(Date date, String productId) { + String text = hpeLegendMap.get(date); + if (text == null) { + dataJob.scheduleRetrieval(date, productId); + } + + return text; + } + + private class HpeSourceDataJob extends Job { + private volatile String productId; + + private volatile Date date; + + public HpeSourceDataJob() { + super("Get HPE Source"); + } + + protected void scheduleRetrieval(Date date, String productId) { + this.productId = productId; + this.date = date; + if (this.getState() == Job.RUNNING + || this.getState() == Job.SLEEPING + || this.getState() == Job.WAITING) { + return; + } + this.schedule(); + } + + @Override + protected IStatus run(IProgressMonitor monitor) { + // Request the text from edex + try { + HpeLabelDataRequest req = new HpeLabelDataRequest(productId, + date); + HpeLabelDataResponse response = (HpeLabelDataResponse) ThriftClient + .sendRequest(req); + Map data = response.getData(); + for (Date d : data.keySet()) { + hpeLegendMap.put(d, data.get(d)); + } + } catch (VizException e) { + statusHandler.error(e.getLocalizedMessage(), e); + } + + return Status.OK_STATUS; + } + } } diff --git a/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/rsc/general/GridResource.java b/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/rsc/general/GridResource.java index 73cd259f94..bed96f158d 100644 --- a/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/rsc/general/GridResource.java +++ b/cave/com.raytheon.viz.grid/src/com/raytheon/viz/grid/rsc/general/GridResource.java @@ -28,12 +28,12 @@ import javax.measure.unit.Unit; import org.geotools.coverage.grid.GeneralGridGeometry; -import com.raytheon.uf.common.inventory.exception.DataCubeException; import com.raytheon.uf.common.dataplugin.PluginDataObject; import com.raytheon.uf.common.dataplugin.grid.GridRecord; import com.raytheon.uf.common.dataplugin.grid.util.GridStyleUtil; import com.raytheon.uf.common.datastorage.records.FloatDataRecord; import com.raytheon.uf.common.datastorage.records.IDataRecord; +import com.raytheon.uf.common.inventory.exception.DataCubeException; import com.raytheon.uf.common.style.ParamLevelMatchCriteria; import com.raytheon.uf.common.time.DataTime; import com.raytheon.uf.viz.core.exception.VizException; @@ -54,6 +54,7 @@ import com.raytheon.uf.viz.datacube.DataCubeContainer; * Mar 09, 2011 bsteffen Initial creation * Sep 24, 2013 2404 bclement match criteria built using GridStyleUtil * Jan 14, 2014 2661 bsteffen Switch vectors to u,v only. + * May 05, 2014 3026 mpduff Made getCurrentGribRecord() public * * * @@ -150,7 +151,7 @@ public class GridResource extends + record.getParameter().getName(); } - protected GridRecord getCurrentGridRecord() { + public GridRecord getCurrentGridRecord() { List pdos = getCurrentPluginDataObjects(); if (pdos == null || pdos.isEmpty()) { return null; diff --git a/cave/com.raytheon.viz.hydro.feature/feature.xml b/cave/com.raytheon.viz.hydro.feature/feature.xml index a0fab3939d..678974858a 100644 --- a/cave/com.raytheon.viz.hydro.feature/feature.xml +++ b/cave/com.raytheon.viz.hydro.feature/feature.xml @@ -130,4 +130,11 @@ version="0.0.0" unpack="false"/> + + diff --git a/deltaScripts/14.3.1/DR3026/addMetadataColumnFFMP.sh b/deltaScripts/14.3.1/DR3026/addMetadataColumnFFMP.sh new file mode 100644 index 0000000000..76ea698a49 --- /dev/null +++ b/deltaScripts/14.3.1/DR3026/addMetadataColumnFFMP.sh @@ -0,0 +1,16 @@ +#!/bin/bash +# DR 3026 - Add metadata column to FFMP database + +PSQL="/awips2/psql/bin/psql" + +echo "INFO: Adding column metadata to table ffmp" + +${PSQL} -U awips -d metadata -c "ALTER TABLE ffmp ADD COLUMN metadata varchar(255);" + +if [ $? -ne 0 ]; then + echo "ERROR: Failed to add column metadata to table ffmp" + echo "FATAL: The update has failed." + exit 1 +fi + +echo "INFO: column metadata added successfully" diff --git a/edexOsgi/com.raytheon.uf.common.dataplugin.ffmp/src/com/raytheon/uf/common/dataplugin/ffmp/FFMPRecord.java b/edexOsgi/com.raytheon.uf.common.dataplugin.ffmp/src/com/raytheon/uf/common/dataplugin/ffmp/FFMPRecord.java index 3e07637fbe..1afaa5a5f0 100644 --- a/edexOsgi/com.raytheon.uf.common.dataplugin.ffmp/src/com/raytheon/uf/common/dataplugin/ffmp/FFMPRecord.java +++ b/edexOsgi/com.raytheon.uf.common.dataplugin.ffmp/src/com/raytheon/uf/common/dataplugin/ffmp/FFMPRecord.java @@ -90,6 +90,7 @@ import com.raytheon.uf.common.time.util.ImmutableDate; * Jul 15, 2013 2184 dhladky Remove all HUC's for storage except ALL * Aug 30, 2013 2298 rjpeter Make getPluginName abstract * Oct 14, 2013 2361 njensen Removed XML annotations + * May 01, 2014 3026 mpduff Added metadata column. * * * @@ -131,6 +132,10 @@ public class FFMPRecord extends PersistablePluginDataObject implements @DynamicSerializeElement private String siteKey; + @Column(length = 255) + @DynamicSerializeElement + private String metaData; + @Transient private FFMPBasinData basins = new FFMPBasinData();; @@ -600,6 +605,21 @@ public class FFMPRecord extends PersistablePluginDataObject implements return isRate; } + /** + * @return the metaData + */ + public String getMetaData() { + return metaData; + } + + /** + * @param metaData + * the metaData to set + */ + public void setMetaData(String metaData) { + this.metaData = metaData; + } + /** * Purges out old data * diff --git a/edexOsgi/com.raytheon.uf.common.ohd/utility/common_static/base/hydro/Apps_defaults b/edexOsgi/com.raytheon.uf.common.ohd/utility/common_static/base/hydro/Apps_defaults index 59d708ef3b..819a0815db 100644 --- a/edexOsgi/com.raytheon.uf.common.ohd/utility/common_static/base/hydro/Apps_defaults +++ b/edexOsgi/com.raytheon.uf.common.ohd/utility/common_static/base/hydro/Apps_defaults @@ -127,6 +127,7 @@ #10/03/12 - Added token section for script execution #02/12/2014 - Added token for default display to replace field in rwprefs table #02/18/14 - Added section for run_report_alarm service configuration. +#05/05/2014 - #3026 added hpe_grib_input_dir token # ============================================================================== @@ -1123,6 +1124,7 @@ dhr_dirname1 : $(data_archive_root)/radar # first part of directo dhr_dirname2 : DHR/layer0/res1/level256 # second part of directory name # containing DHR products for # associated or dial in radar + dhr_grid_dir : $(pproc_local_data)/dhr_decoded # decoded DHR radar grids dhr_error_dir : $(pproc_local_data)/dhr_error # DHR error files @@ -1149,6 +1151,7 @@ dsp_error_dir : $(pproc_local_data)/dsp_error # DSP error files dsp_arch_dir : $(pproc_local_data)/dsp_archive # DSP archives +hpe_grib_input_dir : $(EDEX_HOME)/data/local/hpegrib hpe_generate_list : DHRMOSAIC,BDHRMOSAIC,ERMOSAIC,LSATPRE,EBMOSAIC hpe_qpe_fieldtype : ERMOSAIC # field type to be saved as qpe diff --git a/edexOsgi/com.raytheon.uf.common.plugin.hpe/.classpath b/edexOsgi/com.raytheon.uf.common.plugin.hpe/.classpath new file mode 100644 index 0000000000..098194ca4b --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.plugin.hpe/.classpath @@ -0,0 +1,7 @@ + + + + + + + diff --git a/edexOsgi/com.raytheon.uf.common.plugin.hpe/.project b/edexOsgi/com.raytheon.uf.common.plugin.hpe/.project new file mode 100644 index 0000000000..d621d2b9da --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.plugin.hpe/.project @@ -0,0 +1,28 @@ + + + com.raytheon.uf.common.plugin.hpe + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.pde.ManifestBuilder + + + + + org.eclipse.pde.SchemaBuilder + + + + + + org.eclipse.pde.PluginNature + org.eclipse.jdt.core.javanature + + diff --git a/edexOsgi/com.raytheon.uf.common.plugin.hpe/.settings/org.eclipse.jdt.core.prefs b/edexOsgi/com.raytheon.uf.common.plugin.hpe/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 0000000000..c537b63063 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.plugin.hpe/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,7 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 +org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.source=1.6 diff --git a/edexOsgi/com.raytheon.uf.common.plugin.hpe/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.common.plugin.hpe/META-INF/MANIFEST.MF new file mode 100644 index 0000000000..980394b25f --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.plugin.hpe/META-INF/MANIFEST.MF @@ -0,0 +1,17 @@ +Manifest-Version: 1.0 +Bundle-ManifestVersion: 2 +Bundle-Name: Hpe +Bundle-SymbolicName: com.raytheon.uf.common.plugin.hpe +Bundle-Version: 1.14.3.qualifier +Bundle-Vendor: RAYTHEON +Require-Bundle: org.eclipse.core.runtime, + com.raytheon.uf.common.util;bundle-version="1.14.0", + com.raytheon.uf.common.status;bundle-version="1.12.1174", + com.raytheon.uf.common.time;bundle-version="1.12.1174", + javax.persistence;bundle-version="1.0.0", + com.raytheon.uf.common.serialization.comm;bundle-version="1.12.1174", + com.raytheon.uf.common.serialization;bundle-version="1.12.1174" +Bundle-RequiredExecutionEnvironment: JavaSE-1.6 +Bundle-ActivationPolicy: lazy +Export-Package: com.raytheon.uf.common.plugin.hpe.data, + com.raytheon.uf.common.plugin.hpe.request diff --git a/edexOsgi/com.raytheon.uf.common.plugin.hpe/build.properties b/edexOsgi/com.raytheon.uf.common.plugin.hpe/build.properties new file mode 100644 index 0000000000..34d2e4d2da --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.plugin.hpe/build.properties @@ -0,0 +1,4 @@ +source.. = src/ +output.. = bin/ +bin.includes = META-INF/,\ + . diff --git a/edexOsgi/com.raytheon.uf.common.plugin.hpe/src/com/raytheon/uf/common/plugin/hpe/data/BiasDynRecord.java b/edexOsgi/com.raytheon.uf.common.plugin.hpe/src/com/raytheon/uf/common/plugin/hpe/data/BiasDynRecord.java new file mode 100644 index 0000000000..3d7a407d5c --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.plugin.hpe/src/com/raytheon/uf/common/plugin/hpe/data/BiasDynRecord.java @@ -0,0 +1,204 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.common.plugin.hpe.data; + +import java.util.Date; + +import com.raytheon.uf.common.util.StringUtil; + +/** + * Data structure holding data from the RWBiasDyn and the DAABiasDyn tables. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Mar 26, 2014    3026    mpduff      Initial creation
+ * 
+ * 
+ * + * @author mpduff + * @version 1.0 + */ + +public class BiasDynRecord { + /** Radar ID */ + private String radarId; + + /** Office ID */ + private String officeId; + + /** Observation time */ + private Date obsTime; + + /** MemspanIndex */ + private float memspanIndex; + + /** Number pairs */ + private double numPairs; + + /** Sum of Gages */ + private float sumGages; + + /** Sum of radars */ + private float sumRadars; + + private float bias; + + /** + * @return the radarId + */ + public String getRadarId() { + return radarId; + } + + /** + * @param radarId + * the radarId to set + */ + public void setRadarId(String radarId) { + this.radarId = radarId; + } + + /** + * @return the officeId + */ + public String getOfficeId() { + return officeId; + } + + /** + * @param officeId + * the officeId to set + */ + public void setOfficeId(String officeId) { + this.officeId = officeId; + } + + /** + * @return the obsTime + */ + public Date getObsTime() { + return obsTime; + } + + /** + * @param obsTime + * the obsTime to set + */ + public void setObsTime(Date obsTime) { + this.obsTime = obsTime; + } + + /** + * @return the memspanIndex + */ + public float getMemspanIndex() { + return memspanIndex; + } + + /** + * @param memspanIndex + * the memspanIndex to set + */ + public void setMemspanIndex(float memspanIndex) { + this.memspanIndex = memspanIndex; + } + + /** + * @return the numPairs + */ + public double getNumPairs() { + return numPairs; + } + + /** + * @param numPairs + * the numPairs to set + */ + public void setNumPairs(double numPairs) { + this.numPairs = numPairs; + } + + /** + * @return the sumGages + */ + public float getSumGages() { + return sumGages; + } + + /** + * @param sumGages + * the sumGages to set + */ + public void setSumGages(float sumGages) { + this.sumGages = sumGages; + } + + /** + * @return the sumRadars + */ + public float getSumRadars() { + return sumRadars; + } + + /** + * @param sumRadars + * the sumRadars to set + */ + public void setSumRadars(float sumRadars) { + this.sumRadars = sumRadars; + } + + /** + * @return the bias + */ + public float getBias() { + return bias; + } + + /** + * @param bias + * the bias to set + */ + public void setBias(float bias) { + this.bias = bias; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("Bias: ").append(this.bias).append(StringUtil.NEWLINE); + sb.append("MemSpanIndex: ").append(this.memspanIndex) + .append(StringUtil.NEWLINE); + sb.append("NumPairs: ").append(this.numPairs) + .append(StringUtil.NEWLINE); + sb.append("OfficeId: ").append(this.officeId) + .append(StringUtil.NEWLINE); + sb.append("RadarId: ").append(this.radarId).append(StringUtil.NEWLINE); + sb.append("sumGages: ").append(this.sumGages) + .append(StringUtil.NEWLINE); + sb.append("sumRadars: ").append(this.sumRadars); + + return sb.toString(); + } +} diff --git a/edexOsgi/com.raytheon.uf.common.plugin.hpe/src/com/raytheon/uf/common/plugin/hpe/request/HpeLabelDataRequest.java b/edexOsgi/com.raytheon.uf.common.plugin.hpe/src/com/raytheon/uf/common/plugin/hpe/request/HpeLabelDataRequest.java new file mode 100644 index 0000000000..21825000e4 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.plugin.hpe/src/com/raytheon/uf/common/plugin/hpe/request/HpeLabelDataRequest.java @@ -0,0 +1,120 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.common.plugin.hpe.request; + +import java.util.ArrayList; +import java.util.Date; +import java.util.List; + +import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; +import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; +import com.raytheon.uf.common.serialization.comm.IServerRequest; + +/** + * HPE bias source request object. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 23, 2014   3026     mpduff      Initial creation
+ * 
+ * 
+ * + * @author mpduff + * @version 1.0 + */ +@DynamicSerialize +public class HpeLabelDataRequest implements IServerRequest { + + /** HPE Product name */ + @DynamicSerializeElement + private String productName; + + /** HPE list of dates */ + @DynamicSerializeElement + private List dateList; + + /** + * Constructor. + */ + public HpeLabelDataRequest() { + + } + + /** + * Constructor. + * + * @param productName + * The Hpe product name + * @param dateList + * List of times for the product + */ + public HpeLabelDataRequest(String productName, List dateList) { + this.productName = productName; + this.dateList = dateList; + } + + /** + * Constructor. + * + * @param productName + * The Hpe product name + * @param date + * Date of the product + */ + public HpeLabelDataRequest(String productName, Date date) { + this.productName = productName; + dateList = new ArrayList(1); + dateList.add(date); + } + + /** + * @return the productName + */ + public String getProductName() { + return productName; + } + + /** + * @param productName + * the productName to set + */ + public void setProductName(String productName) { + this.productName = productName; + } + + /** + * @return the dateList + */ + public List getDateList() { + return dateList; + } + + /** + * @param dateList + * the dateList to set + */ + public void setDateList(List dateList) { + this.dateList = dateList; + } +} diff --git a/edexOsgi/com.raytheon.uf.common.plugin.hpe/src/com/raytheon/uf/common/plugin/hpe/request/HpeLabelDataResponse.java b/edexOsgi/com.raytheon.uf.common.plugin.hpe/src/com/raytheon/uf/common/plugin/hpe/request/HpeLabelDataResponse.java new file mode 100644 index 0000000000..4a9fb1028a --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.plugin.hpe/src/com/raytheon/uf/common/plugin/hpe/request/HpeLabelDataResponse.java @@ -0,0 +1,65 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.common.plugin.hpe.request; + +import java.util.Date; +import java.util.Map; + +import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; +import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; + +/** + * HPE bias source response object. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 23, 2014    3026    mpduff      Initial creation
+ * 
+ * 
+ * + * @author mpduff + * @version 1.0 + */ +@DynamicSerialize +public class HpeLabelDataResponse { + + /** Map of Dates->bias source text */ + @DynamicSerializeElement + private Map data; + + /** + * @return the data + */ + public Map getData() { + return data; + } + + /** + * @param data + * the data to set + */ + public void setData(Map data) { + this.data = data; + } +} diff --git a/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml b/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml index 62015e6f02..46b70f5435 100644 --- a/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml +++ b/edexOsgi/com.raytheon.uf.edex.dataplugins.feature/feature.xml @@ -381,4 +381,17 @@ version="0.0.0" unpack="false"/> + + + + diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/META-INF/MANIFEST.MF index a14e28f88a..e54447274f 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/META-INF/MANIFEST.MF +++ b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/META-INF/MANIFEST.MF @@ -19,7 +19,8 @@ Require-Bundle: com.raytheon.uf.edex.cpgsrv;bundle-version="1.11.7";resolution:= com.raytheon.uf.common.status;bundle-version="1.12.1174", com.raytheon.uf.common.event;bundle-version="1.0.0", com.raytheon.uf.edex.event;bundle-version="1.0.0", - com.raytheon.uf.common.stats;bundle-version="1.0.0" + com.raytheon.uf.common.stats;bundle-version="1.0.0", + com.raytheon.uf.edex.plugin.hpe;bundle-version="1.14.0" Import-Package: com.raytheon.uf.common.dataplugin.grid, com.raytheon.uf.common.ohd, com.raytheon.uf.common.status, diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java index a841b1d811..d315b4d954 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.ffmp/src/com/raytheon/uf/edex/plugin/ffmp/common/FFMPProcessor.java @@ -102,6 +102,7 @@ import com.vividsolutions.jts.geom.Polygon; * Jul 15, 2013 2184 dhladky Remove all HUC's for storage except ALL * 09/03/2013 DR 13083 G. Zhang Added a fix in processRADAR(ArrayList). * 03 April 2014 2940 dhladky Better error message for bad configurations. + * Apr 15, 2014 3026 mpduff Set the xmrg filename into the metadata column. * * @author dhladky * @version 1 @@ -262,6 +263,7 @@ public class FFMPProcessor { xmrg = (XmrgFile) config.getSourceData( source.getSourceName()).get(dataKey); xmrgData = getXMRGData(); + ffmpRec.setMetaData(xmrg.getFile().getName()); } catch (Exception e) { fireBadConfigMessage(type, e); return; diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.hpe/.classpath b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/.classpath new file mode 100644 index 0000000000..ad32c83a78 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/.classpath @@ -0,0 +1,7 @@ + + + + + + + diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.hpe/.project b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/.project new file mode 100644 index 0000000000..57c93e109e --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/.project @@ -0,0 +1,28 @@ + + + com.raytheon.uf.edex.plugin.hpe + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.pde.ManifestBuilder + + + + + org.eclipse.pde.SchemaBuilder + + + + + + org.eclipse.pde.PluginNature + org.eclipse.jdt.core.javanature + + diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.hpe/.settings/org.eclipse.jdt.core.prefs b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 0000000000..8000cd6ca6 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,11 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve +org.eclipse.jdt.core.compiler.compliance=1.6 +org.eclipse.jdt.core.compiler.debug.lineNumber=generate +org.eclipse.jdt.core.compiler.debug.localVariable=generate +org.eclipse.jdt.core.compiler.debug.sourceFile=generate +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.source=1.6 diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.hpe/META-INF/MANIFEST.MF b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/META-INF/MANIFEST.MF new file mode 100644 index 0000000000..afff97de3b --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/META-INF/MANIFEST.MF @@ -0,0 +1,18 @@ +Manifest-Version: 1.0 +Bundle-ManifestVersion: 2 +Bundle-Name: Hpe Grib Preprocessor +Bundle-SymbolicName: com.raytheon.uf.edex.plugin.hpe +Bundle-Version: 1.14.0.qualifier +Bundle-Vendor: RAYTHEON +Bundle-RequiredExecutionEnvironment: JavaSE-1.6 +Bundle-ActivationPolicy: lazy +Require-Bundle: com.raytheon.uf.common.status;bundle-version="1.12.1174", + com.raytheon.uf.edex.database;bundle-version="1.0.0", + com.raytheon.uf.common.time;bundle-version="1.12.1174", + com.google.guava;bundle-version="11.0.2", + com.raytheon.uf.common.util;bundle-version="1.14.0", + org.apache.camel;bundle-version="2.11.2", + com.raytheon.uf.common.plugin.hpe;bundle-version="1.0.0", + com.raytheon.uf.common.serialization.comm;bundle-version="1.12.1174", + com.raytheon.uf.common.serialization;bundle-version="1.12.1174", + com.raytheon.edex.common;bundle-version="1.12.1174" diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.hpe/build.properties b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/build.properties new file mode 100644 index 0000000000..5791d48d5f --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/build.properties @@ -0,0 +1,5 @@ +source.. = src/ +output.. = bin/ +bin.includes = META-INF/,\ + .,\ + res/ diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.hpe/res/spring/hpe-file-endpoint.xml b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/res/spring/hpe-file-endpoint.xml new file mode 100644 index 0000000000..78fb11a3e6 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/res/spring/hpe-file-endpoint.xml @@ -0,0 +1,38 @@ + + + + + + + + + + + + + + + + + + + + java.lang.Throwable + + + + + + + + + + + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.hpe/res/spring/hpe-request.xml b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/res/spring/hpe-request.xml new file mode 100644 index 0000000000..05916c959d --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/res/spring/hpe-request.xml @@ -0,0 +1,15 @@ + + + + + + + + + + + diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/handler/HpeLabelDataHandler.java b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/handler/HpeLabelDataHandler.java new file mode 100644 index 0000000000..5f6709cf64 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/handler/HpeLabelDataHandler.java @@ -0,0 +1,86 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.plugin.hpe.handler; + +import java.util.Date; +import java.util.HashMap; +import java.util.Map; + +import com.raytheon.uf.common.plugin.hpe.request.HpeLabelDataRequest; +import com.raytheon.uf.common.plugin.hpe.request.HpeLabelDataResponse; +import com.raytheon.uf.common.serialization.comm.IRequestHandler; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.edex.plugin.hpe.util.HpeDataAccessor; +import com.raytheon.uf.edex.plugin.hpe.util.HpeLabelGenerator; + +/** + * HPE bias source label request handler. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 23, 2014    3026    mpduff      Initial creation
+ * 
+ * 
+ * + * @author mpduff + * @version 1.0 + */ + +public class HpeLabelDataHandler implements + IRequestHandler { + /** Status handler */ + private static final IUFStatusHandler statusHandler = UFStatus + .getHandler(HpeLabelDataHandler.class); + + @Override + public Object handleRequest(HpeLabelDataRequest request) throws Exception { + return getData(request); + } + + private HpeLabelDataResponse getData(HpeLabelDataRequest request) { + // Generate the label string, put in response and send back + HpeLabelDataResponse response = new HpeLabelDataResponse(); + Map labelMap = new HashMap(); + try { + for (Date d : request.getDateList()) { + String label = generateHpeLabel(request.getProductName(), d); + labelMap.put(d, label); + } + + response.setData(labelMap); + } catch (Exception e) { + statusHandler.error(e.getMessage(), e); + } + return response; + } + + private String generateHpeLabel(String productName, Date date) + throws Exception { + HpeDataAccessor dataAccessor = new HpeDataAccessor(); + HpeLabelGenerator generator = new HpeLabelGenerator(dataAccessor); + String text = generator.getHpeLabel(date, productName); + return text; + } +} diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/process/HpeGribFileNameProcessor.java b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/process/HpeGribFileNameProcessor.java new file mode 100644 index 0000000000..800a5c8898 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/process/HpeGribFileNameProcessor.java @@ -0,0 +1,62 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.plugin.hpe.process; + +import java.util.regex.Matcher; +import java.util.regex.Pattern; + +import org.apache.camel.Exchange; +import org.apache.camel.Processor; + +/** + * Processor for HPE grib files. Adds the filename without the extension as the + * secondaryId. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 21, 2014    3026    mpduff      Initial creation
+ * 
+ * 
+ * + * @author mpduff + * @version 1.0 + */ + +public class HpeGribFileNameProcessor implements Processor { + /** Filename pattern to match for HPE grib files */ + private static final Pattern FILENAME_PATTERN = Pattern + .compile("^([A-Za-z]*MOSAIC[0-9]*z)\\.grib$"); + + @Override + public void process(Exchange exchange) throws Exception { + String fileName = (String) exchange.getIn().getHeader( + "CamelFileNameOnly"); + Matcher matcher = FILENAME_PATTERN.matcher(fileName); + if (matcher.matches()) { + // Take the text before the last "." + String productName = matcher.group(1); + exchange.getIn().setHeader("secondaryid", productName); + } + } +} diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeDataAccessor.java b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeDataAccessor.java new file mode 100644 index 0000000000..7974098139 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeDataAccessor.java @@ -0,0 +1,244 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.plugin.hpe.util; + +import java.text.SimpleDateFormat; +import java.util.ArrayList; +import java.util.Date; +import java.util.List; +import java.util.SortedMap; +import java.util.TimeZone; +import java.util.TreeMap; + +import com.raytheon.edex.site.SiteUtil; +import com.raytheon.uf.common.plugin.hpe.data.BiasDynRecord; +import com.raytheon.uf.common.time.util.TimeUtil; +import com.raytheon.uf.edex.database.dao.CoreDao; +import com.raytheon.uf.edex.database.dao.DaoConfig; +import com.raytheon.uf.edex.plugin.hpe.util.HpeEnums.HpeDataSource; + +/** + * HPE database access utility class. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Mar 26, 2014    3026    mpduff      Initial creation
+ * 
+ * 
+ * + * @author mpduff + * @version 1.0 + */ + +public class HpeDataAccessor { + private static final String IHFS = "ihfs"; + + private static final String POSTGRES_DATE_STRING = "yyyy-MM-dd HH:mm:ss"; + + private static final String HPE_RADAR_QUERY = "select distinct(radid) from "; + + /** + * Full query string for HpeRadarResult table + */ + public static final String FULL_HPE_RADAR_RESULT_QUERY = "select hpe_productname, producttime, " + + "num_radar_avail, bias_source, radar_data_source from hperadarresult"; + + /** + * Database date string format + */ + private final ThreadLocal sdf = TimeUtil + .buildThreadLocalSimpleDateFormat(POSTGRES_DATE_STRING, + TimeZone.getTimeZone("GMT")); + + /** The data access object */ + private final CoreDao dao; + + /** + * Constructor. + */ + public HpeDataAccessor() { + dao = new CoreDao(DaoConfig.forDatabase(IHFS)); + } + + /** + * Get a map of radar id->BiasDynRecords + * + * @param recdate + * @param productName + * @return BiasDynRecords + * @throws Exception + */ + public SortedMap> getBiasDynRecords( + Date recdate, String productName) throws Exception { + SortedMap> dataMap = new TreeMap>(); + + HpeRadarResult hpeResult = getHpeRadarResult(recdate, productName); + + HpeDataSource source = hpeResult.getRadarDataSource(); + + String table = null; + if (source == HpeDataSource.S) { + table = "RWBiasDyn"; + } else if (source == HpeDataSource.D) { + table = "DAABiasDyn"; + } else { + throw new Exception( + "Invalid bias source defined in HPERadarResult table: " + + source); + } + + String office = SiteUtil.getSite(); + StringBuilder query = new StringBuilder("select radid, office_id, "); + query.append("obstime, memspan_ind, numpairs, sumgag, sumrad, bias"); + query.append(" from ").append(table); + query.append(" where office_id ").append(" = '").append(office) + .append("'"); + query.append(" and obstime = '").append(sdf.get().format(recdate)); + query.append("'").append(" order by radid asc, memspan_ind asc"); + + Object[] results = dao.executeSQLQuery(query.toString()); + for (Object result : results) { + if (result instanceof Object[]) { + Object[] oa = (Object[]) result; + BiasDynRecord rec = new BiasDynRecord(); + rec.setRadarId((String) oa[0]); + rec.setOfficeId((String) oa[1]); + rec.setObsTime((Date) oa[2]); + rec.setMemspanIndex((Integer) oa[3]); + rec.setNumPairs((Float) oa[4]); + rec.setSumGages((Float) oa[5]); + rec.setSumRadars((Float) oa[6]); + rec.setBias((Float) oa[7]); + + if (!dataMap.containsKey(rec.getOfficeId())) { + dataMap.put(rec.getOfficeId(), + new ArrayList()); + } + + dataMap.get(rec.getRadarId()).add(rec); + } else { + throw new Exception( + "Unexpected return type from bias query, expected Object[], got " + + result.getClass().getName()); + } + } + + return dataMap; + } + + /** + * Get the hpeRadarResult entry for this product. + * + * @param date + * date of the product + * @param productName + * name of the product + * @return record object + * @throws Exception + */ + public HpeRadarResult getHpeRadarResult(Date date, String productName) + throws Exception { + HpeRadarResult hpeResult = new HpeRadarResult(); + try { + String where = " where producttime = '" + sdf.get().format(date) + + "' and hpe_productname = '" + productName + "'"; + + Object[] results = dao.executeSQLQuery(FULL_HPE_RADAR_RESULT_QUERY + + where); + if (results != null && results.length == 5) { + hpeResult.setHpeProductName((String) results[0]); + hpeResult.setProductTime((Date) results[1]); + + if (results[2] != null) { + hpeResult.setNumRadarAvailable((Integer) results[2]); + } + + if (results[3] != null) { + hpeResult.setBiasSource((String) results[3]); + } + + if (results[4] != null) { + hpeResult.setRadarDataSource((String) results[4]); + } + } + } catch (Exception e) { + throw new Exception("Error querying the IHFS hperadarresult table", + e); + } + + return hpeResult; + } + + /** + * Get the nPairBiasSelect value. + * + * @return the nPairBiasSelect value + * @throws Exception + */ + public int getNPairBiasSelect() throws Exception { + try { + Object[] results = dao + .executeSQLQuery("select npair_bias_select from RWBiasStat"); + if (results != null && results.length == 1) { + return (Integer) results[0]; + } + } catch (Exception e) { + throw new Exception("Error querying the IHFS hperadarresult table", + e); + } + + return 0; + } + + /** + * Get a list of HPE radars for the current time. + * + * @param date + * The obstime + * @param table + * The table to query + * @return List of radars + * @throws Exception + */ + public List getHpeRadars(Date date, String table) throws Exception { + StringBuilder query = new StringBuilder(HPE_RADAR_QUERY); + query.append(table).append(" where obstime = '"); + query.append(sdf.get().format(date)).append("' order by radid"); + + List radarList; + + try { + Object[] results = dao.executeSQLQuery(query.toString()); + radarList = new ArrayList(results.length); + for (Object o : results) { + radarList.add((String) o); + } + + return radarList; + } catch (Exception e) { + throw new Exception("Error querying the IHFS hperadarresult table", + e); + } + } +} \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeEnums.java b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeEnums.java new file mode 100644 index 0000000000..63b32a0d51 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeEnums.java @@ -0,0 +1,82 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.plugin.hpe.util; + +/** + * HPE Enumerations. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Apr 23, 2014    3026    mpduff      Initial creation
+ * 
+ * 
+ * + * @author mpduff + * @version 1.0 + */ + +public class HpeEnums { + /** + * HPE Data Source + * + *
+     * S for single pol 
+     * D for dual pol
+     * 
+ */ + public enum HpeDataSource { + S, D + } + + /** + * HPE Bias Source. + */ + public enum HpeBiasSource { + RFC_MEAN_BIAS("RCF MEAN BIAS"), SITE_MEAN_BIAS("SITE MEAN BIAS"), SITE_LOCAL_BIAS( + "SITE LOCAL BIAS"), NO_BIAS("NO BIAS"); + + private final String biasSource; + + HpeBiasSource(String biasSource) { + this.biasSource = biasSource; + } + + public String getBiasSource() { + return biasSource; + } + + public static HpeBiasSource fromString(String source) { + if (source != null) { + for (HpeBiasSource h : HpeBiasSource.values()) { + if (source.equalsIgnoreCase(h.getBiasSource())) { + return h; + } + } + } + + throw new IllegalArgumentException( + "No souce found for HpeBiasSource value: " + source); + } + } +} diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeLabelGenerator.java b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeLabelGenerator.java new file mode 100644 index 0000000000..08a9c32672 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeLabelGenerator.java @@ -0,0 +1,183 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.plugin.hpe.util; + +import java.text.DecimalFormat; +import java.util.Date; +import java.util.List; +import java.util.SortedMap; + +import com.raytheon.uf.common.plugin.hpe.data.BiasDynRecord; +import com.raytheon.uf.common.status.IUFStatusHandler; +import com.raytheon.uf.common.status.UFStatus; +import com.raytheon.uf.common.util.StringUtil; +import com.raytheon.uf.edex.plugin.hpe.util.HpeEnums.HpeBiasSource; +import com.raytheon.uf.edex.plugin.hpe.util.HpeEnums.HpeDataSource; + +/** + * HPE label generator. Creates labels based on the HPE bias source data. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Mar 26, 2014   3026     mpduff      Initial creation
+ * 
+ * 
+ * + * @author mpduff + * @version 1.0 + */ + +public class HpeLabelGenerator { + private static final IUFStatusHandler statusHandler = UFStatus + .getHandler(HpeLabelGenerator.class); + + /** + * 2 decimal place formatter + */ + private final ThreadLocal twoDeciamalFormatter = new ThreadLocal() { + + @Override + protected DecimalFormat initialValue() { + DecimalFormat format = new DecimalFormat("0.00"); + return format; + } + }; + + private static String SLASH = "/"; + + private static String SPACE = " "; + + private static String Y = "Y"; + + private static String N = "N"; + + private final HpeDataAccessor dataAccessor; + + /** + * Constructor. + * + * @param dataAccessor + */ + public HpeLabelGenerator(HpeDataAccessor dataAccessor) { + this.dataAccessor = dataAccessor; + } + + /** + * Get the HPE label string. + * + * @param recDate + * The date of the record + * @param productName + * The name of the HPE product + * + * @return the label + * @throws Exception + */ + public String getHpeLabel(Date recDate, String productName) + throws Exception { + HpeRadarResult hpeResult = dataAccessor.getHpeRadarResult(recDate, + productName); + + if (hpeResult == null || hpeResult.isEmpty()) { + return "No HPE bias source data"; + } + + HpeDataSource source = hpeResult.getRadarDataSource(); + HpeBiasSource biasSource = hpeResult.getBiasSource(); + + // Site->BiasDynRecord list + SortedMap> dataMap = dataAccessor + .getBiasDynRecords(recDate, productName); + + StringBuilder label = new StringBuilder("Dual-Pol Source: "); + + // Label if single or dual + if (source == HpeDataSource.S) { + label.append(N); + } else if (source == HpeDataSource.D) { + label.append(Y); + } + + label.append(StringUtil.NEWLINE); + + // Add bias value + if (biasSource == HpeBiasSource.SITE_MEAN_BIAS) { + label.append("Bias Source: "); + label.append(System.getProperty("AW_SITE_IDENTIFIER")); + } else if (biasSource == HpeBiasSource.RFC_MEAN_BIAS) { + label.append("Bias Source: RFC"); + } else if (biasSource == HpeBiasSource.SITE_LOCAL_BIAS) { + label.append(System.getProperty("AW_SITE_IDENTIFIER")).append( + " Local Bias "); + return label.toString().trim(); + } else { + label.append("Bias Source: none"); + return label.toString().trim(); + } + + label.append(StringUtil.NEWLINE).append(SPACE); + + // Process each radar to get it's part of the label + for (String radar : dataMap.keySet()) { + String labelEntry = getLabelEntry(radar, dataMap.get(radar)); + label.append(labelEntry).append(SPACE); + } + + return label.toString().trim(); + } + + /** + * Get the label entry for the radar. + * + * @param radar + * radar id + * @param records + * BiasDynRecord objects + * @return the label for this radar + * @throws Exception + */ + private String getLabelEntry(String radar, List records) + throws Exception { + StringBuilder sb = new StringBuilder("k"); + sb.append(radar.toLowerCase()).append(SPACE); + final int npairBiasSelect = dataAccessor.getNPairBiasSelect(); + + // process the records + if (!records.isEmpty()) { + for (BiasDynRecord rec : records) { + if (rec.getNumPairs() > npairBiasSelect) { + String bias = twoDeciamalFormatter.get().format( + rec.getBias()); + sb.append(bias).append(SLASH) + .append((int) rec.getNumPairs()); + sb.append(StringUtil.NEWLINE); + + return sb.toString(); + } + } + } + + return sb.toString(); + } +} \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeRadarResult.java b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeRadarResult.java new file mode 100644 index 0000000000..1efd32d79c --- /dev/null +++ b/edexOsgi/com.raytheon.uf.edex.plugin.hpe/src/com/raytheon/uf/edex/plugin/hpe/util/HpeRadarResult.java @@ -0,0 +1,181 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.plugin.hpe.util; + +import java.util.Date; + +import com.raytheon.uf.edex.plugin.hpe.util.HpeEnums.HpeBiasSource; +import com.raytheon.uf.edex.plugin.hpe.util.HpeEnums.HpeDataSource; + +/** + * HpeRadarResult table data object. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Mar 26, 2014    3026    mpduff      Initial creation
+ * 
+ * 
+ * + * @author mpduff + * @version 1.0 + */ + +public class HpeRadarResult { + + private String hpeProductName; + + private Date productTime; + + private int numRadarAvailable; + + private String biasSource; + + private String radarDataSource; + + /** + * Default constructor. + */ + public HpeRadarResult() { + + } + + /** + * @return the hpeProductName + */ + public String getHpeProductName() { + return hpeProductName; + } + + /** + * @param hpeProductName + * the hpeProductName to set + */ + public void setHpeProductName(String hpeProductName) { + this.hpeProductName = hpeProductName; + } + + /** + * @return the productTime + */ + public Date getProductTime() { + return productTime; + } + + /** + * @param productTime + * the productTime to set + */ + public void setProductTime(Date productTime) { + this.productTime = productTime; + } + + /** + * @return the numRadarAvailable + */ + public int getNumRadarAvailable() { + return numRadarAvailable; + } + + /** + * @param numRadarAvailable + * the numRadarAvailable to set + */ + public void setNumRadarAvailable(int numRadarAvailable) { + this.numRadarAvailable = numRadarAvailable; + } + + /** + * @return the biasSource + */ + public String getBiasSourceString() { + return biasSource; + } + + /** + * @return the biasSource + */ + public HpeBiasSource getBiasSource() { + return HpeBiasSource.fromString(biasSource); + } + + /** + * @param biasSource + * the biasSource to set + */ + public void setBiasSource(String biasSource) { + this.biasSource = biasSource; + } + + /** + * @return the radarDataSource String value + */ + public String getRadarDataSourceString() { + return radarDataSource; + } + + /** + * @return the radarDataSource + */ + public HpeDataSource getRadarDataSource() { + return Enum.valueOf(HpeDataSource.class, radarDataSource); + } + + /** + * @param radarDataSource + * the radarDataSource to set + */ + public void setRadarDataSource(String radarDataSource) { + this.radarDataSource = radarDataSource; + } + + /** + * Determine if this is an empty data object. + * + * @return true if empty object, false if populated with data + */ + public boolean isEmpty() { + if (biasSource != null && biasSource.length() > 0) { + return false; + } + + if (hpeProductName != null && hpeProductName.length() > 0) { + return false; + } + + if (numRadarAvailable > 0) { + return false; + } + + if (productTime != null) { + return false; + } + + if (radarDataSource != null && radarDataSource.length() > 0) { + return false; + } + + // Empty file + return true; + } +} \ No newline at end of file diff --git a/nativeLib/files.native/awipsShare/hydroapps/precip_proc/bin/process_hpe_grib_files b/nativeLib/files.native/awipsShare/hydroapps/precip_proc/bin/process_hpe_grib_files index 5303433502..be04b650a4 100755 --- a/nativeLib/files.native/awipsShare/hydroapps/precip_proc/bin/process_hpe_grib_files +++ b/nativeLib/files.native/awipsShare/hydroapps/precip_proc/bin/process_hpe_grib_files @@ -150,7 +150,7 @@ then new_string=`date -u +%d%H%M%S` new_file_name=ZETA98_${out_file%.*}_$new_string.grib - INPUT_DIR=$(get_apps_defaults d2d_input_dir) + INPUT_DIR=$(get_apps_defaults hpe_grib_input_dir) echo Copy grib file $HPE_DHRMOSAIC_GRIB_DIR/$out_file >> $griblog echo to $HPE_DHRMOSAIC_GRIB_DIR/gribfile.tmp >> $griblog @@ -183,7 +183,7 @@ then new_string=`date -u +%d%H%M%S` new_file_name=ZETA98_${out_file%.*}_$new_string.grib - INPUT_DIR=$(get_apps_defaults d2d_input_dir) + INPUT_DIR=$(get_apps_defaults hpe_grib_input_dir) echo Copy grib file $HPE_BDHRMOSAIC_GRIB_DIR/$out_file >> $griblog echo to $HPE_BDHRMOSAIC_GRIB_DIR/gribfile.tmp >> $griblog @@ -216,7 +216,7 @@ then new_string=`date -u +%d%H%M%S` new_file_name=ZETA98_${out_file%.*}_$new_string.grib - INPUT_DIR=$(get_apps_defaults d2d_input_dir) + INPUT_DIR=$(get_apps_defaults hpe_grib_input_dir) echo Copy grib file $HPE_EBMOSAIC_GRIB_DIR/$out_file >> $griblog echo to $HPE_EBMOSAIC_GRIB_DIR/gribfile.tmp >> $griblog @@ -249,7 +249,7 @@ then new_string=`date -u +%d%H%M%S` new_file_name=ZETA98_${out_file%.*}_$new_string.grib - INPUT_DIR=$(get_apps_defaults d2d_input_dir) + INPUT_DIR=$(get_apps_defaults hpe_grib_input_dir) echo Copy grib file $HPE_ERMOSAIC_GRIB_DIR/$out_file >> $griblog echo to $HPE_ERMOSAIC_GRIB_DIR/gribfile.tmp >> $griblog diff --git a/tests/.classpath b/tests/.classpath index a9b0fefae7..79e64062c1 100644 --- a/tests/.classpath +++ b/tests/.classpath @@ -163,5 +163,7 @@ + + diff --git a/tests/manual/com/raytheon/uf/edex/plugin/hpe/util/HpeLabelGeneratorTest.java b/tests/manual/com/raytheon/uf/edex/plugin/hpe/util/HpeLabelGeneratorTest.java new file mode 100644 index 0000000000..6f22553d9b --- /dev/null +++ b/tests/manual/com/raytheon/uf/edex/plugin/hpe/util/HpeLabelGeneratorTest.java @@ -0,0 +1,364 @@ +/** + * This software was developed and / or modified by Raytheon Company, + * pursuant to Contract DG133W-05-CQ-1067 with the US Government. + * + * U.S. EXPORT CONTROLLED TECHNICAL DATA + * This software product contains export-restricted data whose + * export/transfer/disclosure is restricted by U.S. law. Dissemination + * to non-U.S. persons whether in the United States or abroad requires + * an export license or other authorization. + * + * Contractor Name: Raytheon Company + * Contractor Address: 6825 Pine Street, Suite 340 + * Mail Stop B8 + * Omaha, NE 68106 + * 402.291.0100 + * + * See the AWIPS II Master Rights File ("Master Rights File.pdf") for + * further licensing information. + **/ +package com.raytheon.uf.edex.plugin.hpe.util; + +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.when; + +import java.util.ArrayList; +import java.util.Calendar; +import java.util.List; +import java.util.SortedMap; +import java.util.TreeMap; + +import org.junit.Before; +import org.junit.Test; + +import com.raytheon.uf.common.plugin.hpe.data.BiasDynRecord; +import com.raytheon.uf.common.time.util.TimeUtil; +import com.raytheon.uf.edex.plugin.hpe.util.HpeEnums.HpeBiasSource; + +/** + * Test class for HpeLabelGenerator.java. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Mar 26, 2014    3026    mpduff      Initial creation
+ * 
+ * 
+ * + * @author mpduff + * @version 1.0 + */ + +public class HpeLabelGeneratorTest { + + private final HpeDataAccessor dataAccessor = mock(HpeDataAccessor.class); + + private final Calendar cal = TimeUtil.newGmtCalendar(); + + private final String SINGLE_POL_TABLE = "RWBiasDyn"; + + private final String DUAL_POL_TABLE = "DAABiasDyn"; + + private final String productName = "ERMOSAICM60201403051225z"; + + private final SortedMap> meanDataMap = new TreeMap>(); + + private final SortedMap> localDataMap = new TreeMap>(); + + @Before + public void setup() throws Exception { + setCalendar(); + createBiasDynRecords(); + List radarList = getRadarList(); + System.setProperty("AW_SITE_IDENTIFIER", "OAX"); + when(dataAccessor.getNPairBiasSelect()).thenReturn(10); + when(dataAccessor.getHpeRadars(cal.getTime(), SINGLE_POL_TABLE)) + .thenReturn(radarList); + when(dataAccessor.getHpeRadars(cal.getTime(), DUAL_POL_TABLE)) + .thenReturn(radarList); + } + + // Single pol tests + @Test + public void testLabelCreationForSinglePolSiteMeanBias() throws Exception { + // Set up run specific data + HpeRadarResult siteMeanBiasSingle = new HpeRadarResult(); + siteMeanBiasSingle.setHpeProductName(productName); + siteMeanBiasSingle.setProductTime(cal.getTime()); + siteMeanBiasSingle.setBiasSource(HpeBiasSource.SITE_MEAN_BIAS + .getBiasSource()); + siteMeanBiasSingle.setNumRadarAvailable(8); + siteMeanBiasSingle.setRadarDataSource("S"); + + when(dataAccessor.getHpeRadarResult(cal.getTime(), productName)) + .thenReturn(siteMeanBiasSingle); + + when(dataAccessor.getBiasDynRecords(cal.getTime(), productName)) + .thenReturn(meanDataMap); + + // Run the code + HpeLabelGenerator labelGen = new HpeLabelGenerator(dataAccessor); + String label = labelGen.getHpeLabel(cal.getTime(), productName); + + System.out.println(""); + System.out.println("Single Pol Site Mean Bias"); + System.out.println(label); + } + + @Test + public void testLabelCreationForSinglePolRfcMeanBias() throws Exception { + // Set up run specific data + HpeRadarResult rfcMeanBiasSingle = new HpeRadarResult(); + rfcMeanBiasSingle.setHpeProductName(productName); + rfcMeanBiasSingle.setProductTime(cal.getTime()); + rfcMeanBiasSingle.setBiasSource(HpeBiasSource.RFC_MEAN_BIAS + .getBiasSource()); + rfcMeanBiasSingle.setNumRadarAvailable(8); + rfcMeanBiasSingle.setRadarDataSource("S"); + + when(dataAccessor.getHpeRadarResult(cal.getTime(), productName)) + .thenReturn(rfcMeanBiasSingle); + + when(dataAccessor.getBiasDynRecords(cal.getTime(), productName)) + .thenReturn(meanDataMap); + + // Run the code + HpeLabelGenerator labelGen = new HpeLabelGenerator(dataAccessor); + String label; + label = labelGen.getHpeLabel(cal.getTime(), productName); + + System.out.println(""); + System.out.println("Single Pol RFC Mean Bias"); + System.out.println(label); + } + + @Test + public void testLabelCreationForSinglePolLocalBias() throws Exception { + // Set up run specific data + HpeRadarResult rfcLocalBiasSingle = new HpeRadarResult(); + rfcLocalBiasSingle.setHpeProductName(productName); + rfcLocalBiasSingle.setProductTime(cal.getTime()); + rfcLocalBiasSingle.setBiasSource(HpeBiasSource.SITE_LOCAL_BIAS + .getBiasSource()); + rfcLocalBiasSingle.setNumRadarAvailable(8); + rfcLocalBiasSingle.setRadarDataSource("S"); + + when(dataAccessor.getHpeRadarResult(cal.getTime(), productName)) + .thenReturn(rfcLocalBiasSingle); + + when(dataAccessor.getBiasDynRecords(cal.getTime(), productName)) + .thenReturn(localDataMap); + + // Run the code + HpeLabelGenerator labelGen = new HpeLabelGenerator(dataAccessor); + String label = labelGen.getHpeLabel(cal.getTime(), productName); + + System.out.println(""); + System.out.println("Single Pol Local Site Bias"); + System.out.println(label); + } + + @Test + public void testLabelCreationForSinglePolNoBias() throws Exception { + // Set up run specific data + HpeRadarResult rfcLocalBiasSingle = new HpeRadarResult(); + rfcLocalBiasSingle.setHpeProductName(productName); + rfcLocalBiasSingle.setProductTime(cal.getTime()); + rfcLocalBiasSingle.setBiasSource(HpeBiasSource.NO_BIAS.getBiasSource()); + rfcLocalBiasSingle.setNumRadarAvailable(8); + rfcLocalBiasSingle.setRadarDataSource("S"); + + when(dataAccessor.getHpeRadarResult(cal.getTime(), productName)) + .thenReturn(rfcLocalBiasSingle); + + when(dataAccessor.getBiasDynRecords(cal.getTime(), productName)) + .thenReturn(localDataMap); + + // Run the code + HpeLabelGenerator labelGen = new HpeLabelGenerator(dataAccessor); + String label = labelGen.getHpeLabel(cal.getTime(), productName); + + System.out.println(""); + System.out.println("Single Pol No Bias"); + System.out.println(label); + } + + // Dual pol tests + @Test + public void testLabelCreationForDualPolSiteMeanBias() throws Exception { + // Set up run specific data + HpeRadarResult siteMeanBiasSingle = new HpeRadarResult(); + siteMeanBiasSingle.setHpeProductName(productName); + siteMeanBiasSingle.setProductTime(cal.getTime()); + siteMeanBiasSingle.setBiasSource(HpeBiasSource.SITE_MEAN_BIAS + .getBiasSource()); + siteMeanBiasSingle.setNumRadarAvailable(8); + siteMeanBiasSingle.setRadarDataSource("D"); + + when(dataAccessor.getHpeRadarResult(cal.getTime(), productName)) + .thenReturn(siteMeanBiasSingle); + + when(dataAccessor.getBiasDynRecords(cal.getTime(), productName)) + .thenReturn(meanDataMap); + + // Run the code + HpeLabelGenerator labelGen = new HpeLabelGenerator(dataAccessor); + String label = labelGen.getHpeLabel(cal.getTime(), productName); + + System.out.println(""); + System.out.println("Dual Pol Site Mean Bias"); + System.out.println(label); + } + + @Test + public void testLabelCreationForDualPolRfcMeanBias() throws Exception { + // Set up run specific data + HpeRadarResult rfcMeanBiasSingle = new HpeRadarResult(); + rfcMeanBiasSingle.setHpeProductName(productName); + rfcMeanBiasSingle.setProductTime(cal.getTime()); + rfcMeanBiasSingle.setBiasSource(HpeBiasSource.RFC_MEAN_BIAS + .getBiasSource()); + rfcMeanBiasSingle.setNumRadarAvailable(8); + rfcMeanBiasSingle.setRadarDataSource("D"); + + when(dataAccessor.getHpeRadarResult(cal.getTime(), productName)) + .thenReturn(rfcMeanBiasSingle); + + when(dataAccessor.getBiasDynRecords(cal.getTime(), productName)) + .thenReturn(meanDataMap); + + // Run the code + HpeLabelGenerator labelGen = new HpeLabelGenerator(dataAccessor); + String label = labelGen.getHpeLabel(cal.getTime(), productName); + + System.out.println(""); + System.out.println("Dual Pol RFC Mean Bias"); + System.out.println(label); + } + + @Test + public void testLabelCreationForDualPolLocalBias() throws Exception { + // Set up run specific data + HpeRadarResult rfcLocalBiasSingle = new HpeRadarResult(); + rfcLocalBiasSingle.setHpeProductName(productName); + rfcLocalBiasSingle.setProductTime(cal.getTime()); + rfcLocalBiasSingle.setBiasSource(HpeBiasSource.SITE_LOCAL_BIAS + .getBiasSource()); + rfcLocalBiasSingle.setNumRadarAvailable(8); + rfcLocalBiasSingle.setRadarDataSource("D"); + + when(dataAccessor.getHpeRadarResult(cal.getTime(), productName)) + .thenReturn(rfcLocalBiasSingle); + + when(dataAccessor.getBiasDynRecords(cal.getTime(), productName)) + .thenReturn(localDataMap); + + // Run the code + HpeLabelGenerator labelGen = new HpeLabelGenerator(dataAccessor); + String label = labelGen.getHpeLabel(cal.getTime(), productName); + + System.out.println(""); + System.out.println("Dual Pol Local Site Bias"); + System.out.println(label); + } + + @Test + public void testLabelCreationForDualPolNoBias() throws Exception { + // Set up run specific data + HpeRadarResult rfcLocalBiasSingle = new HpeRadarResult(); + rfcLocalBiasSingle.setHpeProductName(productName); + rfcLocalBiasSingle.setProductTime(cal.getTime()); + rfcLocalBiasSingle.setBiasSource(HpeBiasSource.NO_BIAS.getBiasSource()); + rfcLocalBiasSingle.setNumRadarAvailable(8); + rfcLocalBiasSingle.setRadarDataSource("D"); + + when(dataAccessor.getHpeRadarResult(cal.getTime(), productName)) + .thenReturn(rfcLocalBiasSingle); + + when(dataAccessor.getBiasDynRecords(cal.getTime(), productName)) + .thenReturn(localDataMap); + + // Run the code + HpeLabelGenerator labelGen = new HpeLabelGenerator(dataAccessor); + String label = labelGen.getHpeLabel(cal.getTime(), productName); + + System.out.println(""); + System.out.println("Dual Pol No Bias"); + System.out.println(label); + } + + private void setCalendar() { + cal.set(Calendar.YEAR, 2014); + cal.set(Calendar.MONTH, 3); + cal.set(Calendar.DAY_OF_MONTH, 5); + cal.set(Calendar.HOUR, 12); + cal.set(Calendar.MINUTE, 25); + cal.set(Calendar.SECOND, 0); + cal.set(Calendar.MILLISECOND, 0); + } + + private List getRadarList() { + List radarList = new ArrayList(); + radarList.add("ABR"); + radarList.add("DMX"); + radarList.add("EAX"); + radarList.add("FSD"); + radarList.add("LNX"); + radarList.add("OAX"); + radarList.add("TWX"); + radarList.add("UEX"); + + return radarList; + } + + private void createBiasDynRecords() { + List radarList = getRadarList(); + + float[] memSpanIdx = new float[] { 0f, 1.0f, 2.0f, 3.0f, 4.0f, 5.0f, + 6.0f, 7.0f, 8.0f, 9.0f }; + + double[] numPairs = new double[] { 0, 1.8534577634678e-36, + 3.9062266222742e-18, 5.102510849233e-12, 4.0175370594682e-07, + 0.0018974485809437, 7.045055608027, 40.795505532567, + 74.1231615108, 102.99244442947 }; + + float[] sumGages = new float[] { 0.381f, 0.384065f, 0.387877f, + 0.389836f, 0.391715f, 0.393323f, 0.539044f, 1.08328f, 1.15115f, + 1.16888f }; + + float[] sumRadars = new float[] { 1.21662f, 1.09099f, 1.03442f, + 1.01281f, 0.99475f, 0.980855f, 0.949928f, 0.990251f, 0.977503f, + 0.9625f }; + + float[] bias = new float[] { 0.313163f, 0.352033f, 0.37497f, 0.384905f, + 0.393782f, 0.401f, 0.567458f, 1.09394f, 1.17764f, 1.21442f }; + + // Create mean bias data + for (String radar : radarList) { + meanDataMap.put(radar, new ArrayList()); + } + + for (String radar : radarList) { + for (int i = 0; i < memSpanIdx.length; i++) { + BiasDynRecord r = new BiasDynRecord(); + r.setBias(bias[i]); + r.setMemspanIndex(memSpanIdx[i]); + r.setNumPairs(numPairs[i]); + r.setObsTime(cal.getTime()); + r.setOfficeId("OAX"); + r.setRadarId(radar); + r.setSumGages(sumGages[i]); + r.setSumRadars(sumRadars[i]); + meanDataMap.get(radar).add(r); + } + } + + // Create local bias data - local/no bias do not have bias data + for (String radar : radarList) { + localDataMap.put(radar, new ArrayList()); + } + } +} From b23473ee8a4c7bb47003da96196d706154a190a5 Mon Sep 17 00:00:00 2001 From: Mike Duff Date: Thu, 8 May 2014 15:01:52 -0500 Subject: [PATCH 165/188] Issue #3026 - NullPointer fix, test classpath fix Change-Id: Iabc347e51a276fd4c8beb3fd512d928f184767f1 Former-commit-id: 8e70b7ae1eef7a18ddffa6d6c88d10bdd0043bcc --- .../viz/monitor/ffmp/ui/rsc/FFMPResource.java | 18 ++++++++++++------ tests/.classpath | 1 - 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPResource.java b/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPResource.java index f826d1408f..4474c409d7 100644 --- a/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPResource.java +++ b/cave/com.raytheon.uf.viz.monitor.ffmp/src/com/raytheon/uf/viz/monitor/ffmp/ui/rsc/FFMPResource.java @@ -516,10 +516,15 @@ public class FFMPResource extends ve); } } else if (type.equals(ChangeType.DATA_REMOVE)) { - PluginDataObject[] pdos = (PluginDataObject[]) object; - for (PluginDataObject pdo : pdos) { - FFMPRecord ffmpRec = (FFMPRecord) pdo; - hpeLegendMap.remove(ffmpRec.getDataTime().getRefTime()); + if (object instanceof PluginDataObject[]) { + PluginDataObject[] pdos = (PluginDataObject[]) object; + for (PluginDataObject pdo : pdos) { + FFMPRecord ffmpRec = (FFMPRecord) pdo; + hpeLegendMap.remove(ffmpRec.getDataTime().getRefTime()); + } + } else if (object instanceof DataTime) { + DataTime dt = (DataTime) object; + hpeLegendMap.remove(dt.getRefTime()); } } } @@ -1221,7 +1226,8 @@ public class FFMPResource extends }); // Set flag for HPE data - isHpe = resourceData.siteKey.equalsIgnoreCase(HPE); + isHpe = resourceData.siteKey.equalsIgnoreCase(HPE) + || resourceData.siteKey.equalsIgnoreCase("BHPE"); } /** @@ -1467,7 +1473,7 @@ public class FFMPResource extends } // Paint the HPE bias source text if HPE - if (isHpe) { + if (isHpe && qpeRecord != null) { String text = getText(paintTime.getRefTime(), qpeRecord.getMetaData()); if (text != null) { diff --git a/tests/.classpath b/tests/.classpath index 79e64062c1..8ac824597b 100644 --- a/tests/.classpath +++ b/tests/.classpath @@ -162,7 +162,6 @@ - From 1e1f46e68baf4d9af2970f723f76bf0be1332ad9 Mon Sep 17 00:00:00 2001 From: Bryan Kowal Date: Thu, 8 May 2014 16:20:35 -0500 Subject: [PATCH 166/188] Issue #3108 - update bignsharp for Windows 64-bit compatibility. Upgrade JNA. Amend: updated and/or added change revision history comments Amend: fixed Java requirement in JNA classpath Amend: fixed Java requirement in JNA MANIFEST Change-Id: I5033f05c48a271fe08d3ec2ac01fe79481564371 Former-commit-id: fb12234836a3562156a30531e6961c0a064588bd --- cots/com.sun.jna/.classpath | 4 +- .../.settings/org.eclipse.jdt.core.prefs | 1 - cots/com.sun.jna/META-INF/MANIFEST.MF | 10 +- cots/com.sun.jna/build.properties | 2 +- cots/com.sun.jna/com.sun.jna.ecl | 0 cots/com.sun.jna/jna-4.1.0.jar | Bin 0 -> 914597 bytes cots/com.sun.jna/jna.jar | Bin 865400 -> 0 bytes .../bignsharp.dll | Bin 2447068 -> 2460040 bytes .../noaa/nws/ncep/ui/nsharp/Activator.java | 3 + .../display/rsc/NsharpDataPaneResource.java | 2 +- .../ncep/ui/nsharp/natives/NsharpNative.java | 3157 ++++++++++------- .../META-INF/MANIFEST.MF | 3 +- .../nws/ncep/viz/rsc/ncgrid/Activator.java | 5 + .../ncep/viz/tools/aodt/natives/datagrid.java | 91 +- .../ncep/viz/tools/aodt/natives/dis_vars.java | 76 +- .../ncep/viz/tools/aodt/natives/irdata.java | 202 +- .../ncep/viz/tools/aodt/natives/odtdata.java | 85 +- .../viz/tools/aodt/natives/remap_vars.java | 86 +- .../ncep/viz/tools/aodt/natives/ringdata.java | 76 +- .../viz/tools/aodt/natives/tiff_header.java | 84 +- .../viz/tools/aodt/natives/tiff_record.java | 92 +- .../viz/tools/aodt/natives/tiff_vars.java | 124 +- 22 files changed, 2547 insertions(+), 1556 deletions(-) delete mode 100644 cots/com.sun.jna/com.sun.jna.ecl create mode 100644 cots/com.sun.jna/jna-4.1.0.jar delete mode 100644 cots/com.sun.jna/jna.jar diff --git a/cots/com.sun.jna/.classpath b/cots/com.sun.jna/.classpath index fdf6ee4767..410e1da7cb 100644 --- a/cots/com.sun.jna/.classpath +++ b/cots/com.sun.jna/.classpath @@ -1,7 +1,7 @@ - + - + diff --git a/cots/com.sun.jna/.settings/org.eclipse.jdt.core.prefs b/cots/com.sun.jna/.settings/org.eclipse.jdt.core.prefs index 001f2d2882..c537b63063 100644 --- a/cots/com.sun.jna/.settings/org.eclipse.jdt.core.prefs +++ b/cots/com.sun.jna/.settings/org.eclipse.jdt.core.prefs @@ -1,4 +1,3 @@ -#Fri Mar 25 11:20:40 CDT 2011 eclipse.preferences.version=1 org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6 diff --git a/cots/com.sun.jna/META-INF/MANIFEST.MF b/cots/com.sun.jna/META-INF/MANIFEST.MF index 389310e0f2..8d1acd8664 100644 --- a/cots/com.sun.jna/META-INF/MANIFEST.MF +++ b/cots/com.sun.jna/META-INF/MANIFEST.MF @@ -1,10 +1,10 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 -Bundle-Name: Jna +Bundle-Name: JNA FOSS Bundle-SymbolicName: com.sun.jna -Bundle-Version: 3.3.0 -Bundle-ClassPath: jna.jar -Bundle-Vendor: Raytheon-bundled OSS +Bundle-Version: 4.1.0 +Bundle-ClassPath: jna-4.1.0.jar Export-Package: com.sun.jna, - com.sun.jna.ptr + com.sun.jna.ptr, + com.sun.jna.win32 Bundle-RequiredExecutionEnvironment: JavaSE-1.6 diff --git a/cots/com.sun.jna/build.properties b/cots/com.sun.jna/build.properties index 315c860036..48701da7af 100644 --- a/cots/com.sun.jna/build.properties +++ b/cots/com.sun.jna/build.properties @@ -1,2 +1,2 @@ bin.includes = META-INF/,\ - jna.jar + jna-4.1.0.jar diff --git a/cots/com.sun.jna/com.sun.jna.ecl b/cots/com.sun.jna/com.sun.jna.ecl deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/cots/com.sun.jna/jna-4.1.0.jar b/cots/com.sun.jna/jna-4.1.0.jar new file mode 100644 index 0000000000000000000000000000000000000000..b1a3922fec1aa6124b3a307c3a9154e73aac4d75 GIT binary patch literal 914597 zcmafaW00l6mTgscnO(MR+qP|de2s&EDEPS=*0KWng)a_JAS;ou86YWca%U)@<0C=fI~K%tl^!$h8@wDW9MP|rL; z=>;BW{c=x^{j#kKIz@zFk0}0!>--Pq)4rxY+^rJ1`~vK671%_>~@!r-g|e)&6b^5wjk%ot$tDe z?KYS|4gEwRCpuhgtvV|>Ny$hG&#denZHutU0nH9&1%gE1TfCiVzn0RusTTF7X6(ey z-byM>IEI&@&VWHUo`!Ndgkxo&Cz8JS08BAWq%x}sW_ip(AFzKIaxlky_J${euwa=0jwZ&sdiB%91t z+mP=>UJ>P-NqNXRZSGT`ZF$^I2*YJtSW|&fk}^>K7@WP#Q&=LdO2SoU4*qM7sX07* z`u#*yEfpM|Hfg5k+E7H-Tr>;uY79=)==R`xJTnk*?Pd9^|4qSNGa~!j`2(&>h(RMa z%%6kt;N&GLfbtCm_~r}MRqoX>9H+05_YK2;>KX(D`Cn21?60m(>}~%C#9#6M8^YPu z?w?Tq$d7-@BoMfNLRr}v{SU|=|AKUIarz(7$p3_UtGxF zhx}jgLN+cUMm9EePEjA5 zb4)BSLFz|mT{S>jEN4MG2@u>6An;S@@^-oJrTfP#Rq z{7b<9h}PK1#F|vi&cw*o+`>f+XaaEfN7#}^cBVD}r+<&$HFgRCROm-=<>zI+q$Dn{ z|941oM^{u~V#izO8@wbyjMf?fZ&ncGtzy5lDDh%`N8;DKTFd(pOkP-IOkfOhek$fz zL`y`Nc{#!zJ7ch&HFZ!|I5LU%fN`&O2d(>O`HTd5W();-79(d}rCLuHG3ReW=wfW! zCSuiXZ;m0`Wau1&o6L!uL#C`Ib)x*cKdQNyh5Z4?l*&l?Z{@7cK4d1spBm|6gr@P4 zPQkQJ3TZ-LY;>G6SA+l?)aw23|Eb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