<
From version < 5.1 >
edited by blaine
on 2008/06/20
To version < 6.1 >
edited by blaine
on 2008/06/20
>
Change comment: Updated after testing a work-around

Summary

Details

Page properties
Content
... ... @@ -15,13 +15,14 @@
15 15  
16 16  where <tt>\[DATABASE_LOCATION\]</tt> is where you wish to put the HSQL database. For example <tt>/apps/xwiki-database/xwiki</tt>.
17 17  * You can use a remote HSQLDB database instead of embedding it. To do this, just use a URL like "jdbc:hsqldb:hsql:HOSTNAME..." instead of the "jdbcc:hsqldb:file:.." URL. The major version of the hsqldb jar file must match the major version that the HyperSQL server is using.
18 -* *Xwiki does not handle container-managed data sources*, as intended by Hibernate. This is due to bad assumptions in the class <tt>com.xpn.xwiki.store.DBCPConnectionProvider</tt>.
19 -<!-- ENABLE THIS IF Xwiki FIXES THEIR DBCP ConnectionProviderFactory IMPLEMENTATION:
20 20  * If you want to use your app server facilities to manage your data sources (generally a better strategy), then
21 21  ** Put the hsqldb*.jar file into your app server class path instead of in your web app (like in <tt>$CATALINA_HOME/common/lib</tt>).
22 -** Use <tt>hibernate.cfg.xml</tt> remove settings for connection.url, connection.username, connection.password, connection.driver_class, and add settings like this:
20 +** In <tt>hibernate.cfg.xml</tt>, use the following settings in place of the HSQLDB block in the sample file. Specifically, you do not set url, user, etc, here, andleave the provider_class unset (i.e. use the default vlaue), since Xwiki's implementation does not handle container-managed data sources.
21 +{code}
22 +<property name="connection.datasource">java:/comp/env/jdbc/xwiki</property>
23 23  <property name="dialect">org.hibernate.dialect.HSQLDialect</property>
24 -<property name="connection.datasource">java:/comp/env/jdbc/xwikiDs</property>
24 +<mapping resource="xwiki.hbm.xml"/>
25 +<mapping resource="feeds.hbm.xml"/>
26 +<mapping resource="activitystream.hbm.xml"/>
25 25  {code}
26 26  ** Then you manage the data source using app server facilities. With Tomcat, for example, you would map the ~~resource link~~ <tt>jcbc/xwikiDs</tt> to a container-managed data source using the Admin web app or by editing the file <tt>conf/Catalina/*/xwiki.xml</tt> (i.e. webapp-name + ".xml").
27 --->

Get Connected