On Wednesday, August 29, 2012 at 11:36 PM, Andrea Campi wrote:
On Thu, Aug 30, 2012 at 6:19 AM, John Alberts < "> > wrote:That's great to hear. ThanksOn Wed, Aug 29, 2012 at 10:26 PM, Daniel DeLeo < "> > wrote:Definitely a bug and probably an easy fix. I'll make sure it getsattention.I commented on the ticket—I strongly believe the current behavior iscorrect. Here it is for convenience:There have been questions before, people wondering why Chef doesn'tcreate an init script—and the general consensus was that the serviceresource should assume everything is set up correctly, including aninit script.Following that line of reasoning, if I ask Chef to stop a service andthe init script is missing, Chef won't be able to stop it—and that's afatal error if there ever was one.The stop action cannot assume the recipe is also calling disable—maybethe recipe is stopping it to apply some changes and then start itagain. If the service doesn't stop, all bets are off; subsequentactions may corrupt data and so on.The disable action is different.On most distros it doesn't depend on the init script at all, in whichcase I agree it can ignore the absence of the init script.The bottom line is, the service shouldn't swallow exceptions.I think that's already the case, so here's my vote for rejecting this ticket.(Note that I'm not arguing the implementation is perfect—if adistro-specific init system doesn't need the init script to disablethe service yet it fails, then the distro-specific provider should befixed. I'm only arguing this shouldn't leak into the generic provider)
Archive powered by MHonArc 2.6.16.