summaryrefslogtreecommitdiffstats
path: root/lib/puppet/transaction.rb
Commit message (Collapse)AuthorAgeFilesLines
...
* Consolidating all of the configuration parameter declarations into ↵luke2007-05-041-18/+2
| | | | | | configuration, at least partially just because then the docs for each parameter have to be a bit better. Also, I have gotten rid of the "puppet" section, replacing it with "main", and changed, added, or removed a couple of other sections. In general, we should now prefer more sections, rather than fewer. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2463 980ebf18-57e1-0310-9a29-db15c13687c0
* Adding a --summarize option, to get a transaction summaryluke2007-05-041-11/+4
| | | | git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2459 980ebf18-57e1-0310-9a29-db15c13687c0
* Renaming some methods so that we can generate a report on a transaction and ↵luke2007-03-301-38/+40
| | | | | | then retrieve it later git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2372 980ebf18-57e1-0310-9a29-db15c13687c0
* More work on #542 -- services in noop now produce noop events so that they ↵luke2007-03-181-1/+7
| | | | | | can themselves trigger further changes git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2295 980ebf18-57e1-0310-9a29-db15c13687c0
* Trying to clean up the error message from #490. It looks like the problem ↵luke2007-03-181-1/+1
| | | | | | is just a failure in one of the types, and it has nothing to do with the state file. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2287 980ebf18-57e1-0310-9a29-db15c13687c0
* Fixing #542. Transactions now cause services to warn when they would have ↵luke2007-03-171-8/+24
| | | | | | gotten restarted by a noop resource. Also fixing #549 -- transactions now only refuse to delete required resources if they are being purged. All other resources can be deleted just fine. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2286 980ebf18-57e1-0310-9a29-db15c13687c0
* Adding some more testing on the @should values for :groups on users, and ↵luke2007-03-081-4/+1
| | | | | | fixing a bug that often made :groups think it was out of sync. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2267 980ebf18-57e1-0310-9a29-db15c13687c0
* Fixing at least part of #514. This does not get rid of all errors, but at ↵luke2007-02-281-11/+18
| | | | | | least it fixes the spurious warning git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2241 980ebf18-57e1-0310-9a29-db15c13687c0
* Redoing some aspects of the graphing in hopes of helping hte performance a bit.luke2007-02-271-2/+3
| | | | git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2230 980ebf18-57e1-0310-9a29-db15c13687c0
* Moving some of the stand-alone classes into the util/ subdirectory, to clean ↵luke2007-02-071-2/+2
| | | | | | up the top-level namespace a bit. This is a lot of file modifications, but most of them just change class names and file paths. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2178 980ebf18-57e1-0310-9a29-db15c13687c0
* Merging the state-rename branch. This includes the diff from version 2156 ↵luke2007-02-071-9/+11
| | | | | | to 2168. All states should now be properties, with backward compatibility for the types that restricted themselves to the methods. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2169 980ebf18-57e1-0310-9a29-db15c13687c0
* Providing a partial fix for #428. Resources can now be deleted as long as ↵luke2007-01-301-2/+3
| | | | | | all of their dependencies are also being deleted. This, combined with the fix to #433, means that you can now explicitly specify the order of deletion, and everything will work as long as all required objects are being removed, too. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2129 980ebf18-57e1-0310-9a29-db15c13687c0
* Fixing #433. I basically just added checks to all the places where I add ↵luke2007-01-301-6/+30
| | | | | | edges, to make sure automatic relationships lose out to explicit ones. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2117 980ebf18-57e1-0310-9a29-db15c13687c0
* Doing more work on #113. Mostly, just making sure remounts do not happen ↵luke2007-01-291-4/+6
| | | | | | spuriously very often. They will still have extra remounts when changing the value of "ensure", but that is not currently avoidable (similar to #199). git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2109 980ebf18-57e1-0310-9a29-db15c13687c0
* Fixing #113. I added support in the transaction for self-refreshing, which ↵luke2007-01-281-3/+17
| | | | | | just creates a special trigger for resources that have self-refreshing enabled. Logging is a bit different for them, so it is clear why they are refreshing. I still need to verify the remount methods work in the providers. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2107 980ebf18-57e1-0310-9a29-db15c13687c0
* Changing how transactions check whether a resource is being deleted. This ↵luke2007-01-281-3/+3
| | | | | | is a small step towards fixing #428. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2102 980ebf18-57e1-0310-9a29-db15c13687c0
* Wrapping the resource generation methods in begin/rescue blocks so that ↵luke2007-01-231-2/+15
| | | | | | failures cannot kill the transaction. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2085 980ebf18-57e1-0310-9a29-db15c13687c0
* Fixing #424. The configuration compile time is now cached in the yaml cache ↵luke2007-01-231-1/+0
| | | | | | file. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2081 980ebf18-57e1-0310-9a29-db15c13687c0
* Fixing #437. Transactions now check whether graphs are cyclic, with a ↵luke2007-01-231-0/+3
| | | | | | somewhat-useful error message if they are. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2079 980ebf18-57e1-0310-9a29-db15c13687c0
* Fixing a few testing bugs that have crept in, and fixing a self-reference ↵luke2007-01-051-6/+11
| | | | | | problem when configuring, graphing, and setting graphdir manually. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2052 980ebf18-57e1-0310-9a29-db15c13687c0
* Fixing #401. Transactions were trying to trigger every resource, even those ↵luke2007-01-031-1/+2
| | | | | | that did not respond to the specified callback. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2022 980ebf18-57e1-0310-9a29-db15c13687c0
* Not setting the graphdir to the puppet user, since it is only used by puppetdluke2007-01-031-5/+1
| | | | git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2021 980ebf18-57e1-0310-9a29-db15c13687c0
* Fixing #390. You can now add --graph to produce dot files, and you can then ↵luke2006-12-311-3/+29
| | | | | | produce pngs or whatever from those. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@2007 980ebf18-57e1-0310-9a29-db15c13687c0
* Adding a bit more testing to mounts, and pulling a bit of the transaction ↵luke2006-12-291-13/+18
| | | | | | into a separate method to shorten the apply() method. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1986 980ebf18-57e1-0310-9a29-db15c13687c0
* Finally writing unit tests for Transaction#trigger, and drastically ↵luke2006-12-291-52/+46
| | | | | | simplifying the method in the process. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1985 980ebf18-57e1-0310-9a29-db15c13687c0
* A couple of small bug fixesluke2006-12-291-7/+8
| | | | git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1982 980ebf18-57e1-0310-9a29-db15c13687c0
* Fixing #387, hopefully.luke2006-12-281-0/+4
| | | | git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1978 980ebf18-57e1-0310-9a29-db15c13687c0
* Fixing #386.luke2006-12-271-0/+2
| | | | git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1974 980ebf18-57e1-0310-9a29-db15c13687c0
* Not downcasing facts any longer, closing #210 (although not using the patch ↵luke2006-12-231-23/+22
| | | | | | from mpalmer, since I had not noticed the patch was there). Also, making all nodes, classes, and definitions case insensitive, closing #344. Finally, I added case insensitivity to the language in general, which should preserve backwards compatibility and probably makes the most sense in the long run anyway. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1964 980ebf18-57e1-0310-9a29-db15c13687c0
* *whew* Fixing the vast majority of the graph-related performance problems. ↵luke2006-12-211-6/+7
| | | | | | I found a simple solution to handling events produced by generated resources, and that basically fixed all of the performance problems. Transaction tests still fail, but I wanted to get the fix in now so I do not forget it. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1961 980ebf18-57e1-0310-9a29-db15c13687c0
* Fixing #372 and #374. All is not perfect, since OS X still cannot set UID, ↵luke2006-12-191-0/+1
| | | | | | but it is much better. There is still plenty of bug-fixing to do on other platforms, I expect. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1954 980ebf18-57e1-0310-9a29-db15c13687c0
* Adding :replace aliases, as requested in #366.luke2006-12-191-2/+0
| | | | git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1952 980ebf18-57e1-0310-9a29-db15c13687c0
* Some more graph optimizations; I think I am now close enough that I am ↵luke2006-12-171-31/+66
| | | | | | basically just going to spend a bit more time making sure the modeling is right in the transactions, and then walk away for now. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1947 980ebf18-57e1-0310-9a29-db15c13687c0
* Fixing the next round of bugs, mostly little things but I had to modify ↵luke2006-12-131-1/+11
| | | | | | transactions so they are willing to delete implicit resources even if they have dependencies, else we would often not be able to purge files at all. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1917 980ebf18-57e1-0310-9a29-db15c13687c0
* Almost all tests now pass. I have basically reached the point where I was ↵luke2006-12-111-5/+6
| | | | | | before I integrated graphing, except that all of the relationship handling is now inside the transaction, and any kind of recursion (including file) is *tons* easier to model and manage. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1905 980ebf18-57e1-0310-9a29-db15c13687c0
* Most tests now pass in the whole system, but there are still about 8 cases ↵luke2006-12-111-0/+5
| | | | | | that do not work. I am working on those now. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1904 980ebf18-57e1-0310-9a29-db15c13687c0
* Most of the graph handling is now done, and all of the recursive types ↵luke2006-12-101-42/+67
| | | | | | (basically just file, tidy, and component) now correctly use the generation mechanisms in the transactions, instead of sticking them in their @children array. Now I just need to go through the rest of the tests and make sure everything passes. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1901 980ebf18-57e1-0310-9a29-db15c13687c0
* Another intermediate commit. Most of the graphing work itself is now done, ↵luke2006-12-091-71/+153
| | | | | | but I am in the middle of converting files to use the graphs and at the same time am writing some actually decent tests for the file recursion stuff. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1899 980ebf18-57e1-0310-9a29-db15c13687c0
* Most of the graphing work is now done. I have also added the generator work ↵luke2006-12-011-66/+113
| | | | | | in transactions, but I need to migrate files to using it. Until that migration is done, files will not work correctly for many cases. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1896 980ebf18-57e1-0310-9a29-db15c13687c0
* Intermediate commit -- I am ready to start pushing the graph stuff into the ↵luke2006-11-261-2/+6
| | | | | | types and transactions, which will break everything for a little while. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1894 980ebf18-57e1-0310-9a29-db15c13687c0
* An intermediate commit. All of the classes that use parsedfile are ↵luke2006-11-111-0/+1
| | | | | | | | assuredly broken, since I have basically completely rewritten it. These classes have been a thorn in my side almost since I created them, yet they have been significantly less functional that I wanted. So, I decided to do the rewrite I have been putting off, just to spend all of the maintenance time now so I do not spend 3 days on them every release. Tomorrow I will be porting all of the existing types (including cron, hopefully) over to this new base. This will also make it possible to add other types of providers to these classes; we should be able to reuse the netinfo provider for os x types, and we should be able to create a cron provider that writes to /etc/crontab instead of user crontabs. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1856 980ebf18-57e1-0310-9a29-db15c13687c0
* Adding prefetch of providers to transactions. Nothing is using it yet. I ↵luke2006-10-181-0/+18
| | | | | | wrote it for cron jobs, but it is too much work to fix this for cron jobs right now. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1806 980ebf18-57e1-0310-9a29-db15c13687c0
* Fixing the rrdgraph report so that it creates a separate rrd directory for ↵luke2006-10-051-9/+9
| | | | | | each host git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1735 980ebf18-57e1-0310-9a29-db15c13687c0
* Adding flush functionality as requested by Scott Seagoluke2006-09-271-0/+5
| | | | git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1697 980ebf18-57e1-0310-9a29-db15c13687c0
* As requested by Christian Warden, triggering an object now results inluke2006-09-221-7/+25
| | | | | | | | an event, which can result in further triggers. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1660 980ebf18-57e1-0310-9a29-db15c13687c0
* Using the "trace" configuration parameter to determine whether a stack trace ↵luke2006-09-151-1/+1
| | | | | | should be printed, rather than just using "debug". I added the param a little while ago and was using it internally in Puppet::DevError, but I just now went through the whole configuration and switched to using it. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1613 980ebf18-57e1-0310-9a29-db15c13687c0
* Adding an "ignoretags" attribute to transaction, and setting it for ↵luke2006-09-051-2/+2
| | | | | | downloading plugins or facts, and for creating config directories git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1562 980ebf18-57e1-0310-9a29-db15c13687c0
* Removing all of the changes I made towards refactoring in the last couple of ↵luke2006-09-051-16/+1
| | | | | | days. They have all been moved into the sync-retrieve-refactor branch. This branch will soon become 0.19.0, and will not include that refactoring. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1555 980ebf18-57e1-0310-9a29-db15c13687c0
* Committing functional mount support. All that's left in this chunk of work ↵luke2006-09-051-1/+1
| | | | | | is cron. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1552 980ebf18-57e1-0310-9a29-db15c13687c0
* Beginning the process of moving parsedtypes to a provider. Each parsedluke2006-09-031-0/+9
| | | | | | | | | | | | | | | | | | type will have a parsedfile provider, which will be responsible for all of the file parsing and generation. This should allow us to create a useful DSL for file handling, but it also *drastically* simplifies these types. These types have always been a bit fragile, and it was never quite clear who was responsible for what. Now, with the type/provider split, everything is much clearer. I still need to convert host, sshkey, and mount, and something needs to be done with cron. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1547 980ebf18-57e1-0310-9a29-db15c13687c0