Issue #1802 Refactored DD transaction management

Change-Id: Idec6238188f29f51f3738d2e40f95d6c562cfe39

Former-commit-id: 534777d96a45b275abd9cc26818b7df200974595
This commit is contained in:
Benjamin Phillippe 2013-03-18 11:49:17 -05:00
parent 1b7e9e41ce
commit b10b1150be
193 changed files with 7623 additions and 3376 deletions

View file

@ -1,5 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry exported="true" kind="lib" path="camel-servlet-2.4.0.jar"/>
<classpathentry exported="true" kind="lib" path="camel-jms-2.4.0.jar" sourcepath="apache-camel-2.4.0-src.zip"/>
<classpathentry exported="true" kind="lib" path="camel-atom-2.4.0.jar" sourcepath="apache-camel-2.4.0-src.zip"/>
<classpathentry exported="true" kind="lib" path="camel-bam-2.4.0.jar" sourcepath="apache-camel-2.4.0-src.zip"/>

View file

@ -12,8 +12,7 @@ Bundle-ClassPath: .,
camel-groovy-2.4.0.jar,
camel-http-2.4.0.jar,
camel-jetty-2.4.0.jar,
camel-jms-2.4.0.jar
camel-jpa-2.4.0.jar,
camel-jms-2.4.0.jarcamel-jpa-2.4.0.jar,
camel-jxpath-2.4.0.jar,
camel-mina-2.4.0.jar,
camel-msv-2.4.0.jar,
@ -27,7 +26,8 @@ Bundle-ClassPath: .,
camel-stringtemplate-2.4.0.jar,
camel-velocity-2.4.0.jar,
camel-xmpp-2.4.0.jar,
camel-xstream-2.4.0.jar
camel-xstream-2.4.0.jar,
camel-servlet-2.4.0.jar
Export-Package: org.apache.camel,
org.apache.camel.bam,
org.apache.camel.bam.model,
@ -60,6 +60,7 @@ Export-Package: org.apache.camel,
org.apache.camel.component.ref,
org.apache.camel.component.rmi,
org.apache.camel.component.seda,
org.apache.camel.component.servlet,
org.apache.camel.component.stream,
org.apache.camel.component.stringtemplate,
org.apache.camel.component.test,

View file

@ -22,4 +22,5 @@ bin.includes = META-INF/,\
camel-velocity-2.4.0.jar,\
camel-xmpp-2.4.0.jar,\
camel-xstream-2.4.0.jar,\
camel-jms-2.4.0.jar
camel-jms-2.4.0.jar,\
camel-servlet-2.4.0.jar

Binary file not shown.

View file

@ -1,5 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry exported="true" kind="lib" path="spring-web.jar"/>
<classpathentry exported="true" kind="lib" path="com.springsource.org.aopalliance-1.0.0.jar" sourcepath="spring-framework-2.5.6.zip"/>
<classpathentry exported="true" kind="lib" path="antlr-2.7.6.jar" sourcepath="spring-framework-2.5.6.zip"/>
<classpathentry kind="lib" path="backport-util-concurrent.jar" sourcepath="spring-framework-2.5.6.zip"/>

View file

@ -17,6 +17,7 @@ Bundle-ClassPath: antlr-2.7.6.jar,
spring-jms.jar,
spring-orm.jar,
spring-tx.jar,
spring-web.jar,
.
Export-Package: org.aopalliance.aop,
org.aopalliance.intercept,
@ -212,5 +213,13 @@ Export-Package: org.aopalliance.aop,
org.springframework.util.comparator,
org.springframework.util.xml,
org.springframework.validation,
org.springframework.validation.support
org.springframework.validation.support,
org.springframework.web,
org.springframework.web.context,
org.springframework.web.context.request,
org.springframework.web.context.support,
org.springframework.web.filter,
org.springframework.web.jsf,
org.springframework.web.jsf.el,
org.springframework.web.util
Require-Bundle: org.apache.commons.logging;bundle-version="1.1.1"

View file

@ -12,4 +12,5 @@ bin.includes = META-INF/,\
spring-jms.jar,\
spring-orm.jar,\
spring-tx.jar,\
com.springsource.org.aopalliance-1.0.0.jar
com.springsource.org.aopalliance-1.0.0.jar,\
spring-web.jar

Binary file not shown.

View file

@ -0,0 +1,127 @@
#!/bin/bash
DUMP_FILE="/tmp/dump.sql"
SCHEMA_DEFINITION_SCRIPT="ebxmlSchemaDefinition.sql"
TABLE_NAME_UPDATE_SCRIPT="tableNameUpdate.sql"
# ensure that the schema definition script is present
if [ ! -f ${SCHEMA_DEFINITION_SCRIPT} ]; then
echo "ERROR: the required sql script - ${SCHEMA_DEFINITION_SCRIPT} was not found."
echo "FATAL: the update has failed!"
exit 1
fi
# ensure that the table name update script is present
if [ ! -f ${TABLE_NAME_UPDATE_SCRIPT} ]; then
echo "ERROR: the required sql script - ${TABLE_NAME_UPDATE_SCRIPT} was not found."
echo "FATAL: the update has failed!"
exit 1
fi
echo -n "Modifying table names to conform to new schema..."
psql -U awips -d ebxml -f $TABLE_NAME_UPDATE_SCRIPT > /dev/null
echo "Done!"
echo -n "Dumping existing ebxml database contents..."
pg_dump --port 5432 --username "awips" --role "awips" --no-password --format plain --data-only --inserts --column-inserts --file $DUMP_FILE "ebxml"
if [ $? -ne 0 ]; then
echo "FATAL: Failed to dump existing database contents!"
echo "FATAL: the update has failed!"
exit 1
fi
echo "Done!"
echo -n "Setting search path in dump file to be ebxml..."
sed -i 's/SET search_path =.*/SET search_path TO ebxml, pg_catalog;/g' $DUMP_FILE
if [ $? -ne 0 ]; then
echo "FATAL: Failed to reset search path in dump file!"
echo "FATAL: the update has failed!"
exit 1
fi
echo "Done!"
echo -n "Removing references to versioninfo table..."
sed -i "s/INSERT INTO versioninfo/--INSERT INTO versioninfo/g" $DUMP_FILE
if [ $? -ne 0 ]; then
echo "FATAL: Removing references to versioninfo table has failed!"
echo "FATAL: the update has failed!"
exit 1
fi
echo "Done!"
echo -n "Updating column names for version info columns..."
sed -i "s/versioninfo_versionname/versionname/g" $DUMP_FILE
if [ $? -ne 0 ]; then
echo "FATAL: Updating version info column names has failed!"
echo "FATAL: the update has failed!"
exit 1
fi
sed -i "s/versioninfo_userversionname/userversionname/g" $DUMP_FILE
if [ $? -ne 0 ]; then
echo "FATAL: Updating version info column names has failed!"
echo "FATAL: the update has failed!"
exit 1
fi
echo "Done!"
#Redirect standard out to null, but keep standard error for the following psql commands
echo -n "Adding tables to ebxml schema..."
psql -U awips -d metadata -f $SCHEMA_DEFINITION_SCRIPT > /dev/null
if [ $? -ne 0 ]; then
echo "FATAL: Exporting new ebxml schema has failed!"
echo "FATAL: the update has failed!"
exit 1
fi
echo "Done!"
echo -n "Getting current hibernate_sequence value to update new sequences..."
sequenceValue=$(psql -t -U awips -d ebxml -c "SELECT nextval('hibernate_sequence');")
echo "Done!"
echo "Current hibernate_sequence value is: $sequenceValue"
for seq in 'action' 'deliveryinfo' 'emailaddress' 'internationalstring' 'localizedstring' 'map' 'objectreflist' 'parameter' 'postaladdress' 'queryexpression' 'registryobjectlist' 'simplelink' 'slot' 'telephonenumber' 'value'
do
echo -n "Updating sequence ebxml.${seq}_sequence with value $sequenceValue to avoid key violations.."
psql -U awips -d metadata -c "SELECT pg_catalog.setval('ebxml.${seq}_sequence', $sequenceValue, true);" > /dev/null
if [ $? -ne 0 ]; then
echo "FATAL: Updating sequence ${seq} has failed!"
echo "FATAL: The update has failed!"
exit 1
fi
echo "Done!"
done
echo -n "Removing references to hibernate_sequence..."
sed -i "s/SELECT pg_catalog.setval('hibernate_sequence'/--SELECT pg_catalog.setval('hibernate_sequence'/g" $DUMP_FILE
if [ $? -ne 0 ]; then
echo "FATAL: Removal of references to hibernate_sequence has failed!"
echo "FATAL: the update has failed!"
exit 1
fi
echo "Done!"
echo -n "Populating ebxml schema with existing database contents..."
psql -U awips -d metadata -f $DUMP_FILE > /dev/null
if [ $? -ne 0 ]; then
echo "FATAL: Populating ebxml schema with existing data has failed!"
echo "FATAL: the update has failed!"
exit 1
fi
echo "Done!"
echo -n "Removing dump file: $DUMP_FILE..."
rm -f $DUMP_FILE
if [ $? -ne 0 ]; then
echo "Warn: File $DUMP_FILE has not been removed. Clean up manually. Update still successful."
else
echo "Done!"
fi
echo "Ebxml database schema update successful!"
exit 0

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,13 @@
ALTER TABLE localizedstrings RENAME TO localizedstring;
ALTER TABLE intlstring RENAME TO internationalstring;
ALTER TABLE intlstring_localizedstrings RENAME TO internationalstring_localizedstring;
ALTER TABLE internationalstring_localizedstring RENAME COLUMN intlstring_key TO internationalstring_key;
ALTER TABLE serviceinterfacetype RENAME TO serviceinterface;
ALTER TABLE stringqueryexpressiontype RENAME TO stringqueryexpression;
ALTER TABLE vocabularytermtype RENAME TO vocabularyterm;
ALTER TABLE xmlqueryexpressiontype RENAME TO xmlqueryexpression;
ALTER TABLE queryexpressiontype RENAME TO queryexpression;
ALTER TABLE queryexpressiontype_slot RENAME TO queryexpression_slot;
ALTER TABLE maptype RENAME TO map;
ALTER TABLE entrytype RENAME TO entry;
ALTER TABLE maptype_entrytype RENAME TO map_entry;

View file

@ -1,79 +0,0 @@
<?xml version='1.0' encoding='utf-8'?>
<!DOCTYPE hibernate-configuration PUBLIC
"-//Hibernate/Hibernate Configuration DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
<!--
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.
-->
<hibernate-configuration>
<session-factory>
<!-- JDBC Properties -->
<property name="connection.driver_class">
org.postgresql.Driver
</property>
<property name="dialect">
org.hibernate.dialect.PostgreSQLDialect
</property>
<property name="connection.url">
jdbc:postgresql://${db.addr}:${db.port}/ebxml
</property>
<property name="connection.username">awips</property>
<property name="connection.password">awips</property>
<property name="connection.release_mode">
after_transaction
</property>
<property name="jdbc.batch_size">100</property>
<!-- Optional Hibernate Configuration Properties -->
<!-- Write all SQL statements to console -->
<property name="hibernate.show_sql">false</property>
<!-- Pretty print the SQL in the log and console -->
<property name="hibenate.format_sql">false</property>
<!-- If turned on, Hibernate will generate comments inside the SQL, for easier debugging, defaults to false -->
<property name="hibernate.use_sql_comments">false</property>
<!-- Use c3p0 connection pooling -->
<property name="hibernate.connection.provider_class">org.hibernate.connection.C3P0ConnectionProvider</property>
<!-- c3p0 Connection Pool Properties -->
<!-- Additional properties may be added to c3p0.properties -->
<property name="hibernate.c3p0.idle_test_period">60</property>
<property name="hibernate.c3p0.timeout">1800</property>
<property name="hibernate.c3p0.max_statements">10</property>
<property name="hibernate.c3p0.acquire_increment">5</property>
<property name="hibernate.c3p0.min_size">${db.metadata.pool.min}</property>
<property name="hibernate.c3p0.max_size">${db.metadata.pool.max}</property>
<property name="hibernate.generate_statistics">true</property>
<property name="hibernate.transaction.factory_class">org.hibernate.transaction.JDBCTransactionFactory</property>
<property name="hibernate.current_session_context_class">thread</property>
<property name="net.sf.ehcache.configurationResourceName">ebxmlRegistryCache.xml</property>
<property name="hibernate.cache.provider_class">net.sf.ehcache.hibernate.EhCacheProvider</property>
<property name="hibernate.cache.use_second_level_cache">true</property>
<property name="hibernate.cache.use_query_cache">true</property>
<property name="hibernate.cache.jbc.query.localonly">true</property>
</session-factory>
</hibernate-configuration>

View file

@ -67,7 +67,7 @@
<property name="hibernate.c3p0.max_size">${db.metadata.pool.max}</property>
<property name="hibernate.generate_statistics">false</property>
<property name="hibernate.transaction.factory_class">org.hibernate.transaction.JDBCTransactionFactory</property>
<property name="hibernate.cache.use_second_level_cache">false</property>
<property name="hibernate.jdbc.use_streams_for_binary">false</property>
<property name="cache.use_query_cache">false</property>

View file

@ -18,8 +18,4 @@
* further licensing information.
**/
\set ON_ERROR_STOP 1
DROP DATABASE IF EXISTS ebxml;
DROP TABLESPACE IF EXISTS ebxml_data;
CREATE TABLESPACE ebxml_data OWNER awips LOCATION '%{database_files_home}%/ebxml';
COMMENT ON TABLESPACE ebxml_data IS 'EBXML Registry Database tablespace';
CREATE DATABASE ebxml OWNER awips TABLESPACE ebxml_data;
CREATE SCHEMA ebxml AUTHORIZATION awips;

View file

@ -13,6 +13,7 @@ import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlRootElement;
import com.raytheon.uf.common.dataplugin.persist.IPersistableDataObject;
import com.raytheon.uf.common.serialization.ISerializableObject;
import com.raytheon.uf.common.serialization.annotations.DynamicSerialize;
import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@ -28,6 +29,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* Mar 1, 2012 jsanchez Initial creation
* 3/18/2012 1802 bphillip Modified to implement IPersistableDataObject
*
* </pre>
*
@ -39,7 +41,8 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlRootElement
@XmlAccessorType(XmlAccessType.NONE)
@DynamicSerialize
public class NotificationRecord implements ISerializableObject {
public class NotificationRecord implements ISerializableObject,
IPersistableDataObject<Integer> {
@GeneratedValue(strategy = GenerationType.AUTO)
@Id
@ -119,4 +122,9 @@ public class NotificationRecord implements ISerializableObject {
this.message = message;
}
@Override
public Integer getIdentifier() {
return this.id;
}
}

View file

@ -21,5 +21,7 @@ Require-Bundle: org.apache.commons.codec;bundle-version="1.4.0",
com.raytheon.uf.common.status;bundle-version="1.12.1174",
com.raytheon.uf.common.comm;bundle-version="1.12.1174",
com.raytheon.uf.common.time;bundle-version="1.12.1174",
org.apache.http;bundle-version="4.1.2"
org.apache.http;bundle-version="4.1.2",
com.raytheon.uf.common.dataplugin;bundle-version="1.12.1174",
org.springframework;bundle-version="2.5.6"
Import-Package: com.vividsolutions.jts.geom

View file

@ -32,8 +32,10 @@ import oasis.names.tc.ebxml.regrep.xsd.rs.v4.RegistryExceptionType;
import oasis.names.tc.ebxml.regrep.xsd.rs.v4.RegistryResponseType;
import oasis.names.tc.ebxml.regrep.xsd.rs.v4.UnresolvedReferenceExceptionType;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import com.google.common.annotations.VisibleForTesting;
import com.raytheon.uf.common.comm.CommunicationException;
import com.raytheon.uf.common.registry.IMultipleResultFormatter;
import com.raytheon.uf.common.registry.IResultFormatter;
import com.raytheon.uf.common.registry.OperationStatus;
@ -68,11 +70,14 @@ import com.raytheon.uf.common.util.ReflectionException;
* Aug 27, 2012 0743 djohnson Add handling for AssociationQuery objects.
* Sep 14, 2012 1169 djohnson Add use of create only mode.
* Feb 26, 2013 1643 djohnson Remove registry manager debug toggle.
* 3/18/2013 1802 bphillip Implemented transaction boundaries
*
* </pre>
*
* @author djohnson
*/
@Service
@Transactional
public class FactoryRegistryHandler implements RegistryHandler {
@VisibleForTesting
@ -103,8 +108,6 @@ public class FactoryRegistryHandler implements RegistryHandler {
private QueryManagerFactory queryManagerFactory;
private RegistryTxManager registryTxManager;
/**
* Private constructor to disallow instance creation.
*/
@ -145,18 +148,6 @@ public class FactoryRegistryHandler implements RegistryHandler {
return queryManagerFactory;
}
/**
* Getter method for the RegistryTxManager attribute. This attribute will be
* set using Spring dependency injection based on where the RegistryManager
* is called from.
*
* @return The RegistryTxManager to use for this instance of
* RegistryManager.
*/
public RegistryTxManager getRegistryTxManager() {
return registryTxManager;
}
/**
* Setter method for the LifecycleManagerFactory attribute. This attribute
* will be set using Spring dependency injection based on where the
@ -183,19 +174,6 @@ public class FactoryRegistryHandler implements RegistryHandler {
this.queryManagerFactory = queryManagerFactory;
}
/**
* Setter method for the RegistryTxManager attribute. This attribute will be
* set using Spring dependency injection based on where the RegistryManager
* is called from.
*
* @param registryTxManager
* The RegistryTxManager implementation to use for this instance
* of RegistryManager.
*/
public void setTxManager(RegistryTxManager registryTxManager) {
this.registryTxManager = registryTxManager;
}
private List<RegistryObjectType> getAssociations(QueryManager qm,
String sourceObjectId, String targetObjectId, String associationType)
throws MsgRegistryException {
@ -287,26 +265,21 @@ public class FactoryRegistryHandler implements RegistryHandler {
* @return the response
*/
private <T extends RegistryResponse<U>, U> T processRequest(
Callable<T> request,
T response) {
TxManager tx = registryTxManager.getTxManager();
Callable<T> request, T response) {
T calledResponse = null;
try {
tx.startTransaction();
T calledResponse = request.call();
calledResponse = request.call();
calledResponse.setStatus(OperationStatus.SUCCESS);
return calledResponse;
} catch (WebServiceException e) {
return RegistryUtil.getFailedResponse(response,
calledResponse = RegistryUtil.getFailedResponse(response,
new RegistryException(
RegistryUtil.UNABLE_TO_CONNECT_TO_REGISTRY, e));
} catch (CommunicationException e) {
return RegistryUtil.getFailedResponse(response, e);
} catch (Exception e) {
calledResponse = RegistryUtil.getFailedResponse(response, e);
} catch (Throwable e) {
return RegistryUtil.getFailedResponse(response, e);
} finally {
tx.closeTransaction();
calledResponse = RegistryUtil.getFailedResponse(response, e);
}
return calledResponse;
}
/**
@ -328,8 +301,7 @@ public class FactoryRegistryHandler implements RegistryHandler {
* @see RegistryManager.getRegistyObjects()
*/
private <T> List<T> getObjects(QueryManager qm,
RegistryQuery<T> registryQuery)
throws MsgRegistryException {
RegistryQuery<T> registryQuery) throws MsgRegistryException {
ITimer timer = TimeUtil.getTimer();
timer.start();
@ -350,8 +322,7 @@ public class FactoryRegistryHandler implements RegistryHandler {
timer.stop();
long totalElapsedTime = timer.getElapsedTime();
if (debugLog) {
statusHandler.debug(totalElapsedTime
+ " ms for entire query ["
statusHandler.debug(totalElapsedTime + " ms for entire query ["
+ registryQuery.getClass().getSimpleName() + "]: "
+ registryObjects.size() + " items returned");
}
@ -721,8 +692,7 @@ public class FactoryRegistryHandler implements RegistryHandler {
*/
@SuppressWarnings("unchecked")
private <T> List<T> store(LifecycleManager lcm, QueryManager qm, T object,
Mode mode)
throws MsgRegistryException, JAXBException,
Mode mode) throws MsgRegistryException, JAXBException,
IllegalArgumentException, ReflectionException,
SerializationException {
List<T> storedObjects = new ArrayList<T>();
@ -923,8 +893,7 @@ public class FactoryRegistryHandler implements RegistryHandler {
* everytime
*/
private static void throwUnsuccessfulResponseException(
final RegistryResponseType response)
throws MsgRegistryException {
final RegistryResponseType response) throws MsgRegistryException {
List<RegistryExceptionType> exceptions = response.getException();
if (exceptions.isEmpty()) {
throw new MsgRegistryException(

View file

@ -1,36 +0,0 @@
package com.raytheon.uf.common.registry.ebxml;
import com.raytheon.uf.common.registry.RegistryManager;
/**
*
* Factory interface used by RegistryManager to obtains a particular client
* implementation for the registry's transaction management services.
*
* <pre>
*
* SOFTWARE HISTORY
*
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* Mar 28, 2012 jspinks Initial creation
*
* </pre>
*
* @author jspinks
* @version 1.0
*
* @see RegistryManager
*/
public interface RegistryTxManager {
/**
* Get a client implementation of the registry's transaction services.
*
* @return An implementation of TxManager.
*
* @see TxManager
*/
TxManager getTxManager();
}

View file

@ -184,8 +184,7 @@ public final class RegistryUtil {
private static final Map<String, SlotConverter> SLOT_CONVERSION;
static {
Map<String, SlotConverter> map = new HashMap<String, SlotConverter>(
11);
Map<String, SlotConverter> map = new HashMap<String, SlotConverter>(11);
// Load the SLOT_CONVERTER map, have to use the String equivalent of the
// key since Class is not comparable... (which keys have to be).
map.put(Long.class.getName(), IntegerSlotConverter.INSTANCE);
@ -454,10 +453,11 @@ public final class RegistryUtil {
RegistryObject ro = c.getAnnotation(RegistryObject.class);
// Use the specified object type name or the current class name as the Object type if not specified.
// Use the specified object type name or the current class name
// as the Object type if not specified.
Class<?> objectType = ro.objectType();
registryObjectType = (Object.class == objectType) ? c
.getName() : objectType.getName();
registryObjectType = (Object.class == objectType) ? c.getName()
: objectType.getName();
if (ro.storeContent()) {
// Store the Base64 encoded Object in a slot called
@ -784,8 +784,7 @@ public final class RegistryUtil {
* @return the response
*/
public static <R extends RegistryResponse<S>, S> R getFailedResponse(
R response,
CommunicationException e) {
R response, CommunicationException e) {
String message = e.getMessage();
String errorMessage = (message
.indexOf(RegistryUtil.DATABASE_ERROR_MESSAGE) != -1) ? RegistryUtil.FAILED_TO_CONNECT_TO_DATABASE

View file

@ -10,7 +10,6 @@ import oasis.names.tc.ebxml.regrep.wsdl.registry.services.v4.LifecycleManagerSOA
import oasis.names.tc.ebxml.regrep.wsdl.registry.services.v4.QueryManager;
import oasis.names.tc.ebxml.regrep.wsdl.registry.services.v4.QueryManagerSOAPService;
/**
*
* A SOAP client implementation for use with the RegistryManager Class.
@ -30,7 +29,7 @@ import oasis.names.tc.ebxml.regrep.wsdl.registry.services.v4.QueryManagerSOAPSer
* @version 1.0
*/
public abstract class SOAPRegistryManager implements LifecycleManagerFactory,
QueryManagerFactory, RegistryTxManager {
QueryManagerFactory {
private static QName queryServiceName = new QName(
"urn:oasis:names:tc:ebxml-regrep:wsdl:registry:interfaces:4.0",
@ -72,21 +71,8 @@ public abstract class SOAPRegistryManager implements LifecycleManagerFactory,
}
/**
* Get an implementation of TxManager to manage transactions
* with the registry.
*
* @return A implementation of TxManager.
*
* @see RegisryTxManager
*/
@Override
public TxManager getTxManager() {
return this.new NoTxManager();
}
/**
* Get an implementation of QueryManager that uses SOAP to submit
* requests to the registry.
* Get an implementation of QueryManager that uses SOAP to submit requests
* to the registry.
*
* @return A SOAP implementation of QueryManager.
*
@ -108,32 +94,6 @@ public abstract class SOAPRegistryManager implements LifecycleManagerFactory,
return a;
}
/**
* Inner class to implement the TxManager interface. The transaction
* management for the SOAP client is handled by the webservice itself,
* so no additional transaction management is required. As such, this
* NoTxManager implementation simply fulfills the RegistryManager
* requirement that a TxManager be specified.
*/
public class NoTxManager implements TxManager {
/**
* Empty method since no additional transaction management
* with the registry is required.
*/
@Override
public void startTransaction() {
}
/**
* Empty method since no additional transaction management
* with the registry is required.
*/
@Override
public void closeTransaction() {
}
}
/**
* Retrieve the url to the query manager service.
*

View file

@ -1,44 +0,0 @@
package com.raytheon.uf.common.registry.ebxml;
import com.raytheon.uf.common.registry.RegistryManager;
import oasis.names.tc.ebxml.regrep.wsdl.registry.services.v4.QueryManager;
/**
* Interface for controlling the transaction management of the
* RegistryManager Class. RegistryManager will call methods on
* this interface to control transactions with the registry services
* provided by LifecycleManager and QueryManager clients.
*
* <pre>
*
* SOFTWARE HISTORY
*
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* Mar 28, 2012 jspinks Initial creation
*
* </pre>
*
* @author jspinks
* @version 1.0
*
* @see LifecycleManager
* @see QueryManager
* @see RegistryManager
* @see RegistryTxManager
*/
public interface TxManager {
/**
* Start a transaction with the registry.
*
* @throws Exception
*/
public void startTransaction() throws Exception;
/**
* Close a transaction with the registry.
*/
public void closeTransaction();
}

View file

@ -24,6 +24,8 @@ import java.util.Arrays;
import java.util.Collection;
import java.util.List;
import org.springframework.transaction.annotation.Transactional;
import com.raytheon.uf.common.registry.OperationStatus;
import com.raytheon.uf.common.registry.RegistryManager;
import com.raytheon.uf.common.registry.RegistryQueryResponse;
@ -51,12 +53,13 @@ import com.raytheon.uf.common.util.CollectionUtil;
* Sep 17, 2012 1169 djohnson Initial creation
* Sep 21, 2012 1187 djohnson Add bulk delete operations.
* Oct 05, 2012 1195 djohnson Remove executeQuery method, add getById.
* 3/18/2013 1802 bphillip Implemented transaction boundaries
* </pre>
*
* @author djohnson
* @version 1.0
*/
@Transactional
public abstract class BaseRegistryObjectHandler<T, QUERY extends AdhocRegistryQuery<T>>
implements IRegistryObjectHandler<T> {
@ -195,8 +198,7 @@ public abstract class BaseRegistryObjectHandler<T, QUERY extends AdhocRegistryQu
* @throws RegistryHandlerException
*/
protected static <T> void checkResponse(RegistryResponse<?> response,
T obj,
String operation) throws RegistryHandlerException {
T obj, String operation) throws RegistryHandlerException {
if (response.getStatus() != OperationStatus.SUCCESS) {
String message = "Unable to " + operation + " "
+ obj.getClass().getName() + ".";

View file

@ -7,7 +7,9 @@ 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.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"
Export-Package: com.raytheon.uf.common.registry.schemas.ebxml.util,
oasis.names.tc.ebxml.regrep.wsdl.registry.services.v4,
oasis.names.tc.ebxml.regrep.xsd.lcm.v4,

View file

@ -3,3 +3,61 @@ oasis.names.tc.ebxml.regrep.xsd.query.v4.ObjectFactory
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ObjectFactory
oasis.names.tc.ebxml.regrep.xsd.rs.v4.ObjectFactory
oasis.names.tc.ebxml.regrep.xsd.spi.v4.ObjectFactory
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ActionType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.AnyValueType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.AssociationType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.AuditableEventType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.BooleanValueType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ClassificationNodeType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ClassificationSchemeType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ClassificationType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.CollectionValueType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.DateTimeValueType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.DeliveryInfoType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.DurationValueType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.EmailAddressType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.EntryType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ExternalIdentifierType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ExternalLinkType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ExtrinsicObjectType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.FederationType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.FloatValueType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.IntegerValueType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.InternationalStringType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.InternationalStringValueType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.LocalizedStringType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.MapType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.MapValueType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.NotificationType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ObjectRefListType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ObjectRefType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.OrganizationType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ParameterType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.PersonNameType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.PersonType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.PostalAddressType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.QueryDefinitionType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.QueryExpressionType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.QueryType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.RegistryObjectListType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.RegistryObjectType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.RegistryPackageType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.RegistryType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.RoleType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ServiceBindingType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ServiceEndpointType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ServiceInterfaceType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ServiceType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.SimpleLinkType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.SlotType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.SlotValueType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.StringQueryExpressionType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.StringValueType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.SubscriptionType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.TaxonomyElementType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.TelephoneNumberType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.ValueType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.VocabularyTermType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.VocabularyTermValueType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.WorkflowActionType
oasis.names.tc.ebxml.regrep.xsd.rim.v4.XMLQueryExpressionType

View file

@ -26,6 +26,7 @@ import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.OneToOne;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
@ -76,13 +77,14 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "Action")
@Table(schema = "ebxml", name = "Action")
public class ActionType extends ExtensibleObjectType implements Serializable {
private static final long serialVersionUID = -8469820571747325703L;
@Id
@GeneratedValue
@SequenceGenerator(name = "ActionTypeGenerator", schema = "ebxml", sequenceName = "ebxml.Action_sequence")
@GeneratedValue(generator = "ActionTypeGenerator")
@XmlTransient
private Integer key;

View file

@ -69,7 +69,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "Association")
@Table(schema = "ebxml", name = "Association")
public class AssociationType extends RegistryObjectType {
@XmlAttribute(required = true)

View file

@ -26,6 +26,7 @@ import java.util.List;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.JoinTable;
import javax.persistence.OneToMany;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
@ -76,12 +77,13 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "AuditableEventType", propOrder = { "action" })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "AuditableEvent")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "AuditableEvent")
public class AuditableEventType extends RegistryObjectType {
@XmlElement(name = "Action", required = true)
@DynamicSerializeElement
@OneToMany(cascade = CascadeType.ALL)
@JoinTable(schema = "ebxml")
protected List<ActionType> action;
@Column

View file

@ -67,7 +67,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "BooleanValue")
@Table(schema = "ebxml", name = "BooleanValue")
public class BooleanValueType extends ValueType {
@Column(name = COLUMN_NAME)

View file

@ -67,7 +67,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "ClassificationNode")
@Table(schema = "ebxml", name = "ClassificationNode")
public class ClassificationNodeType extends TaxonomyElementType {
@XmlAttribute

View file

@ -64,8 +64,8 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "ClassificationSchemeType")
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL, include = "all")
@Table(name = "ClassificationScheme")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL, include = "all")
@Table(schema = "ebxml", name = "ClassificationScheme")
public class ClassificationSchemeType extends TaxonomyElementType {
@XmlAttribute(required = true)

View file

@ -68,7 +68,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "Classification")
@Table(schema = "ebxml", name = "Classification")
public class ClassificationType extends RegistryObjectType {
@XmlAttribute

View file

@ -26,6 +26,7 @@ import java.util.List;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
@ -74,14 +75,15 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "CollectionValueType", propOrder = { "collectionValue" })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "CollectionValue")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "CollectionValue")
public class CollectionValueType extends ValueType {
@XmlElement(name = "Element")
@DynamicSerializeElement
@Column(name = COLUMN_NAME)
@ManyToMany(cascade = CascadeType.ALL)
@JoinTable(schema = "ebxml")
protected List<ValueType> collectionValue;
@XmlAttribute

View file

@ -70,7 +70,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "DateTimeValue")
@Table(schema = "ebxml", name = "DateTimeValue")
public class DateTimeValueType extends ValueType {
@Column(name = "DateTimeValue")

View file

@ -23,6 +23,7 @@ package oasis.names.tc.ebxml.regrep.xsd.rim.v4;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.Transient;
import javax.xml.bind.annotation.XmlAccessType;
@ -74,12 +75,13 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "DeliveryInfoType")
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "DeliveryInfo")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "DeliveryInfo")
public class DeliveryInfoType extends ExtensibleObjectType {
@Id
@GeneratedValue
@SequenceGenerator(name = "DeliveryInfoTypeGenerator", schema = "ebxml", sequenceName = "ebxml.DeliveryInfo_sequence")
@GeneratedValue(generator = "DeliveryInfoTypeGenerator")
@XmlTransient
private Integer key;

View file

@ -68,8 +68,8 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "DurationValueType", propOrder = { "durationValue" })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "DurationType")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "DurationValue")
public class DurationValueType extends ValueType {
@XmlElement(name = "Value")

View file

@ -25,6 +25,7 @@ import java.io.Serializable;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
@ -67,14 +68,15 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "EmailAddressType")
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "EmailAddress")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "EmailAddress")
public class EmailAddressType extends ExtensibleObjectType implements
Serializable {
private static final long serialVersionUID = -2958054699149020163L;
@Id
@GeneratedValue
@SequenceGenerator(name = "EmailAddressTypeGenerator", schema = "ebxml", sequenceName = "ebxml.EmailAddress_sequence")
@GeneratedValue(generator = "EmailAddressTypeGenerator")
@XmlTransient
private Integer key;

View file

@ -72,8 +72,8 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "EntryType", propOrder = { "entryKey", "entryValue" })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "EntryType")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "Entry")
public class EntryType implements Serializable {
private static final long serialVersionUID = -641063902591977048L;

View file

@ -89,7 +89,7 @@ public abstract class ExtensibleObjectType {
@BatchSize(size = 500)
@ManyToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY)
@JoinTable(inverseJoinColumns = @JoinColumn(name = "child_slot_key"))
@JoinTable(schema = "ebxml", inverseJoinColumns = @JoinColumn(name = "child_slot_key"))
@XmlElement(name = "Slot")
@DynamicSerializeElement
protected Set<SlotType> slot;

View file

@ -67,7 +67,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "ExternalIdentifier")
@Table(schema = "ebxml", name = "ExternalIdentifier")
public class ExternalIdentifierType extends RegistryObjectType {
@XmlAttribute

View file

@ -70,7 +70,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "ExternalLink")
@Table(schema = "ebxml", name = "ExternalLink")
public class ExternalLinkType extends RegistryObjectType {
@XmlElement(name = "ExternalRef", required = true)

View file

@ -21,7 +21,11 @@
package oasis.names.tc.ebxml.regrep.xsd.rim.v4;
import javax.activation.DataHandler;
import javax.persistence.AttributeOverride;
import javax.persistence.AttributeOverrides;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Embedded;
import javax.persistence.Entity;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
@ -80,13 +84,16 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlSeeAlso({ CommentType.class })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "ExtrinsicObject")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "ExtrinsicObject")
public class ExtrinsicObjectType extends RegistryObjectType {
@XmlElement(name = "ContentVersionInfo")
@DynamicSerializeElement
@ManyToOne(cascade = CascadeType.ALL)
@AttributeOverrides({
@AttributeOverride(name = "versionName", column = @Column(name = "contentVersionName")),
@AttributeOverride(name = "userVersionName", column = @Column(name = "contentUserVersionName")) })
@Embedded
protected VersionInfoType contentVersionInfo;
@XmlElement(name = "RepositoryItemRef")

View file

@ -64,7 +64,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "Federation")
@Table(schema = "ebxml", name = "Federation")
public class FederationType extends RegistryObjectType {
@Transient

View file

@ -67,7 +67,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "FloatValue")
@Table(schema = "ebxml", name = "FloatValue")
public class FloatValueType extends ValueType {
@Column(name = COLUMN_NAME)
@XmlElement(name = "Value")

View file

@ -32,6 +32,7 @@ import javax.xml.bind.annotation.XmlType;
import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;
import com.raytheon.uf.common.dataplugin.persist.IPersistableDataObject;
import com.raytheon.uf.common.serialization.annotations.DynamicSerialize;
import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@ -66,8 +67,9 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlSeeAlso({ RegistryObjectType.class })
@DynamicSerialize
@MappedSuperclass
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL, include = "all")
public abstract class IdentifiableType extends ExtensibleObjectType {
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL, include = "all")
public abstract class IdentifiableType extends ExtensibleObjectType implements
IPersistableDataObject<String> {
@Id
@XmlAttribute(required = true)
@ -95,4 +97,8 @@ public abstract class IdentifiableType extends ExtensibleObjectType {
this.id = value;
}
public String getIdentifier() {
return id;
}
}

View file

@ -69,7 +69,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "IntegerValue")
@Table(schema = "ebxml", name = "IntegerValue")
public class IntegerValueType extends ValueType {
@Column(name = COLUMN_NAME)
@XmlElement(name = "Value")

View file

@ -29,7 +29,9 @@ import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinTable;
import javax.persistence.OneToMany;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
@ -78,20 +80,22 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@XmlType(name = "InternationalStringType", propOrder = { "localizedString" })
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL, include = "all")
@Table(name = "IntlString")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL, include = "all")
@Table(schema = "ebxml", name = "InternationalString")
public class InternationalStringType implements Serializable {
private static final long serialVersionUID = 2414977045816695691L;
@Id
@GeneratedValue
@SequenceGenerator(name = "InternationalStringTypeGenerator", schema = "ebxml", sequenceName = "ebxml.InternationalString_sequence")
@GeneratedValue(generator = "InternationalStringTypeGenerator")
@XmlTransient
private Integer key;
@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.EAGER)
@XmlElement(name = "LocalizedString")
@DynamicSerializeElement
@JoinTable(schema = "ebxml")
protected List<LocalizedStringType> localizedString;
/**

View file

@ -69,7 +69,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "InternationalStringValue")
@Table(schema = "ebxml", name = "InternationalStringValue")
public class InternationalStringValueType extends ValueType {
@XmlElement(name = "Value")

View file

@ -24,6 +24,7 @@ import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
@ -70,12 +71,13 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "LocalizedStringType")
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "LocalizedStrings")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "LocalizedString")
public class LocalizedStringType {
@Id
@GeneratedValue
@SequenceGenerator(name = "LocalizedStringTypeGenerator", schema = "ebxml", sequenceName = "ebxml.LocalizedString_sequence")
@GeneratedValue(generator = "LocalizedStringTypeGenerator")
@XmlTransient
private Integer key;

View file

@ -27,7 +27,9 @@ import java.util.List;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
@ -75,14 +77,15 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "MapType", propOrder = { "entry" })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "MapType")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "Map")
public class MapType implements Serializable {
private static final long serialVersionUID = 5533297201296624269L;
@Id
@GeneratedValue
@SequenceGenerator(name = "MapTypeGenerator", schema = "ebxml", sequenceName = "ebxml.Map_sequence")
@GeneratedValue(generator = "MapTypeGenerator")
@XmlTransient
protected Integer key;
@ -94,6 +97,7 @@ public class MapType implements Serializable {
@DynamicSerializeElement
@Cascade(value = { org.hibernate.annotations.CascadeType.SAVE_UPDATE })
@ManyToMany
@JoinTable(schema = "ebxml")
protected List<EntryType> entry;
/**

View file

@ -25,6 +25,7 @@ import java.util.List;
import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
@ -70,13 +71,14 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "NotificationType", propOrder = { "event" })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "Notification")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "Notification")
public class NotificationType extends RegistryObjectType {
@XmlElement(name = "Event", required = true)
@DynamicSerializeElement
@ManyToMany(cascade = CascadeType.ALL)
@JoinTable(schema = "ebxml")
protected List<AuditableEventType> event;
@XmlAttribute(required = true)

View file

@ -27,7 +27,9 @@ import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
@ -73,18 +75,20 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "ObjectRefListType", propOrder = { "objectRef" })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "ObjectRefList")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "ObjectRefList")
public class ObjectRefListType {
@Id
@GeneratedValue
@SequenceGenerator(name = "ObjectRefListTypeGenerator", schema = "ebxml", sequenceName = "ebxml.ObjectRefList_sequence")
@GeneratedValue(generator = "ObjectRefListTypeGenerator")
@XmlTransient
private Integer key;
@XmlElement(name = "ObjectRef")
@DynamicSerializeElement
@ManyToMany(cascade = CascadeType.ALL)
@JoinTable(schema = "ebxml")
protected List<ObjectRefType> objectRef;
public Integer getKey() {
@ -121,7 +125,6 @@ public class ObjectRefListType {
return this.objectRef;
}
public void setObjectRef(List<ObjectRefType> objectRef) {
this.objectRef = objectRef;
}

View file

@ -33,6 +33,7 @@ import javax.xml.bind.annotation.XmlType;
import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;
import com.raytheon.uf.common.dataplugin.persist.IPersistableDataObject;
import com.raytheon.uf.common.serialization.annotations.DynamicSerialize;
import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@ -66,9 +67,10 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlSeeAlso({ DynamicObjectRefType.class })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "ObjectRef")
public class ObjectRefType extends ExtensibleObjectType {
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "ObjectRef")
public class ObjectRefType extends ExtensibleObjectType implements
IPersistableDataObject<String> {
@Id
@XmlAttribute(required = true)
@ -96,4 +98,9 @@ public class ObjectRefType extends ExtensibleObjectType {
this.id = value;
}
@Override
public String getIdentifier() {
return getId();
}
}

View file

@ -25,6 +25,7 @@ import java.util.List;
import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
@ -70,13 +71,14 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "OrganizationType", propOrder = { "organization" })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "Organization")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "Organization")
public class OrganizationType extends PartyType {
@XmlElement(name = "Organization")
@DynamicSerializeElement
@ManyToMany(cascade = CascadeType.ALL)
@JoinTable(schema = "ebxml")
protected List<OrganizationType> organization;
@XmlAttribute

View file

@ -28,6 +28,7 @@ import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.ManyToOne;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
@ -82,12 +83,13 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "ParameterType", propOrder = { "name", "description" })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "Parameter")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "Parameter")
public class ParameterType extends ExtensibleObjectType implements Serializable {
@Id
@GeneratedValue
@SequenceGenerator(name = "ParameterTypeGenerator", schema = "ebxml", sequenceName = "ebxml.Parameter_sequence")
@GeneratedValue(generator = "ParameterTypeGenerator")
@XmlTransient
protected Integer key;

View file

@ -24,6 +24,7 @@ import java.util.ArrayList;
import java.util.List;
import javax.persistence.CascadeType;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.MappedSuperclass;
import javax.xml.bind.annotation.XmlAccessType;
@ -74,16 +75,19 @@ public abstract class PartyType extends RegistryObjectType {
@XmlElement(name = "PostalAddress")
@DynamicSerializeElement
@ManyToMany(cascade = CascadeType.ALL)
@JoinTable(schema = "ebxml")
protected List<PostalAddressType> postalAddress;
@XmlElement(name = "TelephoneNumber")
@DynamicSerializeElement
@ManyToMany(cascade = CascadeType.ALL)
@JoinTable(schema = "ebxml")
protected List<TelephoneNumberType> telephoneNumber;
@XmlElement(name = "EmailAddress")
@DynamicSerializeElement
@ManyToMany(cascade = CascadeType.ALL)
@JoinTable(schema = "ebxml")
protected List<EmailAddressType> emailAddress;
/**

View file

@ -67,7 +67,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "PersonName")
@Table(schema = "ebxml", name = "PersonName")
public class PersonNameType extends ExtensibleObjectType implements
Serializable {

View file

@ -66,7 +66,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "Person")
@Table(schema = "ebxml", name = "Person")
public class PersonType extends PartyType {
@XmlElement(name = "PersonName")

View file

@ -23,6 +23,7 @@ package oasis.names.tc.ebxml.regrep.xsd.rim.v4;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
@ -70,12 +71,13 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "PostalAddressType")
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "PostalAddress")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "PostalAddress")
public class PostalAddressType extends ExtensibleObjectType {
@Id
@GeneratedValue
@SequenceGenerator(name = "PostalAddressTypeGenerator", schema = "ebxml", sequenceName = "ebxml.PostalAddress_sequence")
@GeneratedValue(generator = "PostalAddressTypeGenerator")
@XmlTransient
private Integer key;

View file

@ -25,6 +25,7 @@ import java.util.List;
import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
@ -73,13 +74,14 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
"queryExpression" })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "QueryDefinition")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "QueryDefinition")
public class QueryDefinitionType extends RegistryObjectType {
@ManyToMany(cascade = CascadeType.ALL)
@XmlElement(name = "Parameter")
@DynamicSerializeElement
@JoinTable(schema = "ebxml")
protected List<ParameterType> parameter;
@ManyToOne(cascade = CascadeType.ALL)

View file

@ -25,6 +25,8 @@ import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Inheritance;
import javax.persistence.InheritanceType;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAttribute;
@ -71,12 +73,14 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlSeeAlso({ StringQueryExpressionType.class, XMLQueryExpressionType.class })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "QueryExpression")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Inheritance(strategy = InheritanceType.TABLE_PER_CLASS)
public class QueryExpressionType extends ExtensibleObjectType {
@Id
@GeneratedValue
@SequenceGenerator(name = "QueryExpressionTypeGenerator", schema = "ebxml", sequenceName = "ebxml.QueryExpression_sequence")
@GeneratedValue(generator = "QueryExpressionTypeGenerator")
@XmlTransient
protected Integer key;

View file

@ -65,7 +65,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "Query")
@Table(schema = "ebxml", name = "Query")
public class QueryType extends ExtensibleObjectType {
@Id
@XmlAttribute(required = true)

View file

@ -27,7 +27,9 @@ import java.util.List;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
@ -74,20 +76,22 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "RegistryObjectListType", propOrder = { "registryObject" })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "RegistryObjectList")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "RegistryObjectList")
public class RegistryObjectListType implements Serializable {
private static final long serialVersionUID = -254507015539461400L;
@Id
@GeneratedValue
@SequenceGenerator(name = "RegistryObjectListTypeGenerator", schema = "ebxml", sequenceName = "ebxml.RegistryObjectList_sequence")
@GeneratedValue(generator = "RegistryObjectListTypeGenerator")
@XmlTransient
private Integer key;
@ManyToMany
@Cascade(value = { org.hibernate.annotations.CascadeType.SAVE_UPDATE,
org.hibernate.annotations.CascadeType.DETACH })
@JoinTable(schema = "ebxml")
@XmlElement(name = "RegistryObject")
@DynamicSerializeElement
protected List<RegistryObjectType> registryObject;

View file

@ -24,12 +24,13 @@ import java.util.HashSet;
import java.util.Set;
import javax.persistence.CascadeType;
import javax.persistence.Embedded;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.Inheritance;
import javax.persistence.InheritanceType;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.ManyToOne;
import javax.persistence.OneToOne;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
@ -102,7 +103,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@Entity
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL, include = "all")
@Inheritance(strategy = InheritanceType.TABLE_PER_CLASS)
@Table(name = "RegistryObject")
@Table(schema = "ebxml", name = "RegistryObject")
public class RegistryObjectType extends IdentifiableType {
@XmlElement(name = "Name")
@DynamicSerializeElement
@ -116,8 +117,7 @@ public class RegistryObjectType extends IdentifiableType {
@XmlElement(name = "VersionInfo")
@DynamicSerializeElement
@Cascade(value = { org.hibernate.annotations.CascadeType.DETACH })
@ManyToOne(fetch = FetchType.LAZY)
@Embedded
protected VersionInfoType versionInfo;
@XmlElement(name = "Classification")
@ -125,6 +125,7 @@ public class RegistryObjectType extends IdentifiableType {
@Cascade(value = { org.hibernate.annotations.CascadeType.SAVE_UPDATE,
org.hibernate.annotations.CascadeType.DETACH })
@ManyToMany(fetch = FetchType.LAZY)
@JoinTable(schema = "ebxml")
protected Set<ClassificationType> classification;
@XmlElement(name = "ExternalIdentifier")
@ -132,6 +133,7 @@ public class RegistryObjectType extends IdentifiableType {
@Cascade(value = { org.hibernate.annotations.CascadeType.SAVE_UPDATE,
org.hibernate.annotations.CascadeType.DETACH })
@ManyToMany(fetch = FetchType.LAZY)
@JoinTable(schema = "ebxml")
protected Set<ExternalIdentifierType> externalIdentifier;
@XmlElement(name = "ExternalLink")
@ -139,6 +141,7 @@ public class RegistryObjectType extends IdentifiableType {
@Cascade(value = { org.hibernate.annotations.CascadeType.SAVE_UPDATE,
org.hibernate.annotations.CascadeType.DETACH })
@ManyToMany(fetch = FetchType.LAZY)
@JoinTable(schema = "ebxml")
protected Set<ExternalLinkType> externalLink;
@XmlAttribute

View file

@ -69,7 +69,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "RegistryPackage")
@Table(schema = "ebxml", name = "RegistryPackage")
public class RegistryPackageType extends RegistryObjectType {
@OneToOne(cascade = CascadeType.ALL)

View file

@ -79,7 +79,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "Registry")
@Table(schema = "ebxml", name = "Registry")
public class RegistryType extends RegistryObjectType {
@XmlAttribute(required = true)

View file

@ -66,7 +66,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "Role")
@Table(schema = "ebxml", name = "Role")
public class RoleType extends RegistryObjectType {
@XmlAttribute(required = true)

View file

@ -64,7 +64,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "ServiceBinding")
@Table(schema = "ebxml", name = "ServiceBinding")
public class ServiceBindingType extends RegistryObjectType {
@XmlAttribute

View file

@ -67,7 +67,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "ServiceEndpoint")
@Table(schema = "ebxml", name = "ServiceEndpoint")
public class ServiceEndpointType extends RegistryObjectType {
@XmlAttribute

View file

@ -23,6 +23,7 @@ package oasis.names.tc.ebxml.regrep.xsd.rim.v4;
import javax.persistence.Entity;
import javax.persistence.Inheritance;
import javax.persistence.InheritanceType;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlRootElement;
@ -62,7 +63,8 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize;
@XmlType(name = "ServiceInterfaceType")
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "ServiceInterface")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Inheritance(strategy = InheritanceType.TABLE_PER_CLASS)
public class ServiceInterfaceType extends RegistryObjectType {

View file

@ -25,6 +25,7 @@ import java.util.List;
import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
@ -72,13 +73,14 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "ServiceType", propOrder = { "serviceEndpoint" })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "Service")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "Service")
public class ServiceType extends RegistryObjectType {
@ManyToMany(cascade = CascadeType.ALL)
@XmlElement(name = "ServiceEndpoint")
@DynamicSerializeElement
@JoinTable(schema = "ebxml")
protected List<ServiceEndpointType> serviceEndpoint;
@XmlAttribute

View file

@ -23,6 +23,7 @@ package oasis.names.tc.ebxml.regrep.xsd.rim.v4;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.Transient;
import javax.xml.bind.annotation.XmlAccessType;
@ -72,12 +73,13 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "SimpleLinkType")
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "SimpleLink")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "SimpleLink")
public class SimpleLinkType {
@Id
@GeneratedValue
@SequenceGenerator(name = "SimpleLinkTypeGenerator", schema = "ebxml", sequenceName = "ebxml.SimpleLink_sequence")
@GeneratedValue(generator = "SimpleLinkTypeGenerator")
@XmlTransient
private Integer key;

View file

@ -28,6 +28,7 @@ import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.ManyToOne;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
@ -85,13 +86,14 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
// referencedColumnName = "key"), inverseJoinColumns = @JoinColumn(name =
// "child_slot_key", referencedColumnName = "key")))
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL, include = "all")
@Table(name = "Slot")
@Table(schema = "ebxml", name = "Slot")
public class SlotType extends ExtensibleObjectType implements Serializable {
private static final long serialVersionUID = -2184582316481503043L;
@Id
@GeneratedValue
@SequenceGenerator(name = "ExtensibleObjectTypeGenerator", schema = "ebxml", sequenceName = "ebxml.Slot_sequence")
@GeneratedValue(generator = "ExtensibleObjectTypeGenerator")
@XmlTransient
private Integer key;

View file

@ -67,8 +67,8 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "SlotValueType", propOrder = { "slotValue" })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "SlotType")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "SlotValue")
public class SlotValueType extends ValueType {
@XmlElement(name = "Slot")

View file

@ -21,6 +21,7 @@
package oasis.names.tc.ebxml.regrep.xsd.rim.v4;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
@ -61,7 +62,8 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
*
*/
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "StringQueryExpression")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@XmlRootElement
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "StringQueryExpressionType", propOrder = { "value" })

View file

@ -68,7 +68,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "StringValue")
@Table(schema = "ebxml", name = "StringValue")
public class StringValueType extends ValueType {
@Column(name = COLUMN_NAME, columnDefinition = "text")

View file

@ -26,6 +26,7 @@ import java.util.List;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.OneToOne;
import javax.persistence.Table;
@ -80,13 +81,14 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "SubscriptionType", propOrder = { "deliveryInfo", "selector" })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "Subscription")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "Subscription")
public class SubscriptionType extends RegistryObjectType {
@ManyToMany(cascade = CascadeType.ALL)
@XmlElement(name = "DeliveryInfo")
@DynamicSerializeElement
@JoinTable(schema = "ebxml")
protected List<DeliveryInfoType> deliveryInfo;
@OneToOne(cascade = CascadeType.ALL)

View file

@ -26,6 +26,7 @@ import java.util.Set;
import javax.persistence.Entity;
import javax.persistence.Inheritance;
import javax.persistence.InheritanceType;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
@ -79,6 +80,7 @@ public abstract class TaxonomyElementType extends RegistryObjectType {
org.hibernate.annotations.CascadeType.DETACH })
@XmlElement(name = "ClassificationNode")
@DynamicSerializeElement
@JoinTable(schema = "ebxml")
protected Set<ClassificationNodeType> classificationNode;
/**

View file

@ -23,6 +23,7 @@ package oasis.names.tc.ebxml.regrep.xsd.rim.v4;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
@ -68,12 +69,13 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "TelephoneNumberType")
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "TelephoneNumber")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "TelephoneNumber")
public class TelephoneNumberType extends ExtensibleObjectType {
@Id
@GeneratedValue
@SequenceGenerator(name = "TelephoneNumberTypeGenerator", schema = "ebxml", sequenceName = "ebxml.TelephoneNumber_sequence")
@GeneratedValue(generator = "TelephoneNumberTypeGenerator")
@XmlTransient
private Integer key;

View file

@ -25,6 +25,7 @@ import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Inheritance;
import javax.persistence.InheritanceType;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
@ -71,13 +72,14 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerialize;
DurationValueType.class, CollectionValueType.class })
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "Value")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "Value")
@Inheritance(strategy = InheritanceType.SINGLE_TABLE)
public abstract class ValueType {
@Id
@GeneratedValue
@SequenceGenerator(name = "ValueTypeGenerator", schema = "ebxml", sequenceName = "ebxml.Value_sequence")
@GeneratedValue(generator = "ValueTypeGenerator")
@XmlTransient
protected Integer key;

View file

@ -23,19 +23,12 @@ package oasis.names.tc.ebxml.regrep.xsd.rim.v4;
import java.io.Serializable;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Embeddable;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlTransient;
import javax.xml.bind.annotation.XmlType;
import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;
import com.raytheon.uf.common.dataplugin.persist.IPersistableDataObject;
import com.raytheon.uf.common.serialization.annotations.DynamicSerialize;
import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@ -62,31 +55,24 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
*
*
*/
@XmlRootElement
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "VersionInfoType")
@Embeddable
@XmlAccessorType(XmlAccessType.NONE)
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "VersionInfo")
public class VersionInfoType implements Serializable {
public class VersionInfoType implements Serializable,
IPersistableDataObject<String> {
private static final long serialVersionUID = -2869857115641981790L;
@Id
@Column
@XmlAttribute
@DynamicSerializeElement
protected String versionName;
protected String versionName = "1";
@Id
@Column
@XmlAttribute
@DynamicSerializeElement
protected String userVersionName;
@Column
@XmlTransient
private int versionNumber;
/**
* Gets the value of the versionName property.
*
@ -106,7 +92,6 @@ public class VersionInfoType implements Serializable {
*/
public void setVersionName(String value) {
this.versionName = value;
this.versionNumber = Integer.parseInt(this.versionName);
}
/**
@ -135,12 +120,9 @@ public class VersionInfoType implements Serializable {
return versionName + "_" + userVersionName;
}
public int getVersionNumber() {
return versionNumber;
}
public void setVersionNumber(int versionNumber) {
this.versionNumber = versionNumber;
@Override
public String getIdentifier() {
return versionName;
}
}

View file

@ -24,6 +24,7 @@ import java.io.Serializable;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAttribute;
@ -66,7 +67,8 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlType(name = "VocabularyTermType")
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "VocabularyTerm")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
public class VocabularyTermType implements Serializable {
private static final long serialVersionUID = -7560901570669843677L;

View file

@ -69,7 +69,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "VocabularyTermValue")
@Table(schema = "ebxml", name = "VocabularyTermValue")
public class VocabularyTermValueType extends ValueType {
@XmlElement(name = "Value")

View file

@ -65,7 +65,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@DynamicSerialize
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(name = "WorkflowAction")
@Table(schema = "ebxml", name = "WorkflowAction")
public class WorkflowActionType extends RegistryObjectType {
@XmlAttribute(required = true)

View file

@ -22,6 +22,7 @@ package oasis.names.tc.ebxml.regrep.xsd.rim.v4;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAnyElement;
@ -64,7 +65,8 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
*
*/
@Entity
@Cache(region="registryObjects",usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@Table(schema = "ebxml", name = "XMLQueryExpression")
@Cache(region = "registryObjects", usage = CacheConcurrencyStrategy.TRANSACTIONAL)
@XmlRootElement
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "XMLQueryExpressionType", propOrder = { "any" })

View file

@ -44,6 +44,7 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* Aug 21, 2012 jsanchez Initial creation
* 3/18/2013 1802 bphillip Implemented transaction boundaries. Changed to extend parameterized PersistableDataObject
*
* </pre>
*
@ -55,7 +56,10 @@ import com.raytheon.uf.common.serialization.annotations.DynamicSerializeElement;
@XmlRootElement
@XmlAccessorType(XmlAccessType.NONE)
@DynamicSerialize
public class StatsRecord extends PersistableDataObject {
public class StatsRecord extends PersistableDataObject<Integer> {
private static final long serialVersionUID = -2018725770414395081L;
@GeneratedValue(strategy = GenerationType.AUTO)
@Id
@DynamicSerializeElement

View file

@ -20,9 +20,11 @@
package com.raytheon.uf.common.util;
import java.lang.reflect.Array;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collection;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
/**
@ -111,4 +113,29 @@ public final class CollectionUtil {
objArray2.length);
return array;
}
/**
* Utility function to convert an array of objects into a list. The array
* may contain collections. Each member of the collection is added to the
* returned list.
*
* @param objects
* The objects to be moved to a list
* @return The compiled list of objects
*/
@SuppressWarnings("unchecked")
public static <T extends Object> List<T> asUnembeddedList(T... objects) {
List<T> retVal = new ArrayList<T>();
for (T obj : objects) {
if (obj instanceof Collection<?>) {
Collection<?> coll = (Collection<?>) obj;
for (Object obj2 : coll) {
retVal.add((T) obj2);
}
} else {
retVal.add(obj);
}
}
return retVal;
}
}

View file

@ -48,7 +48,6 @@ import com.raytheon.uf.common.util.SizeUtil;
* @author mschenke
* @version 1.0
*/
public class RemoteRequestRouteWrapper {
private static final IUFStatusHandler thriftSrvLogger = UFStatus

View file

@ -57,6 +57,7 @@ import com.raytheon.uf.edex.core.props.PropertiesFactory;
* 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
* </pre>
*
* @author chammack

View file

@ -28,16 +28,20 @@ import java.util.List;
import java.util.Map;
import java.util.Map.Entry;
import org.hibernate.Query;
import org.hibernate.SessionFactory;
import org.hibernate.criterion.DetachedCriteria;
import org.hibernate.dialect.Dialect;
import org.hibernate.impl.SessionFactoryImpl;
import org.springframework.orm.hibernate3.HibernateTemplate;
import org.springframework.stereotype.Repository;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;
import com.raytheon.uf.common.dataplugin.persist.IPersistableDataObject;
import com.raytheon.uf.common.status.IUFStatusHandler;
import com.raytheon.uf.common.status.UFStatus;
import com.raytheon.uf.edex.database.DataAccessLayerException;
/**
* A CoreDao mimic that is session managed. A Dao will never open its own
@ -52,6 +56,7 @@ import com.raytheon.uf.common.status.UFStatus;
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* Feb 07, 2013 1543 djohnson Initial creation
* 3/18/2013 1802 bphillip Added additional database functions. Enforcing mandatory transaction propogation
*
* </pre>
*
@ -59,8 +64,12 @@ import com.raytheon.uf.common.status.UFStatus;
* @version 1.0
*/
@Repository
@Transactional
public abstract class SessionManagedDao<IDENTIFIER extends Serializable, ENTITY extends IPersistableDataObject<IDENTIFIER>> implements ISessionManagedDao<IDENTIFIER, ENTITY> {
@Transactional(propagation = Propagation.MANDATORY)
public abstract class SessionManagedDao<IDENTIFIER extends Serializable, ENTITY extends IPersistableDataObject<IDENTIFIER>>
implements ISessionManagedDao<IDENTIFIER, ENTITY> {
/** The region in the cache which stores the queries */
private static final String QUERY_CACHE_REGION = "Queries";
protected static final IUFStatusHandler statusHandler = UFStatus
.getHandler(SessionManagedDao.class);
@ -132,7 +141,7 @@ public abstract class SessionManagedDao<IDENTIFIER extends Serializable, ENTITY
* {@inheritDoc}
*/
@Override
public ENTITY getById(IDENTIFIER id) {
public ENTITY getById(Serializable id) {
final Class<ENTITY> entityClass = getEntityClass();
return entityClass.cast(template.get(entityClass, id));
}
@ -153,9 +162,13 @@ public abstract class SessionManagedDao<IDENTIFIER extends Serializable, ENTITY
* @param params
* @return
*/
protected List<ENTITY> query(String queryString, Map<String, Object> params) {
return query(queryString, params, 0);
}
@SuppressWarnings("unchecked")
protected List<ENTITY> query(String queryString,
Map<String, Object> params) {
Map<String, Object> params, int maxResults) {
final int numberOfParams = params.size();
String[] paramNames = new String[numberOfParams];
Object[] paramValues = new Object[numberOfParams];
@ -165,8 +178,12 @@ public abstract class SessionManagedDao<IDENTIFIER extends Serializable, ENTITY
paramNames[i] = entry.getKey();
paramValues[i] = entry.getValue();
}
HibernateTemplate templateToUse = (maxResults == 0) ? template
: new HibernateTemplate(this.getSessionFactory());
templateToUse.setMaxResults(maxResults);
return templateToUse.findByNamedParam(queryString, paramNames,
paramValues);
return template.findByNamedParam(queryString, paramNames, paramValues);
}
/**
@ -176,8 +193,7 @@ public abstract class SessionManagedDao<IDENTIFIER extends Serializable, ENTITY
* @param params
* @return
*/
protected ENTITY uniqueResult(String queryString,
Map<String, Object> params) {
protected ENTITY uniqueResult(String queryString, Map<String, Object> params) {
final List<ENTITY> results = query(queryString, params);
if (results.isEmpty()) {
return null;
@ -188,6 +204,219 @@ public abstract class SessionManagedDao<IDENTIFIER extends Serializable, ENTITY
return results.get(0);
}
/**
* Executes an HQL query in a new Hibernate session
*
* @param <T>
* An object type to query for
* @param queryString
* The query to execute
* @return The results of the HQL query
* @throws DataAccessLayerException
* If errors are encountered during the HQL query
*/
public <T extends Object> List<T> executeHQLQuery(String queryString)
throws DataAccessLayerException {
return executeHQLQuery(queryString, true, null);
}
/**
* Executes an HQL query
*
* @param <T>
* The return object type
* @param queryString
* A StringBuilder instance containing an HQL query to execute
* @return List containing the results of the query
* @throws DataAccessLayerException
* If Hibernate errors occur during execution of the query
*/
public List<ENTITY> executeHQLQuery(StringBuilder queryString)
throws DataAccessLayerException {
return executeHQLQuery(queryString.toString(), true, null);
}
/**
* Executes an HQL query with a map of name value pairs with which to
* substitute into the query. This method is a convenience method for
* executing prepared statements
*
* @param <T>
* The return object type
* @param queryString
* The prepared HQL query to execute. This query contains values
* that will be substituted according to the names and values
* found in the params map
* @param params
* The named parameters to substitute into the HQL query
* @return List containing the results of the query
* @throws DataAccessLayerException
* If Hibernate errors occur during the execution of the query
*/
public List<ENTITY> executeHQLQuery(String queryString,
Map<String, Object> params) throws DataAccessLayerException {
return executeHQLQuery(queryString, true, params);
}
/**
* Executes an HQL query in an existing Hibernate session
*
* @param <T>
* An object type to query for
* @param queryString
* The query to execute
* @param session
* The existing Hibernate session
* @return The results of the HQL query
* @throws DataAccessLayerException
* if errors are encountered during the HQL query
*/
@SuppressWarnings("unchecked")
public <T extends Object> List<T> executeHQLQuery(final String queryString,
boolean eager, final Map<String, Object> params)
throws DataAccessLayerException {
try {
Query query = getSessionFactory().getCurrentSession()
.createQuery(queryString).setCacheable(true)
.setCacheRegion(QUERY_CACHE_REGION);
if (params != null) {
for (String name : params.keySet()) {
Object val = params.get(name);
query.setParameter(name, val);
}
}
List<T> results = query.list();
return results;
} catch (Throwable e) {
throw new DataAccessLayerException("Error executing HQLQuery ["
+ queryString + "]", e);
}
}
/**
* Executes an HQL query in a new Hibernate session
*
* @param <T>
* An object type to query for
* @param queryString
* The query to execute
* @return The results of the HQL query
* @throws DataAccessLayerException
* If errors are encountered during the HQL query
*/
public int executeHQLStatement(String queryString)
throws DataAccessLayerException {
return executeHQLStatement(queryString, true, null);
}
/**
* Executes an HQL query
*
* @param <T>
* The return object type
* @param queryString
* A StringBuilder instance containing an HQL query to execute
* @return List containing the results of the query
* @throws DataAccessLayerException
* If Hibernate errors occur during execution of the query
*/
public int executeHQLStatement(StringBuilder queryString)
throws DataAccessLayerException {
return executeHQLStatement(queryString.toString(), true, null);
}
/**
* Executes an HQL query with a map of name value pairs with which to
* substitute into the query. This method is a convenience method for
* executing prepared statements
*
* @param <T>
* The return object type
* @param queryString
* The prepared HQL query to execute. This query contains values
* that will be substituted according to the names and values
* found in the params map
* @param params
* The named parameters to substitute into the HQL query
* @return List containing the results of the query
* @throws DataAccessLayerException
* If Hibernate errors occur during the execution of the query
*/
public int executeHQLStatement(String queryString,
Map<String, Object> params) throws DataAccessLayerException {
return executeHQLStatement(queryString, true, params);
}
/**
* Executes an HQL query in an existing Hibernate session
*
* @param <T>
* An object type to query for
* @param queryString
* The query to execute
* @param session
* The existing Hibernate session
* @return The results of the HQL query
* @throws DataAccessLayerException
* if errors are encountered during the HQL query
*/
@SuppressWarnings("unchecked")
public int executeHQLStatement(final String queryString, boolean eager,
final Map<String, Object> params) throws DataAccessLayerException {
try {
Query query = getSessionFactory().getCurrentSession()
.createQuery(queryString).setCacheable(true)
.setCacheRegion(QUERY_CACHE_REGION);
if (params != null) {
for (String name : params.keySet()) {
Object val = params.get(name);
query.setParameter(name, val);
}
}
return query.executeUpdate();
} catch (Throwable e) {
throw new DataAccessLayerException(
"Error executing HQL Statement [" + queryString + "]", e);
}
}
/**
* Executes a criteria query. This method expects a DetachedQuery instance.
* The DetachedQuery is attached to a new session and executed
*
* @param <T>
* An Object type
* @param criteria
* The DetachedCriteria instance to execute
* @return The results of the query
* @throws DataAccessLayerException
* If errors occur in Hibernate while executing the query
*/
@SuppressWarnings("unchecked")
public <T extends Object> List<T> executeCriteriaQuery(
final DetachedCriteria criteria) throws DataAccessLayerException {
if (criteria == null) {
return Collections.emptyList();
}
try {
List<T> results = null;
results = criteria
.getExecutableCriteria(
getSessionFactory().getCurrentSession())
.setCacheable(true).setCacheRegion(QUERY_CACHE_REGION)
.list();
return results;
} catch (Throwable e) {
throw new DataAccessLayerException(
"Error executing Criteria Query", e);
}
}
public void evict(ENTITY entity) {
this.getSessionFactory().getCurrentSession().evict(entity);
}
/**
* Get the hibernate dialect.
*
@ -198,6 +427,10 @@ public abstract class SessionManagedDao<IDENTIFIER extends Serializable, ENTITY
return ((SessionFactoryImpl) template.getSessionFactory()).getDialect();
}
protected SessionFactory getSessionFactory() {
return template.getSessionFactory();
}
/**
* Return the entity class type.
*

View file

@ -6,6 +6,8 @@ import java.util.List;
import java.util.Map;
import java.util.TreeMap;
import javax.annotation.PostConstruct;
import com.google.common.eventbus.Subscribe;
import com.raytheon.uf.common.datadelivery.registry.Network;
import com.raytheon.uf.common.event.EventBus;
@ -33,6 +35,7 @@ import com.raytheon.uf.edex.datadelivery.retrieval.RetrievalManagerNotifyEvent;
* Oct 26, 2012 1286 djohnson Return list of unscheduled allocations.
* Feb 05, 2013 1580 mpduff EventBus refactor.
* Feb 14, 2013 1596 djohnson Warn log when unable to find a SubscriptionRetrieval.
* 3/18/2013 1802 bphillip Event bus registration is now a post-construct operation to ensure proxy is registered with bus
*
* </pre>
*
@ -60,7 +63,10 @@ public class RetrievalManager {
public RetrievalManager(IBandwidthDao bandwidthDao, Object notifier) {
this.bandwidthDao = bandwidthDao;
this.notifier = notifier;
}
@PostConstruct
public void registerWithEventBus() {
EventBus.register(this);
}

View file

@ -21,4 +21,6 @@ Require-Bundle: com.google.guava;bundle-version="1.0.0",
com.raytheon.uf.common.registry.event;bundle-version="1.0.0",
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.util;bundle-version="1.12.1174"
com.raytheon.uf.common.util;bundle-version="1.12.1174",
org.hibernate;bundle-version="1.0.0",
com.raytheon.uf.common.dataplugin;bundle-version="1.12.1174"

View file

@ -8,6 +8,7 @@
<bean id="notificationHandler" class="com.raytheon.uf.edex.datadelivery.event.handler.NotificationHandler">
<constructor-arg type="java.lang.String" value="jms-generic:topic:notify.msg?destinationResolver=#qpidDurableResolver"/>
<property name="notificationDao" ref="notificationDao"/>
</bean>
<!-- verify text product info for site, spawns in separate thread to not delay start up -->

View file

@ -1,43 +1,60 @@
<beans
xmlns="http://www.springframework.org/schema/beans"
xmlns:amq="http://activemq.apache.org/schema/core"
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-2.0.xsd
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:amq="http://activemq.apache.org/schema/core" 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-2.0.xsd
http://activemq.apache.org/schema/core http://activemq.apache.org/schema/core/activemq-core.xsd
http://camel.apache.org/schema/spring http://camel.apache.org/schema/spring/camel-spring.xsd">
<bean id="getNotificationHandler" class="com.raytheon.uf.edex.datadelivery.event.handler.GetNotificationHandler"/>
<bean factory-bean="handlerRegistry" factory-method="register">
<constructor-arg value="com.raytheon.uf.common.datadelivery.event.notification.GetNotificationRequest"/>
<constructor-arg ref="getNotificationHandler"/>
</bean>
<bean id="getNotificationHandler"
class="com.raytheon.uf.edex.datadelivery.event.handler.GetNotificationHandler">
<property name="notificationDao" ref="notificationDao" />
</bean>
<bean factory-bean="handlerRegistry" factory-method="register">
<constructor-arg
value="com.raytheon.uf.common.datadelivery.event.notification.GetNotificationRequest" />
<constructor-arg ref="getNotificationHandler" />
</bean>
<bean id="deleteNotificationHandler" class="com.raytheon.uf.edex.datadelivery.event.handler.DeleteNotificationHandler">
<constructor-arg type="java.lang.String" value="jms-generic:topic:notify.msg" />
</bean>
<bean factory-bean="handlerRegistry" factory-method="register">
<constructor-arg value="com.raytheon.uf.common.datadelivery.event.notification.DeleteNotificationRequest"/>
<constructor-arg ref="deleteNotificationHandler"/>
</bean>
<bean id="deleteNotificationHandler"
class="com.raytheon.uf.edex.datadelivery.event.handler.DeleteNotificationHandler">
<constructor-arg type="java.lang.String" value="jms-generic:topic:notify.msg" />
<property name="notificationDao" ref="notificationDao" />
</bean>
<bean factory-bean="handlerRegistry" factory-method="register">
<constructor-arg
value="com.raytheon.uf.common.datadelivery.event.notification.DeleteNotificationRequest" />
<constructor-arg ref="deleteNotificationHandler" />
</bean>
<bean id="subscriptionNotificationHandler"
class="com.raytheon.uf.edex.datadelivery.event.handler.SubscriptionNotificationHandler">
<constructor-arg type="java.lang.String" value="jms-generic:topic:notify.msg" />
<property name="notificationDao" ref="notificationDao" />
</bean>
<bean factory-bean="handlerRegistry" factory-method="register">
<constructor-arg
value="com.raytheon.uf.common.datadelivery.service.SubscriptionNotificationRequest" />
<constructor-arg ref="subscriptionNotificationHandler" />
</bean>
<bean factory-bean="handlerRegistry" factory-method="register">
<constructor-arg
value="com.raytheon.uf.common.datadelivery.service.ApprovedPendingSubscriptionNotificationRequest" />
<constructor-arg ref="subscriptionNotificationHandler" />
</bean>
<bean factory-bean="handlerRegistry" factory-method="register">
<constructor-arg
value="com.raytheon.uf.common.datadelivery.service.DeniedPendingSubscriptionNotificationRequest" />
<constructor-arg ref="subscriptionNotificationHandler" />
</bean>
<bean factory-bean="handlerRegistry" factory-method="register">
<constructor-arg
value="com.raytheon.uf.common.datadelivery.service.PendingSubscriptionNotificationRequest" />
<constructor-arg ref="subscriptionNotificationHandler" />
</bean>
<bean id="notificationDao"
class="com.raytheon.uf.edex.datadelivery.event.notification.NotificationDao">
<property name="sessionFactory" ref="metadataSessionFactory" />
</bean>
<bean id="subscriptionNotificationHandler" class="com.raytheon.uf.edex.datadelivery.event.handler.SubscriptionNotificationHandler">
<constructor-arg type="java.lang.String" value="jms-generic:topic:notify.msg" />
</bean>
<bean factory-bean="handlerRegistry" factory-method="register">
<constructor-arg value="com.raytheon.uf.common.datadelivery.service.SubscriptionNotificationRequest"/>
<constructor-arg ref="subscriptionNotificationHandler"/>
</bean>
<bean factory-bean="handlerRegistry" factory-method="register">
<constructor-arg value="com.raytheon.uf.common.datadelivery.service.ApprovedPendingSubscriptionNotificationRequest"/>
<constructor-arg ref="subscriptionNotificationHandler"/>
</bean>
<bean factory-bean="handlerRegistry" factory-method="register">
<constructor-arg value="com.raytheon.uf.common.datadelivery.service.DeniedPendingSubscriptionNotificationRequest"/>
<constructor-arg ref="subscriptionNotificationHandler"/>
</bean>
<bean factory-bean="handlerRegistry" factory-method="register">
<constructor-arg value="com.raytheon.uf.common.datadelivery.service.PendingSubscriptionNotificationRequest"/>
<constructor-arg ref="subscriptionNotificationHandler"/>
</bean>
</beans>

View file

@ -1,5 +1,8 @@
package com.raytheon.uf.edex.datadelivery.event.handler;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import com.raytheon.uf.common.datadelivery.event.notification.NotificationRecord;
import com.raytheon.uf.common.serialization.SerializationException;
import com.raytheon.uf.common.serialization.SerializationUtil;
@ -10,16 +13,35 @@ import com.raytheon.uf.edex.core.EdexException;
import com.raytheon.uf.edex.datadelivery.event.notification.NotificationDao;
/**
*
* Abstract class to provide the send and store capabilities to subclasses.
*
* @author jsanchez
* <pre>
*
* SOFTWARE HISTORY
*
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* 3/18/2013 1802 bphillip Implemented transactional boundaries
*
* </pre>
*
* @author djohnson
* @version 1.0
*/
@Service
@Transactional
public abstract class AbstractHandler {
private static final IUFStatusHandler statusHandler = UFStatus
.getHandler(AbstractHandler.class);
protected NotificationDao notificationDao;
protected AbstractHandler() {
}
/**
* Sends the object to 'notifyRoute'.
*
@ -43,9 +65,13 @@ public abstract class AbstractHandler {
*/
void storeAndSend(NotificationRecord record, String endpoint) {
if (record != null) {
NotificationDao dao = new NotificationDao();
dao.persist(record);
notificationDao.createOrUpdate(record);
send(record, endpoint);
}
}
public void setNotificationDao(NotificationDao notificationDao) {
this.notificationDao = notificationDao;
}
}

View file

@ -5,7 +5,6 @@ import com.raytheon.uf.common.datadelivery.event.notification.DeleteNotification
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.datadelivery.event.notification.NotificationDao;
/**
*
@ -18,6 +17,7 @@ import com.raytheon.uf.edex.datadelivery.event.notification.NotificationDao;
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* Mar 7, 2012 jsanchez Initial creation
* 3/18/2013 1802 bphillip Modified to use transactional boundaries and spring injection of daos
*
* </pre>
*
@ -32,6 +32,10 @@ public class DeleteNotificationHandler extends AbstractHandler implements
private String uri;
public DeleteNotificationHandler() {
super();
}
/**
* Create a new object
*
@ -48,8 +52,7 @@ public class DeleteNotificationHandler extends AbstractHandler implements
@Override
public DeleteNotificationResponse handleRequest(
DeleteNotificationRequest request) throws Exception {
NotificationDao dao = new NotificationDao();
int rowsDeleted = dao.deleteRecords(request.getIds());
int rowsDeleted = notificationDao.deleteRecords(request.getIds());
DeleteNotificationResponse response = new DeleteNotificationResponse();
response.setIds(request.getIds());

View file

@ -1,11 +1,10 @@
package com.raytheon.uf.edex.datadelivery.event.handler;
import java.util.ArrayList;
import java.util.List;
import com.raytheon.uf.common.datadelivery.event.notification.GetNotificationRequest;
import com.raytheon.uf.common.datadelivery.event.notification.NotificationRecord;
import com.raytheon.uf.common.serialization.comm.IRequestHandler;
import com.raytheon.uf.edex.datadelivery.event.notification.NotificationDao;
/**
*
@ -18,6 +17,7 @@ import com.raytheon.uf.edex.datadelivery.event.notification.NotificationDao;
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* Mar 7, 2012 jsanchez Initial creation
* 3/18/2013 1802 bphillip Modified to use transactional boundaries and spring injection of daos
*
* </pre>
*
@ -27,16 +27,19 @@ import com.raytheon.uf.edex.datadelivery.event.notification.NotificationDao;
public class GetNotificationHandler extends AbstractHandler implements
IRequestHandler<GetNotificationRequest> {
public GetNotificationHandler() {
super();
}
/**
* Handles request to retrieve Notification records
*/
@Override
public ArrayList<NotificationRecord> handleRequest(
GetNotificationRequest request) throws Exception {
NotificationDao dao = new NotificationDao();
ArrayList<NotificationRecord> notifications = dao.lookupNotifications(
request.getUsername(), request.getHours(),
request.getMaxResults());
public List<NotificationRecord> handleRequest(GetNotificationRequest request)
throws Exception {
List<NotificationRecord> notifications = notificationDao
.lookupNotifications(request.getUsername(), request.getHours(),
request.getMaxResults());
return notifications;
}

View file

@ -1,5 +1,7 @@
package com.raytheon.uf.edex.datadelivery.event.handler;
import javax.annotation.PostConstruct;
import com.google.common.eventbus.AllowConcurrentEvents;
import com.google.common.eventbus.Subscribe;
import com.raytheon.uf.common.datadelivery.event.INotifiableEvent;
@ -26,6 +28,7 @@ import com.raytheon.uf.common.registry.event.RemoveRegistryEvent;
* the method with it as a parameter (i.e. superclass parameter methods receive it too).
* Dec 07, 2012 1104 djohnson Changed to use INotifiableEvent for events with notifications.
* Feb 05, 2013 1580 mpduff EventBus refactor.
* 3/18/2013 1802 bphillip Modified to use transactional boundaries and spring injection of daos
*
* </pre>
*
@ -41,6 +44,11 @@ public class NotificationHandler extends AbstractHandler {
* DataDeliveryEventBus
*/
public NotificationHandler() {
super();
}
@PostConstruct
public void registerWithEventBus() {
EventBus.register(this);
}
@ -50,7 +58,6 @@ public class NotificationHandler extends AbstractHandler {
*/
public NotificationHandler(String endpoint) {
this.endpoint = endpoint;
EventBus.register(this);
}
/**

View file

@ -47,6 +47,7 @@ import com.raytheon.uf.common.status.UFStatus;
* Sep 24, 2012 1157 mpduff Changed to use BaseSubscriptionNotificationRequest.
* Jan 17, 2013 1501 djohnson If a subscription is still in the registry, use it for the notification response.
* Jan 21, 2013 1501 djohnson Throw an exception if subscription is not provided on the request.
* 3/18/2013 1802 bphillip Modified to use transactional boundaries and spring injection of daos
* </pre>
*
* @author mpduff
@ -60,7 +61,11 @@ public class SubscriptionNotificationHandler<T extends Subscription> extends
private static final IUFStatusHandler statusHandler = UFStatus
.getHandler(SubscriptionNotificationHandler.class);
private final String uri;
private String uri;
public SubscriptionNotificationHandler() {
super();
}
/**
* Constructor

View file

@ -1,15 +1,13 @@
package com.raytheon.uf.edex.datadelivery.event.notification;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import com.raytheon.uf.common.datadelivery.event.notification.NotificationRecord;
import com.raytheon.uf.common.dataquery.db.QueryParam.QueryOperand;
import com.raytheon.uf.common.status.UFStatus.Priority;
import com.raytheon.uf.edex.database.DataAccessLayerException;
import com.raytheon.uf.edex.database.dao.CoreDao;
import com.raytheon.uf.edex.database.dao.DaoConfig;
import com.raytheon.uf.edex.database.query.DatabaseQuery;
import com.raytheon.uf.edex.database.dao.SessionManagedDao;
/**
*
@ -22,19 +20,21 @@ import com.raytheon.uf.edex.database.query.DatabaseQuery;
* Date Ticket# Engineer Description
* ------------ ---------- ----------- --------------------------
* Mar 1, 2012 jsanchez Initial creation
* 3/18/2013 1802 bphillip Modified to use transactional boundaries and spring injection of daos
*
* </pre>
*
* @author jsanchez
* @version 1.0
*/
public class NotificationDao extends CoreDao {
public class NotificationDao extends
SessionManagedDao<Integer, NotificationRecord> {
/**
* Creates a new data access object
*/
public NotificationDao() {
super(DaoConfig.forClass("metadata", NotificationRecord.class));
}
/**
@ -50,35 +50,36 @@ public class NotificationDao extends CoreDao {
* @return the Notificaion records based on passed contraints. The records
* are in descending order based on date
*/
public ArrayList<NotificationRecord> lookupNotifications(String username,
public List<NotificationRecord> lookupNotifications(String username,
Integer hours, Integer maxResults) {
DatabaseQuery query = new DatabaseQuery(this.daoClass);
if (username != null) {
query.addQueryParam("username", username, QueryOperand.IN);
}
Map<String, Object> params = new HashMap<String, Object>();
String hql = "from NotificationRecord rec";
String nameClause = " rec.username=:userName ";
String dateClause = " rec.date >= :date ";
Calendar latestTime = null;
if (hours != null) {
Calendar latestTime = Calendar.getInstance();
latestTime = Calendar.getInstance();
latestTime.add(Calendar.HOUR, -hours);
query.addQueryParam("date", latestTime,
QueryOperand.GREATERTHANEQUALS);
}
if (maxResults != null) {
query.setMaxResults(maxResults);
if (username == null && hours != null) {
hql += " where " + dateClause;
params.put("date", latestTime);
} else if (username != null && hours == null) {
hql += " where " + nameClause;
params.put("userName", username);
} else if (username != null && hours != null) {
hql += " where " + nameClause + " and " + dateClause;
params.put("date", latestTime);
params.put("userName", username);
}
hql += " order by rec.date desc";
query.addOrder("date", false);
ArrayList<NotificationRecord> result = null;
try {
result = (ArrayList<NotificationRecord>) queryByCriteria(query);
} catch (DataAccessLayerException e) {
statusHandler.handle(Priority.PROBLEM,
"Error querying notification table", e);
if (maxResults == null) {
return this.query(hql, params);
} else {
return this.query(hql, params, maxResults);
}
return result;
}
/**
@ -91,9 +92,10 @@ public class NotificationDao extends CoreDao {
*/
public int purgeExpiredData(Calendar expiration)
throws DataAccessLayerException {
DatabaseQuery deleteStmt = new DatabaseQuery(this.daoClass);
deleteStmt.addQueryParam("date", expiration, QueryOperand.LESSTHAN);
return this.deleteByCriteria(deleteStmt);
Map<String, Object> params = new HashMap<String, Object>();
params.put("date", expiration);
String hqlStatement = "delete NotificationRecord r where r.date < :date";
return this.executeHQLStatement(hqlStatement, params);
}
/**
@ -103,18 +105,20 @@ public class NotificationDao extends CoreDao {
* the notification ids
* @return the number of rows deleted
*/
public int deleteRecords(ArrayList<Integer> ids)
throws DataAccessLayerException {
StringBuffer sb = new StringBuffer();
for (Integer id : ids) {
if (sb.length() != 0) {
sb.append(",");
}
sb.append(String.valueOf(id.intValue()));
}
public int deleteRecords(List<Integer> ids) throws DataAccessLayerException {
Map<String, Object> params = new HashMap<String, Object>();
params.put("ids", ids);
String hqlStatement = "delete NotificationRecord r where r.id in :ids";
return this.executeHQLStatement(hqlStatement, params);
}
DatabaseQuery deleteStmt = new DatabaseQuery(this.daoClass);
deleteStmt.addQueryParam("id", sb.toString(), QueryOperand.IN);
return this.deleteByCriteria(deleteStmt);
@Override
public NotificationRecord getById(Integer id) {
return super.getById(id);
}
@Override
protected Class<NotificationRecord> getEntityClass() {
return NotificationRecord.class;
}
}

View file

@ -44,6 +44,7 @@ import com.raytheon.uf.edex.datadelivery.retrieval.LinkStore;
import com.raytheon.uf.edex.datadelivery.retrieval.ProviderCollectionLinkStore;
import com.raytheon.uf.edex.datadelivery.retrieval.ServiceFactory;
import com.raytheon.uf.edex.datadelivery.retrieval.ServiceTypeFactory;
import com.raytheon.uf.edex.registry.ebxml.init.RegistryInitializedListener;
/**
* Harvest MetaData
@ -61,6 +62,7 @@ import com.raytheon.uf.edex.datadelivery.retrieval.ServiceTypeFactory;
* Oct 03, 2012 1241 djohnson Use registry handler.
* Nov 09, 2012 1263 dhladky Changed to Site Level
* Feb 05, 2013 1580 mpduff EventBus refactor.
* 3/18/2013 1802 bphillip Modified to insert provider object after database is initialized
*
* </pre>
*
@ -68,7 +70,7 @@ import com.raytheon.uf.edex.datadelivery.retrieval.ServiceTypeFactory;
* @version 1.0
*/
public class CrawlMetaDataHandler {
public class CrawlMetaDataHandler implements RegistryInitializedListener {
public static final String DASH = "-";
@ -140,7 +142,6 @@ public class CrawlMetaDataHandler {
public CrawlMetaDataHandler(CommunicationStrategy communicationStrategy) {
this.communicationStrategy = communicationStrategy;
IPathManager pm = PathManagerFactory.getPathManager();
LocalizationContext lc = pm.getContext(LocalizationType.COMMON_STATIC,
@ -148,6 +149,10 @@ public class CrawlMetaDataHandler {
LocalizationFile lf = pm.getLocalizationFile(lc, PROCESSED_DIR);
timesDir = lf.getFile();
}
public void executeAfterRegistryInit() {
statusHandler
.info("<<<<<<<<<<<<<<<<<<<<< INITIALIZING CRAWL META DATA HANDLER >>>>>>>>>>>>>>>>>>>>>>");
hconfigs = readCrawlConfigs();

Some files were not shown because too many files have changed in this diff Show more