Module: QaServer::MonitorStatus::PerformanceGraphBehavior
Constant Summary
PerformanceHistoryDataKeys::ALL_AUTH, PerformanceHistoryDataKeys::AVG_FULL, PerformanceHistoryDataKeys::AVG_LOAD, PerformanceHistoryDataKeys::AVG_NORM, PerformanceHistoryDataKeys::BY_DAY, PerformanceHistoryDataKeys::BY_HOUR, PerformanceHistoryDataKeys::BY_MONTH, PerformanceHistoryDataKeys::FOR_DATATABLE, PerformanceHistoryDataKeys::FOR_DAY, PerformanceHistoryDataKeys::FOR_MONTH, PerformanceHistoryDataKeys::FOR_YEAR, PerformanceHistoryDataKeys::HIGH_FULL, PerformanceHistoryDataKeys::HIGH_LOAD, PerformanceHistoryDataKeys::HIGH_NORM, PerformanceHistoryDataKeys::LOW_FULL, PerformanceHistoryDataKeys::LOW_LOAD, PerformanceHistoryDataKeys::LOW_NORM, PerformanceHistoryDataKeys::STATS
Instance Method Summary
collapse
Instance Method Details
44
45
46
47
|
# File 'app/presenters/concerns/qa_server/monitor_status/performance_graph_behavior.rb', line 44
def performance_data_section_class(graph_info)
return 'performance-data-section-visible' if default_graph?(graph_info)
'performance-data-section-hidden'
end
|
49
50
51
52
|
# File 'app/presenters/concerns/qa_server/monitor_status/performance_graph_behavior.rb', line 49
def performance_day_graph_selected?(graph_info)
return true if graph_info[:time_period] == :day
false
end
|
28
29
30
|
# File 'app/presenters/concerns/qa_server/monitor_status/performance_graph_behavior.rb', line 28
def performance_default_graph_id
"performance-for-day-#{ALL_AUTH}"
end
|
16
17
18
|
# File 'app/presenters/concerns/qa_server/monitor_status/performance_graph_behavior.rb', line 16
def performance_graph(graph_info)
graph_info[:graph]
end
|
20
21
22
|
# File 'app/presenters/concerns/qa_server/monitor_status/performance_graph_behavior.rb', line 20
def performance_graph_authority(graph_info)
graph_info[:authority_name]
end
|
40
41
42
|
# File 'app/presenters/concerns/qa_server/monitor_status/performance_graph_behavior.rb', line 40
def performance_graph_data_section_base_id(graph_info)
graph_info[:base_id]
end
|
36
37
38
|
# File 'app/presenters/concerns/qa_server/monitor_status/performance_graph_behavior.rb', line 36
def performance_graph_data_section_id(graph_info)
"#{graph_info[:base_id]}-during-#{graph_info[:time_period]}"
end
|
32
33
34
|
# File 'app/presenters/concerns/qa_server/monitor_status/performance_graph_behavior.rb', line 32
def performance_graph_id(graph_info)
"#{graph_info[:base_id]}-during-#{graph_info[:time_period]}-chart"
end
|
24
25
26
|
# File 'app/presenters/concerns/qa_server/monitor_status/performance_graph_behavior.rb', line 24
def performance_graph_label(graph_info)
graph_info[:label]
end
|
8
9
10
11
12
13
14
|
# File 'app/presenters/concerns/qa_server/monitor_status/performance_graph_behavior.rb', line 8
def performance_graphs
auth_list = QaServer::AuthorityListerService.authorities_list
graphs = []
performance_graphs_for_authority(graphs, ALL_AUTH)
auth_list.each { |auth_name| performance_graphs_for_authority(graphs, auth_name) }
graphs
end
|
54
55
56
57
|
# File 'app/presenters/concerns/qa_server/monitor_status/performance_graph_behavior.rb', line 54
def performance_month_graph_selected?(graph_info)
return true if graph_info[:time_period] == :month
false
end
|
59
60
61
62
|
# File 'app/presenters/concerns/qa_server/monitor_status/performance_graph_behavior.rb', line 59
def performance_year_graph_selected?(graph_info)
return true if graph_info[:time_period] == :year
false
end
|