Hi > as far I see there have been a regression while refactoring the redhat > service provider to user /sbin/service. This commit fixes this bug (1426) and > service restarts are working again on redhat based systems. > There are no tests, as I couldn't figure out how that should be tested. It > seems that some restart logic is already tested, however it looks like not > every single kind of provider is covered by tests, nor I see at the moment > how I could do that.
and pushed to: http://github.com/duritong/puppet/tree/ticket%2F1426 however another question have been raised to me while fixing that: on redhat most (i would say 99.999%) of the services support the restart cmd, as well the status cmd. so if we have an own redhat provider, why not assume that restart and status are simply there and use them by default? I know that for example the status isn't triggered by default, as there are many systems which won't support it. but on redhat based systems you have it often (nearly always, as my experience would tell). so couldn't we assume on redhat based systems that both are simply there? so having this for example in the restart method: def restart unless @resource[:hasrestart] == :false super else service(@resource[:name], "restart") end end any thought from redhat/centos/fedora/etc. dudes? Pro: less typing and cleaner code for redhat-based shops, i simply add them now to nearly every service. Con: breaks the common and recent behaviour. "might" be a place for confusion. greets pete ps: james and luke: the next time simply tell me to fix it on my own. it's really not that hard if you into it once... ;) --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Puppet Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/puppet-dev?hl=en -~----------~----~----~----~------~----~------~--~---
