BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 1 | #!/bin/bash |
| 2 | |
| 3 | TC_ONELINE_DESCR="DFC file retention. Publish 1 file, restart MR sim. No new publish." |
| 4 | |
| 5 | . ../common/testcase_common.sh $1 $2 |
| 6 | |
| 7 | #### TEST BEGIN #### |
| 8 | |
| 9 | clean_containers |
| 10 | |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 11 | export MR_TC="--tc100" |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 12 | export MR_GROUPS="OpenDcae-c12:PM_MEAS_FILES" |
| 13 | export MR_FILE_PREFIX_MAPPING="PM_MEAS_FILES:A" |
| 14 | |
| 15 | export DR_TC="--tc normal" |
| 16 | export DR_FEEDS="2:A" |
| 17 | |
| 18 | export DR_REDIR_TC="--tc normal" |
| 19 | export DR_REDIR_FEEDS="2:A" |
| 20 | |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 21 | export NUM_FTPFILES="1" |
| 22 | export NUM_PNFS="1" |
| 23 | export FILE_SIZE="1MB" |
| 24 | export FTP_TYPE="SFTP" |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 25 | export FTP_FILE_PREFIXES="A" |
| 26 | export NUM_FTP_SERVERS=1 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 27 | |
| 28 | log_sim_settings |
| 29 | |
| 30 | start_simulators |
| 31 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 32 | consul_config_app 0 "../simulator-group/consul/c12_feed2_PM.json" |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 33 | |
| 34 | mr_equal ctr_requests 0 60 |
| 35 | dr_equal ctr_published_files 0 60 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 36 | |
| 37 | mr_print tc_info |
| 38 | dr_print tc_info |
| 39 | drr_print tc_info |
| 40 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 41 | start_dfc 0 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 42 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 43 | dr_equal ctr_published_files 1 60 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 44 | |
| 45 | sleep_wait 30 |
| 46 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 47 | dr_equal ctr_published_files 1 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 48 | |
| 49 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 50 | mr_equal ctr_events 1 |
| 51 | mr_equal ctr_unique_files 1 |
| 52 | mr_equal ctr_unique_PNFs 1 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 53 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 54 | dr_equal ctr_publish_query 1 |
| 55 | dr_equal ctr_publish_query_bad_file_prefix 0 |
| 56 | dr_equal ctr_publish_query_published 0 |
| 57 | dr_equal ctr_publish_query_not_published 1 |
| 58 | dr_equal ctr_publish_req 1 |
| 59 | dr_equal ctr_publish_req_bad_file_prefix 0 |
| 60 | dr_equal ctr_publish_req_redirect 1 |
| 61 | dr_equal ctr_publish_req_published 0 |
| 62 | dr_equal ctr_published_files 1 |
| 63 | dr_equal ctr_double_publish 0 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 64 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 65 | drr_equal ctr_publish_requests 1 |
| 66 | drr_equal ctr_publish_requests_bad_file_prefix 0 |
| 67 | drr_equal ctr_publish_responses 1 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 68 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 69 | drr_equal dwl_volume 1000000 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 70 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 71 | check_dfc_logs |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 72 | |
| 73 | store_logs PART1 |
| 74 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 75 | mr_greater ctr_requests 4 120 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 76 | |
| 77 | kill_mr |
| 78 | start_simulators |
| 79 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 80 | mr_equal ctr_requests 4 120 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 81 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 82 | mr_equal ctr_events 1 |
| 83 | mr_equal ctr_unique_files 1 |
| 84 | mr_equal ctr_unique_PNFs 1 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 85 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 86 | dr_equal ctr_publish_query 1 |
| 87 | dr_equal ctr_publish_query_published 0 |
| 88 | dr_equal ctr_publish_query_not_published 1 |
| 89 | dr_equal ctr_publish_req 1 |
| 90 | dr_equal ctr_publish_req_redirect 1 |
| 91 | dr_equal ctr_publish_req_published 0 |
| 92 | dr_equal ctr_published_files 1 |
| 93 | dr_equal ctr_double_publish 0 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 94 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 95 | drr_equal ctr_publish_requests 1 |
| 96 | drr_equal ctr_publish_responses 1 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 97 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 98 | drr_equal dwl_volume 1000000 |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 99 | |
BjornMagnussonXA | a79a043 | 2019-07-17 08:26:50 +0000 | [diff] [blame] | 100 | check_dfc_logs |
BjornMagnussonXA | 42dcb26 | 2019-04-26 19:29:54 +0000 | [diff] [blame] | 101 | |
| 102 | #### TEST COMPLETE #### |
| 103 | |
| 104 | store_logs END |
| 105 | |
| 106 | print_result |