Skip to content
This repository has been archived by the owner on Dec 18, 2023. It is now read-only.

Added large document tests to Surreal DB #97

Merged
merged 4 commits into from
Oct 16, 2022

Conversation

Du-z
Copy link
Collaborator

@Du-z Du-z commented Oct 16, 2022

Note: This PR relies on fixes in #82 #95 to work, merge this one after it is completed.

The tests don't currently push past the limit outlined below:

For REST is looks like there is a limit in SurrealDB somewhere between 31238 bytes and 57862 bytes.

{
    "code": 413,
    "details": "Payload too large",
    "description": "The request has exceeded the maximum payload size. Refer to the documentation for the request limitations."
}

For RPC there seems to be a limit somewhere between 17926 bytes and 31238 bytes.

System.Net.WebSockets.WebSocketException
The remote party closed the WebSocket connection without completing the close handshake.
   at System.Net.WebSockets.ManagedWebSocket.ReceiveAsyncPrivate[TResult](Memory`1 payloadBuffer, CancellationToken cancellationToken)

@ProphetLamb
Copy link
Collaborator

@Du-z Did you mean #95 instead of #82, Things with JSON keys?

@Du-z
Copy link
Collaborator Author

Du-z commented Oct 16, 2022

@ProphetLamb Yeah your right, when #95 is merged.

Copy link
Collaborator

@ProphetLamb ProphetLamb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good

@@ -59,4 +61,11 @@ public static class TestHelper {
Exception ex = new(message);
throw ex;
}

public static string RandomString(int length = 10) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Du-z We have the Bogus package installed IIRC, this can be used to generate UNICODE dummy data, instead of a manual impl. Bogus is to .NET what faker is to JS

@ProphetLamb ProphetLamb merged commit 63a4635 into develop Oct 16, 2022
@ProphetLamb ProphetLamb deleted the feature/large_document_tests branch October 16, 2022 21:58
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants