You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by Greg Mann <gr...@mesosphere.io> on 2018/07/03 21:40:44 UTC

Re: Review Request 67187: Tested per-framework task state metrics.

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67187/
-----------------------------------------------------------

(Updated July 3, 2018, 9:40 p.m.)


Review request for mesos, Gastón Kleiman and Gilbert Song.


Bugs: MESOS-8847
    https://issues.apache.org/jira/browse/MESOS-8847


Repository: mesos


Description
-------

This patch adds `MasterTest.TaskStateMetrics`, which verifies that
per-framework task state metrics for both terminal and active task
states report correct values, even after agent reregistration.


Diffs (updated)
-----

  src/tests/master_tests.cpp 8e04023ed04e79881e0d323c2e2283bebaf262eb 


Diff: https://reviews.apache.org/r/67187/diff/2/

Changes: https://reviews.apache.org/r/67187/diff/1-2/


Testing
-------

The new test was run ~10,000 times with no failures.


Thanks,

Greg Mann


Re: Review Request 67187: Tested per-framework task state metrics.

Posted by Greg Mann <gr...@mesosphere.io>.

> On July 25, 2018, 9:06 p.m., Gastón Kleiman wrote:
> > src/tests/master_tests.cpp
> > Lines 9113-9117 (patched)
> > <https://reviews.apache.org/r/67187/diff/4/?file=2061407#file2061407line9113>
> >
> >     Can we use the new helpers here?
> >     
> >     ```
> >       testing::Sequence taskSequence1;
> >       Future<TaskStatus> running1;
> >     
> >       EXPECT_CALL(
> >           sched,
> >           statusUpdate(&driver, AllOf(
> >               TaskStatusTaskIdEq(task1.id()),
> >               TaskStatusStateEq(TASK_STARTING))))
> >         .InSequence(taskSequence1)
> >         
> >       EXPECT_CALL(
> >          sched,
> >          statusUpdate(&driver, AllOf(
> >              TaskStatusTaskIdEq(task1.id()),
> >              TaskStatusStateEq(TASK_RUNNING))))
> >        .InSequence(taskSequence1)
> >        .WillOnce(FutureArg<1>(&running1));
> >     ```

Thx for this suggestion!!


- Greg


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67187/#review206466
-----------------------------------------------------------


On July 31, 2018, 12:22 a.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/67187/
> -----------------------------------------------------------
> 
> (Updated July 31, 2018, 12:22 a.m.)
> 
> 
> Review request for mesos, Gastón Kleiman and Gilbert Song.
> 
> 
> Bugs: MESOS-8847
>     https://issues.apache.org/jira/browse/MESOS-8847
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This patch adds `MasterTest.TaskStateMetrics`, which verifies that
> per-framework task state metrics for both terminal and active task
> states report correct values, even after agent reregistration.
> 
> 
> Diffs
> -----
> 
>   src/tests/master_tests.cpp 44b0ac39f87c6415e130c5e7f505428642739311 
> 
> 
> Diff: https://reviews.apache.org/r/67187/diff/7/
> 
> 
> Testing
> -------
> 
> The new test was run ~10,000 times with no failures.
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 67187: Tested per-framework task state metrics.

Posted by Greg Mann <gr...@mesosphere.io>.

> On July 25, 2018, 9:06 p.m., Gastón Kleiman wrote:
> > src/tests/master_tests.cpp
> > Lines 9107 (patched)
> > <https://reviews.apache.org/r/67187/diff/4/?file=2061407#file2061407line9107>
> >
> >     Do we have to specify the resources? I think the defaults should be good.

But the resources are a required parameter for `createTask`?


- Greg


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67187/#review206466
-----------------------------------------------------------


On July 27, 2018, 4:23 p.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/67187/
> -----------------------------------------------------------
> 
> (Updated July 27, 2018, 4:23 p.m.)
> 
> 
> Review request for mesos, Gastón Kleiman and Gilbert Song.
> 
> 
> Bugs: MESOS-8847
>     https://issues.apache.org/jira/browse/MESOS-8847
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This patch adds `MasterTest.TaskStateMetrics`, which verifies that
> per-framework task state metrics for both terminal and active task
> states report correct values, even after agent reregistration.
> 
> 
> Diffs
> -----
> 
>   src/tests/master_tests.cpp 44b0ac39f87c6415e130c5e7f505428642739311 
>   src/tests/mesos.hpp 8142f3f3ab8e4e9230efdcd2e6846d0e0bd293b2 
> 
> 
> Diff: https://reviews.apache.org/r/67187/diff/6/
> 
> 
> Testing
> -------
> 
> The new test was run ~10,000 times with no failures.
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 67187: Tested per-framework task state metrics.

Posted by Gastón Kleiman <ga...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67187/#review206466
-----------------------------------------------------------




src/tests/master_tests.cpp
Lines 9107 (patched)
<https://reviews.apache.org/r/67187/#comment289434>

    Do we have to specify the resources? I think the defaults should be good.



src/tests/master_tests.cpp
Lines 9110-9111 (patched)
<https://reviews.apache.org/r/67187/#comment289436>

    I'd add a comment here saying that we set the filter to 0s to get an offer without having to wait until the filter expires.



src/tests/master_tests.cpp
Lines 9113-9117 (patched)
<https://reviews.apache.org/r/67187/#comment289435>

    Can we use the new helpers here?
    
    ```
      testing::Sequence taskSequence1;
      Future<TaskStatus> running1;
    
      EXPECT_CALL(
          sched,
          statusUpdate(&driver, AllOf(
              TaskStatusTaskIdEq(task1.id()),
              TaskStatusStateEq(TASK_STARTING))))
        .InSequence(taskSequence1)
        
      EXPECT_CALL(
         sched,
         statusUpdate(&driver, AllOf(
             TaskStatusTaskIdEq(task1.id()),
             TaskStatusStateEq(TASK_RUNNING))))
       .InSequence(taskSequence1)
       .WillOnce(FutureArg<1>(&running1));
    ```



src/tests/master_tests.cpp
Lines 9147-9154 (patched)
<https://reviews.apache.org/r/67187/#comment289437>

    Ditto using the "new" awsum helpers =).



src/tests/master_tests.cpp
Lines 9214-9216 (patched)
<https://reviews.apache.org/r/67187/#comment289439>

    Note: this might not be enough to make the agent re-register. This made some of my tests that follow this pattern flaky.
    
    I don't know why this happens, but the test will probably become stable if you add `Clock::resume()` here.


- Gastón Kleiman


On July 17, 2018, 6:46 p.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/67187/
> -----------------------------------------------------------
> 
> (Updated July 17, 2018, 6:46 p.m.)
> 
> 
> Review request for mesos, Gastón Kleiman and Gilbert Song.
> 
> 
> Bugs: MESOS-8847
>     https://issues.apache.org/jira/browse/MESOS-8847
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This patch adds `MasterTest.TaskStateMetrics`, which verifies that
> per-framework task state metrics for both terminal and active task
> states report correct values, even after agent reregistration.
> 
> 
> Diffs
> -----
> 
>   src/tests/master_tests.cpp 8e04023ed04e79881e0d323c2e2283bebaf262eb 
> 
> 
> Diff: https://reviews.apache.org/r/67187/diff/4/
> 
> 
> Testing
> -------
> 
> The new test was run ~10,000 times with no failures.
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 67187: Tested per-framework task state metrics.

Posted by Gastón Kleiman <ga...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67187/#review206468
-----------------------------------------------------------




src/tests/master_tests.cpp
Lines 9185 (patched)
<https://reviews.apache.org/r/67187/#comment289440>

    I think we should verify the metrics at this point too.


- Gastón Kleiman


On July 17, 2018, 6:46 p.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/67187/
> -----------------------------------------------------------
> 
> (Updated July 17, 2018, 6:46 p.m.)
> 
> 
> Review request for mesos, Gastón Kleiman and Gilbert Song.
> 
> 
> Bugs: MESOS-8847
>     https://issues.apache.org/jira/browse/MESOS-8847
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This patch adds `MasterTest.TaskStateMetrics`, which verifies that
> per-framework task state metrics for both terminal and active task
> states report correct values, even after agent reregistration.
> 
> 
> Diffs
> -----
> 
>   src/tests/master_tests.cpp 8e04023ed04e79881e0d323c2e2283bebaf262eb 
> 
> 
> Diff: https://reviews.apache.org/r/67187/diff/4/
> 
> 
> Testing
> -------
> 
> The new test was run ~10,000 times with no failures.
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 67187: Tested per-framework task state metrics.

Posted by Gastón Kleiman <ga...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67187/#review206701
-----------------------------------------------------------


Fix it, then Ship it!





src/tests/master_tests.cpp
Lines 9117 (patched)
<https://reviews.apache.org/r/67187/#comment289773>

    Nit: do we nee the `mesos::internal::` prefix? No other test seems to need it.



src/tests/master_tests.cpp
Lines 9123 (patched)
<https://reviews.apache.org/r/67187/#comment289774>

    Ditto prefix.


- Gastón Kleiman


On July 30, 2018, 6:53 p.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/67187/
> -----------------------------------------------------------
> 
> (Updated July 30, 2018, 6:53 p.m.)
> 
> 
> Review request for mesos, Gastón Kleiman and Gilbert Song.
> 
> 
> Bugs: MESOS-8847
>     https://issues.apache.org/jira/browse/MESOS-8847
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This patch adds `MasterTest.TaskStateMetrics`, which verifies that
> per-framework task state metrics for both terminal and active task
> states report correct values, even after agent reregistration.
> 
> 
> Diffs
> -----
> 
>   src/tests/master_tests.cpp 44b0ac39f87c6415e130c5e7f505428642739311 
> 
> 
> Diff: https://reviews.apache.org/r/67187/diff/8/
> 
> 
> Testing
> -------
> 
> The new test was run ~10,000 times with no failures.
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 67187: Tested per-framework task state metrics.

Posted by Greg Mann <gr...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67187/
-----------------------------------------------------------

(Updated July 31, 2018, 11:25 p.m.)


Review request for mesos, Gastón Kleiman and Gilbert Song.


Bugs: MESOS-8847
    https://issues.apache.org/jira/browse/MESOS-8847


Repository: mesos


Description
-------

This patch adds `MasterTest.TaskStateMetrics`, which verifies that
per-framework task state metrics for both terminal and active task
states report correct values, even after agent reregistration.


Diffs (updated)
-----

  src/tests/master_tests.cpp 44b0ac39f87c6415e130c5e7f505428642739311 


Diff: https://reviews.apache.org/r/67187/diff/9/

Changes: https://reviews.apache.org/r/67187/diff/8-9/


Testing
-------

The new test was run ~10,000 times with no failures.


Thanks,

Greg Mann


Re: Review Request 67187: Tested per-framework task state metrics.

Posted by Greg Mann <gr...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67187/
-----------------------------------------------------------

(Updated July 31, 2018, 1:53 a.m.)


Review request for mesos, Gastón Kleiman and Gilbert Song.


Bugs: MESOS-8847
    https://issues.apache.org/jira/browse/MESOS-8847


Repository: mesos


Description
-------

This patch adds `MasterTest.TaskStateMetrics`, which verifies that
per-framework task state metrics for both terminal and active task
states report correct values, even after agent reregistration.


Diffs (updated)
-----

  src/tests/master_tests.cpp 44b0ac39f87c6415e130c5e7f505428642739311 


Diff: https://reviews.apache.org/r/67187/diff/8/

Changes: https://reviews.apache.org/r/67187/diff/7-8/


Testing
-------

The new test was run ~10,000 times with no failures.


Thanks,

Greg Mann


Re: Review Request 67187: Tested per-framework task state metrics.

Posted by Greg Mann <gr...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67187/
-----------------------------------------------------------

(Updated July 31, 2018, 12:22 a.m.)


Review request for mesos, Gastón Kleiman and Gilbert Song.


Bugs: MESOS-8847
    https://issues.apache.org/jira/browse/MESOS-8847


Repository: mesos


Description
-------

This patch adds `MasterTest.TaskStateMetrics`, which verifies that
per-framework task state metrics for both terminal and active task
states report correct values, even after agent reregistration.


Diffs (updated)
-----

  src/tests/master_tests.cpp 44b0ac39f87c6415e130c5e7f505428642739311 


Diff: https://reviews.apache.org/r/67187/diff/7/

Changes: https://reviews.apache.org/r/67187/diff/6-7/


Testing
-------

The new test was run ~10,000 times with no failures.


Thanks,

Greg Mann


Re: Review Request 67187: Tested per-framework task state metrics.

Posted by Greg Mann <gr...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67187/
-----------------------------------------------------------

(Updated July 27, 2018, 4:23 p.m.)


Review request for mesos, Gastón Kleiman and Gilbert Song.


Bugs: MESOS-8847
    https://issues.apache.org/jira/browse/MESOS-8847


Repository: mesos


Description
-------

This patch adds `MasterTest.TaskStateMetrics`, which verifies that
per-framework task state metrics for both terminal and active task
states report correct values, even after agent reregistration.


Diffs (updated)
-----

  src/tests/master_tests.cpp 44b0ac39f87c6415e130c5e7f505428642739311 
  src/tests/mesos.hpp 8142f3f3ab8e4e9230efdcd2e6846d0e0bd293b2 


Diff: https://reviews.apache.org/r/67187/diff/6/

Changes: https://reviews.apache.org/r/67187/diff/5-6/


Testing
-------

The new test was run ~10,000 times with no failures.


Thanks,

Greg Mann


Re: Review Request 67187: Tested per-framework task state metrics.

Posted by Greg Mann <gr...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67187/
-----------------------------------------------------------

(Updated July 27, 2018, 4:16 p.m.)


Review request for mesos, Gastón Kleiman and Gilbert Song.


Bugs: MESOS-8847
    https://issues.apache.org/jira/browse/MESOS-8847


Repository: mesos


Description
-------

This patch adds `MasterTest.TaskStateMetrics`, which verifies that
per-framework task state metrics for both terminal and active task
states report correct values, even after agent reregistration.


Diffs (updated)
-----

  src/tests/master_tests.cpp 44b0ac39f87c6415e130c5e7f505428642739311 
  src/tests/mesos.hpp 8142f3f3ab8e4e9230efdcd2e6846d0e0bd293b2 


Diff: https://reviews.apache.org/r/67187/diff/5/

Changes: https://reviews.apache.org/r/67187/diff/4-5/


Testing
-------

The new test was run ~10,000 times with no failures.


Thanks,

Greg Mann


Re: Review Request 67187: Tested per-framework task state metrics.

Posted by Greg Mann <gr...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67187/#review206467
-----------------------------------------------------------




src/tests/master_tests.cpp
Lines 9175-9181 (patched)
<https://reviews.apache.org/r/67187/#comment289438>

    How can we prevent a possible race here?


- Greg Mann


On July 18, 2018, 1:46 a.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/67187/
> -----------------------------------------------------------
> 
> (Updated July 18, 2018, 1:46 a.m.)
> 
> 
> Review request for mesos, Gastón Kleiman and Gilbert Song.
> 
> 
> Bugs: MESOS-8847
>     https://issues.apache.org/jira/browse/MESOS-8847
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This patch adds `MasterTest.TaskStateMetrics`, which verifies that
> per-framework task state metrics for both terminal and active task
> states report correct values, even after agent reregistration.
> 
> 
> Diffs
> -----
> 
>   src/tests/master_tests.cpp 8e04023ed04e79881e0d323c2e2283bebaf262eb 
> 
> 
> Diff: https://reviews.apache.org/r/67187/diff/4/
> 
> 
> Testing
> -------
> 
> The new test was run ~10,000 times with no failures.
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 67187: Tested per-framework task state metrics.

Posted by Greg Mann <gr...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67187/
-----------------------------------------------------------

(Updated July 18, 2018, 1:46 a.m.)


Review request for mesos, Gastón Kleiman and Gilbert Song.


Changes
-------

Updated metric keys.


Bugs: MESOS-8847
    https://issues.apache.org/jira/browse/MESOS-8847


Repository: mesos


Description
-------

This patch adds `MasterTest.TaskStateMetrics`, which verifies that
per-framework task state metrics for both terminal and active task
states report correct values, even after agent reregistration.


Diffs (updated)
-----

  src/tests/master_tests.cpp 8e04023ed04e79881e0d323c2e2283bebaf262eb 


Diff: https://reviews.apache.org/r/67187/diff/4/

Changes: https://reviews.apache.org/r/67187/diff/3-4/


Testing
-------

The new test was run ~10,000 times with no failures.


Thanks,

Greg Mann


Re: Review Request 67187: Tested per-framework task state metrics.

Posted by Greg Mann <gr...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/67187/
-----------------------------------------------------------

(Updated July 10, 2018, 9:25 p.m.)


Review request for mesos, Gastón Kleiman and Gilbert Song.


Bugs: MESOS-8847
    https://issues.apache.org/jira/browse/MESOS-8847


Repository: mesos


Description
-------

This patch adds `MasterTest.TaskStateMetrics`, which verifies that
per-framework task state metrics for both terminal and active task
states report correct values, even after agent reregistration.


Diffs (updated)
-----

  src/tests/master_tests.cpp 8e04023ed04e79881e0d323c2e2283bebaf262eb 


Diff: https://reviews.apache.org/r/67187/diff/3/

Changes: https://reviews.apache.org/r/67187/diff/2-3/


Testing
-------

The new test was run ~10,000 times with no failures.


Thanks,

Greg Mann