Class: Flare::SpansController
- Inherits:
-
ApplicationController
- Object
- ActionController::Base
- ApplicationController
- Flare::SpansController
- Defined in:
- app/controllers/flare/spans_controller.rb
Constant Summary collapse
- PER_PAGE =
50- CATEGORIES =
{ "queries" => { title: "Queries", icon: "database", badge_class: "sql" }, "cache" => { title: "Cache", icon: "archive", badge_class: "cache" }, "views" => { title: "Views", icon: "layout", badge_class: "view" }, "http" => { title: "HTTP", icon: "globe", badge_class: "http" }, "mail" => { title: "Mail", icon: "mail", badge_class: "mail" }, "redis" => { title: "Redis", icon: "database", badge_class: "other" }, "exceptions" => { title: "Exceptions", icon: "alert-triangle", badge_class: "exception" } }.freeze
Instance Method Summary collapse
- #cache ⇒ Object
- #exceptions ⇒ Object
- #http ⇒ Object
- #mail ⇒ Object
- #queries ⇒ Object
- #redis ⇒ Object
- #show ⇒ Object
- #views ⇒ Object
Instance Method Details
#cache ⇒ Object
25 26 27 |
# File 'app/controllers/flare/spans_controller.rb', line 25 def cache list_spans("cache") end |
#exceptions ⇒ Object
45 46 47 |
# File 'app/controllers/flare/spans_controller.rb', line 45 def exceptions list_spans("exceptions") end |
#http ⇒ Object
33 34 35 |
# File 'app/controllers/flare/spans_controller.rb', line 33 def http list_spans("http") end |
#mail ⇒ Object
37 38 39 |
# File 'app/controllers/flare/spans_controller.rb', line 37 def mail list_spans("mail") end |
#queries ⇒ Object
21 22 23 |
# File 'app/controllers/flare/spans_controller.rb', line 21 def queries list_spans("queries") end |
#redis ⇒ Object
41 42 43 |
# File 'app/controllers/flare/spans_controller.rb', line 41 def redis list_spans("redis") end |
#show ⇒ Object
49 50 51 52 53 54 55 56 57 58 |
# File 'app/controllers/flare/spans_controller.rb', line 49 def show @span = Flare.storage.find_span(params[:id]) if @span.blank? redirect_to requests_path, alert: "Span not found" return end @category = params[:category] end |
#views ⇒ Object
29 30 31 |
# File 'app/controllers/flare/spans_controller.rb', line 29 def views list_spans("views") end |