-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathconf.py
53 lines (49 loc) · 1.29 KB
/
conf.py
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
write_db_host = '127.0.0.1'
write_db_port = 27017
write_db_name = 'backup'
write_db_auth = False
write_db_uname = 'uname'
write_db_pwd = '12345678'
read_db_host = '127.0.0.1'
read_db_port = 27017
read_db_name = 'dump'
read_db_auth = False
read_db_uname = 'uname'
read_db_pwd = '12345678'
# This supports reading and writing from/to keys using dot operator
migrate_conf = [
{
'read_collection_name': 'Collection_Read',
'write_collection_name': 'Collection_Write',
'fields_map_from_to': [
('_id', '_id'),
('name.fullName', 'fullName'),
('mobileNo', 'contact.mobile'),
('emailId', 'contact.email'),
('createdAt', 'createdAt'),
('type', 'type'),
],
'default_fields': {
'migratedData': True
},
'filter':{
'type':'sample'
},
'check_field': ['age']
},
{
'read_collection_name': 'Collection2_Read',
'write_collection_name': 'Collection2_Write',
'fields_map_from_to': [
('_id', '_id'),
('sample', 'sampleNew'),
],
'default_fields': {
'migratedData': True
},
'filter':{
'type':'sample'
},
'check_field': ['sampleField']
},
]