Buggy code:
public final class ModelParser { private static final Pattern SIZE_PATTERN = Pattern . compile ( "(\\d+)([kKmMgGbBtT])?" ) ; private ModelParser ( ) { } public static Filter parseFilter ( final OperationContext context , final ModelNode node ) throws OperationFailedException { if ( node . hasDefined ( ACCEPT . getName ( ) ) ) { return AcceptAllFilter . getInstance ( ) ; } else if ( node . hasDefined ( ALL . getName ( ) ) ) { final List < Filter > filters = new ArrayList < Filter > ( ) ; for ( ModelNode n : node . get ( ALL . getName ( ) ) . asList ( ) ) { filters . add ( ModelParser . parseFilter ( context , n ) ) ; } return new AllFilter ( filters ) ; } else if ( node . hasDefined ( ANY . getName ( ) ) ) { final List < Filter > filters = new ArrayList < Filter > ( ) ; for ( ModelNode n : node . get ( ANY . getName ( ) ) . asList ( ) ) { filters . add ( ModelParser . parseFilter ( context , n ) ) ; } return new AnyFilter ( filters ) ; } else if ( node . hasDefined ( CHANGE_LEVEL . getName ( ) ) ) { return new org . jboss . logmanager . filters . LevelChangingFilter ( ModelParser . parseLevel ( CHANGE_LEVEL . resolveModelAttribute ( context , node ) ) ) ; } else if ( node . hasDefined ( DENY . getName ( ) ) ) { return DenyAllFilter . getInstance ( ) ; } else if ( node . hasDefined ( LEVEL . getName ( ) ) ) { return new org . jboss . logmanager . filters . LevelFilter ( ModelParser . parseLevel ( LEVEL . resolveModelAttribute ( context , node ) ) ) ; } else if ( node . hasDefined ( LEVEL_RANGE . getName ( ) ) ) { final Level min = ModelParser . parseLevel ( MIN_LEVEL . resolveModelAttribute ( context , node ) ) ; final Level max = ModelParser . parseLevel ( MAX_LEVEL . resolveModelAttribute ( context , node ) ) ; final boolean minInclusive = MIN_INCLUSIVE . resolveModelAttribute ( context , node ) . asBoolean ( ) ; final boolean maxInclusive = MAX_INCLUSIVE . resolveModelAttribute ( context , node ) . asBoolean ( ) ; return new LevelRangeFilter ( min , minInclusive , max , maxInclusive ) ; } else if ( node . hasDefined ( MATCH . getName ( ) ) ) { <START_BUG> return new org . jboss . logmanager . filters . RegexFilter ( PATTERN . resolveModelAttribute ( context , node ) . asString ( ) ) ; <END_BUG> } else if ( node . hasDefined ( NOT . getName ( ) ) ) { return new org . jboss . logmanager . filters . InvertFilter ( ModelParser . parseFilter ( context , NOT . resolveModelAttribute ( context , node ) ) ) ; } else if ( node . hasDefined ( REPLACE . getName ( ) ) ) { final String pattern = PATTERN . resolveModelAttribute ( context , node ) . asString ( ) ; final String replacement = REPLACEMENT . resolveModelAttribute ( context , node ) . asString ( ) ; final boolean replaceAll = REPLACE_ALL . resolveModelAttribute ( context , node ) . asBoolean ( ) ; return new SubstituteFilter ( pattern , replacement , replaceAll ) ; } final String name = ( node . hasDefined ( FILTER . getName ( ) ) ) ? node . get ( FILTER . getName ( ) ) . asString ( ) : node . asString ( ) ; throw new OperationFailedException ( new ModelNode ( ) . set ( LoggingMessages . MESSAGES . invalidFilter ( name ) ) ) ; } public static long parseSize ( final ModelNode node ) throws OperationFailedException { } public static Level parseLevel ( final ModelNode node ) throws OperationFailedException { } public static OverflowAction parseOverflowAction ( final ModelNode node ) throws OperationFailedException { } }

Fix:
return new org . jboss . logmanager . filters . RegexFilter ( MATCH . resolveModelAttribute ( context , node ) . asString ( ) ) ;