[
https://issues.apache.org/jira/browse/MESOS-8463?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16357317#comment-16357317
]
Till Toenshoff edited comment on MESOS-8463 at 2/8/18 6:00 PM:
---------------------------------------------------------------
This was fixed before on some of the allocator tests, but not all - I wonder
why not all of them?
Note that the agent registers after a backoff delay.
1. pause the timer
2. advance the timer after the slave-startup by the authentication
backoff-factor + registration backoff-factor
3. expect at least one {{addSlave}} on the allocator - but not exactly one -
{{WillOnce(DoAll(InvokeAddSlave(&allocator);}} could do here
(4.) satisfy a future during the {{addSlave}} invocation to allow explicit
waiting for that event on the allocator -- this could ease the stress on later
awaits and hence would increase the sturdynes
For the scheduler registration, we need to do similar things - however without
advancing the timer as we dont need to cover a backoff
2. expect at least one {{addFramework}} on the allocator - but again not
exactly one
(3.) satisfy a future during the {{addFramework}} invocation to allow explicit
waiting for that event on the allocator
was (Author: tillt):
This was fixed before on some of the allocator tests, but not all - I wonder
why not all of them?
Note that the agent registers after a backoff delay.
1. pause the timer
2. advance the timer after the slave-startup by the authentication
backoff-factor + registration backoff-factor
3. expect at least one {{addSlave}} on the allocator - but not exactly one -
{{WillOnce(DoAll(InvokeAddSlave(&allocator);}} could do here
(4.) satisfy a future during the `addSlave` invocation to allow explicit
waiting for that event on the allocator -- this could ease the stress on later
awaits and hence would increase the sturdynes
For the scheduler registration, we need to do similar things - however without
advancing the timer as we dont need to cover a backoff
2. expect at least one {{addFramework}} on the allocator - but again not
exactly one
(3.) satisfy a future during the `addFramework` invocation to allow explicit
waiting for that event on the allocator -- this could ease the stress on later
awaits and hence would increase the sturdynes
> Test MasterAllocatorTest/1.SingleFramework is flaky
> ---------------------------------------------------
>
> Key: MESOS-8463
> URL: https://issues.apache.org/jira/browse/MESOS-8463
> Project: Mesos
> Issue Type: Bug
> Components: allocation, test
> Affects Versions: 1.5.0
> Reporter: Benjamin Bannier
> Assignee: Till Toenshoff
> Priority: Major
> Labels: flaky-test
> Attachments: consoleText.txt
>
>
> Observed in our internal CI on a ubuntu-16 setup in a plain autotools build,
> {noformat}
> ../../src/tests/master_allocator_tests.cpp:175
> Mock function called more times than expected - taking default action
> specified at:
> ../../src/tests/allocator.hpp:273:
> Function call: addSlave(@0x7fe8dc03d0e8
> 1eb6ab2c-293d-4b99-b76b-87bd939a1a19-S1, @0x7fe8dc03d108 hostname:
> "ip-172-16-10-65.ec2.internal"
> resources {
> name: "cpus"
> type: SCALAR
> scalar {
> value: 2
> }
> }
> resources {
> name: "mem"
> type: SCALAR
> scalar {
> value: 1024
> }
> }
> resources {
> name: "ports"
> type: RANGES
> ranges {
> range {
> begin: 31000
> end: 32000
> }
> }
> }
> id {
> value: "1eb6ab2c-293d-4b99-b76b-87bd939a1a19-S1"
> }
> checkpoint: true
> port: 40262
> , @0x7fe8ffa276c0 { 32-byte object <48-94 7D-0E E9-7F 00-00 00-00 00-00 00-00
> 00-00 01-00 00-00 00-00 00-00 01-00 00-00 00-00 00-00>, 32-byte object <48-94
> 7D-0E E9-7F 00-00 00-00 00-00 00-00 00-00 01-00 00-00 00-00 00-00 02-00 00-00
> 00-00 00-00>, 32-byte object <48-94 7D-0E E9-7F 00-00 00-00 00-00 00-00 00-00
> 01-00 00-00 00-00 00-00 03-00 00-00 73-79 73-74> }, @0x7fe8ffa27720 48-byte
> object <01-00 00-00 E8-7F 00-00 00-00 00-00 00-00 00-00 00-00 00-00 00-00
> 00-00 08-7A A2-FF E8-7F 00-00 A0-32 24-7D 62-55 00-00 DE-3C 11-0A E9-7F
> 00-00>, @0x7fe8dc03d4c8 { cpus:2, mem:1024, ports:[31000-32000] },
> @0x7fe8dc03d460 {})
> Expected: to be called once
> Actual: called twice - over-saturated and active
> Stacktrace
> ../../src/tests/master_allocator_tests.cpp:175
> Mock function called more times than expected - taking default action
> specified at:
> ../../src/tests/allocator.hpp:273:
> Function call: addSlave(@0x7fe8dc03d0e8
> 1eb6ab2c-293d-4b99-b76b-87bd939a1a19-S1, @0x7fe8dc03d108 hostname:
> "ip-172-16-10-65.ec2.internal"
> resources {
> name: "cpus"
> type: SCALAR
> scalar {
> value: 2
> }
> }
> resources {
> name: "mem"
> type: SCALAR
> scalar {
> value: 1024
> }
> }
> resources {
> name: "ports"
> type: RANGES
> ranges {
> range {
> begin: 31000
> end: 32000
> }
> }
> }
> id {
> value: "1eb6ab2c-293d-4b99-b76b-87bd939a1a19-S1"
> }
> checkpoint: true
> port: 40262
> , @0x7fe8ffa276c0 { 32-byte object <48-94 7D-0E E9-7F 00-00 00-00 00-00 00-00
> 00-00 01-00 00-00 00-00 00-00 01-00 00-00 00-00 00-00>, 32-byte object <48-94
> 7D-0E E9-7F 00-00 00-00 00-00 00-00 00-00 01-00 00-00 00-00 00-00 02-00 00-00
> 00-00 00-00>, 32-byte object <48-94 7D-0E E9-7F 00-00 00-00 00-00 00-00 00-00
> 01-00 00-00 00-00 00-00 03-00 00-00 73-79 73-74> }, @0x7fe8ffa27720 48-byte
> object <01-00 00-00 E8-7F 00-00 00-00 00-00 00-00 00-00 00-00 00-00 00-00
> 00-00 08-7A A2-FF E8-7F 00-00 A0-32 24-7D 62-55 00-00 DE-3C 11-0A E9-7F
> 00-00>, @0x7fe8dc03d4c8 { cpus:2, mem:1024, ports:[31000-32000] },
> @0x7fe8dc03d460 {})
> Expected: to be called once
> Actual: called twice - over-saturated and active
> {noformat}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)