[DRIVERS-2328] Remove legacy shell from test scripts Created: 15/May/22  Updated: 22/Jan/24

Status: Implementing
Project: Drivers
Component/s: Evergreen Tools
Fix Version/s: None

Type: Task Priority: Major - P3
Reporter: Kevin Albertson Assignee: Andreas Braun
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
backported by CDRIVER-4433 Add Ubuntu 22.04 build variant Backlog
Depends
depends on MONGOSH-1364 assert.commandWorked throws Reference... Open
Duplicate
Issue split
split to RUBY-3164 Remove legacy shell from test scripts Backlog
split to CDRIVER-4512 Remove legacy shell from test scripts Closed
split to CSHARP-4380 Remove legacy shell from test scripts Closed
split to CXX-2605 Remove legacy shell from test scripts Closed
split to GODRIVER-2607 Remove legacy shell from test scripts Closed
split to MOTOR-1055 Remove legacy shell from test scripts Closed
split to PHPLIB-1028 Remove legacy shell from test scripts Closed
split to PYTHON-3489 Remove legacy shell from test scripts Closed
split to RUST-1525 Remove legacy shell from test scripts Closed
split to JAVA-4791 Remove legacy shell from test scripts Closed
split to NODE-4764 Remove legacy shell from test scripts Scheduled
Problem/Incident
causes PYTHON-3618 Perf tests are failing on the centos6... Closed
Driver Changes: Needed
Quarter: FY23Q4
Downstream Changes Summary:

The legacy shell will no longer be installed in the near future. Drivers are encouraged to remove all usages of the legacy shell in their drivers with this Go driver PR serving as inspiration.

All drivers that require the use of the legacy library are required to define the INSTALL_LEGACY_SHELL environment variable to a non-zero value when running MongoDB installation (either by running run-orchestration.sh or by manually invoking download_and_extract() from download-mongoldb.sh). This variable replaces the current SKIP_LEGACY_SHELL variable which will no longer be respected.

The upcoming changes can be tested by using the development branch for this change. In your evergreen functions, locate the git clone command that clones the drivers-evergreen-tools repository and replace it with this command:

git clone https://github.com/alcaeus/drivers-evergreen-tools.git --depth 1 --branch skip-legacy-shell-by-default $DRIVERS_TOOLS

This will show which of your build tasks still need the legacy shell, which can be installed using the INSTALL_LEGACY_SHELL environment variable in that specific task.

Engineering Lead: Andreas Braun Andreas Braun
Start date:
Driver Compliance:
Key Status/Resolution FixVersion
CDRIVER-4512 Fixed 1.26.0
CXX-2605 Works as Designed
CSHARP-4380 Fixed 2.23.0
GODRIVER-2607 Done
JAVA-4791 Fixed 5.0.0
NODE-4764 Scheduled
MOTOR-1055 Duplicate
PYTHON-3489 Done
PHPLIB-1028 Works as Designed
RUBY-3164 Backlog
RUST-1525 Fixed 3.0.0
SWIFT-1671 Won't Do

 Description   

Summary

SERVER-64352 removed the legacy "mongo" shell from latest packages.
Drivers test scripts that rely on the legacy shell need to be updated.

drivers-evergreen-tools uses the "mongo" shell. Examples: ecs_hosted_test.sh, aws_e2e_ecs.js, and run-orchestration.sh

Motivation

Who is the affected end user?

DBX engineers.

How does this affect the end user?

Blocked. AWS auth tasks and API version tasks run on latest will fail during setup.

Is this issue urgent?

Yes. A workaround is urgent to get tests passing. A long-term solution is less urgent.

Is this ticket required by a downstream team?

No.

Is this ticket only for tests?

Yes.

Proposal

Download the legacy shell from 6.0 packages as a temporary workaround.

For a long-term solution:

  • Consider downloading mongosh as a replacement.
  • Consider using pymongo as a replacement. mongo-orchestration already depends on pymongo.


 Comments   
Comment by Githook User [ 22/Jan/24 ]

Author:

{'name': 'Steven Silvester', 'email': 'steven.silvester@ieee.org', 'username': 'blink1073'}

Message: DRIVERS-2328 Add more explicit AWS test instructions (#375)

Comment by Githook User [ 22/Jan/24 ]

Author:

{'name': 'Andreas Braun', 'email': 'alcaeus@users.noreply.github.com', 'username': 'alcaeus'}

Message: DRIVERS-2328: Skip installing the legacy shell by default (#366)

Skip installing the legacy shell by default
Branch: dependabot/pip/dot-evergreen/ocsp/flask-2.2.5
https://github.com/mongodb-labs/drivers-evergreen-tools/commit/6b9fa1516ab3fa2f6c4d6cf35d53c1cd54c1a8b5

Comment by Githook User [ 22/Jan/24 ]

Author:

{'name': 'Steven Silvester', 'email': 'steven.silvester@ieee.org', 'username': 'blink1073'}

Message: DRIVERS-2328 Add aws_setup convenience script (#365)

  • cleanup
  • fix handling of directory
  • get the right secrets
  • fix unbound var
  • clean up script
  • more cleanup
  • fix handling of file
  • activate venv
  • allow user to already exist
  • fix import
  • fixups
  • try again
  • ignore windows for now
  • debug
  • debug
  • move secrets handling out
  • fix typo
  • debug
  • use robust script dir
  • fix handling of token file
  • syntax
  • try adding os env
Comment by Githook User [ 29/Nov/23 ]

Author:

{'name': 'Steven Silvester', 'email': 'steven.silvester@ieee.org', 'username': 'blink1073'}

Message: DRIVERS-2328 Add more explicit AWS test instructions (#375)

Comment by Githook User [ 29/Nov/23 ]

Author:

{'name': 'Andreas Braun', 'email': 'alcaeus@users.noreply.github.com', 'username': 'alcaeus'}

Message: DRIVERS-2328: Skip installing the legacy shell by default (#366)

Skip installing the legacy shell by default
Branch: master
https://github.com/mongodb-labs/drivers-evergreen-tools/commit/6b9fa1516ab3fa2f6c4d6cf35d53c1cd54c1a8b5

Comment by Githook User [ 17/Oct/23 ]

Author:

{'name': 'Steven Silvester', 'email': 'steven.silvester@ieee.org', 'username': 'blink1073'}

Message: DRIVERS-2328 Add aws_setup convenience script (#365)

  • cleanup
  • fix handling of directory
  • get the right secrets
  • fix unbound var
  • clean up script
  • more cleanup
  • fix handling of file
  • activate venv
  • allow user to already exist
  • fix import
  • fixups
  • try again
  • ignore windows for now
  • debug
  • debug
  • move secrets handling out
  • fix typo
  • debug
  • use robust script dir
  • fix handling of token file
  • syntax
  • try adding os env
Comment by Githook User [ 31/May/23 ]

Author:

{'name': 'Steven Silvester', 'email': 'steven.silvester@ieee.org', 'username': 'blink1073'}

Message: DRIVERS-2328 Fix Windows Support for AWS Scripts (#310)
Branch: master
https://github.com/mongodb-labs/drivers-evergreen-tools/commit/3603e596e4d7a2224cf858d77adaab8d71041b1a

Comment by Githook User [ 24/May/23 ]

Author:

{'name': 'Steven Silvester', 'email': 'steven.silvester@ieee.org', 'username': 'blink1073'}

Message: DRIVERS-2328 Use Python and Mongo Shell for AWS Testing (#306)
Branch: master
https://github.com/mongodb-labs/drivers-evergreen-tools/commit/52cf98c37afc5b29097265e5dbb70954d8c1469b

Comment by Githook User [ 02/May/23 ]

Author:

{'name': 'Andreas Braun', 'email': 'alcaeus@users.noreply.github.com', 'username': 'alcaeus'}

Message: DRIVERS-2328: Allow disabling usage of legacy shell (#298)

  • Use mongosh for stable API tests
  • Allow skipping legacy shell install
Comment by Githook User [ 06/Feb/23 ]

Author:

{'name': 'Andreas Braun', 'email': 'alcaeus@users.noreply.github.com', 'username': 'alcaeus'}

Message: DRIVERS-2328: Download mongosh alongside the legacy shell (#265)

Download mongosh alongside the legacy shell
Branch: master
https://github.com/mongodb-labs/drivers-evergreen-tools/commit/6ac2fdd5eadc0a9deb960c661c3f9ecca1b0cca9

Comment by Githook User [ 16/May/22 ]

Author:

{'name': 'Kevin Albertson', 'email': 'kevin.albertson@mongodb.com', 'username': 'kevinAlbs'}

Message: DRIVERS-2328 download legacy shell from 5.0 package (#199)
Branch: master
https://github.com/mongodb-labs/drivers-evergreen-tools/commit/7691087da3a783858a14711c936fcc2dbb6a453f

Generated at Thu Feb 08 08:25:18 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.