Bug 779150 (SOA-1546)

Summary: "javax.naming.NameNotFoundException: InquiryService not bound" during server shutdown.
Product: [JBoss] JBoss Enterprise SOA Platform 4 Reporter: Pavel Macik <pmacik>
Component: JBossESBAssignee: Kevin Conner <kevin.conner>
Status: CLOSED NEXTRELEASE QA Contact:
Severity: high Docs Contact:
Priority: high    
Version: 4.3 CP02CC: dlesage
Target Milestone: ---   
Target Release: 4.3 CP04 ER1   
Hardware: Unspecified   
OS: Unspecified   
URL: http://jira.jboss.org/jira/browse/SOA-1546
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
RHEL5-x86_64, Sun JDK 1.6.0_13-x86_64
Last Closed: 2010-03-24 09:10:01 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Deadline: 2010-03-08   
Attachments:
Description Flags
server.log.zip none

Description Pavel Macik 2009-10-23 09:50:22 UTC
Date of First Response: 2009-12-02 05:31:17
Help Desk Ticket Reference: https://enterprise.redhat.com/issue-tracker/453363
project_key: SOA

During server shut-down (via CTRL+C) the following exception occurs:

2009-10-22 17:51:49,505 INFO  [org.jboss.internal.soa.esb.dependencies.JuddiRMIService] (JBoss Shutdown Hook) Unbinding juddi services
2009-10-22 17:51:49,505 WARN  [org.jboss.internal.soa.esb.dependencies.JuddiRMIService] (JBoss Shutdown Hook) Stopping failed jboss.esb:service=JuddiRMI
javax.naming.NameNotFoundException: InquiryService not bound
	at org.jnp.server.NamingServer.getBinding(NamingServer.java:771)
	at org.jnp.server.NamingServer.getBinding(NamingServer.java:779)
	at org.jnp.server.NamingServer.unbind(NamingServer.java:349)
	at org.jnp.interfaces.NamingContext.unbind(NamingContext.java:871)
	at org.jnp.interfaces.NamingContext.unbind(NamingContext.java:854)
	at javax.naming.InitialContext.unbind(InitialContext.java:416)
	at org.jboss.internal.soa.esb.dependencies.JuddiRMIService.stopService(JuddiRMIService.java:133)
	at org.jboss.system.ServiceMBeanSupport.jbossInternalStop(ServiceMBeanSupport.java:405)
	at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:324)
	at sun.reflect.GeneratedMethodAccessor81.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157)
	at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96)
	at org.jboss.mx.server.Invocation.invoke(Invocation.java:88)
	at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
	at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:668)
	at org.jboss.system.microcontainer.ServiceProxy.invoke(ServiceProxy.java:189)
	at $Proxy38.stop(Unknown Source)
	at org.jboss.system.microcontainer.StartStopLifecycleAction.uninstallAction(StartStopLifecycleAction.java:56)
	at org.jboss.system.microcontainer.StartStopLifecycleAction.uninstallAction(StartStopLifecycleAction.java:37)
	at org.jboss.dependency.plugins.action.SimpleControllerContextAction.simpleUninstallAction(SimpleControllerContextAction.java:79)
	at org.jboss.dependency.plugins.action.AccessControllerContextAction.uninstall(AccessControllerContextAction.java:131)
	at org.jboss.dependency.plugins.AbstractControllerContextActions.uninstall(AbstractControllerContextActions.java:58)
	at org.jboss.dependency.plugins.AbstractControllerContext.uninstall(AbstractControllerContext.java:354)
	at org.jboss.dependency.plugins.AbstractController.uninstall(AbstractController.java:1665)
	at org.jboss.dependency.plugins.AbstractController.uninstallContext(AbstractController.java:1276)
	at org.jboss.dependency.plugins.AbstractController.uninstallContext(AbstractController.java:1180)
	at org.jboss.dependency.plugins.AbstractController.uninstallContext(AbstractController.java:1235)
	at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:828)
	at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:553)
	at org.jboss.system.ServiceController.doChange(ServiceController.java:688)
	at org.jboss.system.ServiceController.stop(ServiceController.java:510)
	at org.jboss.system.deployers.ServiceDeployer.stop(ServiceDeployer.java:170)
	at org.jboss.system.deployers.ServiceDeployer.undeploy(ServiceDeployer.java:150)
	at org.jboss.system.deployers.ServiceDeployer.undeploy(ServiceDeployer.java:46)
	at org.jboss.deployers.spi.deployer.helpers.AbstractSimpleRealDeployer.internalUndeploy(AbstractSimpleRealDeployer.java:69)
	at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.undeploy(AbstractRealDeployer.java:112)
	at org.jboss.deployers.plugins.deployers.DeployerWrapper.undeploy(DeployerWrapper.java:196)
	at org.jboss.deployers.plugins.deployers.DeployersImpl.doUndeploy(DeployersImpl.java:1470)
	at org.jboss.deployers.plugins.deployers.DeployersImpl.doUninstallParentLast(DeployersImpl.java:1377)
	at org.jboss.deployers.plugins.deployers.DeployersImpl.doUninstallParentLast(DeployersImpl.java:1370)
	at org.jboss.deployers.plugins.deployers.DeployersImpl.doUninstallParentLast(DeployersImpl.java:1357)
	at org.jboss.deployers.plugins.deployers.DeployersImpl.uninstall(DeployersImpl.java:1332)
	at org.jboss.dependency.plugins.AbstractControllerContext.uninstall(AbstractControllerContext.java:354)
	at org.jboss.dependency.plugins.AbstractController.uninstall(AbstractController.java:1665)
	at org.jboss.dependency.plugins.AbstractController.uninstallContext(AbstractController.java:1276)
	at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:828)
	at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:553)
	at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:695)
	at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:679)
	at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.process(MainDeployerAdapter.java:117)
	at org.jboss.system.server.profileservice.repository.ProfileDeployAction.uninstall(ProfileDeployAction.java:95)
	at org.jboss.system.server.profileservice.repository.AbstractProfileAction.uninstall(AbstractProfileAction.java:70)
	at org.jboss.system.server.profileservice.repository.AbstractProfileService.uninstall(AbstractProfileService.java:417)
	at org.jboss.dependency.plugins.AbstractControllerContext.uninstall(AbstractControllerContext.java:354)
	at org.jboss.dependency.plugins.AbstractController.uninstall(AbstractController.java:1665)
	at org.jboss.dependency.plugins.AbstractController.uninstallContext(AbstractController.java:1276)
	at org.jboss.dependency.plugins.AbstractController.uninstallContext(AbstractController.java:1180)
	at org.jboss.dependency.plugins.AbstractController.uninstallContext(AbstractController.java:1235)
	at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:828)
	at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:553)
	at org.jboss.system.server.profileservice.repository.AbstractProfileService.deactivateProfile(AbstractProfileService.java:448)
	at org.jboss.system.server.profileservice.ProfileServiceBootstrap.deactivateProfiles(ProfileServiceBootstrap.java:381)
	at org.jboss.system.server.profileservice.ProfileServiceBootstrap.shutdown(ProfileServiceBootstrap.java:339)
	at org.jboss.bootstrap.AbstractServerImpl.shutdownServer(AbstractServerImpl.java:571)
	at org.jboss.bootstrap.AbstractServerImpl$ShutdownHook.run(AbstractServerImpl.java:909)

Comment 1 Pavel Macik 2009-10-23 09:53:33 UTC
Attached whole server log

Comment 2 Pavel Macik 2009-10-23 09:53:33 UTC
Attachment: Added: server.log.zip


Comment 3 Pavel Macik 2009-10-23 10:02:19 UTC
I can't see the exception neither in the EAP nor in the ESB nor in the AS... just in SOA-P. 

Comment 4 trev 2009-12-02 10:31:17 UTC
Juddi code has changed since ER1 removing SOA 5 fix version as this jisra is no longer applicable

Comment 5 Martin Weiler 2010-02-16 12:06:18 UTC
Help Desk Ticket Reference: Added: https://enterprise.redhat.com/issue-tracker/453363


Comment 6 Martin Weiler 2010-02-16 12:10:11 UTC
I could reproduce this error by starting SOA-P 4.3 CP02 in a clustered profile and the -b <IP> switch:

./bin/run.sh -c production -b x.x.x.x

If I start the same instance with -b 0.0.0.0, I get a different error message at server shutdown:

ERROR [MessagingXAResourceWrapper] ********************************Failed to connect to server
javax.naming.NameNotFoundException: DefaultJMSProvider not bound
	at org.jnp.server.NamingServer.getBinding(NamingServer.java:581)
	at org.jnp.server.NamingServer.getBinding(NamingServer.java:589)
	at org.jnp.server.NamingServer.getObject(NamingServer.java:595)
	at org.jnp.server.NamingServer.lookup(NamingServer.java:342)
	at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:667)
	at org.jnp.interfaces.NamingContext.lookup(NamingContext.java:627)
	at javax.naming.InitialContext.lookup(InitialContext.java:409)


Comment 8 Anne-Louise Tangring 2010-02-25 17:51:49 UTC
Suggested for SOA 4.3 CP03, needs approval.

Comment 9 Anne-Louise Tangring 2010-03-05 14:29:23 UTC
Approved for SOA 4.3 CP03, if done by due date. 

Comment 10 Kevin Conner 2010-03-09 10:16:17 UTC
I have tried without success to reproduce this issue and the only theory I can come up with is a discrepancy between the juddi codebase responsible for registering the entries in JNDI and our MBean, which eventually unbinds them.

The juddi codebase (and our current configuration) forces the JNDI binding to take place over RMI, whereas the unbind in our MBean uses the default InitialContext.  One possible scenario could be that the RMI lookup is failing, forcing the fallback to the discovery mechanism.

In any case the juddi JNDI accesses should be using the local server, rather than over RMI, so I will make that change.



Comment 11 Kevin Conner 2010-03-09 10:18:19 UTC
Link: Added: This issue depends JBESB-3202


Comment 12 Kevin Conner 2010-03-09 10:40:49 UTC
The binding now takes place using the local JNDI server, hopefully addressing this issue.  The issue raised by Martin is not the same as this one.

If this reappears, please create a new issue and link it to this one.

Comment 13 Kevin Conner 2010-03-09 10:41:17 UTC
Updated in ESB codebase, will be in next merge.

Comment 14 David Le Sage 2010-03-09 23:23:50 UTC
The draft text for the Resolved Issues section of the Release Notes states:

https://jira.jboss.org/jira/browse/JBESB-3202

    Whilst the server was shutting down, a javax.naming.NameNotFoundException:
    InquiryService not bound exception could occur. This appears to have been caused by a
    discrepancy between the jUDDI codebase responsible for registering the entries in JNDI and the
    MBean which eventually unbinds them. This is because the binding was occurring over RMI whilst
    the MBean was using the default InitialContext. The code has now been changed so that
    JNDI accesses no longer occur over RMI. Rather, the local server is used.


Comment 15 Pavel Macik 2010-03-24 09:10:01 UTC
Verified in ER1