Page History
UI Text Box | ||
---|---|---|
| ||
When a custom implementation is created please keep in mind that Blueriq upgrades may lead to changes in the persistence API, which should be implemented in the custom implementation to avoid loss of functionality (eq. Blueriq plugins who call the API). Where possible we will try to be backwards compatible, but if not possible it may be that the impact of an upgrade is larger then usually. |
UI Text Box | ||
---|---|---|
| ||
We have decided to temporarily deactivate Search in structured and unstructured information in version 10.1 to increase the speed of development of the persistence API. This feature will return in a future release |
The persistence API is part of the Customerdata Client Component.
System requirements
Minimal
2 CPU cores
256 MB Heap
Recommended
2 CPU cores
512 MB Heap
Configuration
The Persistence API is required by the Customerdata Client Component, so when this component is used the following needs to be configured first.
Table of Contents | ||||
---|---|---|---|---|
|
Create database
Scripts to create the required database content are provided for the following databases:
- SQL Server
- Oracle
- H2 (we do not recommend using a H2 database in production environments)
Use the appropriate scripts to create the tables on your database.
Datasource configuration
For the Persistence API to work a datasource needs to be configured in application.yml
. This file is placed in the following folder by the installer: <Blueriq installation folder>\Services\blueriq-customerdata\conf
.
Code Block | ||||
---|---|---|---|---|
| ||||
####################################################################### ## datasource configuration ## ####################################################################### spring: datasource: url: <url> username: <username> password: <password> driver-class-name: org.h2.Driver validation-query: SELECT 1 hibernate: dialect: org.hibernate.dialect.H2Dialect hbm2ddl: auto: validate id: new_generator_mappings: true show_sql: false use_nationalized_character_data: true ####################################################################### ## Security configuration ## ## ## ## Here you can override the default username/password ## ####################################################################### security: user: name: <username> password: <password> |
UI Text Box | ||
---|---|---|
| ||
We recommend setting a validation query so that when a database connection is lost due to a network failure for instance, it can be recovered once the network is restored. The validation query is database specific, the query below works with SQL Server (and H2), for Oracle use |
UI Text Box | ||
---|---|---|
| ||
When using H2, which is not suitable for production environments, the |
Database drivers
Depending on the underlying database, a specific driver needs to be installed on the application server as described on Configuring JDBC database drivers.
Endpoint per aggregate type
Since Blueriq 10.4 it became possible to have different endpoints per aggregate type. To get this working configure the runtime properties as stated in the chapter Runtime properties.
In the schematic overview below is shown how having multiple endpoints per aggregate looks like. The runtime properties has the possibility to have multiple connections per aggregate type, the customerdata properties has the information to which data store the aggregate should be saved to.
Runtime properties
The following properties need to be set in the
Include Page | ||||
---|---|---|---|---|
|
Code Block | ||||
---|---|---|---|---|
| ||||
# Mandatory = default connection for every aggregate that does not have a custom connection blueriq.customerdata-client.url=http://localhost:10097/customerdata/api/v1 blueriq.customerdata-client.username=blueriq blueriq.customerdata-sql-store.odata-serverclient.password=welcome # Optional - Custom connection(s) per aggregate type blueriq.customerdata-client.type.employee.url=http://localhost:1009720097/customerdata/api/v1 blueriq.customerdata-sql-store.odata-serverclient.type.employee.username=blueriq blueriq.customerdata-client.type.employee.password=welcome blueriq.customerdata-client.type.departement.url=http://localhost:30097/customerdata/api/v1 blueriq.customerdata-client.type.departement.username=blueriq blueriq.customerdata-sql-store.odata-serverclient.type.departement.password=welcome |
UI Text Box | ||
---|---|---|
| ||
The properties above contain the default settings, which are set by the Installer. If afterwards these settings are customized in the persistence API they need to be changed in the Runtime as well. |