Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support deploying microservice #2377

Merged
merged 4 commits into from
Apr 12, 2024
Merged

Support deploying microservice #2377

merged 4 commits into from
Apr 12, 2024

Conversation

rleungx
Copy link
Member

@rleungx rleungx commented Feb 8, 2024

What problem does this PR solve?

Ref #2429

What is changed and how it works?

Check List

Tests

  • Manual test
# # Global variables are applied to all deployments and used as the default value of
# # the deployments if a specific deployment value is missing.
global:
  user: "tidb"
  ssh_port: 22
  deploy_dir: "/tidb-deploy"
  data_dir: "/tidb-data"
  listen_host: 0.0.0.0
  arch: "amd64"
  pd_mode: "ms"

monitored:
  # # The communication port for reporting system information of each node in the TiDB cluster.
  node_exporter_port: 9200
  # # Blackbox_exporter communication port, used for TiDB cluster port monitoring.
  blackbox_exporter_port: 9215
  # # Storage directory for deployment files, startup scripts, and configuration files of monitoring components.
  # deploy_dir: "/tidb-deploy/monitored-9100"
  # # Data storage directory of monitoring components.
  # data_dir: "/tidb-data/monitored-9100"
  # # Log storage directory of the monitoring component.
  # log_dir: "/tidb-deploy/monitored-9100/log"

# # Server configs are used to specify the configuration of PD Servers.
pd_servers:
  # # The ip address of the PD Server.
  - host: 10.2.8.101
    # # SSH port of the server.
    # ssh_port: 22
    # # PD Server name
    # name: "pd-1"
    # # communication port for TiDB Servers to connect.
    client_port: 22379
    # # Communication port among PD Server nodes.
    peer_port: 22380
    # # PD Server deployment file, startup script, configuration file storage directory.
    # deploy_dir: "/tidb-deploy/pd-2379"
    # # PD Server data storage directory.
    # data_dir: "/tidb-data/pd-2379"
    # # PD Server log file storage directory.
    # log_dir: "/tidb-deploy/pd-2379/log"
    # # numa node bindings.
    # numa_node: "0,1"
    # # The following configs are used to overwrite the `server_configs.pd` values.
    # config:
    #   schedule.max-merge-region-size: 20
    #   schedule.max-merge-region-keys: 200000

# # Server configs are used to specify the configuration of TiDB Servers.
tidb_servers:
  # # The ip address of the TiDB Server.
  - host: 10.2.8.101
    # # SSH port of the server.
    # ssh_port: 22
    # # The port for clients to access the TiDB cluster.
    port: 40000
    # # TiDB Server status API port.
    status_port: 18000
    # # TiDB Server deployment file, startup script, configuration file storage directory.
    # deploy_dir: "/tidb-deploy/tidb-4000"
    # # TiDB Server log file storage directory.
    # log_dir: "/tidb-deploy/tidb-4000/log"

# # Server configs are used to specify the configuration of TiKV Servers.
tikv_servers:
  # # The ip address of the TiKV Server.
  - host: 10.2.8.101
    # # SSH port of the server.
    # ssh_port: 22
    # # TiKV Server communication port.
    port: 22260
    # # TiKV Server status API port.
    status_port: 22280
    # # TiKV Server deployment file, startup script, configuration file storage directory.
    # deploy_dir: "/tidb-deploy/tikv-20160"
    # # TiKV Server data storage directory.
    # data_dir: "/tidb-data/tikv-20160"
    # # TiKV Server log file storage directory.
    # log_dir: "/tidb-deploy/tikv-20160/log"
    # # The following configs are used to overwrite the `server_configs.tikv` values.
    # config:
    #   log.level: warn

tso_servers:
  - host: 10.2.8.101
    port: 33379

scheduling_servers:
  - host: 10.2.8.101

# # Server configs are used to specify the configuration of Prometheus Server.
monitoring_servers:
  # # The ip address of the Monitoring Server.
  - host: 10.2.8.101
    # # SSH port of the server.
    # ssh_port: 22
    # # Prometheus Service communication port.
    port: 9099
    # # ng-monitoring servive communication port
    ng_port: 22020
    # # Prometheus deployment file, startup script, configuration file storage directory.
    # deploy_dir: "/tidb-deploy/prometheus-8249"
    # # Prometheus data storage directory.
    # data_dir: "/tidb-data/prometheus-8249"
    # # Prometheus log file storage directory.
    # log_dir: "/tidb-deploy/prometheus-8249/log"

# # Server configs are used to specify the configuration of Grafana Servers.
grafana_servers:
  # # The ip address of the Grafana Server.
  - host: 10.2.8.101
    # # Grafana web port (browser access)
    port: 3100
    # # Grafana deployment file, startup script, configuration file storage directory.
    # deploy_dir: /tidb-deploy/grafana-3000
Screenshot 2024-02-28 at 11 20 14

Code changes

  • Has exported function/method change
  • Has exported variable/fields change
  • Has interface methods change
  • Has persistent data change

Side effects

  • Possible performance regression
  • Increased code complexity
  • Breaking backward compatibility

Related changes

  • Need to cherry-pick to the release branch
  • Need to update the documentation

Release notes:

NONE

@ti-chi-bot ti-chi-bot bot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Feb 8, 2024
@codecov-commenter
Copy link

codecov-commenter commented Feb 8, 2024

Codecov Report

Attention: Patch coverage is 9.26573% with 519 lines in your changes are missing coverage. Please review.

Project coverage is 54.89%. Comparing base (6f01692) to head (6ec0e82).
Report is 6 commits behind head on master.

❗ Current head 6ec0e82 differs from pull request most recent head 9218e5b. Consider uploading reports for the commit 9218e5b to get more accurate results

Files Patch % Lines
pkg/cluster/spec/scheduling.go 6.95% 173 Missing and 1 partial ⚠️
pkg/cluster/spec/tso.go 6.95% 173 Missing and 1 partial ⚠️
pkg/cluster/api/pdapi.go 0.00% 117 Missing ⚠️
pkg/cluster/template/scripts/scheduling.go 0.00% 15 Missing ⚠️
pkg/cluster/template/scripts/tso.go 0.00% 15 Missing ⚠️
pkg/cluster/spec/monitoring.go 16.67% 8 Missing and 2 partials ⚠️
pkg/cluster/task/update_meta.go 42.86% 6 Missing and 2 partials ⚠️
pkg/cluster/template/config/prometheus.go 0.00% 6 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2377      +/-   ##
==========================================
- Coverage   55.96%   54.89%   -1.06%     
==========================================
  Files         329      333       +4     
  Lines       35221    35592     +371     
==========================================
- Hits        19709    19538     -171     
- Misses      13141    13712     +571     
+ Partials     2371     2342      -29     
Flag Coverage Δ
cluster 44.43% <9.27%> (-0.81%) ⬇️
dm 25.06% <0.18%> (-0.45%) ⬇️
playground 14.74% <0.00%> (-1.79%) ⬇️
tiup 33.60% <ø> (-0.04%) ⬇️
unittest 21.87% <3.71%> (-0.29%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@rleungx rleungx changed the title Support deploying tso service Support deploying microservice Feb 28, 2024
@ti-chi-bot ti-chi-bot bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Apr 9, 2024
Signed-off-by: Ryan Leung <[email protected]>
Signed-off-by: Ryan Leung <[email protected]>
Signed-off-by: Ryan Leung <[email protected]>
Copy link
Collaborator

@kaaaaaaang kaaaaaaang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@ti-chi-bot ti-chi-bot bot added the lgtm label Apr 12, 2024
Copy link
Contributor

ti-chi-bot bot commented Apr 12, 2024

[LGTM Timeline notifier]

Timeline:

  • 2024-04-12 09:47:46.515755234 +0000 UTC m=+1214928.043295783: ☑️ agreed by kaaaaaaang.

@kaaaaaaang
Copy link
Collaborator

/approve

Copy link
Contributor

ti-chi-bot bot commented Apr 12, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: kaaaaaaang

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ti-chi-bot ti-chi-bot bot added approved and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. labels Apr 12, 2024
@ti-chi-bot ti-chi-bot bot merged commit 2c38be7 into pingcap:master Apr 12, 2024
19 checks passed
@rleungx rleungx deleted the tso branch April 15, 2024 03:49
@kaaaaaaang kaaaaaaang added this to the v1.16.0 milestone Jun 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants