summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
| | | | * | (#5771): Fix spec failures associated with rspec upgradeNick Lewis2011-01-054-96/+6
| | | |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Due to changes in the spec_helper, some of the specs that use puppettest were failing when run individually. In the future, it would be nice to remove puppettest from the specs entirely, as it's old, crufty, and only used for a couple of things. Paired-With: Matt Robinson
| | | * | Merge branch 'ticket/2.6.next/upgrade_rspec' into 2.6.nextNick Lewis2011-01-0450-228/+83
| | | |\ \
| | | | * | (#5771) Upgrade rspec to version 2Matt Robinson2011-01-0450-228/+83
| | | |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The biggest change is that we no longer need to monkey patch rspec to get confine behavior. Describe blocks can now be conditional like confine used to be. "describe" blocks with "shared => true" are now "shared_examples_for". Paired-With: Nick Lewis
| | | * | Merge branch 'maint/2.6.next/remove_stray_p' into 2.6.nextJesse Wolfe2011-01-031-1/+1
| | | |\ \
| | | | * | maint: remove stray debug statement.Jesse Wolfe2011-01-031-1/+1
| | | |/ / | | | | | | | | | | | | | | | I accidentally committed a debug statement. Now I am removing it.
| | | * | Merge branch 'maint/2.6.next/speed_up_slow_inspects' into 2.6.nextJesse Wolfe2011-01-035-0/+20
| | | |\ \
| | | | * | maint: Prune #inspect methods on various objectsJesse Wolfe2011-01-035-0/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ruby's default #inspect method can lead to printing factorial-order output for large graphs of objects. Since we have large graphs of objects, this is not optimal. This patch replaces a few well-connected objects' #inspect methods with methods that produce reduced output, and are thus much faster. Paired-With: Nick Lewis <nick@puppetlabs.com>
| | | * | | Merge branch 'ticket/2.6.next/5758' into 2.6.nextPaul Berry2011-01-033-13/+64
| | | |\ \ \ | | | | |/ / | | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | * ticket/2.6.next/5758: (#5758) Verify that report events are correctly created Prep work for #5758: set audited=true on all audit events Prep work for #5758: clean up initializer for Puppet::Transaction::Event
| | | | * | (#5758) Verify that report events are correctly createdPaul Berry2011-01-031-6/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added code to resource_harness_spec to test all the attributes of report events, not just the log messages. Paired-with: Matt Robinson <matt@puppetlabs.com>
| | | | * | Prep work for #5758: set audited=true on all audit eventsPaul Berry2011-01-031-4/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, events would only have audited=true if auditing was enabled AND there had been a change in an audited parameter. Paired-with: Matt Robinson <matt@puppetlabs.com>
| | | | * | Prep work for #5758: clean up initializer for Puppet::Transaction::EventPaul Berry2011-01-031-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Puppet::Transaction::Event#initialize() contained unnecessary code that allowed the properties of an event to be passed in as separate arguments. This was never used. Paired-with: Matt Robinson <matt@puppetlabs.com>
| | | * | | Merge branch 'ticket/2.6.next/5698' into 2.6.nextJesse Wolfe2011-01-033-4/+31
| | | |\ \ \ | | | | |/ / | | | |/| |
| | | | * | Fix #5698 puppet inspect shouldn't report of attributes of deleted filesJesse Wolfe2011-01-033-4/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If a resource is absent, then reporting that its properties are all ":absent" is not particularly correct. This patch makes the `inspect` application's reports behave more like `apply` reports, and skip properties other than :ensure for absent resources. Reviewed-By: Nick Lewis <nick@puppetlabs.com>
| | | * | | Merge branch 'ticket/2.6.next/5715' into 2.6.nextPaul Berry2010-12-3023-159/+230
| | | |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * ticket/2.6.next/5715: (#5715) Added attributes resource_type and title to Puppet::Resource::Status. (#5715) Removed attribute source_description from the YAML representation of Puppet::Resource::Status. (#5715) Removed unnecessary attributes from YAML of Puppet::Transaction::Event. (#5715) Make certain report attributes always present. (#5715) Changed the type of metric names to always be strings. (#5715) Add status attribute to reports. (#5715) Made the report "calculate" methods strictly functional. (#5715) Made the changes/total and events/total metrics always present (#5715) Refactor in preparation for adding a status attribute to reports. (#5715) Added total time to inspect reports and made inspect metrics more consistent. (#5715) Removed Puppet::Transaction::Report#external_times from YAML output. (#5715) Added total time metric to apply reports. (#5715) Removed redundant attribute Transaction::Event#version (#5715) Removed redundant attribute Resource::Status#version (#5715) Removed Puppet::Util::Log#version. (#5715) Removed the unused attribute Puppet::Transaction::Event#node (#5715) Removed Resource::Status#skipped_reason. It was never used. (#5715) Prep work: Fixed add_statuses in report_spec.
| | | | * | | (#5715) Added attributes resource_type and title to Puppet::Resource::Status.Paul Berry2010-12-302-2/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These new attributes save report processors from having to parse the "resource" attribute.
| | | | * | | (#5715) Removed attribute source_description from the YAML representation ofPaul Berry2010-12-302-0/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Puppet::Resource::Status. This attribute is only used for properly generating log messages and was never intended to appear in reports.
| | | | * | | (#5715) Removed unnecessary attributes from YAML of Puppet::Transaction::Event.Paul Berry2010-12-302-0/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The removed attributes are file, line, resource, tags, source_description, and default_log_level. These attributes were all redundant with those in Puppet::Resource::Status.
| | | | * | | (#5715) Make certain report attributes always present.Nick Lewis2010-12-305-8/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The attributes Puppet::Resource::Status#changed, Puppet::Resource::Status#out_of_sync, and Puppet::Transaction::Event#audited used to only appear in reports when their state was true. Now they appear always.
| | | | * | | (#5715) Changed the type of metric names to always be strings.Paul Berry2010-12-305-44/+41
| | | | | | |
| | | | * | | (#5715) Add status attribute to reports.Paul Berry2010-12-302-6/+34
| | | | | | |
| | | | * | | (#5715) Made the report "calculate" methods strictly functional.Paul Berry2010-12-301-9/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These methods previously stored the metrics as a side effect; now they simply compute the metrics and return them.
| | | | * | | (#5715) Made the changes/total and events/total metrics always presentPaul Berry2010-12-302-8/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously these metrics were omitted when their values were zero.
| | | | * | | (#5715) Refactor in preparation for adding a status attribute to reports.Paul Berry2010-12-307-60/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Renamed Puppet::Transaction::Report#calculate_metrics to finalize_report, in preparation for adding more functionality to this method. Removed Puppet::Transaction#send_report and Puppet::Transaction#generate_report. The former was never used, and the latter was unnecessary.
| | | | * | | (#5715) Added total time to inspect reports and made inspect metrics more ↵Paul Berry2010-12-301-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | consistent. Inspect reports now contain all the metrics that apply reports do, and use the same code path for creating them.
| | | | * | | (#5715) Removed Puppet::Transaction::Report#external_times from YAML output.Paul Berry2010-12-302-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This attribute was never intended to be serialized to YAML; it exists merely as temporary storage for metrics that have not yet been placed in the report's metrics attribute.
| | | | * | | (#5715) Added total time metric to apply reports.Paul Berry2010-12-302-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was a feature that was present in 0.25.x and was inadvertently dropped from 2.6.x.
| | | | * | | (#5715) Removed redundant attribute Transaction::Event#versionPaul Berry2010-12-304-4/+4
| | | | | | |
| | | | * | | (#5715) Removed redundant attribute Resource::Status#versionPaul Berry2010-12-302-4/+4
| | | | | | |
| | | | * | | (#5715) Removed Puppet::Util::Log#version.Paul Berry2010-12-309-23/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This attribute was only relevant in reports, and in reports it was redundant with Puppet::Transaction::Report#configuration_version and Puppet::Transaction::Report#puppet_version.
| | | | * | | (#5715) Removed the unused attribute Puppet::Transaction::Event#nodePaul Berry2010-12-302-2/+2
| | | | | | |
| | | | * | | (#5715) Removed Resource::Status#skipped_reason. It was never used.Paul Berry2010-12-302-2/+2
| | | | | | |
| | | | * | | (#5715) Prep work: Fixed add_statuses in report_spec.Paul Berry2010-12-301-1/+1
| | | |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Report_spec contained a helper method called add_statuses which claimed to add a status object n times. It actually always added it 3 times, and fortunately callers always specified n=3. Changed this to be more sane.
| | | * | | Merge branch 'ticket/2.6.next/5723' into 2.6.nextNick Lewis2010-12-291-3/+3
| | | |\ \ \ | | | | |/ / | | | |/| |
| | | | * | (#5723) Fix failing type/package specsNick Lewis2010-12-291-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These tests were failing because they were overly constraining what the code could do. Because of a bug in Mocha 0.9.8, these failures weren't caught when the code causing them was first made. These failures were introduced in 7fff7808e25491a5ea1e207b8de3ade0c4f95f4f. Paired-With: Paul Berry
| | | * | | Merge branch 'ticket/2.6.next/5169' into 2.6.nextJesse Wolfe2010-12-207-12/+132
| | | |\ \ \
| | | | * | | Implement #5168 and #5169 ctime and mtime are propertiesJesse Wolfe2010-12-207-12/+132
| | | |/ / / | | | | | | | | | | | | | | | | | | | | | | | | File ctime and mtime are now implemented as read-only properties, so they can be examined with audit.
| | | * | | Merge branch 'ticket/2.6.next/3782' into 2.6.nextPaul Berry2010-12-171-1/+4
| | | |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | * ticket/2.6.next/3782: [3782] Test isolation problem in test/ral/providers/cron/crontab.rb
| | | | * | | [3782] Test isolation problem in test/ral/providers/cron/crontab.rbPaul Berry2010-12-171-1/+4
| | | |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The test in question (test_parse_line) was nondeterministic because it was relying on the sort order of a Hash whose keys were symbols. When the sort order caused a blank line to appear at the end of the file under test, the blank line was elided by the crontab parser, causing a failure. Modified the test to execute in a deterministic order that doesn't place the blank line at the end.
| | | * | | Merge branch 'maint/2.6.next/5408' into 2.6.nextPaul Berry2010-12-178-680/+315
| | | |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint/2.6.next/5408: Modified the behavior of Puppet::Resource::Status as follows: (#5408) Reworked ResourceHarness so that code is clearer and all behaviors are tested
| | | | * | | Modified the behavior of Puppet::Resource::Status as follows:Paul Berry2010-12-174-11/+62
| | | | |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - #change_count now only counts events that represent successful changes. It does not count failures, audits, or noops. - #changed is equivalent to #change_count > 0. - #out_of_sync_count (a new attribute) counts all events except audits. - #out_of_sync is equivalent to #out_of_sync_count > 0. This should hopefully make the summary statistics in reports more useful.
| | | | * / (#5408) Reworked ResourceHarness so that code is clearer and all behaviors ↵Paul Berry2010-12-178-680/+264
| | | |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | are tested This patch removes the Puppet::Transaction::Change class and replaces it with a method, Puppet::Transaction::ResourceHarness#apply_parameter. The new code is shorter, more thoroughly unit tested, and addresses known bugs in the interaction between auditing and performing changes. This code does not address drawbacks in the report output (for example a resource is still flagged as changed even if it merely contains audit information); those will be addressed in a follow-up patch.
| | | * | Merge branch 'ticket/2.6.next/5493' into 2.6.nextNick Lewis2010-12-1615-91/+77
| | | |\ \
| | | | * | (#5493) Add report_format, puppet_version, and configuration_version to ReportsNick Lewis2010-12-1613-58/+60
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Current report formats are: 0: 0.25 reports and earlier 1: 0.26.1 - 0.26.4 reports 2: 0.26.5 and beyond Paired-With: Jesse Wolfe
| | | | * | (#5375) Rework puppet apply to use configurer.runPaul Berry2010-12-164-33/+17
| | | |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Puppet apply used to contain code that duplicated the functionality of configurer.run. Refactored to share code. Paired-with: Jesse Wolfe <jesse@puppetlabs.com>
| | | * | Merge branch 'ticket/2.6.4/5566' into 2.6.nextJesse Wolfe2010-12-162-1/+20
| | |/| |
| | | * | Fix #5566 none, mtime, and ctime checksum types can write file contentsJesse Wolfe2010-12-162-1/+20
| | | |/ | | | | | | | | | | | | | | | | | | | | | | | | The #write method in lib/puppet/type/file/content.rb relies on the block passed to #sum_stream getting executed. "none", "mtime", and "ctime" aren't real checksums, so they violated that assumption and just returned empty results. This patch causes that block to get executed.
| | * | Merge branch 'ticket/2.6.next/maint-fix_active_record_confine' into 2.6.nextMatt Robinson2010-12-161-12/+15
| | |\ \ | | | | | | | | | | | | | | | | | | | | * ticket/2.6.next/maint-fix_active_record_confine: maint: Fix ActiveRecord confine issue
| | | * | maint: Fix ActiveRecord confine issueMatt Robinson2010-12-161-12/+15
| | |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We made a class that inherited from ActiveRecord, but did so outside a block so the confine wasn't skipping it when ActiveRecord wasn't installed. Moving that class inside a before block caused the confine to work properly. Paired-with: Nick Lewis
| | * | Merge branch 'maint/2.6.next/fix-test-dependency-problems' into 2.6.nextNick Lewis2010-12-1615-0/+15
| |/| |
| | * | maint: Fix a test that was missing a requireMatt Robinson2010-12-162-0/+2
| | | | | | | | | | | | | | | | Paired-with: Nick Lewis