Fluid Topics Configuration Validator - Fluid Topics - 3.6

Install Fluid Topics on a Single Server

Product
Fluid Topics
FT_Version
3.6
Platform
Debian
Category
Technical Notes

From Fluid Topics version 3.4.25, a new Fluid Topics Configuration Validator tool is available.

The Fluid Topics Configuration Validator is able to validate both multi-portal and legacy configurations.

It performs the exact same validation as the portal does when opening a tenant, in the errors that can be displayed in the 500 error page.

The command is available in the antidot-fluidtopics-conf-validator package, which is a dependency of antidot-fluidtopics-standalone, and is installed in /usr/local/afs7/Fluid-Topics/conf-validator/

This command can be used to validate a single configuration file or a whole configuration directory.

The validation is only performed on *.conf.json files.

Command template:

/usr/local/afs7/Fluid-Topics/conf-validator/fluid-topics-conf-validator [-t {AUTO_DETECT,UNKNOWN,MAIN,MONGO,WS,VHOST,GROUPS,ROOT,ANALYTICS}] [-l {AUTO_DETECT,LEGACY,MODERN}] [-f {HUMAN_READABLE,JSON}] file_or_directory

Where file_or_directory is the configuration file or directory. When a directory is provided, only the known configuration file names are considered.

Command arguments:

  • -t: Expects the configuration type among the following list:
    • AUTO_DETECT (default): the validation is guessed based on the filename.
    • MAIN for the conf.json file
    • MONGO for the mongo.conf.json file
    • WS for the ws.conf.json file
    • VHOST for the vhost.conf.json file
    • GROUPS for the groups.conf.json file
    • ROOT for the root.conf.json file
    • ANALYTICS for the analytics.conf.json file

      It can be useful to force a validation type if the filename is a custom one, e.g., conf_customer_A.json.

      Can also be written --conf-type

  • -l: Defines the layout used for the tenant configuration to validate the configuration among the following list:
    • AUTO_DETECT (default): the validation auto-detects the layout considering the file path, e.g., when a conf directory uses a proper and production-like structure.
    • LEGACY: when the configuration directory and files are structured according to conf/service/status
    • MODERN: when the configuration directory and files are structured according to conf/tenant-id, service/status being defined in the conf.json file

      Can also be written --conf-layout

  • -f: Expects an output format for the validation status among the following list:
    • HUMAN_READABLE (default)
    • JSON

      Can also be written --output-format

  • -h: Displays the help and lists all available optional arguments for the command. Can also be written --help

Examples

  • The following command allows to check all *.conf.json files available in the /usr/local/afs7/Fluid-Topics/conf directory:

    As root user

    /usr/local/afs7/Fluid-Topics/conf-validator/fluid-topics-conf-validator /usr/local/afs7/Fluid-Topics/conf

  • The following command allows to check the mongo-prod34.conf.json file according to the mongo.conf.json type:

    As root user

    /usr/local/afs7/Fluid-Topics/conf-validator/fluid-topics-conf-validator --conf-type MONGO mongo-prod34.conf.json

  • The following command allows to check the conf.json file located in a service/status/conf directory according to modern layout:

    As root user

    /usr/local/afs7/Fluid-Topics/conf-validator/fluid-topics-conf-validator --conf-layout MODERN conf.json