> On Aug. 6, 2016, 12:49 a.m., Vinod Kone wrote: > > src/master/master.cpp, lines 6892-6893 > > <https://reviews.apache.org/r/50699/diff/1/?file=1460432#file1460432line6892> > > > > not yours, but lets not have a default case (have an explicit > > TASK_UNKNOWN case that is a no-op) here so that people don't forget to > > update this in the future when they add new statuses.
In this case, we deliberately want to ignore `TASK_UNKNOWN` (since we don't expect to see that status for a task the master knows about). Do you think we should do: ``` case TASK_UNKNOWN: CHECK(false); // Shouldn't happen. ``` Or is there a more idiomatic way to write this? - Neil ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/50699/#review145016 ----------------------------------------------------------- On Aug. 9, 2016, 12:59 a.m., Neil Conway wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/50699/ > ----------------------------------------------------------- > > (Updated Aug. 9, 2016, 12:59 a.m.) > > > Review request for mesos and Vinod Kone. > > > Bugs: MESOS-4049 > https://issues.apache.org/jira/browse/MESOS-4049 > > > Repository: mesos > > > Description > ------- > > TASK_DROPPED, TASK_UNREACHABLE, TASK_GONE, TASK_GONE_BY_OPERATOR, and > TASK_UNKNOWN. These values are intended to replace the existing > TASK_LOST state by offering more fine-grained information on the > current state of a task. These states will only be sent to frameworks > that opt into this new behavior via the PARTITION_AWARE capability. > > Note that this commit doesn't add a master metric for the TASK_UNKNOWN > status, because this is a "default" status reported when the master has > no knowledge of a particular task/agent ID. Hence the number of > "unknown" tasks at any given time is not a well-defined metric. > > > Diffs > ----- > > include/mesos/mesos.proto 6fd8363572ca157ef77004fa4be52dad400fe9c6 > include/mesos/v1/mesos.proto 85468f80379b42426df6a80b4b04075b983fd3ec > src/common/protobuf_utils.cpp 8c4a7264080385789157703b05b42716fb0563b3 > src/examples/disk_full_framework.cpp > ad304fee94d443125a0dec2b2820267c69508621 > src/master/http.cpp 52dd80b856cf2317c0b73ba54bf501696786088d > src/master/master.cpp 0bd1a3490a86fede86a3f5f62ce4745b65aae258 > src/master/metrics.hpp 9d201fcce1c46a890c86a889ab31029f9a061561 > src/master/metrics.cpp 88a752dc2b4b73ccb919e99478b9ea2bd83842a0 > src/tests/master_tests.cpp 398164d09b8ef14f916122ed8780023c4a3cd0f6 > > Diff: https://reviews.apache.org/r/50699/diff/ > > > Testing > ------- > > make check > > > Thanks, > > Neil Conway > >
