Jira (PUP-5471) resource evaluation_time in report does not include time spent responding to events

2017-05-15 Thread Josh Cooper (JIRA)
Title: Message Title
 
 
 
 
 
 
 
 
 
 
  
 
 Josh Cooper updated an issue 
 
 
 
 
 
 
 
 
 
 

 
 
 
 
 
 
 
 Puppet /  PUP-5471 
 
 
 
  resource evaluation_time in report does not include time spent responding to events  
 
 
 
 
 
 
 
 
 

Change By:
 
 Josh Cooper 
 
 
 

Labels:
 
 help_wanted triaged 
 
 
 
 
 
 
 
 
 
 
 
 

 
 Add Comment 
 
 
 
 
 
 
 
 
 
 

 
 
 
 
 
 
 
 
 
 

 This message was sent by Atlassian JIRA (v6.4.14#64029-sha1:ae256fe) 
 
 
 
 
  
 
 
 
 
 
 
 
 
   





-- 
You received this message because you are subscribed to the Google Groups "Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com.
To post to this group, send email to puppet-bugs@googlegroups.com.
Visit this group at https://groups.google.com/group/puppet-bugs.
For more options, visit https://groups.google.com/d/optout.


Jira (PUP-5471) resource evaluation_time in report does not include time spent responding to events

2017-05-15 Thread Josh Cooper (JIRA)
Title: Message Title
 
 
 
 
 
 
 
 
 
 
  
 
 Josh Cooper commented on  PUP-5471 
 
 
 
 
 
 
 
 
 
 

 
 
 
 
 
 
 
  Re: resource evaluation_time in report does not include time spent responding to events  
 
 
 
 
 
 
 
 
 
 
Reid Barton we would greatly accept a pull request 
 
 
 
 
 
 
 
 
 
 
 
 

 
 Add Comment 
 
 
 
 
 
 
 
 
 
 

 
 
 
 
 
 
 
 
 
 

 This message was sent by Atlassian JIRA (v6.4.14#64029-sha1:ae256fe) 
 
 
 
 
  
 
 
 
 
 
 
 
 
   





-- 
You received this message because you are subscribed to the Google Groups "Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com.
To post to this group, send email to puppet-bugs@googlegroups.com.
Visit this group at https://groups.google.com/group/puppet-bugs.
For more options, visit https://groups.google.com/d/optout.


Jira (PUP-5471) resource evaluation_time in report does not include time spent responding to events

2017-05-15 Thread Ruth Linehan (JIRA)
Title: Message Title
 
 
 
 
 
 
 
 
 
 
  
 
 Ruth Linehan commented on  PUP-5471 
 
 
 
 
 
 
 
 
 
 

 
 
 
 
 
 
 
  Re: resource evaluation_time in report does not include time spent responding to events  
 
 
 
 
 
 
 
 
 
 
Thank you for filing this issue. We agree it is likely an improvement, but due to other issues demanding precedence, we don’t anticipate being able to address this any time soon. If you are interested in submitting a patch to the repository for this project at https://github.com/puppetlabs/puppet, please open a pull request and re-open this ticket. Pending that, we are closing this as “Won’t Fix.” We may revisit it at a later time, and if so will re-open this ticket. 
 
 
 
 
 
 
 
 
 
 
 
 

 
 Add Comment 
 
 
 
 
 
 
 
 
 
 

 
 
 
 
 
 
 
 
 
 

 This message was sent by Atlassian JIRA (v6.4.14#64029-sha1:ae256fe) 
 
 
 
 
  
 
 
 
 
 
 
 
 
   





-- 
You received this message because you are subscribed to the Google Groups "Puppet Bugs" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com.
To post to this group, send email to puppet-bugs@googlegroups.com.
Visit this group at https://groups.google.com/group/puppet-bugs.
For more options, visit https://groups.google.com/d/optout.


Jira (PUP-5471) resource evaluation_time in report does not include time spent responding to events

2015-11-04 Thread Reid Barton (JIRA)
Title: Message Title
 
 
 
 
 
 
 
 
 
 
  
 
 Reid Barton updated an issue 
 
 
 
 
 
 
 
 
 
 

 
 
 
 
 
 
 
 Puppet /  PUP-5471 
 
 
 
  resource evaluation_time in report does not include time spent responding to events  
 
 
 
 
 
 
 
 
 

Change By:
 
 Reid Barton 
 
 
 
 
 
 
 
 
 
 Suppose a manifest contains a resource that takes a substantial amount of time to refresh (for example, an exec resource with a slow command) as a result of a notify/subscribe relationship to another resource. Then the time taken to refresh the resource is not included in the record for that resource in the report.For example:{code}$ cat test.ppfile { 'a': path=> '/home/vagrant/puppet_test/a', content => 'aaa', notify  => Exec['b']}exec { 'b': command => 'sleep 3', path=> '/usr/bin:/bin', refreshonly => true}$ rm -rf a var && time puppet apply test.pp --report --verbose --vardir=var --evaltrace...Info: /Stage[main]/Main/Exec[b]: Starting to evaluate the resourceNotice: /Stage[main]/Main/Exec[b]: Triggered 'refresh' from 1 eventsInfo: /Stage[main]/Main/Exec[b]: Evaluated in 3.01 seconds...Info: Creating state file /home/vagrant/puppet_test/var/state/state.yamlNotice: Finished catalog run in 3.02 secondsreal 0m4.653suser 0m1.279ssys 0m0.312s{code}which correctly shows that the command for `Exec[b]` took 3 seconds to run. However, the report file contains{code}$ cat var/reports/*/*.yaml...  resource_statuses:...Exec[b]: !ruby/object:Puppet::Resource::Status  resource: Exec[b]  file: /home/vagrant/puppet_test/test.pp  line: 11  evaluation_time: 0.000116117  change_count: 0  out_of_sync_count: 0  tags:- exec- b- class  time: 2015-11-04 19:00:46.679732 +00:00  events: []  out_of_sync: false  changed: false  resource_type: Exec  title: b  skipped: false  failed: false  containment_path:- Stage[main]- Main- Exec[b]...{code}which has no record of these 3 seconds. 
 
 
 
 
 
 
 
 
 
 
 
 

 
 Add Comment 
 
 
 
 
 
 
 
 
 
 

 
 
 
 
 
 
 
 
 
 

 This message was sent by Atlassian JIRA (v6.4.12#64027-sha1:e3691cc) 
   

Jira (PUP-5471) resource evaluation_time in report does not include time spent responding to events

2015-11-04 Thread Reid Barton (JIRA)
Title: Message Title
 
 
 
 
 
 
 
 
 
 
  
 
 Reid Barton commented on  PUP-5471 
 
 
 
 
 
 
 
 
 
 

 
 
 
 
 
 
 
  Re: resource evaluation_time in report does not include time spent responding to events  
 
 
 
 
 
 
 
 
 
 
The cause of the issue is simple: from `transaction.rb` 
 
 
 
 
 
 
  # Apply all changes for a resource 
 
 
 
 
  def apply(resource, ancestor = nil) 
 
 
 
 
status = resource_harness.evaluate(resource) 
 
 
 
 
add_resource_status(status) 
 
 
 
 
event_manager.queue_events(ancestor || resource, status.events) unless status.failed? 
 
 
 
 
  rescue => detail 
 
 
 
 
resource.err "Could not evaluate: #{detail}" 
 
 
 
 
  end 
 
 
 
 
  
 
 
 
 
  # Evaluate a single resource. 
 
 
 
  

Jira (PUP-5471) resource evaluation_time in report does not include time spent responding to events

2015-11-04 Thread Reid Barton (JIRA)
Title: Message Title
 
 
 
 
 
 
 
 
 
 
  
 
 Reid Barton updated an issue 
 
 
 
 
 
 
 
 
 
 

 
 
 
 
 
 
 
 Puppet /  PUP-5471 
 
 
 
  resource evaluation_time in report does not include time spent responding to events  
 
 
 
 
 
 
 
 
 

Change By:
 
 Reid Barton 
 
 
 
 
 
 
 
 
 
 Suppose a manifest contains a resource that takes a substantial amount of time to refresh (for example, an exec resource with a slow command) as a result of a notify/subscribe relationship to another resource. Then the time taken to refresh the resource is not included in the record for that resource in the report.For example:{code}$ cat test.ppfile { 'a': path=> '/home/vagrant/puppet_test/a', content => 'aaa', notify  => Exec['b']}exec { 'b': command => 'sleep 3', path=> '/usr/bin:/bin', refreshonly => true}$ rm -rf a var && time puppet apply test.pp --report --verbose --vardir=var --evaltrace...Info: /Stage[main]/Main/Exec[b]: Starting to evaluate the resourceNotice: /Stage[main]/Main/Exec[b]: Triggered 'refresh' from 1 eventsInfo: /Stage[main]/Main/Exec[b]: Evaluated in 3.01 seconds...Info: Creating state file /home/vagrant/puppet_test/var/state/state.yamlNotice: Finished catalog run in 3.02 secondsreal 0m4.653suser 0m1.279ssys 0m0.312s{code}which correctly shows that the command for `Exec[b]` took 3 seconds to run. However, the report file contains{code}$ cat var/reports/*/*.yaml...  resource_statuses:...Exec[b]: !ruby/object:Puppet::Resource::Status  resource: Exec[b]  file: /home/vagrant/puppet_test/test.pp  line: 11  evaluation_time: 0.000116117  change_count: 0  out_of_sync_count: 0  tags:- exec- b- class  time: 2015-11-04 19:00:46.679732 +00:00  events: []  out_of_sync: false  changed: false  resource_type: Exec  title: b  skipped: false  failed: false  containment_path:- Stage[main]- Main- Exec[b]...{code}which has no record of these 3 seconds. As a workaround, it's possible to extract the real time it took to process resource `Exec[b]` by running with `--evaltrace` and matching up log messages with resource statuses, but that is inconvenient and the existing `evaluation_time` field of the resource status is misleading. 
 
 
 
 
 
 
 
 
 
 
 
 

 
 Add Comment 
 
 
 
 
 
 
 
 
 
 

 
 
 

Jira (PUP-5471) resource evaluation_time in report does not include time spent responding to events

2015-11-04 Thread Reid Barton (JIRA)
Title: Message Title
 
 
 
 
 
 
 
 
 
 
  
 
 Reid Barton created an issue 
 
 
 
 
 
 
 
 
 
 

 
 
 
 
 
 
 
 Puppet /  PUP-5471 
 
 
 
  resource evaluation_time in report does not include time spent responding to events  
 
 
 
 
 
 
 
 
 

Issue Type:
 
  Bug 
 
 
 

Affects Versions:
 

 PUP 3.8.3 
 
 
 

Assignee:
 

 Unassigned 
 
 
 

Created:
 

 2015/11/04 10:46 AM 
 
 
 

Priority:
 
  Normal 
 
 
 

Reporter:
 
 Reid Barton 
 
 
 
 
 
 
 
 
 
 
 
 

 
 Add Comment 
 
 
 
 
 
 
 
 
 
 

 
 
 
 
 
 
 
 
 
 

 This message was sent by Atlassian JIRA (v6.4.12#64027-sha1:e3691cc) 
 
 
 
 
  
 
 
 
 
 
 
 
 
   





--