From cf2f1215151451710fbc430576e631e7af51584c Mon Sep 17 00:00:00 2001 From: Jesse Keating Date: Wed, 21 Jan 2015 12:25:54 -0800 Subject: [PATCH] Replace deprecated max_failure_precent sla The new sla is a failure_rate with min/max sub-keys. Update the documentation and examples to reflect this. Change-Id: Id947e4684aa84fe7d6c239a28b92e2a893ddaf66 --- .../step_3_adding_success_criteria_for_benchmarks.rst | 4 +++- rally/cmd/commands/info.py | 3 ++- samples/tasks/sla/README.rst | 4 ++-- samples/tasks/sla/create-and-delete-user.json | 4 +++- samples/tasks/sla/create-and-delete-user.yaml | 3 ++- 5 files changed, 12 insertions(+), 6 deletions(-) diff --git a/doc/source/tutorial/step_3_adding_success_criteria_for_benchmarks.rst b/doc/source/tutorial/step_3_adding_success_criteria_for_benchmarks.rst index e66dd79571..d81e0528f9 100644 --- a/doc/source/tutorial/step_3_adding_success_criteria_for_benchmarks.rst +++ b/doc/source/tutorial/step_3_adding_success_criteria_for_benchmarks.rst @@ -41,7 +41,9 @@ To configure the SLA, add the *"sla"* section to the configuration of the corres }, "sla": { "max_seconds_per_iteration": 10, - "max_failure_percent": 25 + "failure_rate": { + "max": 25 + } } } ] diff --git a/rally/cmd/commands/info.py b/rally/cmd/commands/info.py index 9677f2f629..99ba2e05ff 100644 --- a/rally/cmd/commands/info.py +++ b/rally/cmd/commands/info.py @@ -162,7 +162,8 @@ class InfoCommands(object): "assosiated value, e.g.:\n\n" " sla:\n" " max_seconds_per_iteration: 4\n" - " max_failure_percent: 1" + " failure_rate:\n" + " max: 1" "\n\n" + self._compose_table("List of SLA checks", sla) + "To get information about specific SLA checks, run:\n" diff --git a/samples/tasks/sla/README.rst b/samples/tasks/sla/README.rst index cff8e52a75..81dd36186d 100644 --- a/samples/tasks/sla/README.rst +++ b/samples/tasks/sla/README.rst @@ -9,10 +9,10 @@ with contracted values such as maximum error rate or minimum response time. Currently supported criteria: -max_failure_percent +failure_rate ------------------- -Maximum allowed failure rate in percent. +A maximum and/or a minimum failure rate expressed as max or min sub-keys. max_seconds_per_iteration diff --git a/samples/tasks/sla/create-and-delete-user.json b/samples/tasks/sla/create-and-delete-user.json index 3a5367302f..a7ed7d1479 100644 --- a/samples/tasks/sla/create-and-delete-user.json +++ b/samples/tasks/sla/create-and-delete-user.json @@ -11,7 +11,9 @@ }, "sla": { "max_seconds_per_iteration": 4, - "max_failure_percent": 1 + "failure_rate": { + "max": 1 + } } } ] diff --git a/samples/tasks/sla/create-and-delete-user.yaml b/samples/tasks/sla/create-and-delete-user.yaml index fd5112000f..c34d0d16dc 100644 --- a/samples/tasks/sla/create-and-delete-user.yaml +++ b/samples/tasks/sla/create-and-delete-user.yaml @@ -9,4 +9,5 @@ concurrency: 10 sla: max_seconds_per_iteration: 4 - max_failure_percent: 1 + failure_rate: + max: 1