Skip to content

Commit

Permalink
hard-code batchSize to 1000 to make queries more likely to succeed
Browse files Browse the repository at this point in the history
Use each to itterate through restuls rather than toArray to aviod issues with large datasets [fixes loopbackio#129]
chore(release): v7.0.0-alpha.1

 * ci: update Node.js test matrix (Rifa Achrinza)

 * chore: update Node.js engine matrix (Rifa Achrinza)

 * feat: upgrade mongodb driver to version 4.x (Antonio Ramón Sánchez Morales)

 * chore: lock file maintenance (renovate[bot])

 * chore: update supercharge/mongodb-github-action action to v1.8.0 (renovate[bot])

 * chore: update dependency eslint to ^8.23.0 (renovate[bot])

 * chore: update commitlint monorepo to v17 (renovate[bot])

 * chore: update dependency eslint to ^8.19.0 (renovate[bot])

 * chore: update github/codeql-action action to v2 (renovate[bot])

 * chore: update dependency mocha to ^9.2.2 (renovate[bot])

 * chore: update dependency loopback-datasource-juggler to ^4.27.1 (renovate[bot])

 * chore: update dependency eslint to ^8.18.0 (renovate[bot])

 * chore: update dependency strong-globalize to ^6.0.5 (renovate[bot])

 * chore: update supercharge/mongodb-github-action action to v1.7.0 (renovate[bot])

 * chore: update actions/setup-node action to v3 (renovate[bot])

 * chore: update actions/checkout action to v3 (renovate[bot])

 * chore: update dependency semver to ^7.3.7 (renovate[bot])

 * chore: update dependency should to ^13.2.3 (renovate[bot])

 * chore: update dependency debug to ^4.3.4 (renovate[bot])

 * chore: update dependency loopback-connector to ^5.0.1 (renovate[bot])

 * chore: update dependency bson to ^1.1.6 (renovate[bot])

 * chore: update dependency bluebird to ^3.7.2 (renovate[bot])

 * chore: update dependency async to ^3.2.4 (renovate[bot])

 * ci: add renovate config (Rifa Achrinza)

 * fix(*): run autoupdate in serial to avoid conflicts (Simon Stone)

 * fix: optional chaining (preussmann)

 * chore: update v6 EOL (Rifa Achrinza)

 * ci: test against Node.js v18 (Rifa Achrinza)

Signed-off-by: Rifa Achrinza <[email protected]>
ci: update Node.js test matrix

Signed-off-by: Rifa Achrinza <[email protected]>
chore: update Node.js engine matrix

BREAKING CHANGE: This drops explicit, documented support for Node.js
v10, v11, v12, v13, v15, v17

Signed-off-by: Rifa Achrinza <[email protected]>
feat: upgrade mongodb driver to version 4.x

Signed-off-by: Antonio Ramón Sánchez Morales <[email protected]>
chore: lock file maintenance

Signed-off-by: Renovate Bot <[email protected]>
chore: update supercharge/mongodb-github-action action to v1.8.0

Signed-off-by: Renovate Bot <[email protected]>
chore: update dependency eslint to ^8.23.0

Signed-off-by: Renovate Bot <[email protected]>
chore: update commitlint monorepo to v17

Signed-off-by: Renovate Bot <[email protected]>
chore: update dependency eslint to ^8.19.0

Signed-off-by: Renovate Bot <[email protected]>
chore: update github/codeql-action action to v2

Signed-off-by: Renovate Bot <[email protected]>
chore: update dependency mocha to ^9.2.2

Signed-off-by: Renovate Bot <[email protected]>
chore: update dependency loopback-datasource-juggler to ^4.27.1

Signed-off-by: Renovate Bot <[email protected]>
chore: update dependency eslint to ^8.18.0

Signed-off-by: Renovate Bot <[email protected]>
chore: update dependency strong-globalize to ^6.0.5

Signed-off-by: Renovate Bot <[email protected]>
chore: update supercharge/mongodb-github-action action to v1.7.0

Signed-off-by: Renovate Bot <[email protected]>
chore: update actions/setup-node action to v3

Signed-off-by: Renovate Bot <[email protected]>
chore: update actions/checkout action to v3

Signed-off-by: Renovate Bot <[email protected]>
chore: update dependency semver to ^7.3.7

Signed-off-by: Renovate Bot <[email protected]>
chore: update dependency should to ^13.2.3

Signed-off-by: Renovate Bot <[email protected]>
chore: update dependency debug to ^4.3.4

Signed-off-by: Renovate Bot <[email protected]>
chore: update dependency loopback-connector to ^5.0.1

Signed-off-by: Renovate Bot <[email protected]>
chore: update dependency bson to ^1.1.6

Signed-off-by: Renovate Bot <[email protected]>
chore: update dependency bluebird to ^3.7.2

Signed-off-by: Renovate Bot <[email protected]>
chore: update dependency async to ^3.2.4

Signed-off-by: Renovate Bot <[email protected]>
ci: add renovate config

see: loopbackio/cicd#15

Signed-off-by: Rifa Achrinza <[email protected]>
fix(*): run autoupdate in serial to avoid conflicts

Signed-off-by: Simon Stone <[email protected]>
fix: optional chaining

fixed error if this._models[modelName] is an empty object

Signed-off-by: minp <[email protected]>
chore: update v6 EOL

Signed-off-by: Rifa Achrinza <[email protected]>
ci: test against Node.js v18

see: loopbackio/cicd#27

Signed-off-by: Rifa Achrinza <[email protected]>
6.2.0

 * docs: add SECURITY.md (Diana Lau)
 * chore: tls README example (d-bo)
 * docs: update coc (Diana Lau)
 * docs: add code of conduct (Diana Lau)
 * chore: update v6 EOL (Rifa Achrinza)
 * ci: fix typo (Rifa Achrinza)
 * chore: update deps (Rifa Achrinza)
 * feat: add tls options as of mongo 3.7 (d-bo)
 * ci: update Node.js version (Rifa Achrinza)
 * ci: pin NPM version (Rifa Achrinza)
 * chore: add @achrinza and update CODEOWNERS (Diana Lau)
 * fix: isObjectIDProperty array param check (Rifa Achrinza)
 * fix: handle url default db name (Rifa Achrinza)
 * ci: restrict GITHUB_TOKEN permissions (Rifa Achrinza)
docs: add SECURITY.md

Signed-off-by: Diana Lau <[email protected]>
chore: tls README example

Signed-off-by: d-bo <[email protected]>
docs: update coc

Signed-off-by: Diana Lau <[email protected]>
docs: add code of conduct

Signed-off-by: Diana Lau <[email protected]>
chore: update v6 EOL

Coninuation of loopbackio#652

Signed-off-by: Rifa Achrinza <[email protected]>
ci: fix typo

Signed-off-by: Rifa Achrinza <[email protected]>
chore: update deps

Signed-off-by: Rifa Achrinza <[email protected]>
feat: add tls options as of mongo 3.7

Signed-off-by: d-bo <[email protected]>
ci: update Node.js version

see: loopbackio/cicd#2
see: loopbackio/cicd#4

Signed-off-by: Rifa Achrinza <[email protected]>
ci: pin NPM version

see: loopbackio/cicd#6

Signed-off-by: Rifa Achrinza <[email protected]>
chore: add @achrinza and update CODEOWNERS

Signed-off-by: Diana Lau <[email protected]>
fix: isObjectIDProperty array param check

fixes loopbackio#645

Signed-off-by: Rifa Achrinza <[email protected]>
fix: handle url default db name

Co-authored-by: Nico Flaig <[email protected]>
Signed-off-by: Rifa Achrinza <[email protected]>
ci: restrict GITHUB_TOKEN permissions

Signed-off-by: Rifa Achrinza <[email protected]>
6.1.0

 * ci: misc updates (Rifa Achrinza)
 * feat: add transaction support (Sergey Nosenko)
 * ci: align gh actions workflow with 5.x (Rifa Achrinza)
 * chore: move repo to loopbackio org (Diana Lau)
ci: misc updates

- Enable Node.js v16 testing
- Update supercharge/mongodb-github-action to v1.6.0
- Enable amd64/8 testing
- Re-enable coverage reporting
- General CI sync with other pipelines.

Signed-off-by: Rifa Achrinza <[email protected]>
feat: add transaction support

Signed-off by: Sergey Nosenko <[email protected]>
Signed-off-by: Rifa Achrinza <[email protected]>
ci: align gh actions workflow with 5.x

see loopbackio#634

Signed-off-by: Rifa Achrinza <[email protected]>
chore: move repo to loopbackio org

Signed-off-by: Diana Lau <[email protected]>
6.0.1

 * fix: allows fields filter with custom field name (louis.nguyen)
 * README: update notes about 6.0 (Miroslav Bajtoš)
fix: allows fields filter with custom field name

Signed-off-by: louis.nguyen <[email protected]>
README: update notes about 6.0

Remove the message "6.0 is in development", update LTS table with the
correct date of publishing v6.0.0

Signed-off-by: Miroslav Bajtoš <[email protected]>
6.0.0

 * coerce values of array defined as ObjectID type (=)
 * Update mongodb to ^3.6.4 (wolrajhti)
 * ci: convert from Travis to Github action ci (Agnes Lin)
 * README: mention our work on 6.0 (Miroslav Bajtoš)
 * [SEMVER-MAJOR] Drop support for LoopBack 3.x (Yaapa Hage)
coerce values of array defined as ObjectID type

Signed-off-by: = <[email protected]>
Update mongodb to ^3.6.4

Signed-off-by: wolrajhti <[email protected]>
ci: convert from Travis to Github action ci

Signed-off-by: Agnes Lin <[email protected]>
[SEMVER-MAJOR] Drop support for LoopBack 3.x

Signed-off-by: Yaapa Hage <[email protected]>
README: mention our work on 6.0

Signed-off-by: Miroslav Bajtoš <[email protected]>
5.5.0

 * atomic upsertWithWhere (loopbackio#563) (Matteo Padovano)
atomic upsertWithWhere (loopbackio#563)

Signed-off-by: = <[email protected]>
  • Loading branch information
Luke Cameron authored and vramaniuk committed Jun 1, 2023
1 parent ebb8786 commit 4f85c71
Show file tree
Hide file tree
Showing 24 changed files with 10,060 additions and 378 deletions.
2 changes: 1 addition & 1 deletion .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@
"ignorePattern": "^\\s*var\\s.+=\\s*(require\\s*\\()|(/)"
}]
}
}
}
4 changes: 0 additions & 4 deletions .github/ISSUE_TEMPLATE/Question.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,5 @@ Please use one of the following resources for help:
- https://groups.google.com/forum/#!forum/loopbackjs
- https://gitter.im/strongloop/loopback
**Immediate support**
- https://strongloop.com/api-connect-faqs/
- https://strongloop.com/node-js/subscription-plans/
-->
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ blank_issues_enabled: false
contact_links:
- name: Report a security vulnerability
url: https://loopback.io/doc/en/contrib/Reporting-issues.html#security-issues
about: Do not report security vulnerabilities using GitHub issues. Please send an email to `[email protected]` instead.
about: Do not report security vulnerabilities using GitHub issues. Please send an email to `[email protected]` instead.
- name: Get help on StackOverflow
url: https://stackoverflow.com/tags/loopbackjs
about: Please ask and answer questions on StackOverflow.
Expand Down
1 change: 1 addition & 0 deletions .github/codeql/codeql-config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
paths-ignore: [test]
113 changes: 113 additions & 0 deletions .github/workflows/continuous-integration.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,113 @@
name: CI

on:
push:
branches:
- master
- 5.x
pull_request:
branches:
- master
- 5.x
schedule:
- cron: '0 2 * * 1' # At 02:00 on Monday

permissions: {}

jobs:
test:
name: Test
runs-on: ubuntu-latest
timeout-minutes: 15
strategy:
matrix:
node-version: [14, 16, 18, 19]
mongodb-version: [4.4]
fail-fast: false
steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: Start MongoDB
uses: supercharge/[email protected]
with:
mongodb-version: ${{ matrix.mongodb-version }}
- name: Bootstrap project
run: npm ci --ignore-scripts
- name: Update NPM (Node.js v10)
if: matrix.node-version == 10
run: npm install --global npm@7
- name: Update NPM
if: matrix.node-version != 10
run: npm install --global npm@8
- name: Run tests
run: npm test --ignore-scripts
- name: Publish coverage report to Coveralls
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
flag-name: run-${{ matrix.os }}-node@${{ matrix.node-version }}
path-to-lcov: ${{ github.workspace }}/coverage/lcov.info
parallel: true

posttest:
name: Post-Test
needs: test
runs-on: ubuntu-latest
steps:
- name: Coveralls finished
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.github_token }}
parallel-finished: true

code-lint:
name: Code Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Use Node.js 16
uses: actions/setup-node@v3
with:
node-version: 16
- name: Bootstrap project
run: npm ci --ignore-scripts
- name: Verify code linting
run: npm run lint

commit-lint:
name: Commit Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Use Node.js 16
uses: actions/setup-node@v3
with:
node-version: 16
- name: Bootstrap project
run: npm ci --ignore-scripts
- name: Verify commit linting
run: npx --no-install commitlint --from origin/master --to HEAD --verbose

codeql:
name: CodeQL
runs-on: ubuntu-latest
permissions:
# See: https://github.com/github/codeql-action/blob/008b2cc71c4cf3401f45919d8eede44a65b4a322/README.md#usage
security-events: write
steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: 'javascript'
config-file: ./.github/codeql/codeql-config.yml

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
3 changes: 2 additions & 1 deletion .npmrc
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
package-lock=false
package-lock=true
scripts-prepend-node-path=true
52 changes: 33 additions & 19 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,21 +1,35 @@
branches:
only: master
arch: arm64
dist: focal
services: docker
language: node_js
node_js:
- "10"
- "12"
- "14"

env:
- CXX=g++-4.8
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- mongodb-3.2-precise
packages:
- g++-4.8
- mongodb-org-server
- mongodb-org-shell
services:
- mongodb

after_success: npm run coverage
- 10
- 12
- 14
- 16
- 17
- 18
before_install: |
docker run --name=mongodb --publish=27017:27017 --detach mongo:4.4
until docker exec --tty mongodb mongo --port=27017 --eval='db.serverStatus()'
do
sleep 1
echo "."
TIMER=$((TIMER + 1))
if [ $TIMER -eq 20 ]; then
echo "MongoDB did not initialize within 20 seconds. Exiting."
exit 2
fi
done
NODEJS_VERSION=$(node --version)
if [ 'v10' == ${NODEJS_VERSION%%.*} ]
then
npm install --global npm@7
else
npm install --global npm@8
fi
install:
- npm ci --ignore-scripts
script: npm test --ignore-scripts
132 changes: 132 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,135 @@
2022-11-20, Version 7.0.0-alpha.1
=================================

* ci: update Node.js test matrix (Rifa Achrinza)

* chore: update Node.js engine matrix (Rifa Achrinza)

* feat: upgrade mongodb driver to version 4.x (Antonio Ramón Sánchez Morales)

* chore: lock file maintenance (renovate[bot])

* chore: update supercharge/mongodb-github-action action to v1.8.0 (renovate[bot])

* chore: update dependency eslint to ^8.23.0 (renovate[bot])

* chore: update commitlint monorepo to v17 (renovate[bot])

* chore: update dependency eslint to ^8.19.0 (renovate[bot])

* chore: update github/codeql-action action to v2 (renovate[bot])

* chore: update dependency mocha to ^9.2.2 (renovate[bot])

* chore: update dependency loopback-datasource-juggler to ^4.27.1 (renovate[bot])

* chore: update dependency eslint to ^8.18.0 (renovate[bot])

* chore: update dependency strong-globalize to ^6.0.5 (renovate[bot])

* chore: update supercharge/mongodb-github-action action to v1.7.0 (renovate[bot])

* chore: update actions/setup-node action to v3 (renovate[bot])

* chore: update actions/checkout action to v3 (renovate[bot])

* chore: update dependency semver to ^7.3.7 (renovate[bot])

* chore: update dependency should to ^13.2.3 (renovate[bot])

* chore: update dependency debug to ^4.3.4 (renovate[bot])

* chore: update dependency loopback-connector to ^5.0.1 (renovate[bot])

* chore: update dependency bson to ^1.1.6 (renovate[bot])

* chore: update dependency bluebird to ^3.7.2 (renovate[bot])

* chore: update dependency async to ^3.2.4 (renovate[bot])

* ci: add renovate config (Rifa Achrinza)

* fix(*): run autoupdate in serial to avoid conflicts (Simon Stone)

* fix: optional chaining (preussmann)

* chore: update v6 EOL (Rifa Achrinza)

* ci: test against Node.js v18 (Rifa Achrinza)


2022-03-31, Version 6.2.0
=========================

* docs: add SECURITY.md (Diana Lau)

* chore: tls README example (d-bo)

* docs: update coc (Diana Lau)

* docs: add code of conduct (Diana Lau)

* chore: update v6 EOL (Rifa Achrinza)

* ci: fix typo (Rifa Achrinza)

* chore: update deps (Rifa Achrinza)

* feat: add tls options as of mongo 3.7 (d-bo)

* ci: update Node.js version (Rifa Achrinza)

* ci: pin NPM version (Rifa Achrinza)

* chore: add @achrinza and update CODEOWNERS (Diana Lau)

* fix: isObjectIDProperty array param check (Rifa Achrinza)

* fix: handle url default db name (Rifa Achrinza)

* ci: restrict GITHUB_TOKEN permissions (Rifa Achrinza)


2021-09-07, Version 6.1.0
=========================

* ci: misc updates (Rifa Achrinza)

* feat: add transaction support (Sergey Nosenko)

* ci: align gh actions workflow with 5.x (Rifa Achrinza)

* chore: move repo to loopbackio org (Diana Lau)


2021-05-03, Version 6.0.1
=========================

* fix: allows fields filter with custom field name (louis.nguyen)

* README: update notes about 6.0 (Miroslav Bajtoš)


2021-03-22, Version 6.0.0
=========================

* coerce values of array defined as ObjectID type (=)

* Update mongodb to ^3.6.4 (wolrajhti)

* ci: convert from Travis to Github action ci (Agnes Lin)

* README: mention our work on 6.0 (Miroslav Bajtoš)

* [SEMVER-MAJOR] Drop support for LoopBack 3.x (Yaapa Hage)


2020-12-01, Version 5.5.0
=========================

* atomic upsertWithWhere (#563) (Matteo Padovano)


2020-09-02, Version 5.4.0
=========================

Expand Down
4 changes: 2 additions & 2 deletions CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# the last matching pattern has the most precedence.

# Current maintainers
* @jannyHou @dhmlau @nitro404 @emonddr @hacksparrow @agnes512
* @dhmlau @nitro404 @hacksparrow @agnes512 @achrinza

# Alumni maintainers
# @loay @virkt25 @shimks @b-admike
# @loay @virkt25 @shimks @b-admike @jannyHou @emonddr
Loading

0 comments on commit 4f85c71

Please sign in to comment.