private NotProcessed processSecureAdmin(final TYPE type, final SecureAdmin sa, final PropertyChangeEvent[] events) { /* * Any change to the secure admin config requires a restart. */ return new NotProcessed(restartRequiredMsg); } }
private NotProcessed processSecureAdmin(final TYPE type, final SecureAdmin sa, final PropertyChangeEvent[] events) { /* * Any change to the secure admin config requires a restart. */ return new NotProcessed(restartRequiredMsg); } }
private NotProcessed processDomain(final TYPE type, final Domain d, final PropertyChangeEvent[] events) { for (PropertyChangeEvent event : events) { if ( (event.getOldValue() instanceof SecureAdmin && type == Changed.TYPE.REMOVE) || (event.getNewValue() instanceof SecureAdmin && type == Changed.TYPE.ADD) ) { return new NotProcessed(restartRequiredMsg); } } return null; }
private NotProcessed processDomain(final TYPE type, final Domain d, final PropertyChangeEvent[] events) { for (PropertyChangeEvent event : events) { if ( (event.getOldValue() instanceof SecureAdmin && type == Changed.TYPE.REMOVE) || (event.getNewValue() instanceof SecureAdmin && type == Changed.TYPE.ADD) ) { return new NotProcessed(restartRequiredMsg); } } return null; }
/** * @param event - Event to be processed. * @throws AdminEventListenerException when the listener is unable to * process the event. */ public <T extends ConfigBeanProxy> NotProcessed handleUpdate(T instance) { NotProcessed np = null; if (logger.isLoggable(Level.FINE)) { logger.log(Level.FINE, "MessageSecurityConfigEventListenerImpl - " + "handleUpdate called"); } //Handle only the MessageSecurityConfig. if (instance instanceof MessageSecurityConfig) { GFServerConfigProvider.loadConfigContext(service); } else { np = new NotProcessed("unimplemented: unknown instance: " + instance.getClass().getName()); } return np; }
/** * @param event Event to be processed. * @throws AdminEventListenerException when the listener is unable to * process the event. */ public <T extends ConfigBeanProxy> NotProcessed handleCreate(T instance) { NotProcessed np = null; if (logger.isLoggable(Level.FINE)) { logger.log(Level.FINE, "MessageSecurityConfigEventListenerImpl - " + "handleCreate called"); } if (instance instanceof MessageSecurityConfig) { GFServerConfigProvider.loadConfigContext(service); } else { np = new NotProcessed("unimplemented: unknown instance: " + instance.getClass().getName()); } return np; }
/** * @param event - Event to be processed. * @throws AdminEventListenerException when the listener is unable to * process the event. */ public <T extends ConfigBeanProxy> NotProcessed handleUpdate(T instance) { NotProcessed np = null; if (logger.isLoggable(Level.FINE)) { logger.log(Level.FINE, "MessageSecurityConfigEventListenerImpl - " + "handleUpdate called"); } //Handle only the MessageSecurityConfig. if (instance instanceof MessageSecurityConfig) { GFServerConfigProvider.loadConfigContext(service); } else { np = new NotProcessed("unimplemented: unknown instance: " + instance.getClass().getName()); } return np; }
/** * @param event Event to be processed. * @throws AdminEventListenerException when the listener is unable to * process the event. */ public <T extends ConfigBeanProxy> NotProcessed handleCreate(T instance) { NotProcessed np = null; if (logger.isLoggable(Level.FINE)) { logger.log(Level.FINE, "MessageSecurityConfigEventListenerImpl - " + "handleCreate called"); } if (instance instanceof MessageSecurityConfig) { GFServerConfigProvider.loadConfigContext(service); } else { np = new NotProcessed("unimplemented: unknown instance: " + instance.getClass().getName()); } return np; }
/** * @param event Event to be processed. * @throws AdminEventListenerException when the listener is unable to * process the event. */ public <T extends ConfigBeanProxy> NotProcessed handleDelete(T instance) { NotProcessed np = null; if (logger.isLoggable(Level.FINE)) { logger.log(Level.FINE, "MessageSecurityConfigEventListenerImpl - " + "handleDelete called"); } if (instance instanceof MessageSecurityConfig) { GFServerConfigProvider.loadConfigContext(service); } else { np = new NotProcessed("unimplemented: unknown instance: " + instance.getClass().getName()); } return np; }
/** * @param event Event to be processed. * @throws AdminEventListenerException when the listener is unable to * process the event. */ public <T extends ConfigBeanProxy> NotProcessed handleDelete(T instance) { NotProcessed np = null; if (logger.isLoggable(Level.FINE)) { logger.log(Level.FINE, "MessageSecurityConfigEventListenerImpl - " + "handleDelete called"); } if (instance instanceof MessageSecurityConfig) { GFServerConfigProvider.loadConfigContext(service); } else { np = new NotProcessed("unimplemented: unknown instance: " + instance.getClass().getName()); } return np; }
private <T extends ConfigBeanProxy> NotProcessed handleAddEvent( T instance) { NotProcessed np = null; if(instance instanceof AuthRealm){ authRealmCreated((AuthRealm)instance); }else if (instance instanceof JaccProvider){ np = new NotProcessed( "Cannot change JACC provider once installed, restart required" ); //inject PolicyLoader and try to call loadPolicy //but policyLoader in V2 does not allow reloading of policy provider //once installed. The only option is restart the server }else if (instance instanceof AuditModule){ auditModuleCreated((AuditModule)instance); }else if (instance instanceof MessageSecurityConfig){ // do nothing since we have a Message security config listener } else if (instance instanceof SecurityService) { //since everything exists the only thing that can be added // in terms of Attrs is the defaultPrincipal and defaultPrinPassword // but they are directly used from securityService in core/security } else { np = new NotProcessed( "unimplemented: unknown instance: " + instance.getClass().getName() ); } return np; }
private <T extends ConfigBeanProxy> NotProcessed handleAddEvent( T instance) { NotProcessed np = null; if(instance instanceof AuthRealm){ authRealmCreated((AuthRealm)instance); }else if (instance instanceof JaccProvider){ np = new NotProcessed( "Cannot change JACC provider once installed, restart required" ); //inject PolicyLoader and try to call loadPolicy //but policyLoader in V2 does not allow reloading of policy provider //once installed. The only option is restart the server }else if (instance instanceof AuditModule){ auditModuleCreated((AuditModule)instance); }else if (instance instanceof MessageSecurityConfig){ // do nothing since we have a Message security config listener } else if (instance instanceof SecurityService) { //since everything exists the only thing that can be added // in terms of Attrs is the defaultPrincipal and defaultPrinPassword // but they are directly used from securityService in core/security } else { np = new NotProcessed( "unimplemented: unknown instance: " + instance.getClass().getName() ); } return np; }
private <T extends ConfigBeanProxy> NotProcessed handleRemoveEvent(final T instance) { NotProcessed np = null; if(instance instanceof AuthRealm){ authRealmDeleted((AuthRealm)instance); }else if (instance instanceof JaccProvider){ np = new NotProcessed( "Cannot change JACC provider once installed, restart required" ); //inject PolicyLoader and try to call loadPolicy //but policyLoader in V2 does not allow reloading of policy provider //once installed. The only option is restart the server }else if (instance instanceof AuditModule){ auditModuleDeleted((AuditModule)instance); }else if (instance instanceof MessageSecurityConfig){ //do nothing since we have a message security config listener } else if (instance instanceof SecurityService) { // The only Attrs on securityService whose removal can affect the // security code are those which are stored explicitly // they are getAuditEnabled, getDefaultRealm and getAuditModules // not sure what the effect of removing getDefaultRealm } else { np = new NotProcessed( "unimplemented: unknown instance: " + instance.getClass().getName() ); } return np; }
private <T extends ConfigBeanProxy> NotProcessed handleRemoveEvent(final T instance) { NotProcessed np = null; if(instance instanceof AuthRealm){ authRealmDeleted((AuthRealm)instance); }else if (instance instanceof JaccProvider){ np = new NotProcessed( "Cannot change JACC provider once installed, restart required" ); //inject PolicyLoader and try to call loadPolicy //but policyLoader in V2 does not allow reloading of policy provider //once installed. The only option is restart the server }else if (instance instanceof AuditModule){ auditModuleDeleted((AuditModule)instance); }else if (instance instanceof MessageSecurityConfig){ //do nothing since we have a message security config listener } else if (instance instanceof SecurityService) { // The only Attrs on securityService whose removal can affect the // security code are those which are stored explicitly // they are getAuditEnabled, getDefaultRealm and getAuditModules // not sure what the effect of removing getDefaultRealm } else { np = new NotProcessed( "unimplemented: unknown instance: " + instance.getClass().getName() ); } return np; }
public <T extends ConfigBeanProxy> NotProcessed changed(TYPE type, Class<T> changedType, T changedInstance) { NotProcessed np = null; Object args[]= new Object[]{changedType.getName(),changedInstance}; switch (type) { case ADD: if (logger.isLoggable(Level.FINE)) { logger.log(Level.FINE,"added.instance",args); } np = handleAddEvent(changedInstance); break; case CHANGE: if (logger.isLoggable(Level.FINE)) { logger.log(Level.FINE,"changed.instance",args); } np = handleChangeEvent(changedInstance); break; case REMOVE: if (logger.isLoggable(Level.FINE)) { logger.log(Level.FINE,"removed.instance",args); } np = handleRemoveEvent(changedInstance); break; default: np = new NotProcessed("Unrecognized type of change: " + type); break; } return np; }
np = new NotProcessed("Unrecognized type of change: " + type); break;
np = new NotProcessed("Unrecognized type of change: " + type); break;
authRealmUpdated((AuthRealm)instance); }else if (instance instanceof JaccProvider){ np = new NotProcessed( "Cannot change JACC provider once installed, restart required" ); np = new NotProcessed( "Cannot change JACC provider once installed, restart required" ); np = new NotProcessed( "MappedPrincipalClassname changes for existing applications requires restart and redeployment" ); np = new NotProcessed( "DefaultP2R changes for existng applications requires restart and redeployment" ); np = new NotProcessed( "unimplemented: unknown instance: " + instance.getClass().getName() );
private <T extends ConfigBeanProxy> NotProcessed handleChangeEvent(T instance) { NotProcessed np = null; //TODO V3 handle enabled / disabled /redeploy ? debug("handling change event"); try { if (ConnectorsUtil.isValidEventType(instance)) { if(_logger.isLoggable(Level.FINEST)){ debug("redeploying resource : " + instance); } getResourceDeployer(instance).redeployResource(instance); } else if (ConnectorsUtil.isValidEventType(instance.getParent())) { if(_logger.isLoggable(Level.FINEST)){ debug("redeploying resource due to property change : " + instance.getParent()); } //Added in case of a property change //check for validity of the property's parent and redeploy getResourceDeployer(instance.getParent()).redeployResource(instance.getParent()); } } catch (Exception ex) { final String msg = ApplicationScopedResourcesManager.class.getName() + " : " + "Error while handling change Event"; _logger.severe(msg); np = new NotProcessed(msg); } return np; } }
np = new NotProcessed( localStrings.getLocalString( "resources.resource-manager.remove-event-failed",