WildFly
Introduction
Installing Orbeon Forms on WildFly is only one of the possibilities. You can also install Orbeon Forms on other Servlet containers. You can also use Docker containers. See also:
Versions
WildFly was formerly known as JBoss.
The following instructions should work with recent versions of WildFly.
Deploy Orbeon Forms
To install Orbeon Forms:
For Orbeon Forms PE only, either:
place your license file under
~/.orbeon/license.xml
(see License installation),or add your
license.xml
to theorbeon.war
underWEB-INF/resources/config/license.xml
Start a standalone server with
bin/standalone.sh
Move the
orbeon.war
file into the WildFlystandalone/deployments
folderCheck whether the deployment was successful by watching
standalone/log/server.log
Creating an jboss-deployment-structure.xml
With Orbeon Forms 2018.2.2 and earlier, with some versions of WildFly, a jboss-deployment-structure.xml
under the Orbeon Forms WAR's WEB-INF
directory is needed:
Orbeon Forms 2018.2.3 and later, as well as Orbeon Forms 2019.1, already include this descriptor.
Setup a JDBC datasource
To setup a datasource, if you'd like Orbeon Forms to connect to your relational database, do the following:
Setup Orbeon Forms to use a WildFly datasource (configured in the following steps):
Set the
oxf.fr.persistence.provider.*.*.*
property in yourproperties-local.xml
If you already created a
WEB-INF/resources/config/properties-local.xml
unzip it and add the property per the example below. Otherwise create that file with the following content:Change the value of the property according to the database you're using, setting it either to
oracle
,mysql
,sqlserver
,postgresql
, ordb2
.Update
WEB-INF/resources/config/properties-local.xml
inside theorbeon.war
with the version you edited.
Update the
web.xml
Unzip the
WEB-INF/web.xml
inside theorbeon.war
.Editing
WEB-INF/web.xml
, towards the end of the file, uncomment the following:Inside
<resource-ref>
, replaceoracle
by the name of your database.Update
WEB-INF/web.xml
inside theorbeon.war
with the version you edited.
Update the
jboss-web.xml
Unzip the
WEB-INF/jboss-web.xml
inside theorbeon.war
.Editing
WEB-INF/jboss-web.xml
, uncomment the following:Change the
<res-ref-name>
to match what the<res-ref-name> in your
web.xml`.In
<jndi-name>java:jboss/datasources/oracle</jndi-name>
, replaceoracle
by the database name you used in<res-ref-name>
.Update
WEB-INF/jboss-web.xml
inside theorbeon.war
with the version you edited.
In WildFly, install the JDBC driver:
Download the MySQL JDBC driver, say
oracle-driver.jar
, and place it in thestandalone/deployments
directory.Start the server, and check you see the message
Deployed "oracle-driver.jar" (runtime-name : "oracle-driver.jar")
.
In WildFly, define the datasource:
Editing
standalone/configuration/standalone.xml
, inside the<datasources>
add the following:In the
jndi-name
attribute, replaceoracle
by the name of your database. The value of this attribute must match the value you set earlier inside<jndi-name>
when editing thejboss-web.xml
.In
<connection-url>
, put the JDBC URL to your database.In
<driver>
, put the "runtime-name" of your driver as it shows in the log (it wasoracle-driver.jar
in our example above).In
<security>
, fill in the proper username and password.
Finally, you might want to double check the configuration you just did, ensuring names match across files, per the following diagram.
Last updated