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: README.md
+30-61Lines changed: 30 additions & 61 deletions
Original file line number
Diff line number
Diff line change
@@ -10,74 +10,43 @@ This is mirror of postgres repo with several changes to the core and few extra e
10
10
11
11
* Transaction manager interface (eXtensible Transaction Manager, xtm). Generic interface to plug distributed transaction engines. More info at [[https://wiki.postgresql.org/wiki/DTM]] and [[http://www.postgresql.org/message-id/flat/F2766B97-555D-424F-B29F-E0CA0F6D1D74@postgrespro.ru]].
12
12
* Distributed deadlock detection API.
13
-
* Fast 2pc patch. More info at [[http://www.postgresql.org/message-id/flat/74355FCF-AADC-4E51-850B-47AF59E0B215@postgrespro.ru]]
13
+
* Logical decoding of two-phase transactions.
14
+
14
15
15
16
## New extensions:
16
17
17
-
* pg_dtm. Transaction management by interaction with standalone coordinator (Arbiter or dtmd). [[https://wiki.postgresql.org/wiki/DTM#DTM_approach]]
18
18
* pg_tsdtm. Coordinator-less transaction management by tracking commit timestamps.
19
10000
19
* multimaster. Synchronous multi-master replication based on logical_decoding and pg_dtm.
20
20
21
21
22
22
## Changed extension:
23
23
24
-
* postgres_fdw. Added support of pg_dtm.
25
-
26
-
## Deploying
27
-
28
-
For deploy and test postgres over a cluster we use ansible. In each extension directory one can find test subdirectory where we are storing tests and deploy scripts.
29
-
30
-
31
-
### Running tests on local cluster
32
-
33
-
To use it one need ansible hosts file with following groups:
34
-
35
-
farms/cluster.example:
36
-
```
37
-
[clients] # benchmark will start simultaneously on that nodes
38
-
server0.example.com
39
-
[nodes] # all that nodes will run postgres, dtmd/master will be deployed to first
40
-
server1.example.com
41
-
server2.example.com
42
-
server3.example.com
43
-
```
44
-
45
-
After you have proper hosts file you can deploy all stuff to servers:
here nnodes is number of nudes that will be used for that test, nconns is the
59
-
number of connections to the backend.
60
-
61
-
62
-
63
-
## Running tests on Amazon ec2
64
-
65
-
66
-
In the case of amazon cloud there is no need in specific hosts file. Instead of it
67
-
we use script farms/ec2.py to get current instances running on you account. To use
68
-
that script you need to specify you account key and access_key in ~/.boto.cfg (or in
69
-
any other place that described at http://boto.cloudhackers.com/en/latest/boto_config_tut.html)
24
+
* postgres_fdw. Added support of pg_tsdtm.
25
+
26
+
## Installing multimaster
27
+
28
+
1. Build and install postgres from this repo on all machines in cluster.
29
+
1. Install contrib/raftable and contrib/mmts extensions.
30
+
1. Right now we need clean postgres installation to spin up multimaster cluster.
31
+
1. Create required database inside postgres before enabling multimaster extension.
32
+
1. We are requiring following postgres configuration:
33
+
1. 'max_prepared_transactions' > 0 -- in multimaster all writing transaction along with ddl are wrapped as two-phase transaction, so this number will limit maximum number of writing transactions in this cluster node.
34
+
1. 'synchronous_commit - off' -- right now we do not support async commit. (one can enable it, but that will not bring desired effect)
35
+
1. 'wal_level = logical' -- multimaster built on top of logical replication so this is mandatory.
36
+
1. 'max_wal_senders' -- this should be at least number of nodes - 1
37
+
1. 'max_replication_slots' -- this should be at least number of nodes - 1
38
+
1. 'max_worker_processes' -- at least 2*N + P - 1, where N is number of nodes in cluster, P size of pool of workers(see below) (1 raftable, n-1 receiver, n-1 sender, mtm-sender, mtm-receiver, + number of pool worker).
0 commit comments