DataStore SYNC query builder does not allow/include filter by owner
See original GitHub issueDescribe the bug
The DataStore is not including the owner
as part of the sync query. Unless this is a limitation on how AppSync implements/expects sync, I think this is a BUG and causes scalability issues.
To Reproduce
- Install and init
- Implement a simple schema with type having
@model
and@auth
- Configure @auth to include owner
- Configure DataStore
Expected behavior
The DataStore internally builds all queries and mutations. Since we have @auth with owner, it is expected that the owner
field is populated on all queries, including sync queries. This is not the case.
Code Snippet
Here’s where the SYNC query is built. The query does not allows for passing filter
.
https://github.com/aws-amplify/amplify-js/blob/main/packages/datastore/src/sync/utils.ts#L268-L278
documentArgs = `($limit: Int, $nextToken: String, $lastSync: AWSTimestamp)`;
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:11 (3 by maintainers)
Top Results From Across the Web
How can I create a dynamic query in Amplify Datastore
let just say you have an object which defines what user can use what filter queries. Here I assumed user can be of...
Read more >R2022-06 (cumulative patch) - 7.3 - Talend Help Center
From version 7.3.10 onwards, Talend CI Builder is available in the ... Combination of distinct and filtering on same loop does not work ......
Read more >@ember-data/private-build-infra | Yarn - Package Manager
EmberData is a lightweight reactive data library for JavaScript applications that provides composable primitives for ordering query/mutation/peek flows, ...
Read more >Migrator for Notes to Exchange 4.15.2 Program Parameters ...
for sites that do not require free/busy synchronization through the Connector. ... AD search query, to tell the program which AD user objects...
Read more >Untitled
... Bump version to 1.3.9.1-3 - Resolves: Bug 1651279 - The dirsrv user is no ... rootfs-generator: don't set JobRunningTimeoutSec - Sync initramfs...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hey @abdielou, you will be able to pass a filter to the sync query once the feature in this PR gets released
This issue has been automatically locked since there hasn’t been any recent activity after it was closed. Please open a new issue for related bugs.
Looking for a help forum? We recommend joining the Amplify Community Discord server
*-help
channels or Discussions for those types of questions.