Add monasca-setup options max_buffer_size and backlog_send_rate

Change-Id: I4391cf7b9e67d8195191694f3317b8cf3c326acc
This commit is contained in:
Ryan Brandt 2016-09-15 15:22:41 -06:00
parent bd0abce582
commit 19592e7953
3 changed files with 14 additions and 4 deletions

View File

@ -46,12 +46,12 @@ Api:
# DEPRECATED - please use max_measurement_buffer_size instead
# Maximum number of messages (batches of measurements) to buffer when unable to communicate
# with the monasca-api (-1 means no limit)
max_buffer_size: 1000
max_buffer_size: {args.max_buffer_size}
# Maximum number of measurements to buffer when unable to communicate with the monasca-api
# (-1 means no limit)
max_measurement_buffer_size: {args.max_measurement_buffer_size}
# Maximum number of messages to send at one time when communication with the monasca-api is restored
backlog_send_rate: 1000
backlog_send_rate: {args.backlog_send_rate}
# Publish extra metrics to the API by adding this number of 'amplifier' dimensions.
# For load testing purposes only; set to 0 for production use.

View File

@ -112,6 +112,8 @@ All parameters require a '--' before the parameter such as '--verbose'. Run `mon
| skip_detection_plugins | Skip provided space separated list of detection plugins. | system |
| overwrite | This is an optional parameter to overwrite the plugin configuration. Use this if you don't want to keep the original configuration. If this parameter is not specified, the configuration will be appended to the existing configuration, possibly creating duplicate checks. **NOTE:** The agent config file, agent.yaml, will always be overwritten, even if this parameter is not specified. | |
| detection_args | Some detection plugins can be passed arguments. This is a string that will be passed to the detection plugins. | "hostname=ping.me" |
| max_measurement_buffer_size | Integer value for the maximum number of measurements to buffer locally while unable to connect to the monasca-api. If the queue exceeds this value, measurements will be dropped in batches. A value of '-1' indicates no limit | 100000 |
| backlog_send_rate | Integer value of how many batches of buffered measurements to send each time the forwarder flushes data | 1000 |
### Providing Arguments to Detection plugins
When running individual detection plugins you can specify arguments that augment the configuration created. In some instances the arguments just provide additional

View File

@ -268,10 +268,18 @@ def parse_arguments(parser):
"Useful for load testing; not for production use.", default=0)
parser.add_argument('-v', '--verbose', help="Verbose Output", action="store_true")
parser.add_argument('--dry_run', help="Make no changes just report on changes", action="store_true")
parser.add_argument('--max_buffer_size',
help="Maximum number of batches of measurements to"
" buffer while unable to communicate with monasca-api",
default=1000)
parser.add_argument('--max_measurement_buffer_size',
help='Maximum number of measurements to buffer when unable to communicate'
' with the monasca-api',
help="Maximum number of measurements to buffer when unable to communicate"
" with the monasca-api",
default=-1)
parser.add_argument('--backlog_send_rate',
help="Maximum number of buffered batches of measurements to send at"
" one time when connection to the monasca-api is restored",
default=1000)
return parser.parse_args()