File: pg_logicaldec.proto

package info (click to toggle)
postgres-decoderbufs 3.3.0~beta1-1
  • links: PTS, VCS
  • area: main
  • in suites: experimental
  • size: 188 kB
  • sloc: ansic: 559; makefile: 17; sql: 5; sh: 1
file content (50 lines) | stat: -rw-r--r-- 1,099 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
package decoderbufs;

option java_package="io.debezium.connector.postgresql.proto";
option java_outer_classname = "PgProto";
option optimize_for = SPEED;

enum Op {
    UNKNOWN = -1;
    INSERT = 0;
    UPDATE = 1;
    DELETE = 2;
    BEGIN  = 3;
    COMMIT = 4;
}

message Point {
    required double x = 1;
    required double y = 2;
}

message DatumMessage {
    optional string column_name = 1;
    optional int64 column_type = 2;
    oneof datum {
      int32 datum_int32 = 3;
      int64 datum_int64 = 4;
      float datum_float = 5;
      double datum_double = 6;
      bool datum_bool = 7;
      string datum_string = 8;
      bytes datum_bytes = 9;
      Point datum_point = 10;
      bool datum_missing = 11;
    }
}

message TypeInfo {
    required string modifier = 1;
    required bool value_optional = 2;
}

message RowMessage {
    optional uint32 transaction_id = 1;
    optional uint64 commit_time = 2;
    optional string table = 3;
    optional Op op = 4;
    repeated DatumMessage new_tuple = 5;
    repeated DatumMessage old_tuple = 6;
    repeated TypeInfo new_typeinfo = 7;
}