[ 
https://issues.apache.org/jira/browse/MESOS-1465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14026535#comment-14026535
 ] 

Chengwei Yang commented on MESOS-1465:
--------------------------------------

Hi [~bmahler], as I see if {{\-\-num_masters}} was not specified and 
autoInitialization enabled(this is the default behaviour), then we'll get wrong 
clusterSize from quorum, as the code does below
{code}
src/log/recover.cpp:      size_t clusterSize = (2 * quorum) - 1;
{code}

For example, assuming user specified a correct quorum 2, and there are 2 mesos 
masters, however, we'll get clusterSize is 3, then we'll fail at timeout.

It may always fail and we may get many complains from users/operators.

So I'd like to make {{\-\-num_masters}} as mandatory and {{\-\-quorum}} 
optional if replicated log was used. That is

# if {{\-\-quorum}} was not specified, then we get quorum = num_masters / 2 + 1
# else check {{\-\-quorum}} if it's valid and use it as the real quorum, we 
still use num_masters if autoInitialization needed.

About the {{\-\-masters}} option, I think it's some kind of complicated to 
user/operator considering to

# the mesos-start-cluster.sh or mesos-start-masters.sh does check a master 
file, it's more friendly to user/operator I think
# this kind of masters list are known by zookeeper, it may bring extra effort 
to handle the user specified master list and the one known by zookeeper, say 
check consistency?

I'd prefer to use {{\-\-num_masters}} for simplicity.

About the patch, I see it's generally not a big one when talking about the 
visible change to user/operator but really a big one in internal API, The Log 
chain currently only pass {{\-\-quorum}} into and we'll change them to pass 
{{\-\-num_masters}} and {{\-\-quorum}}.

> Use '--nr_of_masters' instead of '--quorum'
> -------------------------------------------
>
>                 Key: MESOS-1465
>                 URL: https://issues.apache.org/jira/browse/MESOS-1465
>             Project: Mesos
>          Issue Type: Improvement
>          Components: master
>    Affects Versions: 0.20.0
>         Environment: master branch HEAD
> commit 5172630ae73b7c5f21e1d0e1840a3dc676816582
> Author: Benjamin Mahler <[email protected]>
> Date:   Thu Jun 5 09:49:40 2014 -0700
>     Added "implicit" reconciliation.
>     
>     Review: https://reviews.apache.org/r/22268
>            Reporter: Chengwei Yang
>            Assignee: Chengwei Yang
>
> --quorum option introduced for log replication when zookeeper used. Log 
> replication is a great feature.
> However, '--quorum' is not very fit into, considering to below:
> # when using with zookeeper, user may confusing with quorum in zookeeper
> # user need to learn how quorum works, why it's necessary.
> While use '--nr_of_masters', the user is definitely know how many mesos 
> masters in his/her clusters. It's quite simple and straight-forward.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to