Skip to content

Commit e44ba9f

Browse files
authored
Merge branch 'main' into change-stream-tracing
2 parents 6d8506f + 75174c4 commit e44ba9f

28 files changed

Lines changed: 157 additions & 352 deletions

File tree

.changeset/six-plums-warn.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
'@powersync/service-module-postgres': patch
3+
'@powersync/service-errors': patch
4+
'@powersync/service-jpgwire': patch
5+
---
6+
7+
Improve Postgres query errors.

libs/lib-mongodb/test/tsconfig.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"extends": "../../../tsconfig.tests.json",
33
"compilerOptions": {
4-
"baseUrl": "./",
54
"paths": {},
65
"rootDir": "src"
76
},

libs/lib-postgres/test/tsconfig.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"extends": "../../../tsconfig.tests.json",
33
"compilerOptions": {
4-
"baseUrl": "./",
54
"paths": {},
65
"rootDir": "src"
76
},

modules/module-core/test/tsconfig.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"extends": "../../../tsconfig.tests.json",
33
"compilerOptions": {
4-
"baseUrl": "./",
54
"paths": {
65
"@/*": ["../../../packages/service-core/src/*"],
76
"@module/*": ["../src/*"],

modules/module-mongodb-storage/test/tsconfig.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"extends": "../../../tsconfig.tests.json",
33
"compilerOptions": {
4-
"baseUrl": "./",
54
"paths": {
65
"@/*": ["../../../packages/service-core/src/*"],
76
"@module/*": ["../src/*"],

modules/module-mongodb/test/tsconfig.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"extends": "../../../tsconfig.tests.json",
33
"compilerOptions": {
4-
"baseUrl": "./",
54
"paths": {
65
"@/*": ["../../../packages/service-core/src/*"],
76
"@module/*": ["../src/*"],

modules/module-mssql/test/tsconfig.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"extends": "../../../tsconfig.tests.json",
33
"compilerOptions": {
4-
"baseUrl": "./",
54
"paths": {
65
"@/*": ["../../../packages/service-core/src/*"],
76
"@module/*": ["../src/*"],

modules/module-mysql/test/tsconfig.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"extends": "../../../tsconfig.tests.json",
33
"compilerOptions": {
4-
"baseUrl": "./",
54
"paths": {
65
"@/*": ["../../../packages/service-core/src/*"],
76
"@module/*": ["../src/*"],

modules/module-postgres-storage/test/tsconfig.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"extends": "../../../tsconfig.tests.json",
33
"compilerOptions": {
4-
"baseUrl": "./",
54
"declarationDir": "dist/@types",
65
"tsBuildInfoFile": "dist/.tsbuildinfo",
76
"lib": ["ES2022", "esnext.disposable"],

modules/module-postgres/src/replication/PgManager.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import { PostgresTypeResolver } from '../types/resolver.js';
55
import { NormalizedPostgresConnectionConfig } from '../types/types.js';
66
import { getApplicationName } from '../utils/application-name.js';
77
import { getServerVersion } from '../utils/postgres_version.js';
8+
import { rquery } from './rquery.js';
89

910
export interface PgManagerOptions extends pgwire.PgPoolOptions {}
1011

@@ -70,14 +71,14 @@ export class PgManager extends BaseObserver<PgManagerListener> {
7071
// Use an shorter timeout for snapshot connections.
7172
// This is to detect broken connections early, instead of waiting
7273
// for the full 6 minutes.
73-
// This we are constantly using the connection, we don't need any
74+
// Since we are constantly using the connection, we don't need any
7475
// custom keepalives.
7576

7677
(connection as any)._socket.setTimeout(SNAPSHOT_SOCKET_TIMEOUT);
7778

7879
// Disable statement timeout for snapshot queries.
7980
// On Supabase, the default is 2 minutes.
80-
await connection.query(`set session statement_timeout = 0`);
81+
await rquery(connection, `set session statement_timeout = 0`);
8182

8283
return connection;
8384
}

0 commit comments

Comments
 (0)