-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdump.yml
90 lines (90 loc) · 2.49 KB
/
dump.yml
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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
# $id: git://github.com/rivethealth/db-slice/schema.json
$schema: http://json-schema.org/draft/2019-09/schema#
description: Definition of slice to dump
title: Slice dump definition
definitions:
column:
description: Name of column
type: string
title: Column
reference:
description: Reference to another table, i.e. a foreign key.
title: Reference
required: [table, columns, referenceColumns, referenceTable]
properties:
columns:
description: Local columns
title: Local columns
type: array
items: { $ref: "#/definitions/column" }
directions:
default: [forward, reverse]
description: Directions to use when discovering rows
items: { $ref: "#/definitions/referenceDirection" }
title: Directions
type: array
uniqueItems: true
referenceColumns:
description: Foreign columns
title: Foreign columns
items: { $ref: "#/definitions/column" }
referenceTable:
description: ID of foreign table
title: Foreign table ID
type: string
type: object
referenceDirection:
description: Direction of reference
choices: [forward, reverse]
type: string
sequence:
description: Sequence.
properties:
name:
description: Name of sequence.
title: Name
type: string
schema:
description: Name of schema.
title: Schema
type: string
required: [schema, name]
title: Sequence
table:
description: Table
properties:
name:
description: Name
type: string
columns:
description: Columns
items: { $ref: "#/definitions/column" }
schema:
default: null
description: Schema name. If null, uses the usual schema search path.
type: ["null", string]
sequences:
description: Sequence IDs that this table depends on.
item: { type: string }
title: Sequences
type: array
required: [columns, name, sequences]
type: object
properties:
references:
additionalProperties: { $ref: "#/definitions/reference" }
description: References
title: References
type: object
sequences:
additionalProperties: { $ref: "#/definitions/sequence" }
description: Sequences.
title: Sequences
type: object
tables:
additionalProperties: { $ref: "#/definitions/table" }
description: Tables
title: Tables
type: object
required: [references, sequences, tables]
type: object