Add test with graphql and sqlite storage#6782
Closed
mapineaultvooban wants to merge 12 commits intopubkey:masterfrom
Closed
Add test with graphql and sqlite storage#6782mapineaultvooban wants to merge 12 commits intopubkey:masterfrom
mapineaultvooban wants to merge 12 commits intopubkey:masterfrom
Conversation
the _attachments is leaked in the graphql payload
pubkey
reviewed
Jan 24, 2025
| }); | ||
| }; | ||
|
|
||
| const dbName = randomCouchString(10); |
Owner
There was a problem hiding this comment.
randomCouchString is called randomToken in RxDB v16.
Author
There was a problem hiding this comment.
I created this branch based on RxDB 15.39, because we are not ready to switch to RxDB 16 yet (we will switch to the version 16 eventually). Would it be possible to fix this issue in RxDB 15.39?
randomToken is not available in RxDB 15.39
Owner
|
Hi @mapineaultvooban |
* OnPage SEO * ADD stuff * ADD meta data * FIX sidebar titles * ADD internal links
* OnPage SEO * ADD stuff * ADD meta data * FIX sidebar titles * ADD internal links * ADD landingpage indexeddb v2
the _attachments is leaked in the graphql payload
…tachment' into graphql_replication_attachment
4 tasks
This reverts commit fbaea6c.
Owner
|
I am sorry but this PR has 528 changed files and is unreadable. Please rebase or recreate. Also please never commit files from the |
Owner
|
Replaced by #6786 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
the _attachments is leaked in the graphql payload
This PR contains:
A unit test that executes a migration on a database with a sqlite storage. Then a graphql server sends an update with leaked property (assumedMasterState contains the _attachments property). I wrote some comments in the test, because I don't have access to the premium package (RxStorageSQLite) in this repository.
When we use a different storage (e.g in memory or another default storage in the public package), the test passed.
Describe the problem you have without this PR
In our project, we use a RxDatabase with
In one of our schemas, we add a new migration. when executed, it seems that the _attachments property is followed. When a user updates a property in an entity, the graphQL server push the update to our backend, causing an error in the serialization (input -> classes).
Here is a payload of one of our shemas with the problem. In the entity's masterState, we can see that the _attachments property is leaked.
Here is our database setup
Todos