Bug #394

Reports do not work - total time is no longer a report meetric in puppet 2.6

Added by Nikolay Aralovets about 4 years ago. Updated about 2 years ago.

Status:ClosedStart date:10/01/2010
Priority:NormalDue date:
Assigned To:Ohad Levy% Done:

100%

Category:Puppet Reports
Target version:0.1-6
Difficulty: Bugzilla link:
Found in release: Pull request:
Story points-
Velocity based estimate-

Description

I upgrade foreman from snapshot's (09.28.2010) in my testing env. When I click
on "Reports" or "host name" url I see error message in foreman
error_log:

=> Booting WEBrick
=> Rails 2.3.5 application starting on http://0.0.0.0:3000
=> Call with -d to detach
=> Ctrl-C to shutdown server
[2010-09-29 16:35:46] INFO WEBrick 1.3.1
[2010-09-29 16:35:46] INFO ruby 1.8.7 (2009-06-08) [i386-linux]
[2010-09-29 16:35:46] INFO WEBrick::HTTPServer#start: pid=13573
port=3000

Processing HostsController#index (for 172.30.64.135 at 2010-09-29
16:35:49) [GET]
Parameters: {"action"=>"index", "controller"=>"hosts"}
Rendering template within layouts/standard
Rendering hosts/index
Completed in 233ms (View: 101, DB: 11) | 200 OK [http://srv2-puppet/]

Processing HostsController#show (for 172.30.64.135 at 2010-09-29
16:35:51) [GET]
Parameters: {"action"=>"show", "id"=>"srv-redhat.net.billing.ru",
"controller"=>"hosts"}

NoMethodError (undefined method `round_with_precision' for 0:Fixnum):
app/models/report.rb:68:in `config_retrieval'
app/models/host.rb:394:in `graph'
app/models/host.rb:393:in `graph'
app/controllers/hosts_controller.rb:28:in `show'
app/controllers/hosts_controller.rb:22:in `show'
/usr/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
/usr/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
/usr/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:95:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `each'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:23:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:82:in `start'

Rendering /var/rails/foreman/public/500.html (500 Internal Server
Error)

Processing ReportsController#index (for 172.30.64.135 at 2010-09-29
16:36:15) [GET]
Parameters: {"action"=>"index", "controller"=>"reports"}
Rendering template within layouts/standard
Rendering reports/index

ActionView::TemplateError (undefined method `round_with_precision' for
0:Fixnum) on line #27 of app/views/reports/_list.html.erb:
24: <td><%= h report.failed ></td>
25: <td><
= h report.failed_restarts ></td>
26: <td><
= h report.skipped ></td>
27: <td><
= h report.config_retrieval ></td>
28: <td><
= h report.runtime ></td>
29: <td align="right">
30: <
= link_to "Details", report %>

app/models/report.rb:68:in `config_retrieval'
app/views/reports/_list.html.erb:27
app/views/reports/_list.html.erb:16:in `each'
app/views/reports/_list.html.erb:16
app/views/reports/index.html.erb:3
/usr/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
/usr/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
/usr/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:95:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `each'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:23:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:82:in `start'

Rendering /var/rails/foreman/public/500.html (500 Internal Server
Error)

report1.JPG (123 KB) Nikolay Aralovets, 10/06/2010 07:53 PM

report2.JPG (37 KB) Nikolay Aralovets, 10/06/2010 07:53 PM

report3.JPG (103 KB) Nikolay Aralovets, 10/06/2010 07:53 PM


Related issues

Related to Foreman - Bug #406: wrong report icon Duplicate 10/14/2010
Related to Foreman - Bug #405: Foreman cannot process 2.6.2 reports Closed 10/13/2010

Associated revisions

Revision 45dad022
Added by Ohad Levy about 4 years ago

fixes #394 - Reports do not work - total time is no longer a report
metric in puppet 2.6

This is a quick and dirty solution until we'll refactor the reporting
db layout in #349

Revision 66125af6
Added by Ohad Levy about 4 years ago

fixes #394 - Reports do not work - total time is no longer a report
metric in puppet 2.6

This is a quick and dirty solution until we'll refactor the reporting
db layout in #349

History

#1 Updated by Ohad Levy about 4 years ago

  • Category set to Puppet Reports
  • Assigned To set to Ohad Levy
  • Target version set to 0.1-6

this is puppet 2.6 integration issue..

#2 Updated by Ohad Levy about 4 years ago

  • Subject changed from Reports do not work in foreman snapshot's (by 09.28.2010) to Reports do not work - total time is no longer a report meetric in puppet 2.6

#3 Updated by Ohad Levy about 4 years ago

  • Status changed from New to Ready For Testing
  • % Done changed from 0 to 100

#5 Updated by Ohad Levy about 4 years ago

  • Status changed from Ready For Testing to Closed

#6 Updated by Nikolay Aralovets about 4 years ago

Hello Ohad,
I used changeset 66125af69149e9cd0aa0ce9fd71abf93cf82909e. URL "host detail" is opening well, but I not see activity for my puppet agent (see file report1.jpg). On url "Reports" activity for host with agent 2.6.1 is NULL also (see file report2.jpg). But on url "report detail" I can see metrics chenges and notification about file creation (see file report3.jpg).
This bug is closed. Should I create new?

Also available in: Atom PDF