2 Documentation This test restarts all controllers to verify recovery of car data from persistence.
4 ... Copyright (c) 2016 Cisco Systems, Inc. and others. All rights reserved.
6 ... This program and the accompanying materials are made available under the
7 ... terms of the Eclipse Public License v1.0 which accompanies this distribution,
8 ... and is available at http://www.eclipse.org/legal/epl-v10.html
11 ... Other models and shards (people, car-people) are not accessed by this suite.
13 ... All data is deleted at the end of the suite.
14 ... This suite expects car module to have a separate Shard.
16 Default Tags clustering carpeople critical
18 Resource ${CURDIR}/../../../libraries/CarPeople.robot
19 Resource ${CURDIR}/../../../libraries/ClusterManagement.robot
20 Resource ${CURDIR}/../../../libraries/TemplatedRequests.robot
21 Variables ${CURDIR}/../../../variables/Variables.py
25 ${MEMBER_START_TIMEOUT} 300s
26 ${VAR_DIR} ${CURDIR}/../../../variables/carpeople/crud
30 [Documentation] Single big PUT to datastore to add cars to car Leader.
31 TemplatedRequests.Put_As_Json_Templated folder=${VAR_DIR}/cars session=${car_leader_session} iterations=${CAR_ITEMS}
34 [Documentation] Kill all controllers.
35 ClusterManagement.Kill_Members_From_List_Or_All confirm=True
38 [Documentation] Start all controllers (should restore the persisted data).
39 ClusterManagement.Start_Members_From_List_Or_All wait_for_sync=True timeout=${MEMBER_START_TIMEOUT}
41 Memorize_Leader_And_Followers
42 [Documentation] Locate current Leader of car Shard.
43 BuiltIn.Wait_Until_Keyword_Succeeds 30s 2s CarPeople.Set_Variables_For_Shard shard_name=car
46 [Documentation] GET cars from Leader, should match the PUT data.
47 TemplatedRequests.Get_As_Json_Templated folder=${VAR_DIR}/cars session=${car_leader_session} verify=True iterations=${CAR_ITEMS}
50 [Documentation] The same check on other members.
51 : FOR ${session} IN @{car_follower_sessions}
52 \ TemplatedRequests.Get_As_Json_Templated folder=${VAR_DIR}/cars session=${session} verify=True iterations=${CAR_ITEMS}
55 [Documentation] Delete cars on the new Leader.
56 TemplatedRequests.Delete_Templated folder=${VAR_DIR}/cars session=${car_leader_session}
60 [Documentation] Initialize resources, memorize car shard leader and followers.
61 ClusterManagement.ClusterManagement_Setup
62 CarPeople.Set_Variables_For_Shard shard_name=car