Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/support-4.8' into support-4.8
Browse files Browse the repository at this point in the history
  • Loading branch information
mederly committed Nov 22, 2023
2 parents 1739c31 + bcf0475 commit d61d34f
Show file tree
Hide file tree
Showing 111 changed files with 542 additions and 7,548 deletions.
15 changes: 14 additions & 1 deletion dist/midpoint-api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
</parent>

<artifactId>midpoint-api</artifactId>
<packaging>pom</packaging>
<packaging>jar</packaging>

<name>midPoint API Distribution</name>

Expand Down Expand Up @@ -126,6 +126,19 @@
<skip>true</skip>
</configuration>
</plugin>
<plugin>
<artifactId>maven-install-plugin</artifactId>
<version>3.1.1</version>
<configuration>
<!--
Option needed to avoid error:
The packaging plugin for this project did not assign a main file to the project but it has attachments. Change packaging to 'pom'.
It's available since 3.1.1 (plugin version overridden in this case).
-->
<allowIncompleteProjects>true</allowIncompleteProjects>
</configuration>
</plugin>
</plugins>
</build>
</project>
4 changes: 4 additions & 0 deletions dist/src/main/bin/ninja.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ JAVA_OPTS="${JAVA_OPTS:- }"

JAVA_def_Xms="1g"
JAVA_def_Xmx="2g"
JAVA_def_trustStore="keystore.jceks"
JAVA_def_trustStoreType="jceks"
ENV_MAP_PREFIX="MP_SET_"
ENV_UNMAP_PREFIX="MP_UNSET_"

Expand Down Expand Up @@ -187,6 +189,8 @@ if $(echo "${JAVA_OPTS:-}" | grep -v -q "\-Xms[0-9]"); then
fi

if $(echo "${JAVA_OPTS:-}" | grep -v -q "\-Dmidpoint.home="); then JAVA_OPTS="${JAVA_OPTS:-} -Dmidpoint.home=\"${MIDPOINT_HOME}\""; fi
if $(echo "${JAVA_OPTS:-}" | grep -v -q "\-Djavax.net.ssl.trustStore="); then JAVA_OPTS="${JAVA_OPTS:-} -Djavax.net.ssl.trustStore=\"${MIDPOINT_HOME}/${JAVA_def_trustStore}\""; fi
if $(echo "${JAVA_OPTS:-}" | grep -v -q "\-Djavax.net.ssl.trustStoreType="); then JAVA_OPTS="${JAVA_OPTS:-} -Djavax.net.ssl.trustStoreType=${JAVA_def_trustStoreType}"; fi

# clean up white spaces in case of key/value removal from the original JAVA_OPTS parameter set
JAVA_OPTS="$(echo "${JAVA_OPTS:-}" | tr -s [[:space:]] " " | sed "s/^[[:space:]]//;s/[[:space:]]$//")"
Expand Down
159 changes: 0 additions & 159 deletions docs/admin-gui/self-service/sel-service-before-4.6.adoc

This file was deleted.

22 changes: 12 additions & 10 deletions docs/deployment/ninja/index.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,10 @@ Connection options:
=== midpoint.home connection

This type of connection initialises repository layer of midPoint and operates on top of the database as a new midPoint node.
Mostly only one option is needed and that's specification of `midpoint.home` directory using `-m` option.
This is not sufficient if `config.xml` uses datasource definition.
Ninja then doesn't know how to connect to DB.
For this case one have to use options to specify URL (`-U`), username (`-u`) and password (`-p` or `-P`).
For all commands that communicate with DB layer `midpoint.home` must be specified using `-m <path>` option.
Ninja will try to read database connection information from `config.xml`.
This will not work when there's only datasource definition in `config.xml` (no JDBC url/username/password).
In such chase one have to specify URL (`-U`), username (`-u`) and password (`-p` or `-P`).
These options can also be used to override JDBC URL, username and password specified in `config.xml`.

With bash, you can provide `MIDPOINT_HOME` for the `ninja.sh` command with this shortcut:
Expand All @@ -62,24 +62,26 @@ With bash, you can provide `MIDPOINT_HOME` for the `ninja.sh` command with this
MIDPOINT_HOME=/var/other-mp-home <midpoint>/bin/ninja.sh [general options] [command] [command options]
----

If unbundled JDBC driver is used, it will not be picked up automatically from the midPoint home directory
and you must point Ninja to it explicitly.
=== JDBC Driver

Only JDBC driver that is bundled is for PostgreSQL database.
This means that for other databases, you must provide JDBC driver yourself.
Most of the time JDBC driver is already present in `<midpoint>/lib` directory.
However, it will not be picked up automatically and you must point Ninja to it explicitly.
Example when using `java -jar`:

[source,bash]
----
java -Dloader.path=<jdbc_driver_jar_path> -jar ninja.jar [general options] [command] [command options]
java -Dloader.path=<jdbc_driver_jar_path> -jar ninja.jar [general/connection options] [command] [command options]
----

If the bundled scripts are used, you can specify the path to the driver with `-j` option, for example:

[source,bash]
----
<midpoint>/bin/ninja.sh -j <JDBC_DRIVER_JAR> [general options] [command] [command options]
<midpoint>/bin/ninja.sh -j <jdbc_driver_jar_path> [general/connection options] [command] [command options]
----

// TODO: mention python CLI

== Supported operations

Ninja currently supports these operations:
Expand Down

0 comments on commit d61d34f

Please sign in to comment.