Change comment:
Rewording
Summary
-
Page properties (3 modified, 0 added, 0 removed)
Details
- Page properties
-
- Title
-
... ... @@ -1,1 +1,1 @@ 1 -HSQL Installation 1 +HSQLDB Installation - Author
-
... ... @@ -1,1 +1,1 @@ 1 -XWiki. VincentMassol1 +XWiki.ManuelSmeria - Content
-
... ... @@ -1,21 +1,20 @@ 1 1 Follow these instructions: 2 2 3 -* HSQL is a very simple database to configure as you don't need to install nor to start it before being able to use it. It comes as a single JAR file named ##hsqldb*.jar##. If your XWiki WAR doesn't have it in ##WEB-INF/lib## you'll need to download it and copy it there. You can download it from the [[HSQLDB web site>>http:// www.hsqldb.org/]] or directly from the [[Maven Central Repository>>http://repo1.maven.org/maven2/hsqldb/hsqldb/]].4 -* Once this is done, you need to tellXWiki to use HSQL and to tell it where the database files will be created. To do this, edit the ##WEB-INF/hibernate.cfg.xml## file where you have expanded the XWiki WAR file and uncomment the HSQLDB part.3 +* HSQLDB is a very simple database to configure as you don't need to install nor to start it before being able to use it. It comes as a single JAR file named ##hsqldb*.jar##. If your XWiki WAR doesn't have it in ##WEB-INF/lib## you'll need to download it and copy it there. You can download it from the [[HSQLDB web site>>http://hsqldb.org/]] or directly from the [[Maven Central Repository>>http://repo1.maven.org/maven2/hsqldb/hsqldb/]]. 4 +* Once this is done, you need to configure XWiki to use HSQLDB and to tell it where the database files will be created. To do this, edit the ##WEB-INF/hibernate.cfg.xml## file where you have expanded the XWiki WAR file and uncommented the HSQLDB part. 5 5 6 6 {{warning}} 7 -If you intend to use HSQLDB in production you should probably tune it for a production usage. If you've installed the XWiki Standalone distribution just be aware that it's not tuned to be production-ready. Also note that you would need to find way to perform backups, live replication, administration tools etc. We would suggest using a more production-ready database such as MySQL or PostgreSQL if you can.7 +If you intend to use HSQLDB in production you should probably tune it for a production usage. If you've installed the XWiki standalone distribution just be aware that it's not tuned to be production-ready. Also note that you would need to find a way to perform backups, live replication, administration tools etc. We would suggest using a more production-ready database such as MySQL or PostgreSQL if you can. 8 8 {{/warning}} 9 9 10 10 = Other optional ideas = 11 11 12 -* You can use a remote HSQLDB database instead of embedding it. 13 -* If you want to use your app server facilities to manage your data sources (generally a better strategy), then 14 -** Put the ##hsqldb*.jar## file into your app server class path instead of in your web app (like in ##$CATALINA_HOME/common/lib##) .15 -** In ##hibernate.cfg.xml##, use the following settings in place of the HSQLDB block in the sample file. youdo not set url, user, etc,here,and leave the provider_class unset (i.e. use the default vlaue), since XWiki's implementation does not handle container-managed data sources. (((12 +* 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 HSQLDB server is using. 13 +* If you want to use your app server facilities to manage your data sources (generally a better strategy), then you must follow these steps: 14 +** Put the ##hsqldb*.jar## file into your app server class path instead of in your web app (like in ##$CATALINA_HOME/common/lib##) 15 +** In ##hibernate.cfg.xml##, use the following settings in place of the HSQLDB block in the sample file. Specifically, do not set the url, user, etc. here and leave the provider_class unset (i.e. use the default value), since XWiki's implementation does not handle container-managed data sources: 16 16 {{code}} 17 17 <property name="connection.datasource">java:/comp/env/jdbc/xwiki</property> 18 18 <property name="dialect">org.hibernate.dialect.HSQLDialect</property> 19 19 {{/code}} 20 -))) 21 -** Then you manage the data source using app server facilities. With Tomcat, for example, you would map the //resource link// ##jcbc/xwikiDs## to a container-managed data source using the Admin web app or by editing the file ##conf/Catalina/*/xwiki.xml## (i.e. webapp-name + ".xml"). 20 +** the final step is to manage the data source using app server facilities. With Tomcat, for example, you would map the //resource link// ##jcbc/xwikiDs## to a container-managed data source using the Admin web app or by editing the file ##conf/Catalina/*/xwiki.xml## (i.e. webapp-name + ".xml").