Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: set the correct config name connect_timout mongoid #432

Merged
merged 1 commit into from
Sep 23, 2024

Conversation

ghassanmas
Copy link
Member

This change just fix the name of the variable that is
respoinsbile for:

The time to wait to establish a connection before timing out,
in seconds

ref: https://www.mongodb.com/docs/offline/mongoid-7.5.tar.gz

@openedx-webhooks
Copy link

openedx-webhooks commented Jul 22, 2024

Thanks for the pull request, @ghassanmas!

What's next?

Please work through the following steps to get your changes ready for engineering review:

🔘 Get product approval

If you haven't already, check this list to see if your contribution needs to go through the product review process.

  • If it does, you'll need to submit a product proposal for your contribution, and have it reviewed by the Product Working Group.
    • This process (including the steps you'll need to take) is documented here.
  • If it doesn't, simply proceed with the next step.

🔘 Provide context

To help your reviewers and other members of the community understand the purpose and larger context of your changes, feel free to add as much of the following information to the PR description as you can:

  • Dependencies

    This PR must be merged before / after / at the same time as ...

  • Blockers

    This PR is waiting for OEP-1234 to be accepted.

  • Timeline information

    This PR must be merged by XX date because ...

  • Partner information

    This is for a course on edx.org.

  • Supporting documentation
  • Relevant Open edX discussion forum threads

🔘 Get a green build

If one or more checks are failing, continue working on your changes until this is no longer the case and your build turns green.

🔘 Let us know that your PR is ready for review:

Who will review my changes?

This repository is currently maintained by @openedx/edx-infinity. Tag them in a comment and let them know that your changes are ready for review.

Where can I find more information?

If you'd like to get more details on all aspects of the review process for open source pull requests (OSPRs), check out the following resources:

When can I expect my changes to be merged?

Our goal is to get community contributions seen and reviewed as efficiently as possible.

However, the amount of time that it takes to review and merge a PR can vary significantly based on factors such as:

  • The size and impact of the changes that it introduces
  • The need for product review
  • Maintenance status of the parent repository

💡 As a result it may take up to several weeks or months to complete a review and merge your PR.

@openedx-webhooks openedx-webhooks added the open-source-contribution PR author is not from Axim or 2U label Jul 22, 2024
@ghassanmas
Copy link
Member Author

I would argue also to change the default value form 0.5s to something longer the default is 10 second... in consumer tutor-forum I will set it 600 second in order to get rid of dockerize...
This ready for review

Copy link

codecov bot commented Jul 22, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 96.19%. Comparing base (ce71c39) to head (e7e94a6).
Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #432   +/-   ##
=======================================
  Coverage   96.19%   96.19%           
=======================================
  Files          58       58           
  Lines        4624     4624           
=======================================
  Hits         4448     4448           
  Misses        176      176           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

ghassanmas added a commit to overhangio/tutor-forum that referenced this pull request Jul 23, 2024
  getting rid of dockerize might resolve #33 and provide other
  solution for #35

  dockerize is used for waiting for other services, in order
  replicate it's effect, we set `MONGOID_TIMEOUT` 600 second
  for mongodb, related upstream PR:
  - openedx/cs_comments_service/pull/432
@itsjeyd itsjeyd added core contributor PR author is a Core Contributor (who may or may not have write access to this repo). waiting for eng review PR is ready for review. Review and merge it, or suggest changes. labels Jul 25, 2024
@itsjeyd
Copy link

itsjeyd commented Jul 25, 2024

Thank you for this contribution @ghassanmas! I marked it as ready for review.

@openedx/2u-infinity Could you please have a look at this change?

@itsjeyd itsjeyd requested a review from a team July 25, 2024 09:49
@itsjeyd itsjeyd added the needs reviewer assigned PR needs to be (re-)assigned a new reviewer label Aug 8, 2024
@itsjeyd
Copy link

itsjeyd commented Aug 8, 2024

@mtyaka @xitij2000 Would one of you be able to help out with a CC review for this PR?

@xitij2000
Copy link
Contributor

@mtyaka @xitij2000 Would one of you be able to help out with a CC review for this PR?

I can review it in the next sprint

@@ -6,7 +6,7 @@ common: &default_client
mode: :<%= ENV['MONGOID_READ_MODE'] || 'primary' %>
max_retries: <%= ENV['MONGOID_MAX_RETRIES'] || 1 %>
retry_interval: <%= ENV['MONGOID_RETRY_INTERVAL'] || 0 %>
timeout: <%= ENV['MONGOID_TIMEOUT'] || 0.5 %>
connect_timeout: <%= ENV['MONGOID_TIMEOUT'] || 0.5 %>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we change the name of the environment variable to MONGOID_CONNECT_TIMEOUT as well?

I see mongoid has other timeout related options (socket_timeout, server_selection_timeout, and wait_queue_timeout) so a more specific name would help avoid confusion.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes makes sense, but I suppsoe this would be a breaking change for downstream app(e.g. tutor-forum, edx-configuration), I can hanlde the case for tutor-forum since I maintain it, but sure about edx-configuration.

But in many case, in practice I don't think it matter that much since the variable was unusable in the first place.

ghassanmas added a commit to overhangio/tutor-forum that referenced this pull request Aug 28, 2024
  getting rid of dockerize might resolve #33 and provide other
  solution for #35

  dockerize is used for waiting for other services, in order
  replicate it's effect, we set `MONGOID_TIMEOUT` 600 second
  for mongodb, related upstream PR:
  - openedx/cs_comments_service/pull/432
@itsjeyd itsjeyd added waiting on author PR author needs to resolve review requests, answer questions, fix tests, etc. and removed needs reviewer assigned PR needs to be (re-)assigned a new reviewer labels Sep 7, 2024
@itsjeyd
Copy link

itsjeyd commented Sep 7, 2024

Hey @ghassanmas, thanks for addressing comments from engineering review here!

It looks like the changes will need a rebase to bring them up to date with the base branch. When you're done with that and the build is green, please ping mtyaka for final approval.

@itsjeyd itsjeyd removed the waiting for eng review PR is ready for review. Review and merge it, or suggest changes. label Sep 7, 2024
@ghassanmas
Copy link
Member Author

@itsjeyd done, @mtyaka this ready for review again

Copy link
Contributor

@mtyaka mtyaka left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @ghassanmas! The changes look good to me 👍

@itsjeyd itsjeyd removed the waiting on author PR author needs to resolve review requests, answer questions, fix tests, etc. label Sep 20, 2024
@itsjeyd
Copy link

itsjeyd commented Sep 20, 2024

@ghassanmas Could you please bring your branch up-to-date with the base branch and ping mtyaka so he can merge the changes?

@itsjeyd itsjeyd added the waiting on author PR author needs to resolve review requests, answer questions, fix tests, etc. label Sep 20, 2024
  This change just fix the name of the variable that is
  respoinsbile for:
  > The time to wait to establish a connection before timing out,
  >  in seconds

  ref: https://www.mongodb.com/docs/offline/mongoid-7.5.tar.gz
@ghassanmas
Copy link
Member Author

Done

@mtyaka mtyaka merged commit d0a8fd7 into openedx:master Sep 23, 2024
16 checks passed
@itsjeyd itsjeyd removed the waiting on author PR author needs to resolve review requests, answer questions, fix tests, etc. label Sep 26, 2024
ghassanmas added a commit to overhangio/tutor-forum that referenced this pull request Oct 11, 2024
  getting rid of dockerize might resolve #33 and provide other
  solution for #35

  dockerize is used for waiting for other services, in order
  replicate it's effect, we set `MONGOID_TIMEOUT` 600 second
  for mongodb, related upstream PR:
  - openedx/cs_comments_service/pull/432
ghassanmas added a commit to overhangio/tutor-forum that referenced this pull request Oct 14, 2024
  getting rid of dockerize might resolve #33 and provide other
  solution for #35

  dockerize is used for waiting for other services, in order
  replicate it's effect, we set `MONGOID_TIMEOUT` 600 second
  for mongodb, related upstream PR:
  - openedx/cs_comments_service/pull/432
ghassanmas added a commit to overhangio/tutor-forum that referenced this pull request Oct 15, 2024
  getting rid of dockerize might resolve #33 and provide other
  solution for #35

  dockerize is used for waiting for other services, in order
  replicate it's effect, we set `MONGOID_TIMEOUT` 600 second
  for mongodb, related upstream PR:
  - openedx/cs_comments_service/pull/432
ghassanmas added a commit to overhangio/tutor-forum that referenced this pull request Oct 15, 2024
  getting rid of dockerize might resolve #33 and provide other
  solution for #35

  dockerize is used for waiting for other services, in order
  replicate it's effect, we set `MONGOID_TIMEOUT` 600 second
  for mongodb, related upstream PR:
  - openedx/cs_comments_service/pull/432
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core contributor PR author is a Core Contributor (who may or may not have write access to this repo). open-source-contribution PR author is not from Axim or 2U
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

5 participants