[SERVER-21955] CleanEveryN hook isn't compatible with MasterSlaveFixture Created: 18/Dec/15  Updated: 16/Nov/16  Resolved: 21/Dec/15

Status: Closed
Project: Core Server
Component/s: Testing Infrastructure
Affects Version/s: 3.2.0
Fix Version/s: 3.2.1, 3.3.0

Type: Bug Priority: Minor - P4
Reporter: Max Hirschhorn Assignee: Max Hirschhorn
Resolution: Done Votes: 0
Labels: test-only
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to SERVER-20899 CleanEveryN hook isn't compatible wit... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Completed:
Steps To Reproduce:

[CleanEveryN:job0] 2015-12-18T15:30:05.134-0500 Starting the fixture back up again...
[executor:js_test:job0] 2015-12-18T15:30:05.139-0500 Encountered an error during test execution.
Traceback (most recent call last):
  File "/home/maxh/debugging/mongo-enterprise/buildscripts/resmokelib/testing/job.py", line 39, in __call__
    self._run(queue, interrupt_flag)
  File "/home/maxh/debugging/mongo-enterprise/buildscripts/resmokelib/testing/job.py", line 70, in _run
    self._execute_test(test)
  File "/home/maxh/debugging/mongo-enterprise/buildscripts/resmokelib/testing/job.py", line 98, in _execute_test
    self._run_hooks_after_tests(test)
  File "/home/maxh/debugging/mongo-enterprise/buildscripts/resmokelib/testing/job.py", line 144, in _run_hooks_after_tests
    hook.after_test(self.report)
  File "/home/maxh/debugging/mongo-enterprise/buildscripts/resmokelib/testing/hooks.py", line 122, in after_test
    self.fixture.setup()
  File "/home/maxh/debugging/mongo-enterprise/buildscripts/resmokelib/testing/fixtures/masterslave.py", line 57, in setup
    self.master.setup()
  File "/home/maxh/debugging/mongo-enterprise/buildscripts/resmokelib/testing/fixtures/standalone.py", line 72, in setup
    self.mongod_options["port"] = core.network.PortAllocator.next_fixture_port(self.job_num)
  File "/home/maxh/debugging/mongo-enterprise/buildscripts/resmokelib/core/network.py", line 27, in wrapper
    port = func(*args, **kwargs)
  File "/home/maxh/debugging/mongo-enterprise/buildscripts/resmokelib/core/network.py", line 87, in next_fixture_port
    % cls._PORTS_PER_FIXTURE)
PortAllocationError: Fixture has requested more than the 10 ports reserved per fixture

Sprint: QuInt E (01/11/16)
Participants:

 Description   

MasterSlaveFixture.setup() creates new MongoDFixture instances each time it gets called.



 Comments   
Comment by Githook User [ 21/Dec/15 ]

Author:

{u'username': u'visemet', u'name': u'Max Hirschhorn', u'email': u'max.hirschhorn@mongodb.com'}

Message: SERVER-21955 Fix issue with MasterSlaveFixture and CleanEveryN hook.

Avoid constructing new Fixture instances inside
MasterSlaveFixture.setup().

(cherry picked from commit f176586570393247747a3774fafa81812f377433)
Branch: v3.2
https://github.com/mongodb/mongo/commit/dab123e614e64a0dcd4163415dd48532b1a79242

Comment by Githook User [ 21/Dec/15 ]

Author:

{u'username': u'visemet', u'name': u'Max Hirschhorn', u'email': u'max.hirschhorn@mongodb.com'}

Message: SERVER-21955 Fix issue with MasterSlaveFixture and CleanEveryN hook.

Avoid constructing new Fixture instances inside
MasterSlaveFixture.setup().
Branch: master
https://github.com/mongodb/mongo/commit/f176586570393247747a3774fafa81812f377433

Comment by Max Hirschhorn [ 18/Dec/15 ]

Somehow managed to forget to do this as part of SERVER-20899.

Generated at Thu Feb 08 03:58:55 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.