From 690b5b73cfb06406849b86dac7bfc13350362a1d Mon Sep 17 00:00:00 2001 From: Dave Hladky Date: Wed, 22 Jan 2014 16:56:06 -0600 Subject: [PATCH] Issue #2584 Step one of versioning for DD Change-Id: I456643a92b95de3d4a74dff3a4e7daa9c08c5c00 Former-commit-id: 878f95f025dc07ec6ce73f715cef57193493e9eb --- .../ebxml-jaxb-datadelivery-registry.xml | 9 +- .../registry/AdhocSubscription.java | 4 + .../DataDeliveryRegistryObjectTypes.java | 52 ++++++++ .../common/datadelivery/registry/DataSet.java | 3 + .../registry/DataSetMetaData.java | 3 + .../datadelivery/registry/DataSetName.java | 3 + .../datadelivery/registry/GriddedTime.java | 2 - .../registry/IDataSetMetaDataVisitor.java | 1 + .../registry/OpenDapGriddedDataSet.java | 7 + .../OpenDapGriddedDataSetMetaData.java | 4 + .../datadelivery/registry/Parameter.java | 4 + .../registry/PendingSharedSubscription.java | 3 + .../registry/PendingSiteSubscription.java | 3 + .../registry/PendingSubscription.java | 1 + .../registry/PointDataSetMetaData.java | 7 + .../datadelivery/registry/Provider.java | 5 +- .../registry/SharedSubscription.java | 4 + .../registry/SiteSubscription.java | 4 + .../datadelivery/registry/Subscription.java | 1 - .../registry/WFSPointDataSet.java | 4 + .../ebxml/DataLevelTypeDescriptionQuery.java | 3 +- .../registry/ebxml/DataLevelTypeQuery.java | 3 +- .../ebxml/DataSetWithFiltersQuery.java | 6 +- .../registry/handlers/DataSetHandler.java | 2 +- .../registry/handlers/IDataSetHandler.java | 2 +- .../handlers/ISiteSubscriptionHandler.java | 2 +- .../raytheon/uf/common/registry/IConvert.java | 47 +++++++ .../annotations/RegistryObjectVersion.java | 51 ++++++++ .../common/registry/ebxml/RegistryUtil.java | 29 +++++ .../encoder/ContentSlotBasedEncoder.java | 14 +- .../encoder/DynamicSerializeEncoder.java | 75 ----------- .../registry/ebxml/encoder/JaxbEncoder.java | 67 +++++++++- .../ebxml/encoder/RegistryEncoders.java | 8 +- .../schemas/ebxml/util/EbxmlJaxbManager.java | 115 +++++++++++++++-- .../schemas/ebxml/util/SerializedType.java | 6 +- .../uf/common/util/ReflectionUtil.java | 21 +++ .../retrieval/RetrievalGenerator.java | 2 +- .../opendap/OpenDAPMetaDataParser.java | 2 +- .../opendap/OpenDAPRetrievalGenerator.java | 2 +- .../edex/plugin/madis/ogc/feature/Madis.java | 2 - .../uf/edex/registry/ebxml/dao/DbInit.java | 3 + .../adhoc/AdhocQueryExpressionManager.java | 121 ------------------ ...HttpProxiedValidClientCredentialsTest.java | 4 +- .../config/HarvesterConfigFixture.java | 2 +- .../registry/GriddedDataSetMetaDataTest.java | 1 + .../PendingSharedSubscriptionFixture.java | 1 + .../registry/PendingSubscriptionTest.java | 1 + .../registry/SharedSubscriptionFixture.java | 1 + .../ebxml/DataSetWithFiltersQueryTest.java | 4 +- .../handlers/MemoryDataSetHandler.java | 2 +- .../ebxml/FactoryRegistryHandlerTest.java | 2 +- .../registry/ebxml/RegistryUtilTest.java | 2 +- .../OpenDAPMetaDataParserNCOMTest.java | 2 +- .../opendap/OpenDAPMetaDataParserRAPTest.java | 2 +- .../subscription/xml/RuleXMLTest.java | 2 +- 55 files changed, 474 insertions(+), 259 deletions(-) create mode 100644 edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/IConvert.java create mode 100644 edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/annotations/RegistryObjectVersion.java delete mode 100644 edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/encoder/DynamicSerializeEncoder.java delete mode 100644 edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/services/query/adhoc/AdhocQueryExpressionManager.java diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/res/spring/ebxml-jaxb-datadelivery-registry.xml b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/res/spring/ebxml-jaxb-datadelivery-registry.xml index b12da17cde..533120623c 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/res/spring/ebxml-jaxb-datadelivery-registry.xml +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/res/spring/ebxml-jaxb-datadelivery-registry.xml @@ -1,9 +1,10 @@ - - - + + + \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/AdhocSubscription.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/AdhocSubscription.java index 2f16a46da9..da8dfbfa3c 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/AdhocSubscription.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/AdhocSubscription.java @@ -24,6 +24,7 @@ import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlRootElement; import com.raytheon.uf.common.registry.annotations.RegistryObject; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; /** @@ -48,6 +49,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; * Oct 11, 2013 2460 dhladky Restored Adhoc's to registryObject store, WFO only * Oct 23, 2013 2484 dhladky Unique ID for subscriptions updated. * Nov 14, 2013 2548 mpduff Add a subscription type slot. + * jan 23, 2013 2584 dhladky Versions. * * * @@ -61,6 +63,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; @RegistryObject({ Subscription.PROVIDER_NAME_SLOT, Subscription.NAME_SLOT, Subscription.DATA_SET_SLOT, Subscription.OWNER_SLOT, Subscription.ORIGINATING_SITE_SLOT, Subscription.SUBSCRIPTION_TYPE_SLOT }) +@RegistryObjectVersion(value = 1.0f) public class AdhocSubscription extends SiteSubscription { @@ -74,4 +77,5 @@ public class AdhocSubscription extends super(subscription); setGroupName("Adhoc"); } + } diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataDeliveryRegistryObjectTypes.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataDeliveryRegistryObjectTypes.java index 3ce94af116..a27bcfbe69 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataDeliveryRegistryObjectTypes.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataDeliveryRegistryObjectTypes.java @@ -19,7 +19,11 @@ **/ package com.raytheon.uf.common.datadelivery.registry; +import oasis.names.tc.ebxml.regrep.xsd.rim.v4.RegistryObjectType; + import com.raytheon.uf.common.registry.ebxml.RegistryUtil; +import com.raytheon.uf.common.registry.ebxml.encoder.IRegistryEncoder; +import com.raytheon.uf.common.serialization.SerializationException; /** * Constants file for data delivery registry object types. @@ -36,6 +40,7 @@ import com.raytheon.uf.common.registry.ebxml.RegistryUtil; * Oct 11, 2013 2460 dhladky Restored Adhoc to registry store, WFO only. * Nov 12, 2013 2506 bgonzale Added is recurring subscription method. * Nov 18, 2013 1736 dhladky Data Set helper method. + * Dec 08, 2013 2584 dhladky Registry versions for objects. * * * @@ -48,6 +53,7 @@ public final class DataDeliveryRegistryObjectTypes { * Private constructor. */ private DataDeliveryRegistryObjectTypes() { + } public static final String DATASETMETADATA = RegistryUtil @@ -67,6 +73,9 @@ public final class DataDeliveryRegistryObjectTypes { public static final String PROVIDER = RegistryUtil .getObjectType(Provider.class); + + public static final String PARAMETER = RegistryUtil + .getObjectType(Parameter.class); /** * Is the object type a recurring subscription type, excluding adhoc @@ -94,4 +103,47 @@ public final class DataDeliveryRegistryObjectTypes { return DataDeliveryRegistryObjectTypes.DATASETMETADATA .equals(objectType); } + + /** + * Convert the object if necessary + * + * @param content + * @param encoder + * @return + */ + public static Object convertObject(Object content, + IRegistryEncoder encoder) { + + /** + * TODO In next step attempt to + * do a conversion + */ + throw new IllegalArgumentException( + "Can not convert Data Delivery Registry Objects in this release!"); + + } + + + /** + * Gets the object from the encoder, checking to see if conversion is + * necessary or not. + * + * @param registryObjectType + * @param encoder + * @return + * @throws SerializationException + */ + public static Object getObject(RegistryObjectType registryObjectType, + IRegistryEncoder encoder) throws SerializationException { + + Object object = encoder.decodeObject(registryObjectType); + + //Returned content. Object is of different version! + if (object instanceof String) { + object = convertObject(object, encoder); + } + + return object; + } + } diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataSet.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataSet.java index da64088909..9a64bf91e6 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataSet.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataSet.java @@ -18,6 +18,7 @@ import com.raytheon.uf.common.registry.annotations.RegistryObjectAssociation; import com.raytheon.uf.common.registry.annotations.RegistryObjectDescription; import com.raytheon.uf.common.registry.annotations.RegistryObjectName; import com.raytheon.uf.common.registry.annotations.RegistryObjectOwner; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.registry.annotations.SlotAttribute; import com.raytheon.uf.common.registry.annotations.SlotAttributeConverter; import com.raytheon.uf.common.registry.ebxml.MapValuesResolver; @@ -41,6 +42,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; * Sep 07, 2012 1102 djohnson Remove invalid {@code @XmlRootElement}. * Nov 19, 2012 1166 djohnson Clean up JAXB representation of registry objects. * Dec 18, 2013 2636 mpduff Add a data availability delay for the dataset. + * jan 23, 2013 2584 dhladky Versions. * * * @@ -50,6 +52,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; @XmlAccessorType(XmlAccessType.NONE) @DynamicSerialize @RegistryObject({ "providerName", "collectionName", "dataSetName" }) +@RegistryObjectVersion(value = 1.0f) public abstract class DataSet { @RegistryObjectOwner diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataSetMetaData.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataSetMetaData.java index a862c7908d..2bd34d4968 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataSetMetaData.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataSetMetaData.java @@ -17,6 +17,7 @@ import com.raytheon.uf.common.registry.annotations.RegistryObject; import com.raytheon.uf.common.registry.annotations.RegistryObjectDescription; import com.raytheon.uf.common.registry.annotations.RegistryObjectName; import com.raytheon.uf.common.registry.annotations.RegistryObjectOwner; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.registry.annotations.SlotAttribute; import com.raytheon.uf.common.registry.annotations.SlotAttributeConverter; import com.raytheon.uf.common.registry.ebxml.slots.DateSlotConverter; @@ -42,6 +43,7 @@ import com.raytheon.uf.common.time.util.ImmutableDate; * Nov 19, 2012 1166 djohnson Clean up JAXB representation of registry objects. * Sept, 30 2013 1797 dhladky Made generic based on Time * Dec 20, 2013 2636 mpduff Add a dataset availability offset + * jan 23, 2013 2584 dhladky Versions. * * * @author dhladky @@ -51,6 +53,7 @@ import com.raytheon.uf.common.time.util.ImmutableDate; @XmlSeeAlso({ GriddedDataSetMetaData.class, OpenDapGriddedDataSetMetaData.class, PointDataSetMetaData.class }) @RegistryObject({ "url" }) +@RegistryObjectVersion(value = 1.0f) public abstract class DataSetMetaData { public static final String DATE_SLOT = "date"; diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataSetName.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataSetName.java index 064f576e19..d072e68c06 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataSetName.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/DataSetName.java @@ -13,6 +13,7 @@ import com.raytheon.uf.common.registry.annotations.RegistryObjectAssociation; import com.raytheon.uf.common.registry.annotations.RegistryObjectDescription; import com.raytheon.uf.common.registry.annotations.RegistryObjectName; import com.raytheon.uf.common.registry.annotations.RegistryObjectOwner; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.registry.annotations.SlotAttribute; import com.raytheon.uf.common.registry.ebxml.MapValuesResolver; import com.raytheon.uf.common.serialization.XmlGenericMapAdapter; @@ -33,6 +34,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; * Aug 22, 2012 0743 djohnson Store data type as an enum. * Sep 07, 2012 1102 djohnson Add {@code @XmlRootElement}. * Nov 19, 2012 1166 djohnson Clean up JAXB representation of registry objects. + * jan 23, 2013 2584 dhladky Versions. * * * @@ -44,6 +46,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; @XmlAccessorType(XmlAccessType.NONE) @DynamicSerialize @RegistryObject(value = { "providerName", "dataSetType", "dataSetName" }, storeContent = false) +@RegistryObjectVersion(value = 1.0f) public class DataSetName { @RegistryObjectOwner diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/GriddedTime.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/GriddedTime.java index ce203f356c..b254c28985 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/GriddedTime.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/GriddedTime.java @@ -33,8 +33,6 @@ import javax.xml.bind.annotation.XmlRootElement; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; -import com.raytheon.uf.common.status.IUFStatusHandler; -import com.raytheon.uf.common.status.UFStatus; /** * Request Time XML diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/IDataSetMetaDataVisitor.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/IDataSetMetaDataVisitor.java index 8a23e994e2..78efaf40e5 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/IDataSetMetaDataVisitor.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/IDataSetMetaDataVisitor.java @@ -19,6 +19,7 @@ **/ package com.raytheon.uf.common.datadelivery.registry; + /** * Defines a type that can visit {@link DataSetMetaData} instances and perform * some activity. diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/OpenDapGriddedDataSet.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/OpenDapGriddedDataSet.java index 42c7b592a4..e8f117135c 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/OpenDapGriddedDataSet.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/OpenDapGriddedDataSet.java @@ -31,6 +31,7 @@ import javax.xml.bind.annotation.XmlRootElement; import javax.xml.bind.annotation.adapters.XmlJavaTypeAdapter; import com.raytheon.uf.common.datadelivery.registry.Provider.ServiceType; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.serialization.XmlGenericMapAdapter; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; @@ -55,9 +56,14 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; */ @XmlRootElement @XmlAccessorType(XmlAccessType.NONE) +@RegistryObjectVersion(value = 1.0f) @DynamicSerialize public class OpenDapGriddedDataSet extends GriddedDataSet { + public OpenDapGriddedDataSet() { + + } + @DynamicSerializeElement @XmlJavaTypeAdapter(type = Map.class, value = XmlGenericMapAdapter.class) private Map cyclesToUrls = new HashMap(); @@ -162,4 +168,5 @@ public class OpenDapGriddedDataSet extends GriddedDataSet { public ServiceType getServiceType() { return ServiceType.OPENDAP; } + } diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/OpenDapGriddedDataSetMetaData.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/OpenDapGriddedDataSetMetaData.java index 4821a8b921..faa522a6f0 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/OpenDapGriddedDataSetMetaData.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/OpenDapGriddedDataSetMetaData.java @@ -23,6 +23,7 @@ import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlRootElement; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; /** @@ -35,6 +36,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Sep 4, 2012 1102 djohnson Initial creation + * jan 23, 2013 2584 dhladky Versions * * * @@ -43,6 +45,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; */ @XmlRootElement @XmlAccessorType(XmlAccessType.NONE) +@RegistryObjectVersion(value = 1.0f) @DynamicSerialize public class OpenDapGriddedDataSetMetaData extends GriddedDataSetMetaData { @@ -53,4 +56,5 @@ public class OpenDapGriddedDataSetMetaData extends GriddedDataSetMetaData { public void accept(IDataSetMetaDataVisitor visitor) { visitor.visit(this); } + } diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/Parameter.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/Parameter.java index 245bd56124..78b209ef21 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/Parameter.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/Parameter.java @@ -20,6 +20,7 @@ import com.raytheon.uf.common.registry.annotations.RegistryObject; import com.raytheon.uf.common.registry.annotations.RegistryObjectAssociation; import com.raytheon.uf.common.registry.annotations.RegistryObjectDescription; import com.raytheon.uf.common.registry.annotations.RegistryObjectName; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.registry.annotations.SlotAttribute; import com.raytheon.uf.common.registry.annotations.SlotAttributeConverter; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; @@ -40,6 +41,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; * Sep 06, 2012 1121 mpduff Added toString(). * Sep 07, 2012 1102 djohnson Add {@code @XmlRootElement}. * Nov 19, 2012 1166 djohnson Clean up JAXB representation of registry objects. + * Dec 08, 2013 2584 dhladky Version update * * * @author dhladky @@ -51,6 +53,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; @XmlAccessorType(XmlAccessType.NONE) @DynamicSerialize @RegistryObject({ "name", "dataType" }) +@RegistryObjectVersion(value = 1.0f) public class Parameter implements Serializable { private static final long serialVersionUID = -2332611624661834210L; @@ -294,4 +297,5 @@ public class Parameter implements Serializable { return hcBuilder.toHashCode(); } + } diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PendingSharedSubscription.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PendingSharedSubscription.java index e3b678ee8f..c7b7fc0b0d 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PendingSharedSubscription.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PendingSharedSubscription.java @@ -25,6 +25,7 @@ import javax.xml.bind.annotation.XmlRootElement; import com.raytheon.uf.common.registry.annotations.AssociationMapping; import com.raytheon.uf.common.registry.annotations.RegistryObject; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.registry.constants.AssociationTypes; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; @@ -39,6 +40,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; * ------------ ---------- ----------- -------------------------- * Apr 04, 2013 1841 djohnson Initial creation * Sept 30, 2013 1797 dhladky Generics + * Dec 08, 2013 2584 dhladky Version update * * * @@ -54,6 +56,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; InitialPendingSubscription.CHANGE_REQUEST_ID_SLOT }, associationMappings = { @AssociationMapping(associationType = AssociationTypes.RELATED_TO, keyFields = { Subscription.PROVIDER_NAME_SLOT, Subscription.NAME_SLOT, Subscription.DATA_SET_SLOT, Subscription.OWNER_SLOT }, required = false, targetObject = SharedSubscription.class) }) +@RegistryObjectVersion(value = 1.0f) public class PendingSharedSubscription extends InitialPendingSharedSubscription implements PendingSubscription { diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PendingSiteSubscription.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PendingSiteSubscription.java index b70e2498f2..f7e0c1b967 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PendingSiteSubscription.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PendingSiteSubscription.java @@ -25,6 +25,7 @@ import javax.xml.bind.annotation.XmlRootElement; import com.raytheon.uf.common.registry.annotations.AssociationMapping; import com.raytheon.uf.common.registry.annotations.RegistryObject; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.registry.constants.AssociationTypes; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; @@ -44,6 +45,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; * Nov 19, 2012 1166 djohnson Clean up JAXB representation of registry objects. * Mar 29, 2013 1841 djohnson Subscription is now UserSubscription. * Oct 1, 2013 1797 dhladky Added some start for generics + * Dec 08, 2013 2584 dhladky Version update * * * @@ -59,6 +61,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; InitialPendingSubscription.CHANGE_REQUEST_ID_SLOT }, associationMappings = { @AssociationMapping(associationType = AssociationTypes.RELATED_TO, keyFields = { Subscription.PROVIDER_NAME_SLOT, Subscription.NAME_SLOT, Subscription.DATA_SET_SLOT, Subscription.OWNER_SLOT }, required = false, targetObject = SiteSubscription.class) }) +@RegistryObjectVersion(value = 1.0f) public class PendingSiteSubscription extends InitialPendingSiteSubscription implements PendingSubscription { diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PendingSubscription.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PendingSubscription.java index 0cc9941894..a7561e76d1 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PendingSubscription.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PendingSubscription.java @@ -19,6 +19,7 @@ **/ package com.raytheon.uf.common.datadelivery.registry; + /** * Pending Subscription definition. * diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PointDataSetMetaData.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PointDataSetMetaData.java index 20aff524cb..6da6f317aa 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PointDataSetMetaData.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/PointDataSetMetaData.java @@ -22,6 +22,7 @@ import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlRootElement; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; /** * Point Meta Data object @@ -42,11 +43,17 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; @XmlRootElement @XmlAccessorType(XmlAccessType.NONE) +@RegistryObjectVersion(value = 1.0f) @DynamicSerialize public class PointDataSetMetaData extends DataSetMetaData { + public PointDataSetMetaData() { + + } + @Override public void accept(IDataSetMetaDataVisitor visitor) { // TODO: not sure what this does? } + } \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/Provider.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/Provider.java index 71cbb2f514..1c951f7bfc 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/Provider.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/Provider.java @@ -12,6 +12,7 @@ import javax.xml.bind.annotation.XmlElements; import javax.xml.bind.annotation.XmlRootElement; import com.raytheon.uf.common.registry.annotations.RegistryObject; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.registry.annotations.SlotAttribute; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; @@ -31,6 +32,7 @@ import com.raytheon.uf.common.time.domain.api.IDuration; * ------------ ---------- ----------- -------------------------- * Feb 16, 2012 dhladky Initial creation * jun 11, 2013 2101 dhladky Updated for username/password DPA exchanges + * Dec 08, 2013 2584 dhladky Version update * * * @@ -42,6 +44,7 @@ import com.raytheon.uf.common.time.domain.api.IDuration; @XmlAccessorType(XmlAccessType.NONE) @DynamicSerialize @RegistryObject({ "name" }) +@RegistryObjectVersion(value = 1.0f) public class Provider { /** @@ -105,7 +108,7 @@ public class Provider { return (long) (latSpan * lonSpan * (timeSpan/5) * requestOverheadInBytes); } } - + private static final Integer BYTES_IN_FLOAT = Float.SIZE / Byte.SIZE; /** a one degree by one degree box **/ diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/SharedSubscription.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/SharedSubscription.java index 812cdacf83..bffae6bc90 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/SharedSubscription.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/SharedSubscription.java @@ -24,6 +24,7 @@ import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlRootElement; import com.raytheon.uf.common.registry.annotations.RegistryObject; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; /** @@ -41,6 +42,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; * Sept 30, 2013 1797 dhladky Generics * Oct 23, 2013 2484 dhladky Unique ID for subscriptions updated. * Nov 14, 2013 2548 mpduff Add a subscription type slot. + * jan 23, 2013 2584 dhladky Versions. * * * @@ -53,6 +55,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; Subscription.NAME_SLOT, Subscription.DATA_SET_SLOT, Subscription.OWNER_SLOT, Subscription.ORIGINATING_SITE_SLOT, Subscription.SUBSCRIPTION_TYPE_SLOT }) +@RegistryObjectVersion(value = 1.0f) @DynamicSerialize public class SharedSubscription extends RecurringSubscription { @@ -143,4 +146,5 @@ public class SharedSubscription extends this.officeIDs.add(officeId); } } + } \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/SiteSubscription.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/SiteSubscription.java index bfe78f8df0..b5bfcde1a5 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/SiteSubscription.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/SiteSubscription.java @@ -25,6 +25,7 @@ import javax.xml.bind.annotation.XmlAttribute; import javax.xml.bind.annotation.XmlRootElement; import com.raytheon.uf.common.registry.annotations.RegistryObject; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.registry.annotations.SlotAttribute; import com.raytheon.uf.common.registry.ebxml.RegistryUtil; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; @@ -64,6 +65,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; * Sept 30, 2013 1797 dhladky Some Generics * Oct 23, 2013 2484 dhladky Unique ID for subscriptions updated. * Nov 14, 2013 2548 mpduff Add a subscription type slot. + * Dec 08, 2013 2584 dhladky Version update * * * @@ -77,6 +79,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement; Subscription.DATA_SET_SLOT, Subscription.OWNER_SLOT, Subscription.ORIGINATING_SITE_SLOT, Subscription.SUBSCRIPTION_TYPE_SLOT }) @DynamicSerialize +@RegistryObjectVersion(value = 1.0f) public class SiteSubscription extends RecurringSubscription { private static final long serialVersionUID = -6422673887457060034L; @@ -180,4 +183,5 @@ public class SiteSubscription extends this.officeIDs.add(officeId); } } + } 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 f884ad4b4b..9c29cb48e5 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 @@ -28,7 +28,6 @@ import javax.xml.bind.annotation.XmlEnum; import javax.xml.bind.annotation.XmlEnumValue; import com.raytheon.uf.common.datadelivery.registry.Utils.SubscriptionStatus; - /** * Definition of a subscription. * diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/WFSPointDataSet.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/WFSPointDataSet.java index 65c0065069..185d7fb024 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/WFSPointDataSet.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/WFSPointDataSet.java @@ -23,6 +23,7 @@ import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlRootElement; import com.raytheon.uf.common.datadelivery.registry.Provider.ServiceType; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; /** @@ -35,6 +36,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Aug 11, 2012 754 dhladky Initial creation + * jan 23, 2013 2584 dhladky Versions. * * * @@ -43,6 +45,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize; */ @XmlRootElement @XmlAccessorType(XmlAccessType.NONE) +@RegistryObjectVersion(value = 1.0f) @DynamicSerialize public class WFSPointDataSet extends PointDataSet { @@ -50,4 +53,5 @@ public class WFSPointDataSet extends PointDataSet { public ServiceType getServiceType() { return ServiceType.WFS; } + } diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/ebxml/DataLevelTypeDescriptionQuery.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/ebxml/DataLevelTypeDescriptionQuery.java index a1d6d75c0e..45ef852d51 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/ebxml/DataLevelTypeDescriptionQuery.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/ebxml/DataLevelTypeDescriptionQuery.java @@ -9,6 +9,7 @@ import javax.persistence.Transient; import oasis.names.tc.ebxml.regrep.xsd.rim.v4.RegistryObjectType; +import com.raytheon.uf.common.datadelivery.registry.DataDeliveryRegistryObjectTypes; import com.raytheon.uf.common.datadelivery.registry.DataLevelType; import com.raytheon.uf.common.datadelivery.registry.Parameter; import com.raytheon.uf.common.registry.IMultipleResultFormatter; @@ -46,7 +47,7 @@ public class DataLevelTypeDescriptionQuery extends RegistryObjectType registryObjectType, IRegistryEncoder encoder) throws SerializationException { - Parameter object = (Parameter) encoder.decodeObject(registryObjectType); + Parameter object = (Parameter) DataDeliveryRegistryObjectTypes.getObject(registryObjectType, encoder); if (alreadyFound == null) { alreadyFound = new HashSet(); diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/ebxml/DataLevelTypeQuery.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/ebxml/DataLevelTypeQuery.java index 30b2acc5ca..ac95f5942a 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/ebxml/DataLevelTypeQuery.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/ebxml/DataLevelTypeQuery.java @@ -7,6 +7,7 @@ import java.util.Map; import oasis.names.tc.ebxml.regrep.xsd.rim.v4.RegistryObjectType; +import com.raytheon.uf.common.datadelivery.registry.DataDeliveryRegistryObjectTypes; import com.raytheon.uf.common.datadelivery.registry.DataLevelType; import com.raytheon.uf.common.datadelivery.registry.DataSet; import com.raytheon.uf.common.datadelivery.registry.Parameter; @@ -59,7 +60,7 @@ public class DataLevelTypeQuery extends RegistryObjectType registryObjectType, IRegistryEncoder encoder) throws SerializationException { - Object object = encoder.decodeObject(registryObjectType); + Object object = DataDeliveryRegistryObjectTypes.getObject(registryObjectType, encoder); if (object instanceof DataSet) { diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/ebxml/DataSetWithFiltersQuery.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/ebxml/DataSetWithFiltersQuery.java index f6d136ad99..93e8169e22 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/ebxml/DataSetWithFiltersQuery.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/ebxml/DataSetWithFiltersQuery.java @@ -11,11 +11,12 @@ import org.geotools.geometry.jts.ReferencedEnvelope; import org.opengis.referencing.operation.TransformException; import com.google.common.annotations.VisibleForTesting; +import com.raytheon.uf.common.datadelivery.registry.DataDeliveryRegistryObjectTypes; import com.raytheon.uf.common.datadelivery.registry.DataLevelType; -import com.raytheon.uf.common.datadelivery.registry.DataLevelType.LevelType; import com.raytheon.uf.common.datadelivery.registry.DataSet; import com.raytheon.uf.common.datadelivery.registry.DataSetMetaData; import com.raytheon.uf.common.datadelivery.registry.Parameter; +import com.raytheon.uf.common.datadelivery.registry.DataLevelType.LevelType; import com.raytheon.uf.common.geospatial.MapUtil; import com.raytheon.uf.common.registry.IResultFormatter; import com.raytheon.uf.common.registry.ebxml.encoder.IRegistryEncoder; @@ -66,8 +67,7 @@ public class DataSetWithFiltersQuery extends DataSetQuery implements IRegistryEncoder encoder) throws SerializationException { DataSet retVal = null; - DataSet object = (DataSet) encoder - .decodeObject(registryObjectType); + DataSet object = (DataSet) DataDeliveryRegistryObjectTypes.getObject(registryObjectType, encoder); if (satisfiesFilterCriteria(object, levels, envelope)) { retVal = object; diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/handlers/DataSetHandler.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/handlers/DataSetHandler.java index d2c0ad1e8c..6b9f22923b 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/handlers/DataSetHandler.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/handlers/DataSetHandler.java @@ -29,9 +29,9 @@ import oasis.names.tc.ebxml.regrep.wsdl.registry.services.v4.MsgRegistryExceptio import org.geotools.geometry.jts.ReferencedEnvelope; -import com.raytheon.uf.common.datadelivery.registry.DataLevelType.LevelType; import com.raytheon.uf.common.datadelivery.registry.DataSet; import com.raytheon.uf.common.datadelivery.registry.Parameter; +import com.raytheon.uf.common.datadelivery.registry.DataLevelType.LevelType; import com.raytheon.uf.common.datadelivery.registry.ebxml.DataSetQuery; import com.raytheon.uf.common.datadelivery.registry.ebxml.DataSetWithFiltersQuery; import com.raytheon.uf.common.registry.RegistryQueryResponse; diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/handlers/IDataSetHandler.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/handlers/IDataSetHandler.java index 61b009bd7e..b0d0abb59b 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/handlers/IDataSetHandler.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/handlers/IDataSetHandler.java @@ -24,8 +24,8 @@ import java.util.Set; import org.geotools.geometry.jts.ReferencedEnvelope; -import com.raytheon.uf.common.datadelivery.registry.DataLevelType.LevelType; import com.raytheon.uf.common.datadelivery.registry.DataSet; +import com.raytheon.uf.common.datadelivery.registry.DataLevelType.LevelType; import com.raytheon.uf.common.registry.handler.IRegistryObjectHandler; import com.raytheon.uf.common.registry.handler.RegistryHandlerException; diff --git a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/handlers/ISiteSubscriptionHandler.java b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/handlers/ISiteSubscriptionHandler.java index 802261b435..0a32270991 100644 --- a/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/handlers/ISiteSubscriptionHandler.java +++ b/edexOsgi/com.raytheon.uf.common.datadelivery.registry/src/com/raytheon/uf/common/datadelivery/registry/handlers/ISiteSubscriptionHandler.java @@ -19,8 +19,8 @@ **/ package com.raytheon.uf.common.datadelivery.registry.handlers; -import com.raytheon.uf.common.datadelivery.registry.Subscription; import com.raytheon.uf.common.datadelivery.registry.SiteSubscription; +import com.raytheon.uf.common.datadelivery.registry.Subscription; import com.raytheon.uf.common.registry.handler.IRegistryObjectHandler; /** diff --git a/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/IConvert.java b/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/IConvert.java new file mode 100644 index 0000000000..7c670dbe6d --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/IConvert.java @@ -0,0 +1,47 @@ +package com.raytheon.uf.common.registry; +/** + * 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. + **/ +/** + * Convert a different version of the Registry Object to this version. + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ *Dec 08, 2013  2584       dhladky     Initial creation
+ * 
+ * 
+ * + * @author dhladky + * @version 1.0 + */ + +public interface IConvert { + + /** + * Convert a Registry Object between versions + * + * @param o + */ + public void convert(Object o); +} + diff --git a/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/annotations/RegistryObjectVersion.java b/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/annotations/RegistryObjectVersion.java new file mode 100644 index 0000000000..60616a8bf4 --- /dev/null +++ b/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/annotations/RegistryObjectVersion.java @@ -0,0 +1,51 @@ +/** + * 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.registry.annotations; + +import java.lang.annotation.Documented; +import java.lang.annotation.ElementType; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +/** + * + * Denotes Version of the Registry Object + * + *
+ * 
+ * SOFTWARE HISTORY
+ * 
+ * Date         Ticket#    Engineer    Description
+ * ------------ ---------- ----------- --------------------------
+ * Dec 4, 2013  2584           dhladky     Initial creation
+ * 
+ * 
+ * + * @author dhladky + * @version 1.0 + */ +@Retention(RetentionPolicy.RUNTIME) +@Target(ElementType.TYPE) +@Documented +public @interface RegistryObjectVersion { + + public float value() default 1.0f; +} 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 f45b3229f3..2c997968c5 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 @@ -23,6 +23,7 @@ import oasis.names.tc.ebxml.regrep.xsd.rim.v4.RegistryObjectListType; import oasis.names.tc.ebxml.regrep.xsd.rim.v4.RegistryObjectType; import oasis.names.tc.ebxml.regrep.xsd.rim.v4.SlotType; import oasis.names.tc.ebxml.regrep.xsd.rim.v4.StringValueType; +import oasis.names.tc.ebxml.regrep.xsd.rim.v4.VersionInfoType; import com.raytheon.uf.common.comm.CommunicationException; import com.raytheon.uf.common.registry.OperationStatus; @@ -36,6 +37,7 @@ import com.raytheon.uf.common.registry.annotations.RegistryObjectAssociation; import com.raytheon.uf.common.registry.annotations.RegistryObjectDescription; import com.raytheon.uf.common.registry.annotations.RegistryObjectName; import com.raytheon.uf.common.registry.annotations.RegistryObjectOwner; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.registry.annotations.SlotAttribute; import com.raytheon.uf.common.registry.annotations.SlotAttributeConverter; import com.raytheon.uf.common.registry.constants.Languages; @@ -76,6 +78,7 @@ import com.raytheon.uf.common.util.ReflectionUtil; * 4/9/2013 1802 bphillip Pulled constants out into existing constants package that was moved into common * 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 * * * @@ -89,6 +92,10 @@ public final class RegistryUtil { } public static String LOCAL_REGISTRY_ADDRESS = null; + + public static final String registryObjectClassName = "registryObjectClassName"; + + public static final String registryObjectDefaultVersion = "1.0"; static { if (System.getenv("EBXML_REGISTRY_HOST") != null @@ -375,6 +382,28 @@ public final class RegistryUtil { .setDescription(getInternationalString(ReflectionUtil .getAnnotatedField(registryObject, RegistryObjectDescription.class))); + // Try to harvest the current version from the PayloadObject + // if none exists, default to encoder provided numeric. + VersionInfoType version = new VersionInfoType(); + String val = null; + RegistryObjectVersion rov = ReflectionUtil + .getAnnotationFromClass(object.getClass(), + RegistryObjectVersion.class); + if (rov != null) { + val = String.valueOf(rov.value()); + } + // no value set in annotation field, apply version default. + if (val == null) { + // default + val = registryObjectDefaultVersion; + } + version.setUserVersionName(val); + registryObject.setVersionInfo(version); + + // We need the actual payload class, not just it's ID for version comparisons + String clazz = object.getClass().getCanonicalName(); + SlotType classNameSlot = new SlotType(registryObjectClassName, new StringValueType(clazz)); + slots.add(classNameSlot); } // Look through all fields that need to be persisted to the diff --git a/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/encoder/ContentSlotBasedEncoder.java b/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/encoder/ContentSlotBasedEncoder.java index 7739cdd74e..1ff369ba68 100644 --- a/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/encoder/ContentSlotBasedEncoder.java +++ b/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/encoder/ContentSlotBasedEncoder.java @@ -24,10 +24,12 @@ import java.util.List; import oasis.names.tc.ebxml.regrep.xsd.rim.v4.RegistryObjectType; import oasis.names.tc.ebxml.regrep.xsd.rim.v4.SlotType; import oasis.names.tc.ebxml.regrep.xsd.rim.v4.ValueType; +import oasis.names.tc.ebxml.regrep.xsd.rim.v4.VersionInfoType; import org.apache.commons.lang.builder.EqualsBuilder; import org.apache.commons.lang.builder.HashCodeBuilder; +import com.raytheon.uf.common.registry.ebxml.RegistryUtil; import com.raytheon.uf.common.serialization.SerializationException; /** @@ -45,6 +47,7 @@ import com.raytheon.uf.common.serialization.SerializationException; * Sep 07, 2012 1102 djohnson Initial creation * Jun 03, 2013 2038 djohnson Add equals/hashcode. * 12/2/2013 1829 bphillip Changed slot field in ExtensibleObjectType to be List instead of Set + * Dec 04, 2013 2584 dhladky Versioning for registry objects * * * @@ -79,15 +82,18 @@ abstract class ContentSlotBasedEncoder returnedSlots = registryObjectType.getSlot(); + // Figure out which version we have and it's class + VersionInfoType vit = registryObjectType.getVersionInfo(); + String className = registryObjectType.getSlotValue(RegistryUtil.registryObjectClassName); + // Walk the returned slots looking for the "content" slot for (SlotType s : returnedSlots) { if (CONTENT_SLOT.equals(s.getName())) { SLOT_VALUE_TYPE sv = getSlotValueTypeClass().cast( s.getSlotValue()); CONTENT_TYPE content = getContent(sv); - object = decodeContent(content); + object = decodeContent(content, className, vit.getUserVersionName()); break; } } @@ -167,11 +173,13 @@ abstract class ContentSlotBasedEncoder - * - * SOFTWARE HISTORY - * - * Date Ticket# Engineer Description - * ------------ ---------- ----------- -------------------------- - * Sep 07, 2012 1102 djohnson Initial creation - * Jun 03, 2013 2038 djohnson Add equals/hashcode. - * - * - * - * @author djohnson - * @version 1.0 - */ -class DynamicSerializeEncoder extends StringBasedEncoder { - - /** - * @param type - */ - DynamicSerializeEncoder() { - super(DYNAMIC_SERIALIZE); - } - - /** - * {@inheritDoc} - */ - @Override - Object decodeContent(String content) throws SerializationException { - return SerializationUtil.transformFromThrift(Object.class, - Base64.decodeBase64(content)); - } - - /** - * {@inheritDoc} - */ - @Override - String encodeContent(Object objectToEncode) throws SerializationException { - return new String(Base64.encodeBase64(SerializationUtil - .transformToThrift(objectToEncode))); - } -} diff --git a/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/encoder/JaxbEncoder.java b/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/encoder/JaxbEncoder.java index 0b82b45136..16420270e4 100644 --- a/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/encoder/JaxbEncoder.java +++ b/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/encoder/JaxbEncoder.java @@ -23,8 +23,13 @@ import static com.raytheon.uf.common.registry.ebxml.encoder.RegistryEncoders.Typ import javax.xml.bind.JAXBException; +import com.raytheon.uf.common.registry.annotations.RegistryObjectVersion; import com.raytheon.uf.common.registry.schemas.ebxml.util.EbxmlJaxbManager; import com.raytheon.uf.common.serialization.SerializationException; +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.ReflectionUtil; /** * A {@link StringBasedEncoder} implementation that uses JAXB. Package-private @@ -40,6 +45,7 @@ import com.raytheon.uf.common.serialization.SerializationException; * Jun 03, 2013 2038 djohnson Add equals/hashcode. * Oct 31, 2013 2361 njensen Use specific JAXBManager instead of SerializationUtil * Nov 14, 2013 2552 bkowal EbxmlJaxbManager is now accessed via getInstance + * Dec 08, 2013 2584 dhladky Versions for JAXB objects, Only use the JAXb encoder now. * * * @@ -48,7 +54,11 @@ import com.raytheon.uf.common.serialization.SerializationException; */ class JaxbEncoder extends StringBasedEncoder { - + + /** The logger */ + private static final transient IUFStatusHandler statusHandler = UFStatus + .getHandler(JaxbEncoder.class); + /** * @param type */ @@ -60,12 +70,24 @@ class JaxbEncoder extends StringBasedEncoder { * {@inheritDoc} */ @Override - Object decodeContent(String content) throws SerializationException { - try { - return EbxmlJaxbManager.getInstance().getJaxbManager() - .unmarshalFromXml(content); - } catch (JAXBException e) { - throw new SerializationException("Unable to decode the object!", e); + Object decodeContent(String content, String className, String version) + throws SerializationException { + + String classVersion = getClassVersion(className); + + if (classVersion.equals(version)) { + try { + return EbxmlJaxbManager.getInstance().getJaxbManager() + .unmarshalFromXml(content); + } catch (JAXBException e) { + throw new SerializationException( + "Unable to decode the object!", e); + } + } else { + statusHandler.handle(Priority.INFO, + "Mismatching class versions, returning content. " + + className + " version: " + version); + return content; } } @@ -75,10 +97,41 @@ class JaxbEncoder extends StringBasedEncoder { @Override String encodeContent(Object objectToEncode) throws SerializationException { try { + // We always encode using our current version return new String(EbxmlJaxbManager.getInstance().getJaxbManager() .marshalToXml(objectToEncode)); } catch (JAXBException e) { throw new SerializationException("Unable to encode the object!", e); } } + + /** + * Get the version of the class + * + * @param className + * @return version + */ + public String getClassVersion(String className) { + + String version = EbxmlJaxbManager.getInstance().getVersion(className); + + if (version == null) { + + Class clazz = EbxmlJaxbManager.getInstance().getClass(className); + RegistryObjectVersion rov = ReflectionUtil.getAnnotationFromClass( + clazz, RegistryObjectVersion.class); + if (rov != null) { + version = String.valueOf(rov.value()); + EbxmlJaxbManager.getInstance().addVersion(className, version); + } else { + throw new IllegalArgumentException( + "Unable to extract RegistryObjectVersion tag from class! " + + className); + } + } + + return version; + } } + + diff --git a/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/encoder/RegistryEncoders.java b/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/encoder/RegistryEncoders.java index 1a33bc0ddc..9fa8428515 100644 --- a/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/encoder/RegistryEncoders.java +++ b/edexOsgi/com.raytheon.uf.common.registry.ebxml/src/com/raytheon/uf/common/registry/ebxml/encoder/RegistryEncoders.java @@ -33,6 +33,7 @@ import java.util.Collections; * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- * Sep 7, 2012 1102 djohnson Initial creation + * Dec 4, 2013 2584 dhladky Only a JAXB encoder for registry * * * @@ -45,14 +46,7 @@ public final class RegistryEncoders { * An enumeration of valid {@link IRegistryEncoder} types. */ public static enum Type { - /** - * An encoder that uses dynamic serialization. - */ - DYNAMIC_SERIALIZE(new DynamicSerializeEncoder()), - /** - * An encoder that uses JAXB marshalling. - */ JAXB(new JaxbEncoder()); private final IRegistryEncoder encoder; diff --git a/edexOsgi/com.raytheon.uf.common.registry.schemas.ebxml/src/com/raytheon/uf/common/registry/schemas/ebxml/util/EbxmlJaxbManager.java b/edexOsgi/com.raytheon.uf.common.registry.schemas.ebxml/src/com/raytheon/uf/common/registry/schemas/ebxml/util/EbxmlJaxbManager.java index d1bc9c4d14..e83be90f8d 100644 --- a/edexOsgi/com.raytheon.uf.common.registry.schemas.ebxml/src/com/raytheon/uf/common/registry/schemas/ebxml/util/EbxmlJaxbManager.java +++ b/edexOsgi/com.raytheon.uf.common.registry.schemas.ebxml/src/com/raytheon/uf/common/registry/schemas/ebxml/util/EbxmlJaxbManager.java @@ -19,7 +19,9 @@ **/ package com.raytheon.uf.common.registry.schemas.ebxml.util; +import java.util.HashMap; import java.util.HashSet; +import java.util.Map; import java.util.Set; import javax.xml.bind.JAXBException; @@ -34,6 +36,8 @@ import org.reflections.util.ConfigurationBuilder; 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; +import com.raytheon.uf.common.util.ReflectionUtil; /** * A JAXB Manager for transforming EBXML objects to/from XML. @@ -44,11 +48,8 @@ import com.raytheon.uf.common.status.UFStatus; * * Date Ticket# Engineer Description * ------------ ---------- ----------- -------------------------- - * Oct 30, 2013 2361 njensen Initial creation - * Nov 14, 2013 2252 bkowal Added the ability to dynamically inject packages - * that this jaxb implementation should support. - * Eliminated use of System.out. - * + * Nov 12, 2013 ---- njensen Initial release. + * Nov 24, 2013 2584 dhladky versioning * * * @author njensen @@ -61,21 +62,31 @@ public class EbxmlJaxbManager { private static final transient IUFStatusHandler statusHandler = UFStatus .getHandler(EbxmlJaxbManager.class); + private JAXBManager jaxb; + + private Set> jaxables; + + private Map> convertables = new HashMap>(1); + + private Map versions = new HashMap(1); + private static EbxmlJaxbManager instance; - private static JAXBManager jaxb; - - private static Set> jaxables; - + /** + * Get the desired version of the EbxmlJaxbManager + * @param version + * @return + */ public static synchronized EbxmlJaxbManager getInstance() { if (instance == null) { instance = new EbxmlJaxbManager(); } return instance; } - + public String findJaxables(String packageName) { - statusHandler.info("Scanning package ... " + packageName); + + statusHandler.info(" Scanning package ... " + packageName); long t0 = System.currentTimeMillis(); ConfigurationBuilder cb = new ConfigurationBuilder(); @@ -124,4 +135,86 @@ public class EbxmlJaxbManager { statusHandler.info("Initialization Complete."); } + + /** + * Gets the set of classes for this encoder. + * @return + */ + public Set> getJaxables() { + return jaxables; + } + + /** + * Gets the class from the convertables + * + * @param className + * @return + */ + public Class getClass(String className) { + + Class clazz = convertables.get(className); + + if (clazz == null) { + + for (Class pclazz : jaxables) { + if (pclazz.getCanonicalName().equals(className)) { + clazz = pclazz; + addClass(className, clazz); + break; + } + } + // Didn't find it, now we have a possible problem. + // Try reflecting a version of it. + if (clazz == null) { + statusHandler.handle(Priority.WARN, + "Didn't find class in list of jaxables! class: " + + className); + try { + clazz = ReflectionUtil.forName(className); + addClass(className, clazz); + } catch (Exception e) { + statusHandler.handle(Priority.ERROR, + "Can not reflect a version of this class. class: " + + className, e); + } + } + } + + return clazz; + } + + /** + * Set the class to the cache + * + * @param className + * @param clazz + */ + private void addClass(String className, Class clazz) { + synchronized (convertables) { + convertables.put(className, clazz); + } + } + + /** + * Set the version to the cache + * + * @param className + * @param clazz + */ + public void addVersion(String className, String version) { + synchronized (versions) { + versions.put(className, version); + } + } + + /** + * Get the version of the class + * + * @param className + * @return version + */ + public String getVersion(String className) { + return versions.get(className); + } + } \ No newline at end of file diff --git a/edexOsgi/com.raytheon.uf.common.registry.schemas.ebxml/src/com/raytheon/uf/common/registry/schemas/ebxml/util/SerializedType.java b/edexOsgi/com.raytheon.uf.common.registry.schemas.ebxml/src/com/raytheon/uf/common/registry/schemas/ebxml/util/SerializedType.java index 2861a0285a..6f4b1ee287 100644 --- a/edexOsgi/com.raytheon.uf.common.registry.schemas.ebxml/src/com/raytheon/uf/common/registry/schemas/ebxml/util/SerializedType.java +++ b/edexOsgi/com.raytheon.uf.common.registry.schemas.ebxml/src/com/raytheon/uf/common/registry/schemas/ebxml/util/SerializedType.java @@ -43,6 +43,7 @@ import org.hibernate.usertype.UserType; * --/--/---- Initial creation * Oct 31, 2013 2361 njensen Use specific JAXBManager instead of SerializationUtil * Nov 14, 2013 2552 bkowal EbxmlJaxbManager is now accessed via getInstance + * Dec 04, 2013 2584 dhladky Version based EbxmlJaxbManager * * * @@ -93,7 +94,7 @@ public class SerializedType implements UserType { String obj = resultSet.getString(names[0]); if (obj != null) { - try { + try { // We always marshall to current version for to XML conversions return EbxmlJaxbManager.getInstance().getJaxbManager() .unmarshalFromXml(obj); } catch (Exception e) { @@ -110,8 +111,7 @@ public class SerializedType implements UserType { if (value == null) { statement.setString(index, null); } else { - try { - ; + try { // We always marshall to current version for to XML conversions statement.setString(index, EbxmlJaxbManager.getInstance() .getJaxbManager().marshalToXml(value)); } catch (Exception e) { diff --git a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/ReflectionUtil.java b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/ReflectionUtil.java index 96e693721b..e656d16598 100644 --- a/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/ReflectionUtil.java +++ b/edexOsgi/com.raytheon.uf.common.util/src/com/raytheon/uf/common/util/ReflectionUtil.java @@ -42,6 +42,7 @@ import org.apache.commons.beanutils.PropertyUtils; * Jul 10, 2012 455 djohnson Move in methods from RegistryUtil, * fix setter method to use parameter types. * Sep 28, 2012 1195 djohnson Add {@link #forName(String)}. + * Jan 23, 2014 2584 dhladky Versions for JAXB objects. * * * @@ -220,6 +221,26 @@ public final class ReflectionUtil { } return null; } + + /** + * Get this annotation from this class if it exists + * + * @param clazz + * The class to check + * @param annotation + * The annotation class to look for + * @return Annotation + */ + public static T getAnnotationFromClass(Class clazz, + Class annotation) throws ReflectionException { + + T ann = clazz.getAnnotation(annotation); + if (ann != null) { + return ann; + } + + return null; + } /** * Create a class instance from its name. diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/RetrievalGenerator.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/RetrievalGenerator.java index 23b4c4b0c3..7928cd3894 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/RetrievalGenerator.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/RetrievalGenerator.java @@ -22,10 +22,10 @@ package com.raytheon.uf.edex.datadelivery.retrieval; import java.util.List; +import com.raytheon.uf.common.datadelivery.registry.Provider.ServiceType; import com.raytheon.uf.common.datadelivery.registry.AdhocSubscription; import com.raytheon.uf.common.datadelivery.registry.Parameter; import com.raytheon.uf.common.datadelivery.registry.PendingSubscription; -import com.raytheon.uf.common.datadelivery.registry.Provider.ServiceType; import com.raytheon.uf.common.datadelivery.registry.Subscription; import com.raytheon.uf.common.datadelivery.registry.SubscriptionBundle; import com.raytheon.uf.common.datadelivery.retrieval.xml.Retrieval; diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPMetaDataParser.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPMetaDataParser.java index 6e6fefe754..ffec6e323e 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPMetaDataParser.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPMetaDataParser.java @@ -31,6 +31,7 @@ import java.util.TreeSet; import com.raytheon.uf.common.datadelivery.registry.Collection; import com.raytheon.uf.common.datadelivery.registry.DataLevelType; import com.raytheon.uf.common.datadelivery.registry.DataLevelType.LevelType; +import com.raytheon.uf.common.datadelivery.registry.Provider.ServiceType; import com.raytheon.uf.common.datadelivery.registry.DataSet; import com.raytheon.uf.common.datadelivery.registry.DataSetMetaData; import com.raytheon.uf.common.datadelivery.registry.DataType; @@ -43,7 +44,6 @@ import com.raytheon.uf.common.datadelivery.registry.OpenDapGriddedDataSet; import com.raytheon.uf.common.datadelivery.registry.OpenDapGriddedDataSetMetaData; import com.raytheon.uf.common.datadelivery.registry.Parameter; import com.raytheon.uf.common.datadelivery.registry.Provider; -import com.raytheon.uf.common.datadelivery.registry.Provider.ServiceType; import com.raytheon.uf.common.datadelivery.registry.Time; import com.raytheon.uf.common.datadelivery.retrieval.util.HarvesterServiceManager; import com.raytheon.uf.common.datadelivery.retrieval.util.LookupManager; diff --git a/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPRetrievalGenerator.java b/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPRetrievalGenerator.java index b29d773fbd..8b216a8222 100644 --- a/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPRetrievalGenerator.java +++ b/edexOsgi/com.raytheon.uf.edex.datadelivery.retrieval/src/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPRetrievalGenerator.java @@ -38,11 +38,11 @@ import com.raytheon.uf.common.datadelivery.registry.Levels; import com.raytheon.uf.common.datadelivery.registry.OpenDapGriddedDataSet; import com.raytheon.uf.common.datadelivery.registry.Parameter; import com.raytheon.uf.common.datadelivery.registry.Provider; -import com.raytheon.uf.common.datadelivery.registry.Provider.ServiceType; import com.raytheon.uf.common.datadelivery.registry.ProviderType; import com.raytheon.uf.common.datadelivery.registry.Subscription; import com.raytheon.uf.common.datadelivery.registry.SubscriptionBundle; import com.raytheon.uf.common.datadelivery.registry.Time; +import com.raytheon.uf.common.datadelivery.registry.Provider.ServiceType; import com.raytheon.uf.common.datadelivery.registry.handlers.DataDeliveryHandlers; import com.raytheon.uf.common.datadelivery.retrieval.xml.Retrieval; import com.raytheon.uf.common.datadelivery.retrieval.xml.RetrievalAttribute; diff --git a/edexOsgi/com.raytheon.uf.edex.plugin.madis.ogc/src/com/raytheon/uf/edex/plugin/madis/ogc/feature/Madis.java b/edexOsgi/com.raytheon.uf.edex.plugin.madis.ogc/src/com/raytheon/uf/edex/plugin/madis/ogc/feature/Madis.java index 1fb06ec5ab..22d7f79e07 100644 --- a/edexOsgi/com.raytheon.uf.edex.plugin.madis.ogc/src/com/raytheon/uf/edex/plugin/madis/ogc/feature/Madis.java +++ b/edexOsgi/com.raytheon.uf.edex.plugin.madis.ogc/src/com/raytheon/uf/edex/plugin/madis/ogc/feature/Madis.java @@ -21,10 +21,8 @@ package com.raytheon.uf.edex.plugin.madis.ogc.feature; **/ import java.util.Calendar; -import java.util.Date; import java.util.GregorianCalendar; import java.util.List; -import java.util.TimeZone; import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessorType; diff --git a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/dao/DbInit.java b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/dao/DbInit.java index 1f7fcff981..0a47ce8c58 100644 --- a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/dao/DbInit.java +++ b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/dao/DbInit.java @@ -36,6 +36,7 @@ import java.util.Map; import java.util.jar.JarEntry; import java.util.jar.JarFile; +import javax.persistence.Version; import javax.xml.bind.JAXBException; import oasis.names.tc.ebxml.regrep.wsdl.registry.services.v4.LifecycleManager; @@ -91,6 +92,7 @@ import com.raytheon.uf.edex.registry.ebxml.init.RegistryInitializedListener; * Nov 01, 2013 2361 njensen Use EbxmlJaxbManager instead of SerializationUtil * Nov 14, 2013 2552 bkowal EbxmlJaxbManager is now accessed via getInstance * Dec 20, 2013 2636 mpduff Set initialized to true before postInitialized is called. + * Dec 04, 2013 2584 dhladky Version based EbxmlJaxbManager * * * @author bphillip @@ -202,6 +204,7 @@ public class DbInit extends com.raytheon.uf.edex.database.init.DbInit implements * * @throws EbxmlRegistryException */ + @SuppressWarnings("resource") private void executeRegistrySql() throws EbxmlRegistryException { JarFile jar = null; diff --git a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/services/query/adhoc/AdhocQueryExpressionManager.java b/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/services/query/adhoc/AdhocQueryExpressionManager.java deleted file mode 100644 index 1c61b8873f..0000000000 --- a/edexOsgi/com.raytheon.uf.edex.registry.ebxml/src/com/raytheon/uf/edex/registry/ebxml/services/query/adhoc/AdhocQueryExpressionManager.java +++ /dev/null @@ -1,121 +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.registry.ebxml.services.query.adhoc; - -import java.io.File; -import java.util.HashMap; -import java.util.Map; - -import com.raytheon.uf.common.localization.LocalizationFile; -import com.raytheon.uf.common.localization.PathManagerFactory; -import com.raytheon.uf.common.registry.schemas.ebxml.util.EbxmlJaxbManager; -import com.raytheon.uf.common.status.IUFStatusHandler; -import com.raytheon.uf.common.status.UFStatus; - -/** - * - * This class manages the adhoc queries stored under - * edex_static/base/ebxml/adhocQueries - * - *
- * 
- * SOFTWARE HISTORY
- * 
- * Date         Ticket#    Engineer    Description
- * ------------ ---------- ----------- --------------------------
- * Feb 29, 2012            bphillip     Initial creation
- * Nov 14, 2013 2552       bkowal       EbxmlJaxbManager is now accessed via getInstance
- * 
- * 
- * - * @author bphillip - * @version 1.0 - */ -public class AdhocQueryExpressionManager { - - /** The logger */ - private static final transient IUFStatusHandler statusHandler = UFStatus - .getHandler(AdhocQueryExpressionManager.class); - - /** The map of available adhocqueries */ - private Map expressionMap = new HashMap(); - - /** The singleton instance */ - private static AdhocQueryExpressionManager instance; - - /** - * Creates a new manager and initializes the prepared adhoc queries - */ - private AdhocQueryExpressionManager() { - loadQueries(); - } - - /** - * Loads the predefined queries - */ - private void loadQueries() { - LocalizationFile[] files = PathManagerFactory.getPathManager() - .listStaticFiles("ebxml/adhocQueries", new String[] { ".xml" }, - true, true); - File[] fileList = new File[files.length]; - for (int i = 0; i < fileList.length; i++) { - fileList[i] = files[i].getFile(); - } - - for (int i = 0; i < fileList.length; i++) { - - AdhocQueryExpression obj = null; - try { - obj = EbxmlJaxbManager - .getInstance() - .getJaxbManager() - .unmarshalFromXmlFile(AdhocQueryExpression.class, - fileList[i]); - } catch (Exception e) { - statusHandler.error("Error getting predefined adhoc queries.", - e); - } - this.expressionMap.put(obj.getQueryName(), obj); - } - } - - /** - * Gets the singleton instance - * - * @return The singleton instance - */ - public static AdhocQueryExpressionManager getInstance() { - if (instance == null) { - instance = new AdhocQueryExpressionManager(); - } - return instance; - } - - /** - * Retrieves the adhoc query with the given name - * - * @param name - * The name of the adhoc query to get - * @return The adhoc query, null if not present - */ - public AdhocQueryExpression getAdhocQueryExpression(String name) { - return expressionMap.get(name); - } -} diff --git a/tests/manual/com/raytheon/uf/common/comm/HttpProxiedValidClientCredentialsTest.java b/tests/manual/com/raytheon/uf/common/comm/HttpProxiedValidClientCredentialsTest.java index a4ecb9836a..afa38cf84a 100644 --- a/tests/manual/com/raytheon/uf/common/comm/HttpProxiedValidClientCredentialsTest.java +++ b/tests/manual/com/raytheon/uf/common/comm/HttpProxiedValidClientCredentialsTest.java @@ -43,13 +43,13 @@ import com.raytheon.uf.common.datadelivery.registry.Connection; import com.raytheon.uf.common.datadelivery.registry.Coverage; import com.raytheon.uf.common.datadelivery.registry.DataType; import com.raytheon.uf.common.datadelivery.registry.Encryption; +import com.raytheon.uf.common.datadelivery.registry.Provider; import com.raytheon.uf.common.datadelivery.registry.Encryption.Algorithim; import com.raytheon.uf.common.datadelivery.registry.Encryption.Padding; +import com.raytheon.uf.common.datadelivery.registry.Provider.ServiceType; import com.raytheon.uf.common.datadelivery.registry.EnvelopeUtils; import com.raytheon.uf.common.datadelivery.registry.PointTime; import com.raytheon.uf.common.datadelivery.registry.Projection; -import com.raytheon.uf.common.datadelivery.registry.Provider; -import com.raytheon.uf.common.datadelivery.registry.Provider.ServiceType; import com.raytheon.uf.common.datadelivery.registry.ProviderType; import com.raytheon.uf.common.datadelivery.registry.Time; import com.raytheon.uf.common.datadelivery.retrieval.xml.RetrievalAttribute; diff --git a/tests/unit/com/raytheon/uf/common/datadelivery/harvester/config/HarvesterConfigFixture.java b/tests/unit/com/raytheon/uf/common/datadelivery/harvester/config/HarvesterConfigFixture.java index 394ea6c4d1..d29988a95a 100644 --- a/tests/unit/com/raytheon/uf/common/datadelivery/harvester/config/HarvesterConfigFixture.java +++ b/tests/unit/com/raytheon/uf/common/datadelivery/harvester/config/HarvesterConfigFixture.java @@ -28,8 +28,8 @@ import com.raytheon.uf.common.datadelivery.harvester.HarvesterConfig; import com.raytheon.uf.common.datadelivery.registry.Collection; import com.raytheon.uf.common.datadelivery.registry.Connection; import com.raytheon.uf.common.datadelivery.registry.Projection; -import com.raytheon.uf.common.datadelivery.registry.Projection.ProjectionType; import com.raytheon.uf.common.datadelivery.registry.Provider; +import com.raytheon.uf.common.datadelivery.registry.Projection.ProjectionType; import com.raytheon.uf.common.time.util.TimeUtil; import com.raytheon.uf.common.util.AbstractFixture; diff --git a/tests/unit/com/raytheon/uf/common/datadelivery/registry/GriddedDataSetMetaDataTest.java b/tests/unit/com/raytheon/uf/common/datadelivery/registry/GriddedDataSetMetaDataTest.java index a7dc4d1db9..c4cd889ce7 100644 --- a/tests/unit/com/raytheon/uf/common/datadelivery/registry/GriddedDataSetMetaDataTest.java +++ b/tests/unit/com/raytheon/uf/common/datadelivery/registry/GriddedDataSetMetaDataTest.java @@ -23,6 +23,7 @@ import org.junit.Ignore; import org.junit.Test; + /** * Test {@link GriddedDataSetMetaData}. * diff --git a/tests/unit/com/raytheon/uf/common/datadelivery/registry/PendingSharedSubscriptionFixture.java b/tests/unit/com/raytheon/uf/common/datadelivery/registry/PendingSharedSubscriptionFixture.java index 9e81e01196..e646c39ad9 100644 --- a/tests/unit/com/raytheon/uf/common/datadelivery/registry/PendingSharedSubscriptionFixture.java +++ b/tests/unit/com/raytheon/uf/common/datadelivery/registry/PendingSharedSubscriptionFixture.java @@ -21,6 +21,7 @@ package com.raytheon.uf.common.datadelivery.registry; import java.util.Random; + /** * Fixture for {@link PendingSharedSubscription} objects. * diff --git a/tests/unit/com/raytheon/uf/common/datadelivery/registry/PendingSubscriptionTest.java b/tests/unit/com/raytheon/uf/common/datadelivery/registry/PendingSubscriptionTest.java index a89e719e61..4983b4cfd0 100644 --- a/tests/unit/com/raytheon/uf/common/datadelivery/registry/PendingSubscriptionTest.java +++ b/tests/unit/com/raytheon/uf/common/datadelivery/registry/PendingSubscriptionTest.java @@ -23,6 +23,7 @@ import static org.junit.Assert.assertEquals; import org.junit.Test; + /** * Test {@link PendingSubscription}. * diff --git a/tests/unit/com/raytheon/uf/common/datadelivery/registry/SharedSubscriptionFixture.java b/tests/unit/com/raytheon/uf/common/datadelivery/registry/SharedSubscriptionFixture.java index d39a13f29e..7e8b5954ec 100644 --- a/tests/unit/com/raytheon/uf/common/datadelivery/registry/SharedSubscriptionFixture.java +++ b/tests/unit/com/raytheon/uf/common/datadelivery/registry/SharedSubscriptionFixture.java @@ -20,6 +20,7 @@ package com.raytheon.uf.common.datadelivery.registry; + /** * Fixture for {@link SharedSubscription} objects. * diff --git a/tests/unit/com/raytheon/uf/common/datadelivery/registry/ebxml/DataSetWithFiltersQueryTest.java b/tests/unit/com/raytheon/uf/common/datadelivery/registry/ebxml/DataSetWithFiltersQueryTest.java index e86ad7a532..ae32324151 100644 --- a/tests/unit/com/raytheon/uf/common/datadelivery/registry/ebxml/DataSetWithFiltersQueryTest.java +++ b/tests/unit/com/raytheon/uf/common/datadelivery/registry/ebxml/DataSetWithFiltersQueryTest.java @@ -29,11 +29,11 @@ import org.geotools.geometry.jts.ReferencedEnvelope; import org.junit.Test; import com.raytheon.uf.common.datadelivery.registry.DataLevelType; -import com.raytheon.uf.common.datadelivery.registry.DataLevelType.LevelType; import com.raytheon.uf.common.datadelivery.registry.DataSet; -import com.raytheon.uf.common.datadelivery.registry.GriddedCoverage; import com.raytheon.uf.common.datadelivery.registry.OpenDapGriddedDataSet; import com.raytheon.uf.common.datadelivery.registry.Parameter; +import com.raytheon.uf.common.datadelivery.registry.DataLevelType.LevelType; +import com.raytheon.uf.common.datadelivery.registry.GriddedCoverage; import com.raytheon.uf.common.geospatial.MapUtil; import com.raytheon.uf.common.gridcoverage.Corner; import com.raytheon.uf.common.gridcoverage.LatLonGridCoverage; diff --git a/tests/unit/com/raytheon/uf/common/datadelivery/registry/handlers/MemoryDataSetHandler.java b/tests/unit/com/raytheon/uf/common/datadelivery/registry/handlers/MemoryDataSetHandler.java index 766e04e140..f660abc1d9 100644 --- a/tests/unit/com/raytheon/uf/common/datadelivery/registry/handlers/MemoryDataSetHandler.java +++ b/tests/unit/com/raytheon/uf/common/datadelivery/registry/handlers/MemoryDataSetHandler.java @@ -25,8 +25,8 @@ import java.util.Set; import org.geotools.geometry.jts.ReferencedEnvelope; -import com.raytheon.uf.common.datadelivery.registry.DataLevelType.LevelType; import com.raytheon.uf.common.datadelivery.registry.DataSet; +import com.raytheon.uf.common.datadelivery.registry.DataLevelType.LevelType; import com.raytheon.uf.common.datadelivery.registry.ebxml.DataSetWithFiltersQuery; import com.raytheon.uf.common.registry.handler.RegistryHandlerException; diff --git a/tests/unit/com/raytheon/uf/common/registry/ebxml/FactoryRegistryHandlerTest.java b/tests/unit/com/raytheon/uf/common/registry/ebxml/FactoryRegistryHandlerTest.java index 0365b3a650..09d977ac3f 100644 --- a/tests/unit/com/raytheon/uf/common/registry/ebxml/FactoryRegistryHandlerTest.java +++ b/tests/unit/com/raytheon/uf/common/registry/ebxml/FactoryRegistryHandlerTest.java @@ -79,7 +79,7 @@ public class FactoryRegistryHandlerTest { RegistryErrorMessage.DATABASE_ERROR_MESSAGE); private static final IRegistryEncoder encoderStrategy = RegistryEncoders - .ofType(Type.DYNAMIC_SERIALIZE); + .ofType(Type.JAXB); private static final FactoryRegistryHandler registryHandler = new FactoryRegistryHandler(); diff --git a/tests/unit/com/raytheon/uf/common/registry/ebxml/RegistryUtilTest.java b/tests/unit/com/raytheon/uf/common/registry/ebxml/RegistryUtilTest.java index d6f8023e5c..3266d32201 100644 --- a/tests/unit/com/raytheon/uf/common/registry/ebxml/RegistryUtilTest.java +++ b/tests/unit/com/raytheon/uf/common/registry/ebxml/RegistryUtilTest.java @@ -62,7 +62,7 @@ public class RegistryUtilTest { RegistryObjectType type = RegistryUtil .newRegistryObject(registryObject, - RegistryEncoders.ofType(Type.DYNAMIC_SERIALIZE)); + RegistryEncoders.ofType(Type.JAXB)); SlotType slotToCheck = null; for (SlotType slot : type.getSlot()) { diff --git a/tests/unit/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPMetaDataParserNCOMTest.java b/tests/unit/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPMetaDataParserNCOMTest.java index d10c149321..f33c9c05cd 100644 --- a/tests/unit/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPMetaDataParserNCOMTest.java +++ b/tests/unit/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPMetaDataParserNCOMTest.java @@ -41,8 +41,8 @@ import com.raytheon.uf.common.datadelivery.registry.DataType; import com.raytheon.uf.common.datadelivery.registry.OpenDapGriddedDataSet; import com.raytheon.uf.common.datadelivery.registry.Parameter; import com.raytheon.uf.common.datadelivery.registry.Projection; -import com.raytheon.uf.common.datadelivery.registry.Projection.ProjectionType; import com.raytheon.uf.common.datadelivery.registry.Provider; +import com.raytheon.uf.common.datadelivery.registry.Projection.ProjectionType; import com.raytheon.uf.common.datadelivery.registry.Provider.ServiceType; import com.raytheon.uf.common.gridcoverage.LatLonGridCoverage; import com.raytheon.uf.common.localization.PathManagerFactoryTest; diff --git a/tests/unit/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPMetaDataParserRAPTest.java b/tests/unit/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPMetaDataParserRAPTest.java index ff97e807f7..d6c2831407 100644 --- a/tests/unit/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPMetaDataParserRAPTest.java +++ b/tests/unit/com/raytheon/uf/edex/datadelivery/retrieval/opendap/OpenDAPMetaDataParserRAPTest.java @@ -42,8 +42,8 @@ import com.raytheon.uf.common.datadelivery.registry.DataType; import com.raytheon.uf.common.datadelivery.registry.OpenDapGriddedDataSet; import com.raytheon.uf.common.datadelivery.registry.Parameter; import com.raytheon.uf.common.datadelivery.registry.Projection; -import com.raytheon.uf.common.datadelivery.registry.Projection.ProjectionType; import com.raytheon.uf.common.datadelivery.registry.Provider; +import com.raytheon.uf.common.datadelivery.registry.Projection.ProjectionType; import com.raytheon.uf.common.datadelivery.registry.Provider.ServiceType; import com.raytheon.uf.common.gridcoverage.LatLonGridCoverage; import com.raytheon.uf.common.localization.PathManagerFactoryTest; diff --git a/tests/unit/com/raytheon/uf/viz/datadelivery/subscription/xml/RuleXMLTest.java b/tests/unit/com/raytheon/uf/viz/datadelivery/subscription/xml/RuleXMLTest.java index 83631c5501..69907afd65 100644 --- a/tests/unit/com/raytheon/uf/viz/datadelivery/subscription/xml/RuleXMLTest.java +++ b/tests/unit/com/raytheon/uf/viz/datadelivery/subscription/xml/RuleXMLTest.java @@ -29,8 +29,8 @@ import org.junit.Before; import org.junit.Test; import com.raytheon.uf.common.datadelivery.registry.DataType; -import com.raytheon.uf.common.datadelivery.registry.Subscription; import com.raytheon.uf.common.datadelivery.registry.SiteSubscription; +import com.raytheon.uf.common.datadelivery.registry.Subscription; import com.raytheon.uf.common.units.DataSizeUnit; import com.raytheon.uf.viz.datadelivery.system.CreateEditRuleDlg.FreqUnitOptions; import com.raytheon.uf.viz.datadelivery.system.Operator;