summaryrefslogtreecommitdiffstats
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* | | | | Merge branch 'ticket/2.6.next/5594' into 2.6.nextnfagerlund2011-01-251-32/+2
|\ \ \ \ \
| * | | | | (#5594) Update documentation of exec resource type.nfagerlund2011-01-251-32/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The exec resource doc referred to duplicate names being allowed, which stopped being true in 0.24.2. Reviewed by Matt Robinson.
* | | | | | Merge branch 'ticket/2.6.next/5931' into 2.6.nextPaul Berry2011-01-2519-55/+31
|\ \ \ \ \ \ | |/ / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * ticket/2.6.next/5931: (#5931) Prevent errors when calling insync? on audited properties Maint: Removed dead code from resource harness. Maint: Rename misleading insync? method in file provider
| * | | | | (#5931) Prevent errors when calling insync? on audited propertiesPaul Berry2011-01-2518-34/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Created a method safe_insync? which first checks whether the property has a "should" value of nil, and if so returns true. Most insync? methods were already doing this, but a few were not, leading to bugs if a property was being audited but not set. Types should continue to override the insync? method, but callers of insync? should call safe_insync? instead. Paired-with: Jesse Wolfe <jesse@puppetlabs.com>
| * | | | | Maint: Removed dead code from resource harness.Paul Berry2011-01-251-18/+0
| | | | | | | | | | | | | | | | | | | | | | | | Paired-with: Jesse Wolfe <jesse@puppetlabs.com>
| * | | | | Maint: Rename misleading insync? method in file providerPaul Berry2011-01-253-3/+3
| |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This method actually checks whether the file owner is in sync. Renamed to is_owner_insync? Paired-with: Jesse Wolfe <jesse@puppetlabs.com>
* / / / / (#5548) Specify return values of manual status commands in service type ↵nfagerlund2011-01-251-4/+10
|/ / / / | | | | | | | | | | | | | | | | | | | | description. Reviewed by Matt Robinson.
* | | | (#5900) Include ResourceStatus#failed in serialized reportsNick Lewis2011-01-141-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This property was excluded from serialization because it was believed that its value could be determined by looking at the events of a ResourceStatus. However, if a resource can't be retrieved, it will have no events created, and will have no other way of determining its status. Reviewed-By: Paul Berry
* | | | (#5882) Added error-handling for bucketing files in puppet inspectNick Lewis2011-01-131-1/+5
| | | | | | | | | | | | | | | | Paired-With: Paul Berry
* | | | (#5882) Added error-handling to puppet inspect when auditingNick Lewis2011-01-131-12/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If auditing a resource fails, the report will contain failure events for every audited property of the resource. The report itself will also be marked as "failed". Paired-With: Paul Berry
* | | | (#5171) Made "puppet inspect" upload audited files to a file bucketPaul Berry2011-01-132-0/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This only occurs if the new setting :archive_files is set. Another new setting, :archive_file_server, can be used to specify the server that files should be uploaded to. Paired-with: Nick Lewis <nick@puppetlabs.com>
* | | | Prep for #5171: Added a missing require to inspect application.Paul Berry2011-01-131-0/+1
| | | | | | | | | | | | | | | | Paired-with: Nick Lewis <nick@puppetlabs.com>
* | | | (#5838) Support paths as part of file bucket requests.Paul Berry2011-01-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In versions of Puppet 2.6.0-2.6.4, file bucket requests are of the form md5/<checksum>/<path>. The path functionality has been removed, however we still need to support requests coming from older clients. Paired-with: Jesse Wolfe <jesse@puppetlabs.com>
* | | | (#5838) Make file bucket dipper efficient when saving a file that already existsPaul Berry2011-01-121-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Before saving to the file bucket, the file bucket dipper now checks to make sure that no file with the given checksum is already present. Paired-with: Jesse Wolfe <jesse@puppetlabs.com>
* | | | (#5838) Implemented the "head" method for FileBucketFile::File terminus.Paul Berry2011-01-123-180/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In order to do this it was necessary to refactor FileBucketFile to untangle responsibilities for computing paths, reading files, etc. In the process, removed speculative generalizations and unused functionality. Paired-with: Jesse Wolfe <jesse@puppetlabs.com>
* | | | (#5838) Added support for HEAD requests to the indirector.Paul Berry2011-01-127-13/+73
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added the ability for the indirector to handle REST HEAD requests. These are done using a new indirector method, head(), which should return true if find() would return a result and false if find() would return nil. Access control for the head method is the union of that for the find and save methods. That is, if either find or save is allowed, then head is allowed. This is necessary so that users will not have to change their authconfig to take advantage of the new feature. Paired-with: Jesse Wolfe <jesse@puppetlabs.com>
* | | | (#5838) Refactored error handling logic into find_in_cache.Paul Berry2011-01-121-7/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Moved the error handling logic surrounding the call to Puppet::Indirector::Indirection#find_in_cache() into the find_in_cache() method itself, so that won't need to be duplicated when find_in_cache() is called from elsewhere. Paired-with: Jesse Wolfe <jesse@puppetlabs.com>
* | | | (#5838) Refactored Puppet::Network::Rights#fail_on_denyPaul Berry2011-01-122-23/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Changed into a method that returns the exception to raised rather than raising it. Paired-with: Jesse Wolfe <jesse@puppetlabs.com>
* | | | (#5171) Made filebucket able to perform diffsJesse Wolfe2011-01-113-3/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is now possible to ask the filebucket to diff two files using a URL of the form: https://puppet/production/file_bucket_file/md5/{first file hash}?diff_with={second file hash} The returned diff is a string, the output of the "diff" command. Paired-with: Paul Berry <paul@puppetlabs.com>
* | | | (#5710) Removed unnecessary calls to insync?Paul Berry2011-01-071-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the resource harness, we were calling insync? on all properties of a resource, even if those properties weren't being managed. This was unsafe. Changed to only call insync? on properties that are mentioned in the manifest. In addition, we discovered that the resource harness's computation of desired_values was incorrect, and was consulting the current system state rather than the desired state. Since this hash was (erroneously) only being consulted to see if it included :ensure, this didn't cause any obvious bugs. However it is now fixed. Paired-with: Jesse Wolfe <jesse@puppetlabs.com>
* | | | Merge branch 'ticket/2.6.next/5799' into 2.6.nextNick Lewis2011-01-071-19/+1
|\| | |
| * | | (#5799) Simplify report dir creationNick Lewis2011-01-061-19/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This report processor was unnecessarily using Puppet to create a single directory. This was causing complex failures in any spec dealing with reports. Paired-With: Paul Berry
* | | | Merge branch 'maint/2.6.next/inspect_audited_should_be_true' into 2.6.nextMatt Robinson2011-01-061-1/+7
|\ \ \ \ | | | | | | | | | | | | | | | | | | | | * maint/2.6.next/inspect_audited_should_be_true: maint: Inspect reports should have audited = true on events
| * | | | maint: Inspect reports should have audited = true on eventsMatt Robinson2011-01-061-1/+7
| |/ / / | | | | | | | | | | | | Paired-with: Jesse Wolfe
* / / / Maint: Added "skipped" to the YAML output for Puppet::Resource::StatusPaul Berry2011-01-061-1/+2
|/ / / | | | | | | | | | | | | | | | In 2.6.4 and earlier, "skipped" appeared only when true. A recent change accidentally caused it to never appear. This change makes it always appear.
* | | 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-032-7/+8
|\ \ \ \ | |/ / / |/| | | | | | | | | | | | | | | | | | | * 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
| * | | 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-032-3/+7
|\ \ \ \ | |/ / / |/| | |
| * | | Fix #5698 puppet inspect shouldn't report of attributes of deleted filesJesse Wolfe2011-01-032-3/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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>
* | | | (#5715) Added attributes resource_type and title to Puppet::Resource::Status.Paul Berry2010-12-301-2/+4
| | | | | | | | | | | | | | | | | | | | 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-301-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | 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-301-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | 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-302-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | 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-302-8/+9
| | | |
* | | | (#5715) Add status attribute to reports.Paul Berry2010-12-301-3/+16
| | | |
* | | | (#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-301-8/+5
| | | | | | | | | | | | | | | | Previously these metrics were omitted when their values were zero.
* | | | (#5715) Refactor in preparation for adding a status attribute to reports.Paul Berry2010-12-304-30/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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-301-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | 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-301-0/+2
| | | | | | | | | | | | | | | | | | | | 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-302-2/+2
| | | |
* | | | (#5715) Removed redundant attribute Resource::Status#versionPaul Berry2010-12-301-2/+2
| | | |
* | | | (#5715) Removed Puppet::Util::Log#version.Paul Berry2010-12-303-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | 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-301-1/+1
| | | |
* | | | (#5715) Removed Resource::Status#skipped_reason. It was never used.Paul Berry2010-12-301-1/+1
|/ / /