-
Notifications
You must be signed in to change notification settings - Fork 10
Developer Guide
The quickest way to setup a development environment for TickTock is to run the official TickTock developer's container. You will need to install Docker Engine first. Assuming the Docker Engine is already installed, run
docker run -td --name tt-dev -h tt -p 3000:3000 -p 6181-6182:6181-6182 ytyou/tt-dev:latest
To get on to the Docker container, run,
docker exec -it tt-dev /bin/bash
Once you are inside the Docker container, you can find the TickTock source code under
/home/ticktock/src/ticktock
The code may not be up-to-date. To get the latest code, and build it with appropriate Makefile, e.g., on ubuntu/debian, do
cd /home/ticktock/src/ticktock
git pull
make -f Makefile.ubuntu clean all
To run unit tests,
cd /home/ticktock/src/ticktock
bin/all_tests
To run integration tests, you need to first start the OpenTSDB in the container,
cd /home/ticktock/src/ticktock/scripts
./opentsdb.sh
Now open another terminal, get on the container, and run
cd /home/ticktock/src/ticktock
test/int_test.py
After the integration test is complete, you can stop the OpenTSDB by simply hit Ctrl-C. It will stop the OpenTSDB, but it will not stop the HBase that was started when you started OpenTSDB. To stop the hbase, and cleanup all its data,
cd /home/ticktock/src/ticktock/scripts
./stop-hbase.sh
You have to stop hbase before you can start another run of integration tests, so that no left-over data from last run remains.
To run the TickTock server,
cd /home/ticktock/src/ticktock
bin/tt -c conf/tt.test.conf -d
To send metrics to it,
/opt/tcollector/tcollector start --port 6181
To view metrics in TickTock, point your browser to the docker host at port 3000.
Logs are specified in the config file (e.g., conf/tt.test.conf).
# Logging level
; log.level = INFO
# Log file (full path)
log.file = /tmp/tt/log/ticktock.log
The default log location of ytyou/ticktock:latest docker is /var/lib/ticktock/log/ticktock.log .
Note that you can online update log.level by curl:
curl -XPOST "http://localhost:6182/api/admin?cmd=log&level=debug"
Your log file will output DEBUG level logs without restarting TickTock.
Currently we support CentOS (or Redhat-based OS) and Ubuntu (or Debian-based OS) only.
First, install necessary tools and libraries,
yum install zlib-devel
yum groupinstall "Development Tools"
yum install epel-release (if you need MQTT support)
yum install mosquitto-devel (if you need MQTT support)
Then, under the root directory of the TickTock repo, run
make -f Makefile.centos clean all
Or, if you want to build TickTockDB with MQTT support, run
make -f Makefile.centos clean all EXTRA="-DENABLE_MQTT"
First, install necessary tools and libraries,
apt install zlib1g-dev
apt install build-essential
apt install libmosquitto-dev (if you need MQTT support)
Then, under the root directory of the TickTock repo, run
make -f Makefile.ubuntu clean all
Or, if you want to build TickTockDB with MQTT support, run
make -f Makefile.ubuntu clean all EXTRA="-DENABLE_MQTT"
1. Introduction
1.1 Docker demo
1.2 Success Stories
2. User Guide
2.1 Usage Examples
4.5 TT vs InfluxDB: a) PI-0-w (1, 2), b) OrangePI-zero2, c) RPI4, d) RPI5 query perf
4.6 TT vs OpenTSDB on x86 : cardinality, throughput