Skip to content
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

feat: added support for batch request feature to WS server (#2461) #2475

Merged
merged 7 commits into from
May 13, 2024

Conversation

quiet-node
Copy link
Member

@quiet-node quiet-node commented May 10, 2024

Description:

  • adds support for batch request feature to WS server
  • adds WS neccessary config variables to configurations.md
  • added two new predefined errors, WS_BATCH_REQUESTS_DISABLED and WS_BATCH_REQUESTS_AMOUNT_MAX_EXCEEDED, to JsonRpcError object
  • added e2e tests to cover the new feature

Todo: #2474

Fixes #2461

Result

  • wscat:
image
  • postman
image image

Notes for reviewer:

Checklist

  • Documented (Code comments, README, etc.)
  • Tested (unit, integration, etc.)

@quiet-node quiet-node self-assigned this May 10, 2024
@quiet-node quiet-node added enhancement New feature or request P1 dev tools Features enabling dev tool integration labels May 10, 2024
Copy link

github-actions bot commented May 10, 2024

Tests

    2 files  147 suites   13s ⏱️
819 tests 818 ✔️ 1 💤 0
831 runs  830 ✔️ 1 💤 0

Results for commit 6d5da4e.

♻️ This comment has been updated with latest results.

Copy link

github-actions bot commented May 10, 2024

Acceptance Tests

  18 files  271 suites   23m 53s ⏱️
583 tests 577 ✔️ 3 💤 3
967 runs  953 ✔️ 9 💤 5

Results for commit 6d5da4e.

♻️ This comment has been updated with latest results.

@quiet-node quiet-node force-pushed the 2461-cannot-send-batch-requests-to-ws-server branch from 3c008bc to 718bc02 Compare May 10, 2024 22:29
AlfredoG87
AlfredoG87 previously approved these changes May 11, 2024
Copy link
Collaborator

@AlfredoG87 AlfredoG87 left a comment

Choose a reason for hiding this comment

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

LG. just a few nits! 👍

docs/configuration.md Outdated Show resolved Hide resolved
packages/ws-server/src/webSocketServer.ts Outdated Show resolved Hide resolved
packages/ws-server/src/webSocketServer.ts Outdated Show resolved Hide resolved
packages/ws-server/src/webSocketServer.ts Outdated Show resolved Hide resolved
AlfredoG87
AlfredoG87 previously approved these changes May 11, 2024
Copy link
Collaborator

@AlfredoG87 AlfredoG87 left a comment

Choose a reason for hiding this comment

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

LGTM

Signed-off-by: Logan Nguyen <logan.nguyen@swirldslabs.com>
…REQUESTS_AMOUNT_MAX_EXCEEDED

Signed-off-by: Logan Nguyen <logan.nguyen@swirldslabs.com>
AlfredoG87
AlfredoG87 previously approved these changes May 11, 2024
Signed-off-by: Logan Nguyen <logan.nguyen@swirldslabs.com>
Signed-off-by: Logan Nguyen <logan.nguyen@swirldslabs.com>
Signed-off-by: Logan Nguyen <logan.nguyen@swirldslabs.com>
Signed-off-by: Logan Nguyen <logan.nguyen@swirldslabs.com>
Signed-off-by: Logan Nguyen <logan.nguyen@swirldslabs.com>
Copy link

sonarcloud bot commented May 13, 2024

Quality Gate Passed Quality Gate passed

Issues
4 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

Copy link
Collaborator

@AlfredoG87 AlfredoG87 left a comment

Choose a reason for hiding this comment

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

LGTM

@quiet-node quiet-node merged commit a1d7632 into main May 13, 2024
33 checks passed
@quiet-node quiet-node deleted the 2461-cannot-send-batch-requests-to-ws-server branch May 13, 2024 16:01
@quiet-node quiet-node added this to the 0.48.0 milestone May 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dev tools Features enabling dev tool integration enhancement New feature or request P1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cannot send batch requests via WS endpoints
2 participants