Daniel
967700bdbc
fix: LiveQuery server is not shut down properly when handleShutdown is called ( #8491 )
2023-06-08 11:04:49 +02:00
Corey
656d673cf5
feat: Add support for $eq query constraint in LiveQuery ( #8614 )
2023-06-08 04:04:58 +02:00
Daniel
c2e4f8369b
refactor: Upgrade lru-cache from 7.12.0 to 9.1.1 ( #8559 )
2023-05-25 23:59:42 +02:00
Daniel
4ce135a4fe
fix: LiveQuery can return incorrectly formatted date ( #8456 )
2023-03-06 11:26:06 +01:00
Daniel
a49e323d5a
feat: Deprecate LiveQuery fields option in favor of keys for semantic consistency ( #8388 )
2023-02-17 13:24:33 +01:00
Daniel
fc92faac75
feat: Add ParseQuery.watch to trigger LiveQuery only on update of specific fields ( #8028 )
2023-01-16 12:32:22 +01:00
Daniel
f3bcc9365c
feat: Access the internal scope of Parse Server using the new maintenanceKey; the internal scope contains unofficial and undocumented fields (prefixed with underscore _) which are used internally by Parse Server; you may want to manipulate these fields for out-of-band changes such as data migration or correction tasks; changes within the internal scope of Parse Server may happen at any time without notice or changelog entry, it is therefore recommended to look at the source code of Parse Server to understand the effects of manipulating internal fields before using the key; it is discouraged to use the maintenanceKey for routine operations in a production environment; see [access scopes]( https://github.com/parse-community/parse-server#access-scopes ) ( #8212 )
...
BREAKING CHANGE: Fields in the internal scope of Parse Server (prefixed with underscore `_`) are only returned using the new `maintenanceKey`; previously the `masterKey` allowed reading of internal fields; see [access scopes](https://github.com/parse-community/parse-server#access-scopes ) for a comparison of the keys' access permissions (#8212 )
2023-01-08 22:02:12 +01:00
Daniel
b2761fb378
feat: Upgrade Redis 3 to 4 for LiveQuery ( #8333 )
2022-11-26 17:45:30 +01:00
Diamond Lewis
0f763da17d
feat: liveQuery support for unsorted distance queries ( #8221 )
2022-10-12 00:27:29 +02:00
Stew
1d9605bc93
fix: liveQuery with containedIn not working when object field is an array ( #8128 )
2022-09-17 13:59:45 +02:00
Manuel
9fd4516cde
fix: protected fields exposed via LiveQuery (GHSA-crrq-vr9j-fxxh) [skip release] ( #8076 )
2022-06-30 13:01:40 +02:00
Layne Bernardo
03caae1e61
fix: websocket connection of LiveQuery interrupts frequently ( #8048 )
2022-06-17 13:20:48 +02:00
Antoine Cormouls
72fac8a5fc
refactor: lru-cache maxAge to ttl ( #8039 )
2022-06-13 15:29:50 +02:00
dblythy
199dfc1722
fix: live query role cache does not clear when a user is added to a role ( #8026 )
2022-06-11 10:21:55 +02:00
Javad
2d5221e480
fix: interrupted WebSocket connection not closed by LiveQuery server ( #8012 )
2022-06-05 16:01:48 +02:00
dblythy
443a509905
feat: improved LiveQuery error logging with additional information ( #7837 )
2022-03-23 02:11:39 +01:00
dblythy
12eb6c823b
refactor: replace hardcoded error codes with references ( #7546 )
2021-10-18 20:19:47 +02:00
dblythy
68a3a87501
fix: set objects in afterFind triggers ( #7311 )
2021-10-09 02:34:09 +02:00
dblythy
caee281bc5
fix: allow LiveQuery on Parse.Session ( #7554 )
2021-10-08 17:24:33 +02:00
dblythy
834ae366f9
Merge pull request from GHSA-7pr3-p5fm-8r9x
...
* fix: strip sessionToken on _User LiveQuery
* delete authData
* add changelog
* Update package.json
* Update CHANGELOG.md
* add changes
* Update ParseLiveQuery.spec.js
Co-authored-by: Manuel <5673677+mtrezza@users.noreply.github.com >
2021-09-30 04:52:12 +02:00
Corey
24e9bdc639
ci: Fix docker image pushing to Docker Hub ( #7548 )
...
* add actions file
* nit
* add multi-platform
* add buildx
* reduce platforms
* remove arm7
* add back arm7
* add missing archs
* remove failing image
* add back in linux/s390x
* switch image name to parse-server
* remove failing images
* nit spelling
* Nit
* add comment about nightly builds
2021-09-07 14:35:03 +02:00
Snyk bot
c3b71ba5b6
[Snyk] Upgrade ws from 7.4.6 to 7.5.3 ( #7457 )
...
* fix: upgrade ws from 7.4.6 to 7.5.0
Snyk has created this PR to upgrade ws from 7.4.6 to 7.5.0.
See this package in npm:
https://www.npmjs.com/package/ws
See this project in Snyk:
https://app.snyk.io/org/acinader/project/8c1a9edb-c8f5-4dc1-b221-4d6030a323eb?utm_source=github&utm_medium=upgrade-pr
* changed logging for circular obj
* upgraded to ws 7.5.3
Co-authored-by: Manuel Trezza <5673677+mtrezza@users.noreply.github.com >
2021-07-25 01:54:28 +02:00
Jason Posthuma
d8dc524c08
Add check for property ( #7421 )
...
* Add check for property
* updated changelog
* Fixed logic returning false positive
* Added test case
* update change log
2021-06-21 16:11:15 -07:00
dblythy
51e08009f8
Fix: properly pass req.user to liveQuery triggers ( #7296 )
2021-05-02 11:23:46 +02:00
Perceval Archimbaud
87dcd23b6a
Fix #7340 by correclty computing function name for push event ( #7341 )
...
* Add a failing test for issue #7340
If any delay occurs after "message.event" assignation in
LiveQueryServer._onAfterSave, the next subscription or request with a different
event might overwrite it, and by that using the wrong "push" function name.
* Remove updade of message and use res.event instead
This prevent computing function name from a
incorrect event if multiple subscriptions override
one by one the message.event.
* Update CHANGELOG.md
* Replace setTimeout by async/await expressions
2021-04-13 14:47:14 -07:00
dblythy
3d76643286
New: requireAnyUserRoles and requireAllUserRoles for Parse Cloud Validator ( #7097 )
...
* new: requireUserRole for Parse Cloud Validator
* change to requireUserRoles
* Update CHANGELOG.md
* revoke triggers
* Update triggers.js
* Update ParseLiveQueryServer.js
* Update ParseLiveQueryServer.js
* create requireUserRoles
* rename to requireAny and requireAll
* allow for a function
2021-02-12 14:01:38 -08:00
Diamond Lewis
1ede078154
fix(Logger): Handle interpolating stdout ( #7114 )
...
* fix(Logger): Handle interpolating stdout
* Update CHANGELOG.md
2021-01-11 09:20:21 -06:00
Diamond Lewis
93781b2195
feat(LiveQuery): Support $and, $nor, $containedBy, $geoWithin ( #7113 )
...
* feat(LiveQuery): Support $and, $nor, $containedBy, $geoWithin, $geoIntersects
* Update CHANGELOG.md
* Update CHANGELOG.md
2021-01-11 01:35:32 -06:00
dblythy
b13a6a4ed2
feat: include sessionToken in onLiveQueryEvent ( #7043 )
...
* feat: include user in onLiveQueryEvent
* Update ParseLiveQuery.spec.js
* increase coverage
* add space
* Update ParseLiveQuery.spec.js
* remove user from runLiveQueryEventHandlers
2020-12-03 18:36:41 -06:00
dblythy
0bf2e84f81
fix: consistent casing for afterLiveQueryEvent ( #7023 )
2020-11-24 13:58:35 -08:00
Diamond Lewis
e6ac3b6932
fix(prettier): Properly handle lint-stage files ( #6970 )
...
Now handles top level files and recursive files in folders.
Set max line length to be 100
2020-10-25 15:06:58 -05:00
Antonio Davi Macedo Coelho de Castro
78b59fb26b
Merge pull request from GHSA-2xm2-xj2q-qgpj
...
* Test case and fixes
* Change requestTimeout default to 5s
* Document new function argument
2020-10-21 16:32:07 -07:00
dblythy
ef2e54c39d
LiveQueryEvent Error Logging Improvements ( #6951 )
...
* LiveQueryEvent Improvements
* Update ParseLiveQueryServer.js
* Update ParseLiveQueryServer.js
* More Tests
* Update ParseLiveQueryServer.js
* Pass thrown errors to subscription
* Update ParseLiveQueryServer.js
* Update ParseLiveQueryServer.js
* Remove ACL error
2020-10-21 16:50:21 -05:00
dblythy
bf39cd68ef
Create Cloud function afterLiveQueryEvent ( #6859 )
...
* Before Connect + Before Subscribe #1
* Cleanup and Documentation
* Add E2E tests
* Bump parse to 2.15.0
* Create afterLiveQueryEvent
* Revert "Create afterLiveQueryEvent"
This reverts commit 828c678a6995216b843a75f5b3c864aec063ba43.
* afterLiveQueryEvent
* Add delete event
* Fix failing tests
* Fix lint
* Update ParseLiveQueryServer.js
* Remove Facebook AccountKit auth (#6870 )
* Remove Facebook AccountKit auth
Account Kit services are no longer available.
https://developers.facebook.com/blog/post/2019/09/09/account-kit-services-no-longer-available-starting-march/
https://www.sinch.com/blog/facebook-account-kit-is-closing-down-are-your-apps-covered/
* remove flaky test
* fix: upgrade uuid from 8.2.0 to 8.3.0 (#6865 )
Snyk has created this PR to upgrade uuid from 8.2.0 to 8.3.0.
See this package in npm:
https://www.npmjs.com/package/uuid
See this project in Snyk:
https://app.snyk.io/org/acinader/project/8c1a9edb-c8f5-4dc1-b221-4d6030a323eb?utm_source=github&utm_medium=upgrade-pr
Co-authored-by: Diamond Lewis <findlewis@gmail.com >
* fix: package.json & package-lock.json to reduce vulnerabilities (#6864 )
The following vulnerabilities are fixed with an upgrade:
- https://snyk.io/vuln/SNYK-JS-LODASH-590103
Co-authored-by: Diamond Lewis <findlewis@gmail.com >
* fix: upgrade ldapjs from 2.0.0 to 2.1.0 (#6857 )
Snyk has created this PR to upgrade ldapjs from 2.0.0 to 2.1.0.
See this package in npm:
https://www.npmjs.com/package/ldapjs
See this project in Snyk:
https://app.snyk.io/org/acinader/project/8c1a9edb-c8f5-4dc1-b221-4d6030a323eb?utm_source=github&utm_medium=upgrade-pr
Co-authored-by: Diamond Lewis <findlewis@gmail.com >
* fix: upgrade apollo-server-express from 2.15.1 to 2.16.0 (#6851 )
Snyk has created this PR to upgrade apollo-server-express from 2.15.1 to 2.16.0.
See this package in npm:
https://www.npmjs.com/package/apollo-server-express
See this project in Snyk:
https://app.snyk.io/org/acinader/project/8c1a9edb-c8f5-4dc1-b221-4d6030a323eb?utm_source=github&utm_medium=upgrade-pr
Co-authored-by: Diamond Lewis <findlewis@gmail.com >
* fix: upgrade @graphql-tools/stitch from 6.0.12 to 6.0.13 (#6845 )
Snyk has created this PR to upgrade @graphql-tools/stitch from 6.0.12 to 6.0.13.
See this package in npm:
https://www.npmjs.com/package/@graphql-tools/stitch
See this project in Snyk:
https://app.snyk.io/org/acinader/project/8c1a9edb-c8f5-4dc1-b221-4d6030a323eb?utm_source=github&utm_medium=upgrade-pr
Co-authored-by: Diamond Lewis <findlewis@gmail.com >
* fix: upgrade @graphql-tools/utils from 6.0.12 to 6.0.13 (#6846 )
Snyk has created this PR to upgrade @graphql-tools/utils from 6.0.12 to 6.0.13.
See this package in npm:
https://www.npmjs.com/package/@graphql-tools/utils
See this project in Snyk:
https://app.snyk.io/org/acinader/project/8c1a9edb-c8f5-4dc1-b221-4d6030a323eb?utm_source=github&utm_medium=upgrade-pr
Co-authored-by: Diamond Lewis <findlewis@gmail.com >
* [Snyk] Upgrade winston from 3.2.1 to 3.3.2 (#6799 )
* fix: upgrade winston from 3.2.1 to 3.3.2
Snyk has created this PR to upgrade winston from 3.2.1 to 3.3.2.
See this package in NPM:
https://www.npmjs.com/package/winston
See this project in Snyk:
https://app.snyk.io/org/acinader/project/8c1a9edb-c8f5-4dc1-b221-4d6030a323eb?utm_source=github&utm_medium=upgrade-pr
* fix tests
Co-authored-by: Diamond Lewis <findlewis@gmail.com >
* afterLiveQueryEvent
* Add delete event
* Fix failing tests
* Before Connect + Before Subscribe #1
* Cleanup and Documentation
* Create afterLiveQueryEvent
* Revert "Create afterLiveQueryEvent"
This reverts commit 828c678a6995216b843a75f5b3c864aec063ba43.
* Update ParseLiveQueryServer.js
* Rebase
* Remove return value / deduplicate tests
* Add docs
* Add additional data to trigger
Co-authored-by: Diamond Lewis <findlewis@gmail.com >
Co-authored-by: Snyk bot <snyk-bot@snyk.io >
2020-10-19 10:38:55 -05:00
dblythy
44015c3e35
Before Connect + Before Subscribe help required ( #6793 )
...
* Before Connect + Before Subscribe #1
* Cleanup and Documentation
* Add E2E tests
* Bump parse to 2.15.0
Co-authored-by: Diamond Lewis <findlewis@gmail.com >
2020-07-16 20:36:38 -05:00
Diamond Lewis
142eaa71bd
Run Prettier JS #2 ( #6796 )
2020-07-13 15:13:08 -07:00
Diamond Lewis
e6a6354b29
Run Prettier JS ( #6795 )
2020-07-13 13:06:52 -05:00
greenkeeper[bot]
b1506995ad
Update uuid to the latest version 🚀 ( #6659 )
...
* fix(package): update uuid to version 8.0.0
* chore(package): update lockfile package-lock.json
* remove deprecated uuid/v4
* use uuidv4 as default
Co-authored-by: greenkeeper[bot] <23040076+greenkeeper[bot]@users.noreply.github.com>
Co-authored-by: Diamond Lewis <findlewis@gmail.com >
2020-04-30 05:21:51 +00:00
Diamond Lewis
ca1ae336c9
Websocket: unhandle rejection ( #6418 )
...
* Websocket: unhandle rejection
Closes: https://github.com/parse-community/parse-server/issues/6413 , https://github.com/parse-community/parse-server/issues/6173
Prevent crashing on websocket error.
Bonus points to anybody who can post a specific payload that the client sends that returns an error.
* log the socket
* fix tests
* fix payload reference link
2020-02-19 01:30:23 -08:00
Diamond Lewis
5bf87d86bb
Improve WebSocketServer Error Handling ( #6230 )
...
* Improve WebSocketServer Error Handling
Closes: https://github.com/parse-community/parse-server/issues/6173
Prevents an unhandled server rejection.
Includes an example for LiveQuery test and closing the proper connections.
Improve live query monitoring
* fix tests
2019-11-22 15:23:04 -06:00
Diamond Lewis
2533db0ad3
Fix installationId on LiveQuery connect ( #6180 )
...
Throws an error and prevents LiveQuery from reconnecting.
Fixes Monitoring installationId.
Allow installationId to be sent to and from client.
2019-11-04 15:53:13 -06:00
Diamond Lewis
3ab9dcdfd0
Improve Live Query Monitoring ( #5927 )
...
* Improve Live Query Monitoring
* typo
2019-08-16 11:38:24 -07:00
Diamond Lewis
cf6e79ee75
Fix: Lint no-prototype-builtins ( #5920 )
...
* Fix: Lint no-prototype-builtins
Closes: https://github.com/parse-community/parse-server/issues/5842
Reference: https://eslint.org/docs/rules/no-prototype-builtins
* replace Object.hasOwnProperty.call
2019-08-14 14:57:00 -07:00
Douglas Muraoka
ef14ca530d
GraphQL Object constraints ( #5715 )
...
* GraphQL Object constraints
Implements the GraphQL Object constraints, which allows us to filter queries results using the `$eq`, `$lt`, `$gt`, `$in`, and other Parse supported constraints.
Example:
```
query objects {
findMyClass(where: {
objField: {
_eq: {
key: 'foo.bar',
value: 'hello'
},
_gt: {
key: 'foo.number',
value: 10
},
_lt: {
key: 'anotherNumber',
value: 5
}
}
}) {
results {
objectId
}
}
}
```
In the example above, we have the `findMyClass` query (automatically generated for the `MyClass` class), and a field named `objField` whose type is Object. The object below represents a valid `objField` value and would satisfy all constraints:
```
{
"foo": {
"bar": "hello",
"number": 11
},
"anotherNumber": 4
}
```
The Object constraint is applied only when using Parse class object type queries. When using "generic" queries such as `get` and `find`, this type of constraint is not available.
* Objects constraints not working on Postgres
Fixes the $eq, $ne, $gt, and $lt constraints when applied on an Object type field.
* Fix object constraint field name
* Fix Postgres constraints indexes
* fix: Object type composed constraints not working
* fix: Rename key and value fields
* refactor: Object constraints for generic queries
* fix: Object constraints not working on Postgres
2019-08-02 12:18:07 -07:00
Antonio Davi Macedo Coelho de Castro
bde96a9002
Fix live query ( #5871 )
...
* Fix live query
* fix test
2019-07-30 22:40:54 -05:00
Diamond Lewis
218c3499f9
Implement WebSocketServer Adapter ( #5866 )
...
* Implement WebSocketServerAdapter
* lint
* clean up
2019-07-30 09:05:41 -05:00
Zeal Murapa
4f21c36825
Update ParseWebSocketServer.js ( #5860 )
...
* Update ParseWebSocketServer.js
fix wss:// error by requiring 'ws' module, remove uws as it has been deprecated and removed from npm
* Update ParseWebSocketServer.js
* remove uws
2019-07-28 22:17:09 -05:00
Diamond Lewis
af6c44eca4
Handle LiveQuery create event with fields ( #5790 )
...
Close: https://github.com/parse-community/parse-server/issues/5764
Fix logic handling null original object
2019-07-10 10:14:55 -05:00
ananfang
fa97df5f4e
Decode Date JSON value at LiveQuery ( #5540 )
2019-04-30 13:00:23 -05:00
Diamond Lewis
ce7ff2ca44
Add original object to LiveQuery Events ( #5265 )
...
* Add original object to LiveQuery Events
* change response original
2018-12-28 17:56:08 -05:00