Skip to content
This repository has been archived by the owner on Jun 24, 2021. It is now read-only.

Commit

Permalink
tiflash add metrics port (#1144) (#1145)
Browse files Browse the repository at this point in the history
  • Loading branch information
marsishandsome committed Feb 17, 2020
1 parent 5ea9307 commit fb2b0b9
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 1 deletion.
2 changes: 2 additions & 0 deletions conf/tiflash.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ flash:
master_ttl: 60
proxy:

status:

logger:
count: 20
size: "1000M"
Expand Down
1 change: 1 addition & 0 deletions group_vars/tiflash_servers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@ interserver_http_port: 9009
flash_service_port: 3930
flash_proxy_port: 20170
flash_proxy_status_port: 20292
metrics_port: 8234
1 change: 1 addition & 0 deletions roles/tiflash/defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,4 @@ http_port: 8123
flash_service_port: 3930
flash_proxy_port: 20170
flash_proxy_status_port: 20292
metrics_port: 8234
2 changes: 1 addition & 1 deletion roles/tiflash/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,4 +63,4 @@

- name: prepare firewalld white list
set_fact:
firewalld_ports: "{{ [tcp_port ~ '/tcp', http_port ~ '/tcp', flash_service_port ~ '/tcp', flash_proxy_port ~ '/tcp', flash_proxy_status_port ~ '/tcp'] + firewalld_ports }}"
firewalld_ports: "{{ [tcp_port ~ '/tcp', http_port ~ '/tcp', flash_service_port ~ '/tcp', flash_proxy_port ~ '/tcp', flash_proxy_status_port ~ '/tcp', metrics_port ~ '/tcp'] + firewalld_ports }}"
8 changes: 8 additions & 0 deletions roles/tiflash/templates/tiflash.toml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,14 @@ config = "{{ flash_proxy_config }}"
{% endif %}
{% endfor %}

[status]
metrics_port = {{ metrics_port }}
{% for item, value in tiflash_conf.profiles | dictsort_by_value_type -%}
{% if value is not mapping -%}
{{ item }} = {{ value | to_json }}
{% endif %}
{% endfor %}

[logger]
errorlog = "{{ tiflash_errlog }}"
log = "{{ tiflash_server_log }}"
Expand Down
2 changes: 2 additions & 0 deletions roles/tiflash/vars/tiflash.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ flash:
master_ttl: 60
proxy:

status:

logger:
count: 20
size: "1000M"
Expand Down

0 comments on commit fb2b0b9

Please sign in to comment.