Skip to content

Commit 4f85c71

Browse files
Luke Cameronvramaniuk
Luke Cameron
authored andcommitted
hard-code batchSize to 1000 to make queries more likely to succeed
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]>
1 parent ebb8786 commit 4f85c71

24 files changed

+10060
-378
lines changed

.eslintrc

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@
77
"ignorePattern": "^\\s*var\\s.+=\\s*(require\\s*\\()|(/)"
88
}]
99
}
10-
}
10+
}

.github/ISSUE_TEMPLATE/Question.md

-4
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,5 @@ Please use one of the following resources for help:
1919
- https://groups.google.com/forum/#!forum/loopbackjs
2020
- https://gitter.im/strongloop/loopback
2121
22-
**Immediate support**
23-
24-
- https://strongloop.com/api-connect-faqs/
25-
- https://strongloop.com/node-js/subscription-plans/
2622
2723
-->

.github/ISSUE_TEMPLATE/config.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ blank_issues_enabled: false
22
contact_links:
33
- name: Report a security vulnerability
44
url: https://loopback.io/doc/en/contrib/Reporting-issues.html#security-issues
5-
about: Do not report security vulnerabilities using GitHub issues. Please send an email to `[email protected]` instead.
5+
about: Do not report security vulnerabilities using GitHub issues. Please send an email to `[email protected]` instead.
66
- name: Get help on StackOverflow
77
url: https://stackoverflow.com/tags/loopbackjs
88
about: Please ask and answer questions on StackOverflow.

.github/codeql/codeql-config.yml

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
paths-ignore: [test]
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,113 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
- 5.x
8+
pull_request:
9+
branches:
10+
- master
11+
- 5.x
12+
schedule:
13+
- cron: '0 2 * * 1' # At 02:00 on Monday
14+
15+
permissions: {}
16+
17+
jobs:
18+
test:
19+
name: Test
20+
runs-on: ubuntu-latest
21+
timeout-minutes: 15
22+
strategy:
23+
matrix:
24+
node-version: [14, 16, 18, 19]
25+
mongodb-version: [4.4]
26+
fail-fast: false
27+
steps:
28+
- uses: actions/checkout@v3
29+
- name: Use Node.js ${{ matrix.node-version }}
30+
uses: actions/setup-node@v3
31+
with:
32+
node-version: ${{ matrix.node-version }}
33+
- name: Start MongoDB
34+
uses: supercharge/[email protected]
35+
with:
36+
mongodb-version: ${{ matrix.mongodb-version }}
37+
- name: Bootstrap project
38+
run: npm ci --ignore-scripts
39+
- name: Update NPM (Node.js v10)
40+
if: matrix.node-version == 10
41+
run: npm install --global npm@7
42+
- name: Update NPM
43+
if: matrix.node-version != 10
44+
run: npm install --global npm@8
45+
- name: Run tests
46+
run: npm test --ignore-scripts
47+
- name: Publish coverage report to Coveralls
48+
uses: coverallsapp/github-action@master
49+
with:
50+
github-token: ${{ secrets.GITHUB_TOKEN }}
51+
flag-name: run-${{ matrix.os }}-node@${{ matrix.node-version }}
52+
path-to-lcov: ${{ github.workspace }}/coverage/lcov.info
53+
parallel: true
54+
55+
posttest:
56+
name: Post-Test
57+
needs: test
58+
runs-on: ubuntu-latest
59+
steps:
60+
- name: Coveralls finished
61+
uses: coverallsapp/github-action@master
62+
with:
63+
github-token: ${{ secrets.github_token }}
64+
parallel-finished: true
65+
66+
code-lint:
67+
name: Code Lint
68+
runs-on: ubuntu-latest
69+
steps:
70+
- uses: actions/checkout@v3
71+
- name: Use Node.js 16
72+
uses: actions/setup-node@v3
73+
with:
74+
node-version: 16
75+
- name: Bootstrap project
76+
run: npm ci --ignore-scripts
77+
- name: Verify code linting
78+
run: npm run lint
79+
80+
commit-lint:
81+
name: Commit Lint
82+
runs-on: ubuntu-latest
83+
steps:
84+
- uses: actions/checkout@v3
85+
with:
86+
fetch-depth: 0
87+
- name: Use Node.js 16
88+
uses: actions/setup-node@v3
89+
with:
90+
node-version: 16
91+
- name: Bootstrap project
92+
run: npm ci --ignore-scripts
93+
- name: Verify commit linting
94+
run: npx --no-install commitlint --from origin/master --to HEAD --verbose
95+
96+
codeql:
97+
name: CodeQL
98+
runs-on: ubuntu-latest
99+
permissions:
100+
# See: https://github.com/github/codeql-action/blob/008b2cc71c4cf3401f45919d8eede44a65b4a322/README.md#usage
101+
security-events: write
102+
steps:
103+
- name: Checkout repository
104+
uses: actions/checkout@v3
105+
106+
- name: Initialize CodeQL
107+
uses: github/codeql-action/init@v2
108+
with:
109+
languages: 'javascript'
110+
config-file: ./.github/codeql/codeql-config.yml
111+
112+
- name: Perform CodeQL Analysis
113+
uses: github/codeql-action/analyze@v2

.npmrc

+2-1
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
package-lock=false
1+
package-lock=true
2+
scripts-prepend-node-path=true

.travis.yml

+33-19
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,35 @@
1+
branches:
2+
only: master
3+
arch: arm64
4+
dist: focal
5+
services: docker
16
language: node_js
27
node_js:
3-
- "10"
4-
- "12"
5-
- "14"
6-
7-
env:
8-
- CXX=g++-4.8
9-
addons:
10-
apt:
11-
sources:
12-
- ubuntu-toolchain-r-test
13-
- mongodb-3.2-precise
14-
packages:
15-
- g++-4.8
16-
- mongodb-org-server
17-
- mongodb-org-shell
18-
services:
19-
- mongodb
20-
21-
after_success: npm run coverage
8+
- 10
9+
- 12
10+
- 14
11+
- 16
12+
- 17
13+
- 18
14+
before_install: |
15+
docker run --name=mongodb --publish=27017:27017 --detach mongo:4.4
16+
until docker exec --tty mongodb mongo --port=27017 --eval='db.serverStatus()'
17+
do
18+
sleep 1
19+
echo "."
20+
TIMER=$((TIMER + 1))
21+
if [ $TIMER -eq 20 ]; then
22+
echo "MongoDB did not initialize within 20 seconds. Exiting."
23+
exit 2
24+
fi
25+
done
26+
NODEJS_VERSION=$(node --version)
27+
if [ 'v10' == ${NODEJS_VERSION%%.*} ]
28+
then
29+
npm install --global npm@7
30+
else
31+
npm install --global npm@8
32+
fi
33+
install:
34+
- npm ci --ignore-scripts
35+
script: npm test --ignore-scripts

CHANGES.md

+132
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,135 @@
1+
2022-11-20, Version 7.0.0-alpha.1
2+
=================================
3+
4+
* ci: update Node.js test matrix (Rifa Achrinza)
5+
6+
* chore: update Node.js engine matrix (Rifa Achrinza)
7+
8+
* feat: upgrade mongodb driver to version 4.x (Antonio Ramón Sánchez Morales)
9+
10+
* chore: lock file maintenance (renovate[bot])
11+
12+
* chore: update supercharge/mongodb-github-action action to v1.8.0 (renovate[bot])
13+
14+
* chore: update dependency eslint to ^8.23.0 (renovate[bot])
15+
16+
* chore: update commitlint monorepo to v17 (renovate[bot])
17+
18+
* chore: update dependency eslint to ^8.19.0 (renovate[bot])
19+
20+
* chore: update github/codeql-action action to v2 (renovate[bot])
21+
22+
* chore: update dependency mocha to ^9.2.2 (renovate[bot])
23+
24+
* chore: update dependency loopback-datasource-juggler to ^4.27.1 (renovate[bot])
25+
26+
* chore: update dependency eslint to ^8.18.0 (renovate[bot])
27+
28+
* chore: update dependency strong-globalize to ^6.0.5 (renovate[bot])
29+
30+
* chore: update supercharge/mongodb-github-action action to v1.7.0 (renovate[bot])
31+
32+
* chore: update actions/setup-node action to v3 (renovate[bot])
33+
34+
* chore: update actions/checkout action to v3 (renovate[bot])
35+
36+
* chore: update dependency semver to ^7.3.7 (renovate[bot])
37+
38+
* chore: update dependency should to ^13.2.3 (renovate[bot])
39+
40+
* chore: update dependency debug to ^4.3.4 (renovate[bot])
41+
42+
* chore: update dependency loopback-connector to ^5.0.1 (renovate[bot])
43+
44+
* chore: update dependency bson to ^1.1.6 (renovate[bot])
45+
46+
* chore: update dependency bluebird to ^3.7.2 (renovate[bot])
47+
48+
* chore: update dependency async to ^3.2.4 (renovate[bot])
49+
50+
* ci: add renovate config (Rifa Achrinza)
51+
52+
* fix(*): run autoupdate in serial to avoid conflicts (Simon Stone)
53+
54+
* fix: optional chaining (preussmann)
55+
56+
* chore: update v6 EOL (Rifa Achrinza)
57+
58+
* ci: test against Node.js v18 (Rifa Achrinza)
59+
60+
61+
2022-03-31, Version 6.2.0
62+
=========================
63+
64+
* docs: add SECURITY.md (Diana Lau)
65+
66+
* chore: tls README example (d-bo)
67+
68+
* docs: update coc (Diana Lau)
69+
70+
* docs: add code of conduct (Diana Lau)
71+
72+
* chore: update v6 EOL (Rifa Achrinza)
73+
74+
* ci: fix typo (Rifa Achrinza)
75+
76+
* chore: update deps (Rifa Achrinza)
77+
78+
* feat: add tls options as of mongo 3.7 (d-bo)
79+
80+
* ci: update Node.js version (Rifa Achrinza)
81+
82+
* ci: pin NPM version (Rifa Achrinza)
83+
84+
* chore: add @achrinza and update CODEOWNERS (Diana Lau)
85+
86+
* fix: isObjectIDProperty array param check (Rifa Achrinza)
87+
88+
* fix: handle url default db name (Rifa Achrinza)
89+
90+
* ci: restrict GITHUB_TOKEN permissions (Rifa Achrinza)
91+
92+
93+
2021-09-07, Version 6.1.0
94+
=========================
95+
96+
* ci: misc updates (Rifa Achrinza)
97+
98+
* feat: add transaction support (Sergey Nosenko)
99+
100+
* ci: align gh actions workflow with 5.x (Rifa Achrinza)
101+
102+
* chore: move repo to loopbackio org (Diana Lau)
103+
104+
105+
2021-05-03, Version 6.0.1
106+
=========================
107+
108+
* fix: allows fields filter with custom field name (louis.nguyen)
109+
110+
* README: update notes about 6.0 (Miroslav Bajtoš)
111+
112+
113+
2021-03-22, Version 6.0.0
114+
=========================
115+
116+
* coerce values of array defined as ObjectID type (=)
117+
118+
* Update mongodb to ^3.6.4 (wolrajhti)
119+
120+
* ci: convert from Travis to Github action ci (Agnes Lin)
121+
122+
* README: mention our work on 6.0 (Miroslav Bajtoš)
123+
124+
* [SEMVER-MAJOR] Drop support for LoopBack 3.x (Yaapa Hage)
125+
126+
127+
2020-12-01, Version 5.5.0
128+
=========================
129+
130+
* atomic upsertWithWhere (#563) (Matteo Padovano)
131+
132+
1133
2020-09-02, Version 5.4.0
2134
=========================
3135

CODEOWNERS

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# the last matching pattern has the most precedence.
44

55
# Current maintainers
6-
* @jannyHou @dhmlau @nitro404 @emonddr @hacksparrow @agnes512
6+
* @dhmlau @nitro404 @hacksparrow @agnes512 @achrinza
77

88
# Alumni maintainers
9-
# @loay @virkt25 @shimks @b-admike
9+
# @loay @virkt25 @shimks @b-admike @jannyHou @emonddr

0 commit comments

Comments
 (0)