Skip to content

[Chore] Update Alpha with Master #44

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

Merged
merged 28 commits into from
May 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
5c25fcd
Fix issue with re-using a shared Mutex.
rkistner Feb 29, 2024
b665748
Merge pull request #31 from powersync-ja/fix-mutex-reuse
rkistner Mar 5, 2024
5dbcb64
Use busy-timeout for database-level locks.
rkistner Apr 2, 2024
b8a68f9
Revert mutex change.
rkistner Apr 2, 2024
713cb12
Rename to lockTimeout.
rkistner Apr 2, 2024
b8121c2
Bump dart SDK.
rkistner Apr 2, 2024
28cf266
Clarify docs on multiple instances.
rkistner Apr 3, 2024
eef16ad
Add failing test.
rkistner Apr 3, 2024
8417334
Use ClosedException.
rkistner Apr 3, 2024
a722156
Fix "Concurrent modification during iteration" errors.
rkistner Apr 3, 2024
dea8505
Handle ClosedException in SqliteConnectionPool.
rkistner Apr 3, 2024
dd2bce0
Fix race condition in closing.
rkistner Apr 3, 2024
5cf85db
Slightly better handling of connection initialization errors.
rkistner Apr 3, 2024
3b79bce
Cleanup.
rkistner Apr 3, 2024
1af625b
Improve handling of uncaught errors in Isolates.
rkistner Apr 3, 2024
c01e637
Rewrite connection pooling queue.
rkistner Apr 3, 2024
726197f
Re-implement lockTimeout.
rkistner Apr 3, 2024
275b38d
Fix imports.
rkistner Apr 3, 2024
ea27d31
Add notes explaining the different locks.
rkistner Apr 4, 2024
662e578
Merge pull request #34 from powersync-ja/multi-isolates
rkistner Apr 4, 2024
2d59a09
Merge remote-tracking branch 'origin/main' into fix-closing
rkistner Apr 4, 2024
88d042b
Merge branch 'fix-closing' into connectionpool-performance
rkistner Apr 4, 2024
bea5c58
Merge pull request #38 from powersync-ja/connectionpool-performance
rkistner Apr 4, 2024
308076c
v0.6.1
rkistner Apr 4, 2024
9023a7b
Merge pull request #39 from powersync-ja/release/0.6.1
rkistner Apr 4, 2024
34e3161
chore: folder structure changes (#40)
DominicGBauer Apr 16, 2024
761baa4
update from master
stevensJourney May 28, 2024
b5fc3c9
qoutes
stevensJourney May 28, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## Next

- Add latest changes from master

## 0.7.0-alpha.3

- Add latest changes from master
Expand Down
2 changes: 1 addition & 1 deletion lib/sqlite3_common.dart
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
// Exports common Sqlite3 exports which are available on web and ffi environments
// Exports common Sqlite3 exports which are available in different environments.
export 'package:sqlite3/common.dart';
5 changes: 3 additions & 2 deletions test/native/basic_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -305,10 +305,11 @@ void main() {
// 4. Now second connection is ready. Second query has two connections to choose from.
// 5. However, first connection is closed, so it's removed from the pool.
// 6. Triggers `Concurrent modification during iteration: Instance(length:1) of '_GrowableList'`
final db = await testUtils.setupDatabase(path: path, initStatements: [
final db = SqliteDatabase.withFactory(
await testUtils.testFactory(path: path, initStatements: [
// Second connection to sleep more than first connection
'SELECT test_sleep(test_connection_number() * 10)'
]);
]));
await db.initialize();

final future1 = db.get('SELECT test_sleep(10) as sleep');
Expand Down
5 changes: 4 additions & 1 deletion test/utils/abstract_test_utils.dart
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,12 @@ abstract class AbstractTestUtils {
Future<TestDefaultSqliteOpenFactory> testFactory(
{String? path,
String sqlitePath = '',
List<String> initStatements = const [],
SqliteOptions options = const SqliteOptions.defaults()}) async {
return TestDefaultSqliteOpenFactory(
path: path ?? dbPath(), sqliteOptions: options);
path: path ?? dbPath(),
sqliteOptions: options,
);
}

/// Creates a SqliteDatabaseConnection
Expand Down
4 changes: 3 additions & 1 deletion test/utils/web_test_utils.dart
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,11 @@ class TestUtils extends AbstractTestUtils {
Future<TestDefaultSqliteOpenFactory> testFactory(
{String? path,
String? sqlitePath,
List<String> initStatements = const [],
SqliteOptions options = const SqliteOptions.defaults()}) async {
await _isInitialized;
return super.testFactory(path: path, options: webOptions);
return super.testFactory(
path: path, options: webOptions, initStatements: initStatements);
}

@override
Expand Down
260 changes: 0 additions & 260 deletions test/watch_shared_test.dart

This file was deleted.

Loading