Introducing CXT / Installation / Modules / Installing modules / MicroApp configuration parameters

MicroApp configuration parameters

Table of contents

Properties file

Specific to single MicroApps

A Properties file can be used for the configuration of the MicroApp ([microapp_name].properties). In the event of an automatic FirstSpirit update, the settings saved in the Properties file remain unchanged and will not be overwritten or reset. First, a config directory must be created in the class path and then a

/config/[microapp_name].properties 

File must be created. When using a Tomcat, e.g., in the directory

${TOMCAT_HOME}/lib 

The desired parameters can be configured in this file.

Universal for all MicroApps

The universal properties file (cxt-microapps-common.properties) provides a central interface for defining parameters that apply to all MicroApps. This promotes consistent configuration and makes it easier to manage common settings.

It should be mentioned that if a custom properties file is defined for a MicroApp, this custom configuration has priority. This means that values from the custom properties file overwrite the values defined in the universal properties file.

Parameters for all MicroApps

The following configuration parameters have to be defined for all MicroApps:

eureka.client.serviceUrl.defaultZone: URL where MicroApps register on the CXT platform using Eureka.

Example:

eureka.client.serviceUrl.defaultZone=http://cxt_eureka:<change-me-eureka-password>@localhost:8080/cxt-platform/eureka/

cxt.platform.oauth.clientSecret: A password (“client secret”) with which MicroApps authenticate themselves to the CXT platform.

Example:

cxt.platform.oauth.clientSecret=<change-me-cxt-oauth-client-secret> 

cxt.firstspirit-connector.url: URL through which MicroApps receive information about the FirstSpirit server from the CXT platform.

Example:

cxt.firstspirit-connector.url=http://localhost:8080/cxt-platform/firstspirit-connector/

cxt.microapps.external-url: Externally accessible URL that is used to create the complete URL of MicroApps.

Example:

cxt.microapps.external-url=<change-me-external-server-url>

cxt.microapp.status-page.enabled: Activates/deactivates the status pages of MicroApps (optional)

Default value: false

Example:

cxt.microapp.status-page.enabled=true

All these parameters can also be defined in the configuration files of the MicroApps, but as a rule they should only be entered in the cxt-microapps-common.properties file.

Parameter for each MicroApp

All MicroApps can set the following configuration parameters:

eureka.instance.metadata-map.contextTypes: A comma separated list of context types.

Example:

eureka.instance.metadata-map.contextTypes=template,fragment

eureka.instance.metadata-map.supportedClients: A comma separated list of CXT-Clients.

Example:

eureka.instance.metadata-map.contextTypes=fragment-creator,content-creator

eureka.instance.metadata-map.embeddable: States if the MicroApp can be embedded in CXT-Clients.

  • true (Used as default value if the value is not set)
  • false

Example:

eureka.instance.metadata-map.embeddable=false

cxt.platform.connection-cleanup-rate: Defines when the MicroApps close their FS connection (in minutes).

Default value: PT30M (30 minutes)

Example:

cxt.platform.connection-cleanup-rate=PT30M

eureka.instance.metadata-map.asNonModalDialog: States if a MicroApp will be displayed as a non-blocking and movable dialog.

  • false (Used as default value if the value is not set)
  • true

Example:

eureka.instance.metadata-map.asNonModalDialog=true

eureka.instance.metadata-map.initNonModalDialogWidth: Defines the initial width of the MicroApp in pixels. Only applies when eureka.instance.metadata-map.asNonModalDialog has the value true.

Example

eureka.instance.metadata-map.initNonModalDialogWidth=650

Basic example configuration

cxt-microapps-common.properties

eureka.client.serviceUrl.defaultZone=http://cxt_eureka:<change-me-eureka-password>@localhost:8080/cxt-platform/eureka/
cxt.platform.oauth.clientSecret=<change-me-cxt-oauth-client-secret>
cxt.firstspirit-connector.url=http://localhost:8080/cxt-platform/firstspirit-connector/
cxt.microapps.external-url=<change-me-external-server-url>

© 2005 - 2024 Crownpeak Technology GmbH | All rights reserved. | FirstSpirit 2024.13 | Data privacy