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
Copy file name to clipboardExpand all lines: CHANGELOG.md
+17
Original file line number
Diff line number
Diff line change
@@ -1,3 +1,20 @@
1
+
## 4.0.1
2
+
3
+
- upgrade sharedb
4
+
5
+
6
+
## 4.0.0
7
+
8
+
- upgrade `pg` from 7.4.1 to 8.5.1 to prevent silent failure for node v14 or later, reported in [this issue](https://github.com/brianc/node-postgres/issues/2317).
9
+
- fix submit ops failed due to version mismatched - https://github.com/share/sharedb-postgres/issues/8
10
+
11
+
## Note about re-versioning
12
+
13
+
Original `sharedb-postgres` seems to have been not maintained for a long time since 2018. Thus we made a fork and maintain it as `@plotdb/sharedb-postgre`.
14
+
15
+
16
+
# Change log in original repo
17
+
1
18
## 3.0.0
2
19
3
20
Thanks to @billwashere, we upgraded to a more modern version of `pg` (4.5.1 ->
Copy file name to clipboardExpand all lines: README.md
+52-6
Original file line number
Diff line number
Diff line change
@@ -1,22 +1,68 @@
1
-
# sharedb-postgres
1
+
# @plotdb/sharedb-postgres
2
2
3
-
PostgreSQL database adapter for [sharedb](https://github.com/share/sharedb). This
4
-
driver can be used both as a snapshot store and oplog.
3
+
PostgreSQL database adapter for [sharedb](https://github.com/share/sharedb). This driver can be used both as a snapshot store and oplog.
5
4
6
5
Doesn't support queries (yet?).
7
6
8
7
Moderately experimental. (This drives [Synaptograph](https://www.synaptograph.com)'s backend, and [@nornagon](https://github.com/nornagon) hasn't noticed any issues so far.)
9
8
10
9
10
+
## Note about versioning
11
+
12
+
This is a fork from the [original `sharedb-postgres`](https://github.com/share/sharedb-postgres) and its relative forks (see [billwashere](https://github.com/billwashere/sharedb-postgres-jsonb), [zbryikt](https://github.com/zbryikt/sharedb-postgres-jsonb). It seems to have been not maintained for a long time since 2018, Thus we decide to fork it and maintain it as `@plotdb/sharedb-postgre`.
13
+
14
+
15
+
## Installation
16
+
17
+
```cmd
18
+
npm i @plotdb/sharedb-postgres
19
+
```
20
+
21
+
22
+
## Requirements
23
+
24
+
Due to the fix to resolve [high concurency issues](https://github.com/share/sharedb-postgres/issues/1) Postgres 9.5+ is now required.
25
+
26
+
## Migrating older versions
27
+
28
+
Older versions of this adaptor used the data type json. You will need to alter the data type prior to using if you are upgrading.
29
+
30
+
```PLpgSQL
31
+
ALTERTABLE ops
32
+
ALTER COLUMN operation
33
+
SET DATA TYPE jsonb
34
+
USING operation::jsonb;
35
+
36
+
ALTERTABLE snapshots
37
+
ALTER COLUMN data
38
+
SET DATA TYPE jsonb
39
+
USING data::jsonb;
40
+
```
41
+
11
42
## Usage
12
43
13
-
`sharedb-postgres` wraps native [node-postgres](https://github.com/brianc/node-postgres), and it supports the same configuration options.
44
+
`sharedb-postgres-jsonb` wraps native [node-postgres](https://github.com/brianc/node-postgres), and it supports the same configuration options.
14
45
15
46
To instantiate a sharedb-postgres wrapper, invoke the module and pass in your
16
-
PostgreSQL configuration as an argument. For example:
47
+
PostgreSQL configuration as an argument or use environmental arguments.
0 commit comments