Configuration
With Kattlo you are able to use human readable notation to declare resources migrations and rules.
Table of contents
Initialization
To initialize new Kattlo project you just run the following command:
kattlo init --directory='/path/to/initialize'
Use the --bootstrap-servers to generate the Kattlo config with right Kafka addresses:
kattlo --bootstrap-servers='my-kafka-b1:9092,my-kafka-b2:9092' \
init --directory='/path/to/initialize'
If you suppress the
--directoryoption, the current folder will be initialized.
Available Notations for Human Readable
- name regex pattern
- time: transformed to millis
secondsorsecondminutesorminutehoursorhourdaysorday
- size: transformed to bytes
KiBMiBGiB
- math: transformed to floating point number between
0and1%
For bytes Kattlo uses the quibibyte notation
Examples:
1daywill be transformed in86400000milliseconds2secondsin2000milliseconds1hourin3600000milliseconds1KiBin1024bytes50%in0.5
--config-file
Relative or absolute path to Kattlo’s configuration file.
In the .kattlo.yaml configuration file you may define the following properties or use the init command to generate it.
Example of .kattlo.yaml
rules:
topic:
namePattern: 'your pattern'
# more rules constraints...
--kafka-config-file
Relative or absolute path to Apache Kafka® configuration file used by Kattlo to perform Admin, Producer and Consumer operations.
Created by init command too
You may put the properties described at official documentation.
Example of kafka.properties:
bootstrap.servers=localhost:19092,localhost:29092
client.id=kattlo-cli