You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
description: "In this tutorial we will show you how to improve the performance of the Supabase Connector for the [React Native To-Do List example app](https://github.com/powersync-ja/powersync-js/tree/main/demos/react-native-supabase-todolist)."
4
4
---
5
5
6
+
# Background
7
+
8
+
The demos in the [powersync-js](https://github.com/powersync-ja/powersync-js/tree/main/demos) monorepo provide a minimal working example that illustrate the use of PowerSync with different frameworks..
9
+
The demos are therefore not necessarily optimized for performance and can therefore be improved.
10
+
11
+
This tutorial demonstrates how to improve the Supabase Connector's performance by implementing two batching strategies that reduce the number of database operations.
12
+
13
+
# Batching Strategies
14
+
15
+
The two batching strategies that will be implemented are:
16
+
17
+
1. Sequential Merge Strategy, and
18
+
2. Pre-sorted Batch Strategy
19
+
6
20
<AccordionGroup>
7
21
<Accordiontitle="Sequential Merge Strategy">
22
+
Overview:
23
+
- Merge adjacent `PUT` and `DELETE` operations for the same table
24
+
- Limit the number of operations that are merged into a single API request to Supabase
8
25
<Note>
9
26
Shoutout to @christoffer_configura for the original implementation of this optimization.
0 commit comments