----- Original Message ----- > From: "Richard Pijnenburg" <richard.pijnenb...@gmail.com> > To: puppet-dev@googlegroups.com > Sent: Tuesday, December 18, 2012 7:59:53 AM > Subject: Re: [Puppet-dev] file concat library > > The main benefit is that it doesn't work with temp files and an, in > my opinion, ugly exec construct.
I agree the exec is hacky, a native one would be great. > Other benefit is that because it doesn't work with temp files it > won't corrupt the concating of files what fails at times, and you can you explain how this corruption happens? I've not had even a single report of such corruption with the concat library > will be able to see exactly what changes with the puppet runs ( this > is not possible with the exec thing ) actually it is - the concat gives you full diffs of each snipper and the final file it is managing on any change, do you have an example of what you mean here? Here's an example of the concat module restoring a line to the motd that got removed, full diffs and standard filebucket behavior remains in place and fully functional: /Stage[main]/Motd/Concat[/etc/motd]/File[/etc/motd]/content: --- /etc/motd 2012-12-18 09:18:53.817195258 +0000 +++ /tmp/puppet-file20121218-14618-1wl2lyi-0 2012-12-18 09:19:26.127176896 +0000 @@ -7,5 +7,6 @@ - ip6tables - iptables - mongodb + - pptp server Info: FileBucket adding {md5}e2e7f25ac68ac9f74073804cc57748dd Info: /Stage[main]/Motd/Concat[/etc/motd]/File[/etc/motd]: Filebucketed /etc/motd to puppet with sum e2e7f25ac68ac9f74073804cc57748dd /Stage[main]/Motd/Concat[/etc/motd]/File[/etc/motd]/content: content changed '{md5}e2e7f25ac68ac9f74073804cc57748dd' to '{md5}ac6612feae066bbdf274848cf6186954' > Also its much faster because it doesn't write temp files and > sorts/read/puts them, this one directly pulls it out of the > inventory. the writing isnt the problem so much as all the forking to do the concating and validation if any change has to happen if those bits gets done natively it would be a huge speedup -- You received this message because you are subscribed to the Google Groups "Puppet Developers" group. To post to this group, send email to puppet-dev@googlegroups.com. To unsubscribe from this group, send email to puppet-dev+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-dev?hl=en.