Merge "Correcting output of swift-ring-builder"
This commit is contained in:
commit
e3ccb3f52d
@ -116,7 +116,7 @@ swift-ring-builder <builder_file>
|
|||||||
else:
|
else:
|
||||||
balance = 100.0 * dev['parts'] / \
|
balance = 100.0 * dev['parts'] / \
|
||||||
(dev['weight'] * weighted_parts) - 100.0
|
(dev['weight'] * weighted_parts) - 100.0
|
||||||
print(' %5d %5d %5d %15s %5d %9s %6.02f %10s'
|
print(' %5d %7d %5d %15s %5d %9s %6.02f %10s'
|
||||||
'%7.02f %s' %
|
'%7.02f %s' %
|
||||||
(dev['id'], dev['region'], dev['zone'], dev['ip'],
|
(dev['id'], dev['region'], dev['zone'], dev['ip'],
|
||||||
dev['port'], dev['device'], dev['weight'], dev['parts'],
|
dev['port'], dev['device'], dev['weight'], dev['parts'],
|
||||||
@ -150,7 +150,7 @@ swift-ring-builder <builder_file> search <search-value>
|
|||||||
else:
|
else:
|
||||||
balance = 100.0 * dev['parts'] / \
|
balance = 100.0 * dev['parts'] / \
|
||||||
(dev['weight'] * weighted_parts) - 100.0
|
(dev['weight'] * weighted_parts) - 100.0
|
||||||
print(' %5d %5d %5d %15s %5d %9s %6.02f %10s %7.02f %s' %
|
print(' %5d %7d %5d %15s %5d %9s %6.02f %10s %7.02f %s' %
|
||||||
(dev['id'], dev['region'], dev['zone'], dev['ip'],
|
(dev['id'], dev['region'], dev['zone'], dev['ip'],
|
||||||
dev['port'], dev['device'], dev['weight'], dev['parts'],
|
dev['port'], dev['device'], dev['weight'], dev['parts'],
|
||||||
balance, dev['meta']))
|
balance, dev['meta']))
|
||||||
|
Loading…
Reference in New Issue
Block a user