opencurve / curve

Curve is a sandbox project hosted by the CNCF Foundation. It's cloud-native, high-performance, and easy to operate. Curve is an open-source distributed storage system for block and shared file storage.
https://opencurve.io
Apache License 2.0
2.32k stars 521 forks source link

bs target #2976

Closed wsehjk closed 8 months ago

wsehjk commented 8 months ago

What problem does this PR solve?

Issue Number: #2564

Problem Summary:

What is changed and how it works?

What's Changed: add target/target.go, How it Works: this command is dependent on two command: curve bs status cluster and curve bs status client Side effects(Breaking backward compatibility? Performance regression?): No side effects found command output:

[
  {
    "label": {
      "job": "etcd"
    },
    "targets": [
      "172.21.0.13:23790",
      "172.21.0.13:23791",
      "172.21.0.13:23792"
    ]
  },
  {
    "label": {
      "job": "mds"
    },
    "targets": [
      "172.21.0.13:6700",
      "172.21.0.13:6701",
      "172.21.0.13:6702"
    ]
  },
  {
    "label": {
      "job": "chunkserver"
    },
    "targets": [
      "172.21.0.13:8200",
      "172.21.0.13:8202",
      "172.21.0.13:8201"
    ]
  },
  {
    "label": {
      "job": "snapshotcloneserver"
    },
    "targets": [
      "172.21.0.13:5550",
      "172.21.0.13:5551",
      "172.21.0.13:5552"
    ]
  },
  {
    "label": {
      "job": "client"
    },
    "targets": [
      "172.21.0.13:9000"
    ]
  }
]

Check List

caoxianfei1 commented 8 months ago

@wsehjk you should squash to one commit and modify the commit message is meaningful.

caoxianfei1 commented 8 months ago

cicheck

montaguelhz commented 8 months ago

It is better to show the results of your test.

montaguelhz commented 8 months ago

cicheck

caoxianfei1 commented 8 months ago

The commit message suggestion: Feat/tool: support export cluster targets for monitor.

caoxianfei1 commented 8 months ago

The command can generate a target.json file is better. And the default path is current directory.

wsehjk commented 8 months ago

cicheck

wsehjk commented 8 months ago

cicheck

wsehjk commented 8 months ago

cicheck

wsehjk commented 8 months ago

cicheck

wsehjk commented 8 months ago

cicheck

montaguelhz commented 8 months ago

cicheck

wsehjk commented 8 months ago

cicheck

wsehjk commented 8 months ago

cicheck

wsehjk commented 8 months ago

cicheck

wsehjk commented 8 months ago

cicheck

wsehjk commented 8 months ago

cicheck

wsehjk commented 8 months ago

cicheck