Merge "Clarify usage of replicator and reconstructor override options"

This commit is contained in:
Jenkins
2017-08-18 03:08:06 +00:00
committed by Gerrit Code Review
5 changed files with 49 additions and 26 deletions

View File

@@ -23,9 +23,11 @@ if __name__ == '__main__':
parser = OptionParser("%prog CONFIG [options]") parser = OptionParser("%prog CONFIG [options]")
parser.add_option('-d', '--devices', parser.add_option('-d', '--devices',
help='Reconstruct only given devices. ' help='Reconstruct only given devices. '
'Comma-separated list') 'Comma-separated list. '
'Only has effect if --once is used.')
parser.add_option('-p', '--partitions', parser.add_option('-p', '--partitions',
help='Reconstruct only given partitions. ' help='Reconstruct only given partitions. '
'Comma-separated list') 'Comma-separated list. '
'Only has effect if --once is used.')
conf_file, options = parse_options(parser=parser, once=True) conf_file, options = parse_options(parser=parser, once=True)
run_daemon(ObjectReconstructor, conf_file, **options) run_daemon(ObjectReconstructor, conf_file, **options)

View File

@@ -23,12 +23,15 @@ if __name__ == '__main__':
parser = OptionParser("%prog CONFIG [options]") parser = OptionParser("%prog CONFIG [options]")
parser.add_option('-d', '--devices', parser.add_option('-d', '--devices',
help='Replicate only given devices. ' help='Replicate only given devices. '
'Comma-separated list') 'Comma-separated list. '
'Only has effect if --once is used.')
parser.add_option('-p', '--partitions', parser.add_option('-p', '--partitions',
help='Replicate only given partitions. ' help='Replicate only given partitions. '
'Comma-separated list') 'Comma-separated list. '
'Only has effect if --once is used.')
parser.add_option('-i', '--policies', parser.add_option('-i', '--policies',
help='Replicate only given policy indices. ' help='Replicate only given policy indices. '
'Comma-separated list') 'Comma-separated list. '
'Only has effect if --once is used.')
conf_file, options = parse_options(parser=parser, once=True) conf_file, options = parse_options(parser=parser, once=True)
run_daemon(ObjectReplicator, conf_file, **options) run_daemon(ObjectReplicator, conf_file, **options)

View File

@@ -37,11 +37,12 @@ reconstruction before it has the correct data to push to the other node.
Show this help message and exit Show this help message and exit
.TP .TP
\fB\-d\fR \fIDEVICES\fR, \fB\-\-devices\fR=\fIDEVICES\fR \fB\-d\fR \fIDEVICES\fR, \fB\-\-devices\fR=\fIDEVICES\fR
Reconstruct only given devices. Comma\-separated list Reconstruct only given devices. Comma\-separated list. Only has effect if
\-\-once is used.
.TP .TP
\fB\-p\fR \fIPARTITIONS\fR, \fB\-\-partitions\fR=\fIPARTITIONS\fR \fB\-p\fR \fIPARTITIONS\fR, \fB\-\-partitions\fR=\fIPARTITIONS\fR
Reconstruct only given partitions. Comma\-separated Reconstruct only given partitions. Comma\-separated
list list. Only has effect if \-\-once is used.
.TP .TP
\fB\-v\fR, \fB\-\-verbose\fR \fB\-v\fR, \fB\-\-verbose\fR
Log to console Log to console

View File

@@ -41,22 +41,29 @@ from the system. When an object item is deleted a tombstone is set as the latest
version of the item. The replicator will see the tombstone and ensure that the item version of the item. The replicator will see the tombstone and ensure that the item
is removed from the entire system. is removed from the entire system.
The options are as follows: .SH OPTIONS
.TP
.RS 4 \fB\-h\fR, \fB\-\-help\fR
.PD 0 Show this help message and exit
.IP "-v" .TP
.IP "--verbose" \fB\-d\fR \fIDEVICES\fR, \fB\-\-devices\fR=\fIDEVICES\fR
.RS 4 Replicate only given devices. Comma\-separated list. Only has effect if
.IP "log to console" \-\-once is used.
.RE .TP
.IP "-o" \fB\-p\fR \fIPARTITIONS\fR, \fB\-\-partitions\fR=\fIPARTITIONS\fR
.IP "--once" Replicate only given partitions. Comma\-separated
.RS 4 list. Only has effect if \-\-once is used.
.IP "only run one pass of daemon" .TP
.RE \fB\-i\fR \fIPOLICIES\fR, \fB\-\-policies\fR=\fIPOLICIES\fR
.PD Replicate only given policy indices. Comma\-separated list. Only has effect if
.RE \-\-once is used.
.TP
\fB\-v\fR, \fB\-\-verbose\fR
Log to console
.TP
\fB\-o\fR, \fB\-\-once\fR
Only run one pass of daemon
.PP
.SH DOCUMENTATION .SH DOCUMENTATION

View File

@@ -44,6 +44,16 @@ Object Replicator
:undoc-members: :undoc-members:
:show-inheritance: :show-inheritance:
.. _object-reconstructor:
Object Reconstructor
====================
.. automodule:: swift.obj.reconstructor
:members:
:undoc-members:
:show-inheritance:
.. _object-server: .. _object-server:
Object Server Object Server