This repository has been archived by the owner on Jun 24, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 274
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
release-3.1: support tiflash (#1148)
* Support Tiflash (#1119) * add tiflash config * Add tiflash * add deploy tiflash * update * fix some error * fix typo * optimize labels for tiflash * optimize format * reset some config (#1096) * Merge multiple configuration files and add status check (#1102) * update tiflash version (#1118) * Update roles/tiflash/tasks/main.yml * create status dir for all services Co-authored-by: Liangliang Gu <marsishandsome@gmail.com> * rename theflash (#1128) * refactor tiflash config (#1136) * add tiflash proxy status port config (#1140) * tiflash add metrics port (#1144) * add tiflash conf in prometheus for tiflash dashboard (#1146) * add tiflash conf in prometheus for tiflash dashboard Co-authored-by: Liangliang Gu <marsishandsome@gmail.com>
- Loading branch information
1 parent
12ecbaf
commit aa20b24
Showing
25 changed files
with
808 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
# TiKV config template | ||
# Human-readable big numbers: | ||
# File size(based on byte): KB, MB, GB, TB, PB | ||
# e.g.: 1_048_576: "1MB" | ||
# Time(based on ms): ms, s, m, h | ||
# e.g.: 78_000: "1.3m" | ||
|
||
readpool: | ||
storage: | ||
|
||
coprocessor: | ||
|
||
server: | ||
|
||
storage: | ||
|
||
pd: | ||
# This section will be overwritten by command line parameters | ||
|
||
metric: | ||
#address: "172.16.30.31:9531" | ||
#interval: "15s" | ||
#job: "tikv" | ||
|
||
raftstore: | ||
|
||
coprocessor: | ||
|
||
rocksdb: | ||
wal-dir: "" | ||
|
||
defaultcf: | ||
|
||
lockcf: | ||
|
||
writecf: | ||
|
||
raftdb: | ||
defaultcf: | ||
|
||
security: | ||
ca-path: "" | ||
cert-path: "" | ||
key-path: "" | ||
|
||
import: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
--- | ||
|
||
global: | ||
display_name: "TiFlash" | ||
default_profile: "default" | ||
mark_cache_size: 5368709120 | ||
listen_host: "0.0.0.0" | ||
flash: | ||
flash_cluster: | ||
refresh_interval: 20 | ||
update_rule_interval: 5 | ||
master_ttl: 60 | ||
proxy: | ||
|
||
status: | ||
|
||
logger: | ||
count: 20 | ||
size: "1000M" | ||
level: "debug" | ||
application: | ||
runAsDaemon: true | ||
|
||
raft: | ||
storage_engine: "tmt" | ||
|
||
quotas: | ||
default: | ||
interval: | ||
result_rows: 0 | ||
read_rows: 0 | ||
execution_time: 0 | ||
queries: 0 | ||
errors: 0 | ||
duration: 3600 | ||
users: | ||
readonly: | ||
quota: "default" | ||
profile: "readonly" | ||
password: "" | ||
networks: | ||
ip: "::/0" | ||
default: | ||
quota: "default" | ||
profile: "default" | ||
password: "" | ||
networks: | ||
ip: "::/0" | ||
profiles: | ||
readonly: | ||
readonly: 1 | ||
default: | ||
load_balancing: "random" | ||
use_uncompressed_cache: 0 | ||
max_memory_usage: 10000000000 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
--- | ||
|
||
tcp_port: 9000 | ||
http_port: 8123 | ||
interserver_http_port: 9009 | ||
flash_service_port: 3930 | ||
flash_proxy_port: 20170 | ||
flash_proxy_status_port: 20292 | ||
metrics_port: 8234 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
--- | ||
|
||
tiflash_dir: "{{ deploy_dir }}/tiflash" | ||
tmp_path: "{{ deploy_dir }}/tiflash/data/tmp" | ||
path: "{{ deploy_dir }}/tiflash/data/db" | ||
cluster_manager_path: "{{ deploy_dir }}/bin/tiflash/flash_cluster_manager" | ||
cluster_manager_log: "{{ deploy_dir }}/log/tiflash_cluster_manager.log" | ||
tiflash_tikv_log: "{{ deploy_dir }}/log/tiflash_tikv.log" | ||
tiflash_errlog: "{{ deploy_dir }}/log/tiflash_error.log" | ||
tiflash_server_log: "{{ deploy_dir }}/log/tiflash.log" | ||
flash_proxy_config: "{{ deploy_dir }}/conf/tiflash-learner.toml" | ||
data_dir: "{{ deploy_dir }}/tiflash/data/flash" | ||
tiflash_conf_dir: "{{ deploy_dir }}/conf" | ||
tiflash_log_dir: "{{ deploy_dir }}/log" | ||
tiflash_scripts_dir: "{{ deploy_dir }}/scripts" | ||
tcp_port: 9000 | ||
http_port: 8123 | ||
flash_service_port: 3930 | ||
flash_proxy_port: 20170 | ||
flash_proxy_status_port: 20292 | ||
metrics_port: 8234 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
--- | ||
|
||
dependencies: | ||
- role: common_dir |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
--- | ||
|
||
- name: deploy tiflash binary | ||
copy: src="{{ resources_dir }}/bin/tiflash" dest="{{ deploy_dir }}/bin/" mode=0755 backup=yes | ||
register: tiflash_binary | ||
|
||
- name: create run script | ||
template: | ||
src: "{{ item }}_{{ role_name }}_binary.sh.j2" | ||
dest: "{{ deploy_dir }}/scripts/{{ item }}_{{ role_name }}.sh" | ||
mode: "0755" | ||
backup: yes | ||
with_items: | ||
- run | ||
vars: | ||
role_status_dir: status/{{ role_name }} | ||
register: tiflash_script | ||
|
||
- name: backup script file | ||
command: mv "{{ tiflash_script.backup_file }}" "{{ backup_dir }}" | ||
when: tiflash_script.changed and tiflash_script.backup_file is defined | ||
|
||
- include_tasks: "systemd_deployment.yml" |
Oops, something went wrong.