Fix demo.yaml example in tempest tests

Change-Id: Icce921290976f80c70487b770ecd7811a3e4ba18
This commit is contained in:
Nikolay Mahotkin 2014-05-07 17:32:28 +04:00
parent c37061ca5e
commit deca14c5e8
1 changed files with 46 additions and 44 deletions

View File

@ -1,57 +1,59 @@
Services: Namespaces:
MyRest: Rest:
type: REST_API class: std.mistral_http
parameters:
baseUrl: http://localhost:8988
actions: actions:
task1: put_service_on_hold:
parameters: base-parameters:
url: /tasks/task1 url: http://localhost:8988/tasks/put_service_on_hold
method: GET
task-parameters:
task2: backup_user_data:
parameters: base-parameters:
url: /tasks/task2 url: http://localhost:8988/tasks/backup_user_data
method: GET
task-parameters:
task3: backup_service_data:
parameters: base-parameters:
url: /tasks/task3 url: http://localhost:8988/tasks/backup_service_data
method: GET
task-parameters:
task4: execute_backup:
parameters: base-parameters:
url: /tasks/task4 url: http://localhost:8988/tasks/execute_backup
method: GET
task-parameters:
Workflow: Workflow:
tasks: tasks:
task1: put_service_on_hold:
action: MyRest:task1 action: Rest.put_service_on_hold
parameters:
task2: backup_user_data:
dependsOn: [task1] requires: [put_service_on_hold]
action: MyRest:task2 action: Rest.backup_user_data
parameters:
task3: backup_service_data:
dependsOn: [task1] requires: [put_service_on_hold]
action: MyRest:task3 action: Rest.backup_service_data
parameters:
task4: send_email:
dependsOn: [task2, task3] requires: [backup_service_data, backup_user_data]
action: MyRest:task4 action: std.email
parameters: parameters:
# Use password if smtpd requires TLS authentication (password: None).
params:
to: [mistral@example.com, boss@example.com]
subject: Backup complete
body: |
Congratulations, the backup is complete
-- Thanks, Mistral Team.
settings:
smtp_server: localhost:10025
from: mistral@example.com
execute_backup:
requires: [backup_user_data, backup_service_data, send_email]
action: Rest.execute_backup
triggers: triggers:
task4: execute_backup:
type: periodic type: periodic
tasks: task4 tasks: execute_backup
parameters: parameters:
cron-pattern: "*/1 * * * *" cron-pattern: "*/1 * * * *"