METHOD_0 ( ) { org . apache . IDENT_0 . Context context = new org . apache . IDENT_0 . Context ( ) ; context . put ( org . apache . IDENT_1 . IDENT_0 . IDENT_2 . IDENT_3 . IDENT_4 . IDENT_5 , org . apache . IDENT_1 . IDENT_0 . IDENT_2 . IDENT_3 . IDENT_6 . IDENT_7 ) ; context . put ( org . apache . IDENT_1 . IDENT_0 . IDENT_2 . IDENT_3 . IDENT_4 . IDENT_8 , IDENT_9 ) ; org . apache . IDENT_1 . IDENT_0 . IDENT_2 . IDENT_3 . IDENT_10 IDENT_3 = new org . apache . IDENT_1 . IDENT_0 . IDENT_2 . IDENT_3 . METHOD_1 ( ) ; org . apache . IDENT_0 . conf . IDENT_11 . METHOD_2 ( IDENT_3 , context ) ; org . apache . IDENT_0 . channel . IDENT_12 channel = new org . apache . IDENT_0 . channel . METHOD_3 ( ) ; org . apache . IDENT_0 . conf . IDENT_11 . METHOD_2 ( channel , context ) ; IDENT_3 . METHOD_4 ( channel ) ; IDENT_3 . start ( ) ; org . apache . IDENT_0 . IDENT_13 . Status status = IDENT_3 . process ( ) ; "<AssertPlaceHolder>" ; IDENT_3 . METHOD_5 ( ) ; } process ( ) { org . apache . IDENT_0 . IDENT_14 channel = METHOD_6 ( ) ; org . apache . IDENT_0 . IDENT_15 transaction = null ; try { transaction = channel . METHOD_7 ( ) ; transaction . METHOD_8 ( ) ; java . util . concurrent . IDENT_16 IDENT_17 = new java . util . concurrent . METHOD_9 ( events . size ( ) ) ; java . util . concurrent . atomic . IDENT_18 IDENT_19 = new java . util . concurrent . atomic . METHOD_10 ( ) ; for ( org . apache . IDENT_0 . IDENT_20 event : events ) { byte [ ] body = event . METHOD_11 ( ) ; org . apache . IDENT_1 . common . message . Message message = new org . apache . IDENT_1 . common . message . Message ( IDENT_21 , IDENT_9 , body ) ; if ( org . apache . IDENT_1 . IDENT_0 . IDENT_2 . IDENT_3 . METHOD_1 . log . METHOD_12 ( ) ) { org . apache . IDENT_1 . IDENT_0 . IDENT_2 . IDENT_3 . METHOD_1 . log . debug ( STRING_0 , new java . lang . String ( body , STRING_1 ) ) ; } IDENT_22 . METHOD_13 ( message , new org . apache . IDENT_1 . IDENT_0 . IDENT_2 . IDENT_3 . METHOD_1 . METHOD_14 ( message , IDENT_17 , IDENT_19 ) ) ; } IDENT_17 . METHOD_15 ( ) ; IDENT_23 . METHOD_16 ( events . size ( ) ) ; if ( ( IDENT_19 . get ( ) ) > 0 ) { org . apache . IDENT_1 . IDENT_0 . IDENT_2 . IDENT_3 . METHOD_1 . log . error ( ( ( STRING_2 + IDENT_19 ) + STRING_3 ) ) ; transaction . METHOD_17 ( ) ; return Status . IDENT_24 ; } else { transaction . commit ( ) ; IDENT_23 . METHOD_18 ( events . size ( ) ) ; return Status . IDENT_25 ; } } catch ( java . lang . Exception e ) { org . apache . IDENT_1 . IDENT_0 . IDENT_2 . IDENT_3 . METHOD_1 . log . error ( STRING_4 , e ) ; if ( transaction != null ) { try { transaction . METHOD_17 ( ) ; } catch ( java . lang . Exception ex ) { org . apache . IDENT_1 . IDENT_0 . IDENT_2 . IDENT_3 . METHOD_1 . log . error ( STRING_5 , ex ) ; throw new org . apache . IDENT_0 . METHOD_19 ( STRING_5 , ex ) ; } } return Status . IDENT_24 ; } finally { if ( transaction != null ) { transaction . close ( ) ; } } }
org . junit . Assert . assertEquals ( status , IDENT_13 . Status . IDENT_24 )