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

add documentation on COUCH2PG_USERS_META_DOC_LIMIT and add safeNum safety #100

Merged
merged 2 commits into from
Sep 16, 2021

Conversation

njogz
Copy link
Contributor

@njogz njogz commented Jul 6, 2021

Add documentation about the COUCH2PG_USERS_META_DOC_LIMIT environment variable and add safeNum safety check

Copy link
Contributor

@mrsarm mrsarm left a comment

Choose a reason for hiding this comment

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

Hey, thanks for taking this! I also linked the PR to another issue that requested the same changes.

README.md Outdated
@@ -23,6 +23,7 @@ The supported environment variables are:
| COUCH2PG_SLEEP_MINS | Number of minutes between synchronization |
| COUCH2PG_DOC_LIMIT | Number of documents cht-couch2pg fetches from CouchDB everytime |
| COUCH2PG_RETRY_COUNT | Number of times cht-couch2pg will retry synchronizing documents from CouchDB after experiencing an error |
| COUCH2PG_USERS_META_DOC_LIMIT | Number of documents from users-meta database that cht-couch2pg fetches from CouchDB everytime |
Copy link
Contributor

Choose a reason for hiding this comment

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

The description seems incomplete, making the variable to look like it sets a limit on how much documents are fetched in total or in total in a batch, while in reality the value is set to limit the number of documents per fetch. A good description I found is here, and would be nice to also add in the description what is the default value taken when the variable is not set.

Also would be nice if you can add in the documentation what is the default value taken in the rest of the variables or at least where to check the default values (inquirer.js).

@njogz njogz requested a review from mrsarm July 6, 2021 19:08
Copy link
Contributor

@mrsarm mrsarm left a comment

Choose a reason for hiding this comment

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

LGTM 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

COUCH2PG_USERS_META_DOC_LIMIT Safety Check Document the use of COUCH2PG_USERS_META_DOC_LIMIT
3 participants