Re: [DISCUSS] PIP-172: Introduce the HEALTH_CHECK command in the binary protocol

2022-07-01 Thread Cong Zhao
Hi Michael, Thanks for your feedback. > What are the use cases where a client needs to know the cluster health > other than for auto-failover? For the time being, I only think of the case of auto-failover. > The question of cluster health is > complicated, given that Pulsar is a distributed sys

Re: [DISCUSS] PIP-172: Introduce the HEALTH_CHECK command in the binary protocol

2022-06-30 Thread Michael Marshall
Thanks for your response Cong Zhao. > I think don't need to handle it, because the client API should be consistent > with the `HEALTH_CHECK` command result, and users can retry it if they need. I think I may be coming at this from a different perspective. A client application does not need to kn

Re: [DISCUSS] PIP-172: Introduce the HEALTH_CHECK command in the binary protocol

2022-06-24 Thread Cong Zhao
Hi Michael, > I think the current PIP might need some clarification on how errors > are handled. For example, if a single broker fails to respond because > it was being restarted, how would the client handle that kind of > failure with this feature? I think don't need to handle it, because the cl

Re: [DISCUSS] PIP-172: Introduce the HEALTH_CHECK command in the binary protocol

2022-06-23 Thread Michael Marshall
Thanks for your replies Cong Zhao. I think the current PIP might need some clarification on how errors are handled. For example, if a single broker fails to respond because it was being restarted, how would the client handle that kind of failure with this feature? > This is a good definition of c

Re: [DISCUSS] PIP-172: Introduce the HEALTH_CHECK command in the binary protocol

2022-06-22 Thread Cong Zhao
Hi Michael, Thanks for your feedback. > I define a client's primary cluster as "healthy" when it is "healthy" for all of its producers and consumers. I define a healthy producer as one that can connect to a topic and publish messages within certain latency and throughput thresholds (configured by

Re: [DISCUSS] PIP-172: Introduce the HEALTH_CHECK command in the binary protocol

2022-06-22 Thread Michael Marshall
I'd like to clarify the motivation for this PIP. My understanding is that the primary motivation is to give clients a robust way to classify a cluster as "healthy". The initial beneficiary of this feature is the auto failover use case. I think the feature makes sense, but before using the broker's

Re: [DISCUSS] PIP-172: Introduce the HEALTH_CHECK command in the binary protocol

2022-06-22 Thread Cong Zhao
Yes, there may have multiple clients request the HC at the same time in the AutoFailover case, so we should add some cache to reduce broker load. On 2022/06/22 12:55:49 Enrico Olivelli wrote: > Il giorno mer 22 giu 2022 alle ore 14:45 Cong Zhao > ha scritto: > > > > Hi Enrico, > > > > > Also, I

Re: [DISCUSS] PIP-172: Introduce the HEALTH_CHECK command in the binary protocol

2022-06-22 Thread Enrico Olivelli
Il giorno mer 22 giu 2022 alle ore 14:45 Cong Zhao ha scritto: > > Hi Enrico, > > > Also, I would like to understand in which usecase you can use the > > binary endpoint and not the HTTP endpoint. > > We can't use the HTTP endpoint when the client did not have the admin auth to > do a health chec

Re: [DISCUSS] PIP-172: Introduce the HEALTH_CHECK command in the binary protocol

2022-06-22 Thread Cong Zhao
Hi Enrico, > Also, I would like to understand in which usecase you can use the > binary endpoint and not the HTTP endpoint. We can't use the HTTP endpoint when the client did not have the admin auth to do a health check. but we need it in some cases such as auto failover on the client-side (htt

Re: [DISCUSS] PIP-172: Introduce the HEALTH_CHECK command in the binary protocol

2022-06-22 Thread Enrico Olivelli
I believe that this proposal is too broad. the PIP reads about: - adding HEALTHCHECK to the binary protocol - add a HEALTHCHECK cache on the broker Also, I would like to understand in which usecase you can use the binary endpoint and not the HTTP endpoint. Health Check is good for scripts and fo

[DISCUSS] PIP-172: Introduce the HEALTH_CHECK command in the binary protocol

2022-06-07 Thread zhaocong
Hello Pulsar Community, Here is a PIP to introduce the HEALTH_CHECK command in the binary protocol. I look forward to your feedback. PIP: https://github.com/apache/pulsar/issues/15859 Thanks, Cong Zhao