ConfigurationUtil.configure(configuration, ejbJar);
setConfigured(true);
//TODO not clear if schema allows/should allow security == null
if (security != null) {
RoleMappingsType roleMappings = security.getRoleMappings();
if (roleMappings != null) {
RoleType[] roles = roleMappings.getRoleArray();
for (int i = 0; i < roles.length; i++) {
RoleType role = roles[i];
RealmType[] realms = role.getRealmArray();
for (int j = 0; j < realms.length; j++) {
RealmType realm = realms[j];