-
Notifications
You must be signed in to change notification settings - Fork 3.3k
improvement(ratelimits, sockets): increase across all plans, reconnecting notif for sockets #3096
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
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Greptile OverviewGreptile SummaryThis PR increases rate limits across all subscription tiers and adds reconnection notifications for improved user experience during socket disruptions. Rate Limit Changes:
All user-facing documentation, UI components, email templates, and deployment configs have been consistently updated. Socket Reconnection Improvements:
Cross-Workflow Protection: Minor Issues:
Confidence Score: 4/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant Client as Client (Browser)
participant Socket as Socket Provider
participant Server as Socket.IO Server
participant Room as Room Manager
participant DB as Database
Note over Client,DB: Normal Operation
Client->>Socket: User makes workflow change
Socket->>Server: emit('subblock-update', {workflowId, ...})
Server->>Room: Validate workflowId matches session
Room-->>Server: Validation OK
Server->>DB: Update subblock value
DB-->>Server: Update confirmed
Server->>Client: broadcast('subblock-update') to room
Note over Client,DB: Socket Disconnection
Server--xClient: Connection lost
Socket->>Socket: Set isConnected = false
Socket->>Socket: Check socket.active = true
Socket->>Socket: Set isReconnecting = true
Socket->>Client: Show "Reconnecting..." notification
Note over Client,DB: Reconnection Process
Socket->>Server: socketInstance.io reconnect attempt
Server-->>Socket: connect_error (temporary)
Socket->>Socket: isReconnecting remains true
Socket->>Server: socketInstance.io reconnect attempt 2
Server-->>Socket: connect success
Socket->>Socket: Set isConnected = true
Socket->>Socket: Set isReconnecting = false
Socket->>Client: Remove "Reconnecting..." notification
Socket->>Server: emit('join-workflow', workflowId)
Server->>Room: Add socket to workflow room
Room-->>Socket: join-workflow-success + presence
Note over Client,DB: Operation Queue Resumes
Socket->>Server: Process queued operations
Server->>Room: Validate workflowId for each operation
Server->>DB: Apply queued changes
Server->>Client: Broadcast updates to room
Note over Client,DB: Cross-Workflow Protection
Client->>Socket: Operation with workflowId A
Socket->>Server: emit with workflowId A in payload
Server->>Room: Check sessionWorkflowId = B
Room-->>Server: Mismatch detected
Server->>Socket: emit('operation-failed', retryable)
Socket->>Socket: Queue handles retry
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
3 files reviewed, no comments
|
@cursor review |
apps/sim/app/workspace/[workspaceId]/providers/workspace-permissions-provider.tsx
Show resolved
Hide resolved
|
@cursor review |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
6 files reviewed, 2 comments
Additional Comments (1)
Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time! Prompt To Fix With AIThis is a comment left during a code review.
Path: apps/sim/hooks/use-collaborative-workflow.ts
Line: 1182:1182
Comment:
inconsistent variable usage - should use `activeWorkflowId` like other operations instead of re-fetching from store as `currentActiveWorkflowId`
```suggestion
workflowId: activeWorkflowId || '',
```
<sub>Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!</sub>
How can I resolve this? If you propose a fix, please make it concise. |
Summary
Sockets -- Reconnecting... notif since workflow join in self healing now.
New Rate Limits
RATE_LIMIT_FREE_SYNC=50
RATE_LIMIT_FREE_ASYNC=200
RATE_LIMIT_PRO_SYNC=150
RATE_LIMIT_PRO_ASYNC=1000
RATE_LIMIT_TEAM_SYNC=300
RATE_LIMIT_TEAM_ASYNC=2500
RATE_LIMIT_ENTERPRISE_SYNC=600
RATE_LIMIT_ENTERPRISE_ASYNC=5000
Type of Change
Testing
N/A
Checklist