Skip to content

Conversation

@zymap
Copy link
Member

@zymap zymap commented Sep 3, 2019

Master issue: #2

output example:

➜  pulsarctl git:(clusters_get_failure_domain) ./pulsarctl cluster get-failure-domain -h
USED FOR:
    This command is used for getting the specified failure domain on the specified cluster.

REQUIRED PERMISSION:
    This command requires super-user permissions.

EXAMPLES:
    #getting the broker list in the <cluster-name> cluster failure domain <domain-name>
    pulsarctl clusters get-failure-domain -n <domain-name> <cluster-name>

OUTPUT:
    #output example
    {
      "brokers" : [
        "failure-broker-A",
        "failure-broker-B",
      ]
    }

    #the cluster name is not specified or the cluster name is specified more than one
    [✖]  only one argument is allowed to be used as a name

    #the specified cluster does not exist in the broker
    [✖]  code: 404 reason: Cluster does not exist

Usage: pulsarctl clusters get-failure-domain [flags]

Aliases: get-failure-domain, gfd

FailureDomain flags:
  -n, --domain-name string   The failure domain name

Common flags:
  -s, --admin-service-url string   The admin web service url that pulsarctl connects to. (default "http://localhost:8080")
  -C, --color string               toggle colorized logs (true,false,fabulous) (default "true")
  -h, --help                       help for this command
  -v, --verbose int                set log level, use 0 to silence, 4 for debugging (default 3)

Use 'pulsarctl clusters get-failure-domain [command] --help' for more information about a command.

@zymap zymap changed the title [WIP] Add command cluster list-failure-domain [WIP] Add command cluster get-failure-domain Sep 3, 2019
@zymap zymap force-pushed the clusters_get_failure_domain branch from 02a31af to 22039c0 Compare September 4, 2019 04:03
@zymap zymap changed the title [WIP] Add command cluster get-failure-domain Add command cluster get-failure-domain Sep 4, 2019
@zymap zymap requested review from sijie and wolfstudy and removed request for sijie September 4, 2019 04:05
@zymap zymap added this to the 0.0.1 milestone Sep 4, 2019

desc.CommandExamples = examples

var out []pulsar.Output
Copy link
Member

Choose a reason for hiding this comment

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

what are the error cases?

Copy link
Member Author

Choose a reason for hiding this comment

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

args error and cluster not found error

@sijie sijie merged commit 04ace9e into master Sep 4, 2019
@sijie sijie deleted the clusters_get_failure_domain branch September 4, 2019 04:45
@sijie sijie mentioned this pull request Sep 4, 2019
29 tasks
tisonkun pushed a commit to tisonkun/pulsar-client-go that referenced this pull request Aug 15, 2023
Master issue: streamnative/pulsarctl#2 

output example:

```
➜  pulsarctl git:(clusters_get_failure_domain) ./pulsarctl cluster get-failure-domain -h
USED FOR:
    This command is used for getting the specified failure domain on the specified cluster.

REQUIRED PERMISSION:
    This command requires super-user permissions.

EXAMPLES:
    #getting the broker list in the <cluster-name> cluster failure domain <domain-name>
    pulsarctl clusters get-failure-domain -n <domain-name> <cluster-name>

OUTPUT:
    #output example
    {
      "brokers" : [
        "failure-broker-A",
        "failure-broker-B",
      ]
    }

    #the cluster name is not specified or the cluster name is specified more than one
    [✖]  only one argument is allowed to be used as a name

    #the specified cluster does not exist in the broker
    [✖]  code: 404 reason: Cluster does not exist

Usage: pulsarctl clusters get-failure-domain [flags]

Aliases: get-failure-domain, gfd

FailureDomain flags:
  -n, --domain-name string   The failure domain name

Common flags:
  -s, --admin-service-url string   The admin web service url that pulsarctl connects to. (default "http://localhost:8080")
  -C, --color string               toggle colorized logs (true,false,fabulous) (default "true")
  -h, --help                       help for this command
  -v, --verbose int                set log level, use 0 to silence, 4 for debugging (default 3)

Use 'pulsarctl clusters get-failure-domain [command] --help' for more information about a command.
```
tisonkun pushed a commit to apache/pulsar-client-go that referenced this pull request Aug 16, 2023
Master issue: streamnative/pulsarctl#2 

output example:

```
➜  pulsarctl git:(clusters_get_failure_domain) ./pulsarctl cluster get-failure-domain -h
USED FOR:
    This command is used for getting the specified failure domain on the specified cluster.

REQUIRED PERMISSION:
    This command requires super-user permissions.

EXAMPLES:
    #getting the broker list in the <cluster-name> cluster failure domain <domain-name>
    pulsarctl clusters get-failure-domain -n <domain-name> <cluster-name>

OUTPUT:
    #output example
    {
      "brokers" : [
        "failure-broker-A",
        "failure-broker-B",
      ]
    }

    #the cluster name is not specified or the cluster name is specified more than one
    [✖]  only one argument is allowed to be used as a name

    #the specified cluster does not exist in the broker
    [✖]  code: 404 reason: Cluster does not exist

Usage: pulsarctl clusters get-failure-domain [flags]

Aliases: get-failure-domain, gfd

FailureDomain flags:
  -n, --domain-name string   The failure domain name

Common flags:
  -s, --admin-service-url string   The admin web service url that pulsarctl connects to. (default "http://localhost:8080")
  -C, --color string               toggle colorized logs (true,false,fabulous) (default "true")
  -h, --help                       help for this command
  -v, --verbose int                set log level, use 0 to silence, 4 for debugging (default 3)

Use 'pulsarctl clusters get-failure-domain [command] --help' for more information about a command.
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants