Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PR for BXMSDOC-2811: Document new kie-server persistence feature #121

Merged
merged 4 commits into from
Jun 4, 2021
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Expand Up @@ -82,6 +82,7 @@ include::{enterprise-dir}/admin-and-config/configuring-openshift-connection-time

ifdef::PAM[]
include::{enterprise-dir}/admin-and-config/persistence-con.adoc[leveloffset=+1]
include::{enterprise-dir}/admin-and-config/proc-configuring-kie-server-persistence.adoc[leveloffset=+2]
include::{enterprise-dir}/admin-and-config/safe-points-configuring-proc.adoc[leveloffset=+2]
include::{enterprise-dir}/admin-and-config/session-persistence-entities-ref.adoc[leveloffset=+2]
include::{enterprise-dir}/admin-and-config/process-instance-persistence-entities-ref.adoc[leveloffset=+2]
Expand Down
@@ -0,0 +1,63 @@
[id='proc-configuring-kie-server-persistence_{context}']

= Configuring {KIE_SERVER} Persistence

You can configure the {KIE_SERVER} persistence by passing Hibernate or JPA parameters as system properties.

The {KIE_SERVER} can acknowledge the system properties with the following prefixes and you can use every Hibernate or JPA parameters with these prefixes:

* `javax.persistence`
* `hibernate`

.Procedure

. To configure {KIE_SERVER} persistence, complete any of the following tasks:

+
--
If you want to configure {KIE_SERVER} persistence using {EAP} configuration file, complete the following tasks:
kaldesai marked this conversation as resolved.
Show resolved Hide resolved

... In your {PRODUCT} installation directory, navigate to the `standalone-full.xml` file. For example, if you use {EAP} installation for {PRODUCT}, go to `$EAP_HOME/standalone/configuration/standalone-full.xml` file.
kaldesai marked this conversation as resolved.
Show resolved Hide resolved
... Open the `standalone-full.xml` file and under the `<system-properties>` tag, set your Hibernate or JPA parameters as system properties.
+
.Example of configuring {KIE_SERVER} persistence using Hibernate parameters
+
[source,xml,subs="attributes+"]
----
<system-properties>
...
<property name="hibernate.hbm2ddl.auto" value="create-drop"/>
...
<system-properties>
----
+
.Example of configuring {KIE_SERVER} persistence using JPA parameters
+
[source,xml,subs="attributes+"]
----
<system-properties>
...
<property name="javax.persistence.jdbc.url" value="jdbc:mysql://mysql.db.server:3306/my_database?useSSL=false&serverTimezone=UTC"/>
...
<system-properties>
----

If you want to configure {KIE_SERVER} persistence using command line, complete the following tasks:
kaldesai marked this conversation as resolved.
Show resolved Hide resolved

... Pass the parameters directly from the command line using `-Dkey=value` as follows:
kaldesai marked this conversation as resolved.
Show resolved Hide resolved
+
.Example of configuring {KIE_SERVER} persistence using Hibernate parameters:
+
[source]
----
$EAP_HOME/bin/standalone.sh -Dhibernate.hbm2ddl.auto=create-drop
----
+
.Example of configuring {KIE_SERVER} persistence using JPA parameters:
+
[source]
----
$EAP_HOME/bin/standalone.sh -Djavax.persistence.jdbc.url=jdbc:mysql://mysql.db.server:3306/my_database?useSSL=false&serverTimezone=UTC
----

--