 < ? x m l   v e r s i o n = " 1 . 0 "   e n c o d i n g = " I S O - 8 8 5 9 - 1 "   s t a n d a l o n e = " y e s " ? > 
 < d u n e s - p o l i c y   n a m e = " S N M P   T r a p   w i t h   d a t a "   t y p e = " 0 "   a p i - v e r s i o n = " 3 . 1 . 0 "     i d = " 8 3 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 0 D 8 B 8 0 8 0 0 1 3 4 5 4 6 4 2 0 7 2 9 8 a e b f 2 a 6 a 5 a 5 "     v e r s i o n = " 0 . 0 . 1 "     a l l o w e d - o p e r a t i o n s = " v f e "   > 
 < d e s c r i p t i o n > < ! [ C D A T A [ R e c i v e   a   s n m p   t r a p   a n d   d e l i v e r s   t h e   d a t a   t o   a   f o l l o w i n g   o b j e c t ] ] > < / d e s c r i p t i o n > 
 < i t e m   t a g = " d e v i c e "   t y p e = " 0 "   s d k T y p e = " S N M P : S n m p D e v i c e " > 
 < e v e n t   t y p e = ' O n T r a p '   k i n d = ' t r i g g e r '   a c t i v e = ' f a l s e ' > 
 < s c r i p t   e n c o d e d = ' f a l s e ' > < ! [ C D A T A [ / /   A u t h o r   C h r i s t i a n   S t r i j b o s   ( c s @ v c o p o r t a l . d e ) 
 / /   b a s e d   o n   E x a m p l e s   a n d   a   B l o g   P o s t   o f     W i l l i a m   L a m 
 / /   S N M P   P o l i c y   t o   C h e c k   f o r   H o s t   M a i n t e n a n c e   i n   c a s e   o f   a n   h o s t   e r r o r 
 
 / /   E x e c u t e   H o s t   M a i n t e n a c e   a f t e r   t r a p   I D 
 v a r   w f I d   =   " 8 3 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 8 0 E 5 8 B 8 0 8 0 0 1 3 4 5 4 6 4 2 0 7 2 9 8 a e b f 2 a 6 a 5 a 5 " ; 
 
 
 / /   p r o c e s s   S N M P   t r a p 
 v a r   k e y   =   e v e n t . g e t V a l u e ( " k e y " ) ; 
 v a r   s n m p R e s u l t   =   S n m p S e r v i c e . r e t r i e v e P o l i c y D a t a ( k e y ) ; 
 v a r   t r a p D a t a   =   S y s t e m . g e t M o d u l e ( " c o m . v m w a r e . l i b r a r y . s n m p " ) . p r o c e s s S n m p R e s u l t ( s n m p R e s u l t ) ; 
 r u n W F ( w f I d , t r a p D a t a ) ; 
 
 / /   f u n c t i o n   t o   l a u n c h   W F   
 f u n c t i o n   r u n W F ( w f I d , t r a p D a t a )   { 
 	 v a r   w o r k f l o w T o L a u n c h   =   S e r v e r . g e t W o r k f l o w W i t h I d ( w f I d ) ; 
 	 i f   ( w o r k f l o w T o L a u n c h   = =   n u l l )   { 
   	 	 t h r o w   " W o r k f l o w   n o t   f o u n d " ; 	 
 	 } 
 	 v a r   w o r k f l o w P a r a m e t e r s   =   n e w   P r o p e r t i e s ( ) ; 
 	 w o r k f l o w P a r a m e t e r s . p u t ( " t r a p D a t a " , t r a p D a t a ) ; 
 	 S y s t e m . l o g ( " L a u n c h i n g   E x e c u t e   H o s t   M a i n t e n a c e   a f t e r   t r a p   W F :   "   +   w f I d ) ; 
 	 v a r   w f T o k e n   =   w o r k f l o w T o L a u n c h . e x e c u t e ( w o r k f l o w P a r a m e t e r s ) ; 
 } 
 
 ] ] > < / s c r i p t > 
 < / e v e n t > 
 < / i t e m > 
 < / d u n e s - p o l i c y >