-
Notifications
You must be signed in to change notification settings - Fork 44
Flux setup and initialisation
This page gives details about how to setup Flux cluster.
Flux uses MySQL for storage. To setup mysql database and tables use the below script.
./setup_db.sh
Flux needs two databases in MySQL.
- flux - contains tables StateMachines, States, Events and AuditRecords.
- flux_redriver - contains table ScheduledMessages and used by Redriver.
The relevant schema can be found in flux/persistence-mysql/src/main/resources/flux/migrations
and flux/persistence-mysql/src/main/resources/flux_redriver/migrations
Located at flux/runtime/src/main/resources/packaged/configuration.yml
and contains all flux runtime related configuration like Hibernate, API and Dashboard Jetty servers, Deployment Unit and Redriver configs.
Using system property flux.configurationFile
you can mention the path of the file.
-Dflux.configurationFile = /etc/flux/configuration.yml
Located at flux/task/src/main/resources/application.conf
and contains Akka specific configuration. Akka is used in Flux for task execution.
For cluster setup, change akka.remote.netty.tcp.hostname to current host IP and mention the seed nodes. The seed nodes are configured contact points for initial, automatic, join of the cluster. Refer to Akka Cluster Usage documentation for more details.
Located at flux/runtime/src/main/resources/log4j2.xml
and contains all logging configuration. Using system property log4j.configurationFile
you can mention the path of the file.
-Dlog4j.configurationFile = /etc/flux/log4j2.xml
com.flipkart.flux.initializer.FluxInitializer
is the Flux initialisation class. Run it by specifying the relevant mode or none for a combined runtime.