Author: chris.laprun(a)jboss.com
Date: 2007-10-11 19:15:21 -0400 (Thu, 11 Oct 2007)
New Revision: 8606
Added:
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/main/org/jboss/portal/wsrp/admin/ui/QNameConverter.java
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/hibernate/
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/hibernate/consumer/
Removed:
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/hibernate/domain.hbm.xml
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/hibernate/ehcache.xml
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/hibernate/hibernate.cfg.xml
Modified:
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/main/org/jboss/portal/wsrp/admin/ui/ProducerBean.java
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/resources/portal-wsrp-admin-war/WEB-INF/faces-config.xml
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/resources/portal-wsrp-admin-war/WEB-INF/jsf/producer.xhtml
branches/JBoss_Portal_Branch_2_6/wsrp/src/main/org/jboss/portal/wsrp/producer/config/impl/ProducerConfigurationServiceImpl.java
Log:
- JBPORTAL-1715: Added support for adding registration properties (does not work properly
but committing for synchronization purpose: QNameConverter will probably be removed to
avoid CCE with XB).
Modified:
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/main/org/jboss/portal/wsrp/admin/ui/ProducerBean.java
===================================================================
---
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/main/org/jboss/portal/wsrp/admin/ui/ProducerBean.java 2007-10-11
15:40:00 UTC (rev 8605)
+++
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/main/org/jboss/portal/wsrp/admin/ui/ProducerBean.java 2007-10-11
23:15:21 UTC (rev 8606)
@@ -25,6 +25,7 @@
import org.jboss.portal.registration.RegistrationPolicy;
import org.jboss.portal.registration.policies.DefaultRegistrationPolicy;
+import org.jboss.portal.wsrp.WSRPConstants;
import org.jboss.portal.wsrp.producer.config.ProducerConfiguration;
import org.jboss.portal.wsrp.producer.config.ProducerConfigurationService;
import org.jboss.portal.wsrp.producer.config.ProducerRegistrationRequirements;
@@ -47,6 +48,9 @@
private ProducerConfigurationService configurationService;
private String policyClassName;
private String validatorClassName;
+ private static final String PROPERTY = "property";
+ private static int counter = 0;
+ private static final String PRODUCER = "producer";
public ProducerConfigurationService getConfigurationService()
{
@@ -157,6 +161,12 @@
log.debug(e);
beanContext.createErrorMessage("status", "Couldn't save
producer configuration. Cause: " + e.getLocalizedMessage());
}
- return null;
+ return PRODUCER;
}
+
+ public String addRegistrationProperty()
+ {
+ getRegRequirements().addRegistrationProperty(new
RegistrationPropertyDescription(PROPERTY + counter++, WSRPConstants.XSD_STRING));
+ return PRODUCER;
+ }
}
Added:
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/main/org/jboss/portal/wsrp/admin/ui/QNameConverter.java
===================================================================
---
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/main/org/jboss/portal/wsrp/admin/ui/QNameConverter.java
(rev 0)
+++
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/main/org/jboss/portal/wsrp/admin/ui/QNameConverter.java 2007-10-11
23:15:21 UTC (rev 8606)
@@ -0,0 +1,47 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2007, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site:
http://www.fsf.org. *
+ ******************************************************************************/
+
+package org.jboss.portal.wsrp.admin.ui;
+
+import javax.faces.component.UIComponent;
+import javax.faces.context.FacesContext;
+import javax.faces.convert.Converter;
+import javax.xml.namespace.QName;
+
+/**
+ * @author <a href="mailto:chris.laprun@jboss.com">Chris
Laprun</a>
+ * @version $Revision$
+ * @since 2.6.3
+ */
+public class QNameConverter implements Converter
+{
+ public Object getAsObject(FacesContext facesContext, UIComponent uiComponent, String
s)
+ {
+ return s == null ? null : QName.valueOf(s);
+ }
+
+ public String getAsString(FacesContext facesContext, UIComponent uiComponent, Object
o)
+ {
+ return o == null ? null : o.toString();
+ }
+}
Property changes on:
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/main/org/jboss/portal/wsrp/admin/ui/QNameConverter.java
___________________________________________________________________
Name: svn:keywords
+ Author Date Id Revision
Name: svn:eol-style
+ native
Modified:
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/resources/portal-wsrp-admin-war/WEB-INF/faces-config.xml
===================================================================
---
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/resources/portal-wsrp-admin-war/WEB-INF/faces-config.xml 2007-10-11
15:40:00 UTC (rev 8605)
+++
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/resources/portal-wsrp-admin-war/WEB-INF/faces-config.xml 2007-10-11
23:15:21 UTC (rev 8606)
@@ -36,6 +36,10 @@
<converter-for-class>org.jboss.portal.wsrp.registration.LocalizedString</converter-for-class>
<converter-class>org.jboss.portal.wsrp.admin.ui.LocalizedStringConverter</converter-class>
</converter>
+ <converter>
+ <converter-for-class>javax.xml.namespace.QName</converter-for-class>
+
<converter-class>org.jboss.portal.wsrp.admin.ui.QNameConverter</converter-class>
+ </converter>
<managed-bean>
<managed-bean-name>beanContext</managed-bean-name>
@@ -83,7 +87,7 @@
<managed-bean>
<managed-bean-name>producer</managed-bean-name>
<managed-bean-class>org.jboss.portal.wsrp.admin.ui.ProducerBean</managed-bean-class>
- <managed-bean-scope>session</managed-bean-scope>
+ <managed-bean-scope>request</managed-bean-scope>
<managed-property>
<property-name>configurationService</property-name>
<property-class>org.jboss.portal.wsrp.producer.config.ProducerConfigurationService</property-class>
Modified:
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/resources/portal-wsrp-admin-war/WEB-INF/jsf/producer.xhtml
===================================================================
---
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/resources/portal-wsrp-admin-war/WEB-INF/jsf/producer.xhtml 2007-10-11
15:40:00 UTC (rev 8605)
+++
branches/JBoss_Portal_Branch_2_6/core-wsrp/src/resources/portal-wsrp-admin-war/WEB-INF/jsf/producer.xhtml 2007-10-11
23:15:21 UTC (rev 8606)
@@ -56,7 +56,7 @@
headerClass="portlet-section-header">
<h:column>
<f:facet
name="header">Name</f:facet>
- <h:inputText value="#{property.name}"
size="60"/>
+ <h:inputText value="#{property.name}"
size="30"/>
</h:column>
<h:column>
<f:facet
name="header">Type</f:facet>
@@ -66,25 +66,25 @@
</h:column>
<h:column>
<f:facet
name="header">Label</f:facet>
- <h:inputText value="#{property.label}"
size="60"/>
+ <h:inputText value="#{property.label}"
size="50"/>
</h:column>
<h:column>
<f:facet
name="header">Hint</f:facet>
- <h:inputText value="#{property.hint}"
size="60"/>
+ <h:inputText value="#{property.hint}"
size="50"/>
</h:column>
</h:dataTable>
- <h:commandLink
action="#{producer.addRegistrationProperty}" value="Add property"
-
styleClass="portlet-form-button"/>
</c:when>
<c:otherwise>
<h:outputText value="No specified required
registration properties."/>
</c:otherwise>
</c:choose>
+ <h:commandLink
action="#{producer.addRegistrationProperty}" value="Add property"
+ styleClass="portlet-form-button"/>
</h:panelGroup>
</h:panelGroup>
<h:outputText value=" "/>
- <h:commandLink action="#{producer.save}"
value="Save" styleClass="portlet-form-button"/>
+ <h:commandButton action="#{producer.save}"
value="Save" styleClass="portlet-form-button"/>
</h:panelGrid>
</h:form>
Modified:
branches/JBoss_Portal_Branch_2_6/wsrp/src/main/org/jboss/portal/wsrp/producer/config/impl/ProducerConfigurationServiceImpl.java
===================================================================
---
branches/JBoss_Portal_Branch_2_6/wsrp/src/main/org/jboss/portal/wsrp/producer/config/impl/ProducerConfigurationServiceImpl.java 2007-10-11
15:40:00 UTC (rev 8605)
+++
branches/JBoss_Portal_Branch_2_6/wsrp/src/main/org/jboss/portal/wsrp/producer/config/impl/ProducerConfigurationServiceImpl.java 2007-10-11
23:15:21 UTC (rev 8606)
@@ -99,6 +99,11 @@
reloadConfiguration();
}
+ protected void stopService() throws Exception
+ {
+ saveConfiguration();
+ }
+
public void reloadConfiguration() throws Exception
{
URL configURL = getConfigLocationURL();
Copied: branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/hibernate
(from rev 8577,
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/consumer/hibernate)
Deleted:
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/hibernate/domain.hbm.xml
===================================================================
---
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/consumer/hibernate/domain.hbm.xml 2007-10-09
18:59:45 UTC (rev 8577)
+++
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/hibernate/domain.hbm.xml 2007-10-11
23:15:21 UTC (rev 8606)
@@ -1,145 +0,0 @@
-<?xml version="1.0"?>
-<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- ~ JBoss, a division of Red Hat ~
- ~ Copyright 2007, Red Hat Middleware, LLC, and individual ~
- ~ contributors as indicated by the @authors tag. See the ~
- ~ copyright.txt in the distribution for a full listing of ~
- ~ individual contributors. ~
- ~ ~
- ~ This is free software; you can redistribute it and/or modify it ~
- ~ under the terms of the GNU Lesser General Public License as ~
- ~ published by the Free Software Foundation; either version 2.1 of ~
- ~ the License, or (at your option) any later version. ~
- ~ ~
- ~ This software is distributed in the hope that it will be useful, ~
- ~ but WITHOUT ANY WARRANTY; without even the implied warranty of ~
- ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ~
- ~ Lesser General Public License for more details. ~
- ~ ~
- ~ You should have received a copy of the GNU Lesser General Public ~
- ~ License along with this software; if not, write to the Free ~
- ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA ~
- ~ 02110-1301 USA, or see the FSF site:
http://www.fsf.org. ~
- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
-
-<!DOCTYPE hibernate-mapping PUBLIC
- "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
- "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
- <hibernate-mapping>
- <class name="org.jboss.portal.wsrp.consumer.ProducerInfo"
table="JBP_PRODUCER_INFO">
- <cache usage="@portal.hibernate.cache.usage(a)"/>
- <id name="key" column="PK" access="field"
type="java.lang.Long">
- <generator class="native">
- <param name="sequence">wsrpconsumer_seq</param>
- </generator>
- </id>
- <many-to-one name="endpointConfigurationInfo"
- column="ENDPOINT_ID"
-
class="org.jboss.portal.wsrp.consumer.EndpointConfigurationInfo"
- unique="true"
- not-null="true"
- cascade="all"
- lazy="false"/>
- <many-to-one name="registrationInfo"
- column="REGISTRATION_ID"
- class="org.jboss.portal.wsrp.consumer.RegistrationInfo"
- unique="true"
- not-null="false"
- cascade="all"
- lazy="false"/>
- <property name="expirationCacheSeconds"
column="EXPIRATION_CACHE_SECONDS" type="java.lang.Integer"/>
- <property name="active" not-null="true"
column="ACTIVE" type="boolean"/>
- <property name="persistentId" column="PRODUCER_ID"
not-null="true" unique="true" type="java.lang.String"
- access="field"/>
- </class>
-
- <class name="org.jboss.portal.wsrp.consumer.EndpointConfigurationInfo"
table="JBP_ENDPOINT_INFO">
- <cache usage="@portal.hibernate.cache.usage(a)"/>
- <id name="key" column="PK"
type="java.lang.Long">
- <generator class="native">
- <param name="sequence">wsrpconsumer_seq</param>
- </generator>
- </id>
- <property name="serviceDescriptionURL" column="SD_URL"
type="java.lang.String" not-null="true"/>
- <property name="markupURL" column="M_URL"
type="java.lang.String" not-null="true"/>
- <property name="portletManagementURL" column="PM_URL"
type="java.lang.String" not-null="false"/>
- <property name="registrationURL" column="R_URL"
type="java.lang.String" not-null="false"/>
- <property name="wsdlDefinitionURL" column="WSDL_URL"
type="java.lang.String" not-null="false"/>
- </class>
-
- <class name="org.jboss.portal.wsrp.consumer.RegistrationInfo"
table="JBP_REGISTRATION_INFO">
- <cache usage="@portal.hibernate.cache.usage(a)"/>
- <id name="key" column="PK"
type="java.lang.Long">
- <generator class="native">
- <param name="sequence">wsrpconsumer_seq</param>
- </generator>
- </id>
- <property name="consumerName" column="CONSUMER_NAME"
type="java.lang.String" not-null="true"/>
- <property name="registrationHandle" column="HANDLE"
type="java.lang.String"/>
- <property name="registrationState" column="STATE"
type="binary" length="50000000"/>
- <map name="persistentRegistrationProperties"
cascade="all,delete-orphan" lazy="false" access="field">
- <cache usage="@portal.hibernate.cache.usage(a)"/>
- <key column="REG_PK" not-null="true"/>
- <map-key type="string" formula="name"/>
- <one-to-many
class="org.jboss.portal.wsrp.consumer.RegistrationProperty"/>
- </map>
- </class>
-
- <class name="org.jboss.portal.wsrp.consumer.RegistrationProperty"
table="JBP_REG_PROPERTY">
- <cache usage="@portal.hibernate.cache.usage(a)"/>
- <id name="key" column="PK"
type="java.lang.Long">
- <generator class="native">
- <param name="sequence">wsrpconsumer_seq</param>
- </generator>
- </id>
- <property name="name" column="NAME"
type="java.lang.String" not-null="true"/>
- <property name="value" column="VALUE"
type="java.lang.String"/>
- <property name="invalid" column="INVALID"
type="java.lang.Boolean"/>
- <property name="lang" column="LANG"
type="java.lang.String" not-null="true"/>
- <many-to-one
- name="description"
- column="DESC_PK"
-
class="org.jboss.portal.wsrp.registration.RegistrationPropertyDescription"
- unique="true"
- cascade="all"
- lazy="false"/>
- </class>
- <class
name="org.jboss.portal.wsrp.registration.RegistrationPropertyDescription"
table="JBP_REG_PROP_DESC">
- <cache usage="@portal.hibernate.cache.usage(a)"/>
- <id name="key" column="PK"
type="java.lang.Long">
- <generator class="native">
- <param name="sequence">portlet_seq</param>
- </generator>
- </id>
- <property name="name" column="NAME"
type="org.jboss.portal.jems.hibernate.QNameUserType"
not-null="true"/>
- <property name="type" column="TYPE"
type="org.jboss.portal.jems.hibernate.QNameUserType"
not-null="true"/>
- <property name="schemaLocation" column="SCHEMA_LOCATION"
type="java.lang.String"/>
- <component name="description"
class="org.jboss.portal.wsrp.registration.LocalizedString">
- <property name="value" column="DESC_VALUE"/>
- <property name="locale" column="DESC_LOCALE"/>
- <property name="resourceName" column="DESC_RES"/>
- </component>
- <component name="hint"
class="org.jboss.portal.wsrp.registration.LocalizedString">
- <property name="value" column="HINT_VALUE"/>
- <property name="locale" column="HINT_LOCALE"/>
- <property name="resourceName" column="HINT_RES"/>
- </component>
- <component name="label"
class="org.jboss.portal.wsrp.registration.LocalizedString">
- <property name="value" column="LABEL_VALUE"/>
- <property name="locale" column="LABEL_LOCALE"/>
- <property name="resourceName" column="LABEL_RES"/>
- </component>
- <array name="usages" table="JBP_REG_PROP_DESC_USAGES"
cascade="all" fetch="join">
- <cache usage="@portal.hibernate.cache.usage(a)"/>
- <key column="PK"/>
- <index column="IDX"/>
- <element column="USAGE" type="java.lang.String"
not-null="true" unique="false"/>
- </array>
- <array name="aliases" table="JBP_REG_PROP_DESC_ALIASES"
cascade="all" fetch="join">
- <cache usage="@portal.hibernate.cache.usage(a)"/>
- <key column="PK"/>
- <index column="IDX"/>
- <element column="ALIAS"
type="org.jboss.portal.jems.hibernate.QNameUserType" not-null="true"
unique="false"/>
- </array>
- </class>
-</hibernate-mapping>
Deleted:
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/hibernate/ehcache.xml
===================================================================
---
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/consumer/hibernate/ehcache.xml 2007-10-09
18:59:45 UTC (rev 8577)
+++
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/hibernate/ehcache.xml 2007-10-11
23:15:21 UTC (rev 8606)
@@ -1,60 +0,0 @@
-<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- ~ JBoss, a division of Red Hat ~
- ~ Copyright 2007, Red Hat Middleware, LLC, and individual ~
- ~ contributors as indicated by the @authors tag. See the ~
- ~ copyright.txt in the distribution for a full listing of ~
- ~ individual contributors. ~
- ~ ~
- ~ This is free software; you can redistribute it and/or modify it ~
- ~ under the terms of the GNU Lesser General Public License as ~
- ~ published by the Free Software Foundation; either version 2.1 of ~
- ~ the License, or (at your option) any later version. ~
- ~ ~
- ~ This software is distributed in the hope that it will be useful, ~
- ~ but WITHOUT ANY WARRANTY; without even the implied warranty of ~
- ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ~
- ~ Lesser General Public License for more details. ~
- ~ ~
- ~ You should have received a copy of the GNU Lesser General Public ~
- ~ License along with this software; if not, write to the Free ~
- ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA ~
- ~ 02110-1301 USA, or see the FSF site:
http://www.fsf.org. ~
- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
-<ehcache>
-
- <!-- Sets the path to the directory where cache .data files are created.
-
- If the path is a Java System Property it is replaced by
- its value in the running VM.
-
- The following properties are translated:
- user.home - User's home directory
- user.dir - User's current working directory
- java.io.tmpdir - Default temp file path -->
- <diskStore path="java.io.tmpdir/wsrpconsumer"/>
-
-
- <!--Default Cache configuration. These will applied to caches programmatically
created through
- the CacheManager.
-
- The following attributes are required for defaultCache:
-
- maxInMemory - Sets the maximum number of objects that will be created in memory
- eternal - Sets whether elements are eternal. If eternal, timeouts are
ignored and the element
- is never expired.
- timeToIdleSeconds - Sets the time to idle for an element before it expires. Is only
used
- if the element is not eternal. Idle time is now - last accessed
time
- timeToLiveSeconds - Sets the time to live for an element before it expires. Is only
used
- if the element is not eternal. TTL is now - creation time
- overflowToDisk - Sets whether elements can overflow to disk when the in-memory
cache
- has reached the maxInMemory limit.
-
- -->
- <defaultCache
- maxElementsInMemory="10000"
- eternal="false"
- timeToIdleSeconds="1800"
- timeToLiveSeconds="1800"
- overflowToDisk="false"
- />
-</ehcache>
\ No newline at end of file
Deleted:
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/hibernate/hibernate.cfg.xml
===================================================================
---
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/consumer/hibernate/hibernate.cfg.xml 2007-10-09
18:59:45 UTC (rev 8577)
+++
branches/JBoss_Portal_Branch_2_6/wsrp/src/resources/portal-wsrp-sar/conf/hibernate/hibernate.cfg.xml 2007-10-11
23:15:21 UTC (rev 8606)
@@ -1,58 +0,0 @@
-<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
- ~ JBoss, a division of Red Hat ~
- ~ Copyright 2007, Red Hat Middleware, LLC, and individual ~
- ~ contributors as indicated by the @authors tag. See the ~
- ~ copyright.txt in the distribution for a full listing of ~
- ~ individual contributors. ~
- ~ ~
- ~ This is free software; you can redistribute it and/or modify it ~
- ~ under the terms of the GNU Lesser General Public License as ~
- ~ published by the Free Software Foundation; either version 2.1 of ~
- ~ the License, or (at your option) any later version. ~
- ~ ~
- ~ This software is distributed in the hope that it will be useful, ~
- ~ but WITHOUT ANY WARRANTY; without even the implied warranty of ~
- ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ~
- ~ Lesser General Public License for more details. ~
- ~ ~
- ~ You should have received a copy of the GNU Lesser General Public ~
- ~ License along with this software; if not, write to the Free ~
- ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA ~
- ~ 02110-1301 USA, or see the FSF site:
http://www.fsf.org. ~
- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
-
-<!DOCTYPE hibernate-configuration PUBLIC
- "-//Hibernate/Hibernate Configuration DTD//EN"
- "http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
-<hibernate-configuration>
- <session-factory>
- <property
name="connection.datasource">java:@portal.datasource.name@</property>
- <property name="show_sql">@portal.sql.show(a)</property>
- <property
name="cache.use_second_level_cache">true</property>
- <property name="cache.use_query_cache">true</property>
-
- <!--
- | Uncomment in clustered mode : use transactional replicated cache
- @portal.single.xml.close@
- <property
name="cache.provider_class">org.jboss.portal.jems.hibernate.JMXTreeCacheProvider</property>
- <property
name="cache.object_name">portal:service=TreeCacheProvider,type=hibernate</property>
- @portal.single.xml.open@
- -->
-
- <!--
- | Comment in clustered mode
- @portal.clustered.xml.close@
- <property
name="cache.provider_configuration_file_resource_path">conf/consumer/hibernate/ehcache.xml</property>
- <property
name="cache.provider_class">org.hibernate.cache.EhCacheProvider</property>
- @portal.clustered.xml.open@
- -->
-
- <!-- Force the dialect instead of using autodetection -->
- <!--
- <property
name="dialect">org.hibernate.dialect.PostgreSQLDialect</property>
- -->
-
- <!-- Mapping files -->
- <mapping resource="conf/consumer/hibernate/domain.hbm.xml"/>
- </session-factory>
-</hibernate-configuration>
\ No newline at end of file