File tree Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Expand file tree Collapse file tree 1 file changed +3
-8
lines changed Original file line number Diff line number Diff line change @@ -57,23 +57,18 @@ def main():
57
57
else :
58
58
dbnames = options .dbnames
59
59
60
- targetdbs = sorted (i for i in target_server )
61
60
for dbname in sorted (dbnames , reverse = True ):
62
61
63
62
start = time .time ()
64
63
print dbname ,
65
64
sys .stdout .flush ()
66
- if dbname not in targetdbs :
65
+ if dbname not in target_server :
67
66
target_server .create (dbname )
68
67
print "created" ,
69
68
sys .stdout .flush ()
70
69
71
- body = {}
72
- if options .continuous :
73
- body ['continuous' ] = True
74
-
75
- body .update ({'source' : '%s%s' % (src , dbname ), 'target' : dbname })
76
- target_server .resource .post ('_replicate' , body )
70
+ sdb = '%s%s' % (src , dbname )
71
+ target_server .replicate (sdb , dbname , continuous = options .continuous )
77
72
print '%.1fs' % (time .time () - start )
78
73
79
74
if not options .compact :
You can’t perform that action at this time.
0 commit comments