-
Type: Task
-
Resolution: Gone away
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
None
-
Query Integration
First, a binary of mongot will need to be downloaded to your VM locally and standalone_search_end_to_end suite YML file will need to be created, in order to run a dummy test that launches a Mongot.
After adding a launch_mongot option to the MongoDFixture, the yml file for the standalone_search_end_to_end should look like:
fixture:
class: MongoDFixture
launch_mongot: true
The constructor for the given MongoDFixture will set a flag, launch_mongot, on either self.mongod_options or self.mongos_options to indicate if a mongot process has been requested by the suite's enable_mongot parameter. MongoDFixture doesn't have a builder, so the MongoTFixture will be created and setup from MongoDFixture::setup().
MongoTFixture::setup() will involve spawning a new mongot process via a new MongoTLauncher class. Like the MongoD and MongoS launchers, MongoTLauncher::launch_mongot_program will return a Process instance.
The Process class, which sets all the command line options before spinning up the server via the command line, can be used to also launch a mongot via the command line. The arg, self.args[0] will be the path to the mongot binary.
The other elements in the args list will include the keyFile path, as specified by the suite's YML definition, and the mongodHostAndPort value, localhost:<port> where <port> will be set by the port allocator. These command line options will be passed to subprocess.Popen, which will spawn and invoke the mongot process.
The mongod process(es) will be launched as normal but now with a mongotHost startup option, the value of which will always be localhost:<port>. And in line with other jstests, the mongo shell will get the driver connection url of the mongod process (wrapped in a fixture) and use this to set global 'db' object that server e2e $search tests will use. In this way, the e2e tests will be immediately hooked up to a mongod that is connected to a real mongot.
- is depended on by
-
SERVER-85195 enable launching MongoT for sharded cluster deployment
- Closed
-
SERVER-85198 create a MongoTFixture for resmoke and enable launching mongot in a single node repl set
- Closed
-
SERVER-85995 track milestone 1
- Closed