ok

Mini Shell

Direktori : /proc/self/root/proc/thread-self/root/lib/python2.7/site-packages/tuned/units/
Upload File :
Current File : //proc/self/root/proc/thread-self/root/lib/python2.7/site-packages/tuned/units/manager.pyc

�
��\c@s}ddlZddlZddlZddlZddlZddljZejj	�Z
dgZdefd��YZ
dS(i����NtManagercBs�eZdZd�Zed��Zed��Zed��Zd�Zd�Z	d�Z
d�Zd	�Zd
�Z
d�Zed�ZRS(
s?
	Manager creates plugin instances and keeps a track of them.
	cCsMtt|�j�||_||_||_||_g|_g|_dS(N(	tsuperRt__init__t_plugins_repositoryt_monitors_repositoryt_def_instance_priorityt_hardware_inventoryt
_instancest_plugins(tselftplugins_repositorytmonitors_repositorytdef_instance_prioritythardware_inventory((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pyRs					cCs|jS(N(R(R	((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pytpluginsscCs|jS(N(R(R	((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pyt	instancesscCs|jS(N(R(R	((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pyR
#sc
Csyg}x}t|j��D]i\}}|jsEtjd|�qn|jjd|j�t|jd�|jd<|j	|�qW|j
dd��tj�}x+|D]#}|jj
d�d||j<q�Wx�t|j��D]�\}}y0|jj|�}|||<|jj	|�Wq�tjjjk
rRtjd|�q�q�tk
r�}	tjd|�tj|	�q�q�Xq�Wg}
x�|D]}||j}|dkr�q�ntjd|j|jf�|j|j|j|j|j|j |j�}|
j	|�q�Wx;|
D]3}|j!j"�|j!j#|�|j!j$|�q!W|j%j&�|j'j(|
�dS(Nsskipping disabled instance '%s'tprioritytkeycSs|jdS(NR(toptions(tx((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pyt<lambda>1ss2skipping plugin '%s', not supported on your systemsfailed to initialize plugin %sscreating '%s' (%s)()tlisttitemstenabledtlogtdebugRt
setdefaultRtinttappendtsorttcollectionstOrderedDicttpoptNonettypeRtcreateRttunedRt
exceptionstNotSupportedPluginExceptiontinfot	Exceptionterrort	exceptiontnametcreate_instancetdevicestdevices_udev_regext
script_pretscript_posttplugintinit_devicestassign_free_devicestinitialize_instanceRtstart_processing_eventsRtextend(
R	tinstances_configtinstance_info_listt
instance_namet
instance_infotplugins_by_nametplugin_nametnoneR1teRtnew_instancetinstance((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pyR#'sP	







cOsby|||�SWnJtk
r]}tj�}tjd|t|�f�tj|�|SXdS(Ns"BUG: Unhandled exception in %s: %s(R(t	tracebackt
format_excRR)tstr(R	tcallertexc_rettftargstkwargsR>ttrace((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pyt	_try_callVs	
cCs�xA|jD]6}tjd|j�|jdd|jj|�q
Wx;|jD]0}tjd|j�|jdd|j	�qNW|j2|j2dS(Nsdestroying instance %stdestroy_allscleaning plugin '%s'(
RRRR+RJR!R1tdestroy_instanceRtcleanup(R	R@R1((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pyRK`s	cCsBx;|jjD]-}tjd|�|jdd|j�q
WdS(Nsupdating monitor %stupdate_monitors(RtmonitorsRRRJR!tupdate(R	tmonitor((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pyRNmscCs.x'|jD]}|jdd|j�q
WdS(Ntstart_tuning(RRJR!tapply_tuning(R	R@((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pyRRrscCsNt}xA|jD]6}|jdt|j|�}|tkrt}qqW|S(Nt
verify_tuning(tTrueRRJtFalseRT(R	tignore_missingtretR@tres((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pyRTws
cCs.x'|jD]}|jdd|j�q
WdS(Nt
update_tuning(RRJR!RZ(R	R@((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pyRZ�scCsD|jj�x0t|j�D]}|jdd|j|�qWdS(Ntstop_tuning(Rtstop_processing_eventstreversedRRJR!tunapply_tuning(R	t
full_rollbackR@((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pyR[�s
(t__name__t
__module__t__doc__RtpropertyRRR
R#RJRKRNRRRTRZRVR[(((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pyRs	
	/	
	
					
(RRAttuned.exceptionsR$t
tuned.logsttuned.plugins.exceptionsttuned.conststconststlogstgetRt__all__tobjectR(((s7/usr/lib/python2.7/site-packages/tuned/units/manager.pyt<module>s	

Zerion Mini Shell 1.0