>> Welcome all,
>>
>> Resources  can  depend  one from each other, and failure of a required
>> resource prevent the dependants from being run.
>>
>> But  how  to  trap these failures and handle them? Is there any way to
>> e.g.   set  a  variable  $error_happened  to  "true"  if  some promise
>> about  the  resource  couldn't  be  kept? Maybe even there is a way to
>> capture the error string?
>>
>> Some  preventive  actions  can  be automated, and Puppet seems to be a
>> good  place to implement   them.   And   users  who program Puppet are
>> encouraged to keep from external scripts as far as they could.

> What are your goals here?

> There isn't a lot of room for programming these aspects of Puppet from
> within the language, but you're the first person to ask for this kind
> of feature, so for all I know, what you're asking for might be
> straightforward to add.

This  question  is  connected  with  my  previous  one,  the one about
determining  if  there  is  enough  place in the destination to copy a
file.  Because  if there isn't - the "file" resource fails and I could
catch  that  condition  and  do  some  action  -  rollback  whole move
operation,  which  means delete the ".puppettmp" file, move back those
files, which had been already moved, and perhaps send an email.

Now  I  understand, that whole that process would better be handled by
custom  scripts, so maybe indeed there is no need for such feature. At
least not when transaction support is ready.

--
 Adam Ryczkowski
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To post to this group, send email to puppet-users@googlegroups.com
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to