final StandaloneServerConfig server =
StandaloneServerConfigTest.ensureDefaultInstance( getDomainRoot() );
assert server != null;
if ( server.getResourceRefConfigMap().get( rc.getName() ) != null )
{
warning( "ResourceRefConfig already exists for: " + rc.getName() );
}
else
{
try
{
server.createResourceRefConfig( rc.getName(), false );
}
catch( Exception e )
{
final Throwable rootCause = ExceptionUtil.getRootCause( e );
warning( "Couldn't add RefConfig to: " + Util.getObjectName( rc ) );
}
}
assert server.getResourceRefConfigMap().get( rc.getName() ) != null;