saltstack/salt — pull request #4387 by terminalmage (2013-04-05 04:36:53+00:00)
Title: Use __context__ to reduce calls to chkconfig/runlevel

This commit uses the __context__ dict to keep
salt.modules.rh_service._services() from running chkconfig --list and
runlevel every time it is called (which is often). The service.running
and service.dead states will clear the context data before trying to
detect changes.

This fixes #4295.