-
Notifications
You must be signed in to change notification settings - Fork 203
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
graphql.schema type with Subscriptions: null in causes errors when working with DataStore #928
Comments
Hi @dougie181, Thanks for reaching out to us and taking the time to explain your use case. To better assist you, I will attempt to re-state your use case. Your application has a model called |
Hi @wooj2, |
Hi @dougie181 , Thanks for getting back to us so quickly. I've talked with the team, and unfortunately, there is not an easy way to do this right now. We are considering this as a feature request and will keep you posted on any progress on this front. |
This issue is stale because it has been open for 14 days with no activity. Please, provide an update or it will be automatically closed in 7 days. |
Are there any updates on this feature request ? |
For what it's worth, since this issue has been opened, we have made some changes in DataStore to continue to operate against disabled subscriptions, the logic in the client library checks if the subscription request returns "Operation disabled". The way to set this up still isn't a fully supported use case that we have documented, but you can modify the subscription operation response mapping in AppSync to return "Operation disabled". Let us know if you are still looking for a solution to this and we can add an integration test that uses a |
Since we haven't heard back on this issue in awhile now, feel free to open a new issue if something isn't working |
|
Describe the bug
I am getting the following subscription errors in my app:
I have two types defined in a graphql.schema.
I am using datastore to sync Device data with the cloud and between devices. The DeviceState data is created from another source and am using API.query as a query method and I do not want to receive subscriptions for this data.
With the above schema, Datastore and subscriptions are not working at all.
If I remove the subscriptions: null from the DeviceState, the app works without any issues, although the app is then bombarded with subscription events from DeviceState, which I do not want.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
I would like to received subscriptions for Device data but not for DeviceState data.
Environment(please complete the following information):
Device Information (please complete the following information):
Additional context
This may not be a bug, so any advice on how I can achieve this using a GraphQL API would be much appreciated.
The text was updated successfully, but these errors were encountered: