Before, when attempting to download the CSV export of nodes and their resource
statuses, the download wouldn't start until after all of the data had been
collected, and converted to CSV.
By passing render a proc, and using output.write, we can send each CSV line to
the client as it is generated.
The nodes controller now has the ability to respond to requests for CSV data,
by serializing its collection of nodes to CSV, similarly to YAML requests.
This is a necessary step to make CSV output actually available to users.
Paired-With: Ben Hengst
Paired-With: Daniel Pittman
Paired-With: Jacob
A compliant node is one without any failed resources. However, because the
failed column on resource_statuses is nullable, it defaults to null. Since we
weren't specifying it in this factory, the resource status wasn't being
considered successful.
Paired-With: Ben Hengst
Signed-off-by: Nick Lewis
When exporting ResourceStatus as CSV, we don't want to include id, report_id,
and tags, so we override the default to_csv_properties.
We exclude id and report_id because they are completely internal fields to
Dashboard. Tags are excluded because, as an array, they don't export well to
CSV.
Paired
This adds a CsvSerializable module which is mixed into Array,
ActiveRecord::NamedScope::Scope, and adds functionality to
ActiveRecord::Base implementing the to_csv method.
On Array, and ActiveRecord::NamedScope::Scope this method will call
"to_csv_header" on the class of the first element of the a
Node.to_csv now uses a custom set of properties for CSV:
name, status, resources_count, pending_count, succeessful_count, failed_count
Each resource status for the node will be included along with the node
properties, which will cause multiple CSV lines to be generated per node (one
for each ass
Paired-with: Jacob Helwig
Signed-off-by: Nick Lewis
---
Local-branch: ticket/next/7007
app/views/pages/_node_summary_row.haml |1 -
1 files changed, 0 insertions(+), 1 deletions(-)
diff --git a/app/views/pages/_node_summary_row.haml
b/app/views/pages/_node_summary_row.haml
index bf3fb96..3
These are similar to the corresponding scopes on node, in that they accept
predicates for failed=true/false and pending=true/false. We do this with a
scope for failed instead of using a finder (find_all_by_failed) so we can chain
it with other scopes for lazy evaluation. These scopes are necessary
This is a simple link to NodesController#index, which doesn't attempt to scale
to support a large number of nodes, or resource statuses. It will always export
the entire node list.
Paired-With: Jacob Helwig
Signed-off-by: Nick Lewis
---
Local-branch: ticket/next/7007
app/views/pages/home.html.h
From: Dominic Maraglia
The test for ticket 7117 producedes spurious failures due to timing:
a curl command is executed from an agent to a freshly started
Puppet Master; if the Puppet Master is not ready to accept the connection
the test will fail. Added an until loop that issues simple curl
com
In ticket #1064 we made the use of 'plugins' directories in modules
deprecated. This was released in 0.25.0 in 2009. This commit removes
this deprecation warning and defaults the plugin directory to 'lib'.
All tests also fixed.
Signed-off-by: James Turnbull
---
Local-branch: tickets/master/7591
On May 20, 2011, at 12:08 PM, Nigel Kersten wrote:
>
>
> On Fri, May 20, 2011 at 9:33 AM, Luke Kanies wrote:
> On May 20, 2011, at 8:36 AM, Nigel Kersten wrote:
>
>> So it turns out that we've never actually had failed pre/post commands cause
>> runs to fail, even though the tests appear to b
Exclude spec test for multiple writer processes as this fails
intermittently on ruby 1.9.
Reviewed-by: Jacob Helwig
---
Local-branch: ticket/2.7.x/7507
spec/integration/util/file_locking_spec.rb |4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/spec/integration/util/f
On Fri, May 20, 2011 at 9:33 AM, Luke Kanies wrote:
> On May 20, 2011, at 8:36 AM, Nigel Kersten wrote:
>
> So it turns out that we've never actually had failed pre/post commands
> cause runs to fail, even though the tests appear to be testing the right
> thing.
>
> it "should fail if the c
Facter 1.5.9 is a maintenance release containing fixes and updates.
This release contains several fixes, and updated facts, as well as
adding some new facts. These include enhancements with Facter & EC2,
additional memory facts for OS X, and better Ruby 1.9 support.
As always, please let us know
Dir.glob returns an array, but a test was stubbing it to return a
string. In Ruby 1.8.7 if you call enumerable methods (each, collect,
etc) on a string, the string is split on \n first. This meant the poor
stubbing didn't affect 1.8.7, but 1.9.2 is more strict and won't
automatically convert when
The first method is not available on Enumerable in ruby 1.8.5, so when
it is mixed into ASTArray, you can't call first.
Reviewed-By: Matt Robinson
Signed-off-by: Josh Cooper
---
Local-branch: ticket/2.7.x/7507
spec/integration/parser/parser_spec.rb |4 ++--
1 files changed, 2 insertions(+),
Additionally we fixed a scoping issue with the File type.
Paired-With: Matt Robinson
Signed-off-by: Josh Cooper
---
Local-branch: ticket/2.7.x/7507
lib/puppet/type/file.rb |2 +-
spec/unit/indirector/facts/couch_spec.rb |4 ++--
spec/unit/parser/resource_spec.rb
Hi all,
I try to code a Puppet type that act like this :
class1 {
mytype { "a name":
command => "command = YY"
}
}
class2 {
mytype { "a name":
command => "command = XX",
}
}
On the client, it generate a file :
myfile.cfg
-
command = YY
command = XX
I want t
On May 20, 2011, at 8:36 AM, Nigel Kersten wrote:
> So it turns out that we've never actually had failed pre/post commands cause
> runs to fail, even though the tests appear to be testing the right thing.
>
> it "should fail if the command fails" do
> Puppet.settings[:prerun_comman
So it turns out that we've never actually had failed pre/post commands cause
runs to fail, even though the tests appear to be testing the right thing.
it "should fail if the command fails" do
Puppet.settings[:prerun_command] = "/my/command"
Puppet::Util.expects(:execute).rais
In the past any error in loading config or parsing application list would simply
result in an empty applicaiton list being returned. In cases of a configuration
error this masked the real cause and made debugging really hard.
We now print the exception received instead and exit with a exit code o
22 matches
Mail list logo