[jboss-jira] [JBoss JIRA] Commented: (JBPORTAL-1730) IdentityServiceControllerImpl : unregister existing MBean service before to re register them

Thomas Heute (JIRA) jira-events at lists.jboss.org
Thu Apr 3 04:41:02 EDT 2008


    [ http://jira.jboss.com/jira/browse/JBPORTAL-1730?page=comments#action_12406794 ] 
            
Thomas Heute commented on JBPORTAL-1730:
----------------------------------------

Now i understand better :)
When i closed the case i did add calls to unregister before registering, and applied that to the trunk of the identity module.
http://anonsvn.jboss.org/repos/portal/modules/identity/trunk/identity/src/main/java/org/jboss/portal/identity/boot/IdentityServiceLoader.java

 I forgot to apply it on the 1.0 Branch, 
http://anonsvn.jboss.org/repos/portal/modules/identity/branches/JBP_IDENTITY_BRANCH_1_0/identity/src/main/org/jboss/portal/identity/boot/IdentityServiceLoader.java

so it didn't get released in identity 1.0.x and JBP 2.6.x .

Sorry about that, it will be included in 2.6.5

Thanks !



> IdentityServiceControllerImpl : unregister existing MBean service before to re register them
> --------------------------------------------------------------------------------------------
>
>                 Key: JBPORTAL-1730
>                 URL: http://jira.jboss.com/jira/browse/JBPORTAL-1730
>             Project: JBoss Portal
>          Issue Type: Task
>      Security Level: Public(Everyone can see) 
>          Components: Portal Identity
>    Affects Versions: 2.6.1 Final
>            Reporter: Antoine Herzog
>         Assigned To: Thomas Heute
>            Priority: Optional
>             Fix For: 2.6.5 Final
>
>
> In IdentityServiceControllerImpl (service name="portal:service=Module,type=IdentityServiceController")
> the Identity Beans are registered as JMX MBeans.
> When redeploying the service, an exception is thrown, as the services are yet deployed.
> javax.management.InstanceAlreadyExistsException: portal:service=Module,type=User already registered.
> Let's put this code before to register the bean, at line 378 of IdentityServiceControllerImpl.java
> // Unregister the former service is if it is yet there.
> // This to avoid the exception when redeploying this service
> if (getServer().isRegistered(
> 		new ObjectName(module.getServiceName()))) {
> 	getServer().unregisterMBean(
> 			new ObjectName(module.getServiceName()));
> }
> Thanks,

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jboss-jira mailing list