0 Replies Latest reply on Oct 13, 2004 4:25 AM by sfrind

    MBean (wrapper for own RMI server) needs stop and start to w

    sfrind Newbie

      Hello,

      I have created a very simple MBean which creates a registry and binds an RMIServer.

      It works when I deploy it with a jboss server with minimal configuration.
      When I start jboss with default configuration I have to stop my mbean and have to start it again to get it work.
      Any ideas? Which other mbeans, services break my RMI registry?
      I have created a gfd.sar directory under deploy directory.

      Here some log of the server.log with default configuration. I have the fealing that my mbean is deployed twice.
      2004-10-13 10:13:59,396 DEBUG [org.jboss.deployment.MainDeployer] Starting deployment of package: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/
      2004-10-13 10:13:59,396 DEBUG [org.jboss.deployment.MainDeployer] Starting deployment (init step) of package at: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/
      2004-10-13 10:13:59,396 DEBUG [org.jboss.deployment.MainDeployer] using deployer org.jboss.deployment.SARDeployer@12bb7e0
      2004-10-13 10:13:59,406 DEBUG [org.jboss.deployment.SARDeployer] about to copy 0 local directories
      2004-10-13 10:13:59,406 DEBUG [org.jboss.deployment.SARDeployer] looking for nested deployments in : file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/
      2004-10-13 10:13:59,406 DEBUG [org.jboss.deployment.SARDeployer] nested deployment: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar
      2004-10-13 10:13:59,406 DEBUG [org.jboss.management.j2ee.LocalJBossServerDomain] handleNotification: javax.management.Notification[source=jboss.system:service=ServiceDeployer,type=org.jboss.deployment.SubDeployer.init,sequenceNumber=5,timeStamp=1097655239406,message=null,userData=org.jboss.deployment.DeploymentInfo@cacca2cf { url=file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/ }
      deployer: org.jboss.deployment.SARDeployer@12bb7e0
      status: null
      state: INIT_DEPLOYER
      watch: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/META-INF/jboss-service.xml
      lastDeployed: 0
      lastModified: 0
      mbeans:
      ]
      2004-10-13 10:13:59,406 DEBUG [org.jboss.deployment.DeploymentInfo] createLoaderRepository from config: LoaderRepositoryConfig(repositoryName: JMImplementation:service=LoaderRepository,name=Default, repositoryClassName: null, configParserClassName: null, repositoryConfig: null)
      2004-10-13 10:13:59,406 DEBUG [org.jboss.mx.loading.UnifiedClassLoader] New jmx UCL with url file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/
      2004-10-13 10:13:59,406 DEBUG [org.jboss.mx.loading.UnifiedClassLoader] setRepository, r=org.jboss.mx.loading.UnifiedLoaderRepository3@482923, ucl=org.jboss.mx.loading.UnifiedClassLoader3@2d189c{ url=file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/ ,addedOrder=0}
      2004-10-13 10:13:59,406 DEBUG [org.jboss.mx.loading.UnifiedClassLoader] setRepository, r=org.jboss.mx.loading.UnifiedLoaderRepository3@482923, ucl=org.jboss.mx.loading.UnifiedClassLoader3@2d189c{ url=file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/ ,addedOrder=0}
      2004-10-13 10:13:59,406 DEBUG [org.jboss.mx.loading.UnifiedLoaderRepository3] Adding org.jboss.mx.loading.UnifiedClassLoader3@2d189c{ url=file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/ ,addedOrder=0}
      2004-10-13 10:13:59,406 DEBUG [org.jboss.mx.loading.ClassLoaderUtils] Multiple class loaders found for pkg:
      2004-10-13 10:13:59,406 DEBUG [org.jboss.deployment.MainDeployer] found 1 subpackages of file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/
      2004-10-13 10:13:59,406 DEBUG [org.jboss.deployment.MainDeployer] Starting deployment (init step) of package at: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar
      2004-10-13 10:13:59,406 DEBUG [org.jboss.deployment.MainDeployer] Copying file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar -> E:\jboss-3.2.5\server\default\tmp\deploy\tmp40870gfdtest.jar
      2004-10-13 10:13:59,406 DEBUG [org.jboss.deployment.JARDeployer] No META-INF or WEB-INF resource found, assuming it if for us
      2004-10-13 10:13:59,416 DEBUG [org.jboss.deployment.MainDeployer] using deployer org.jboss.deployment.JARDeployer@e80842
      2004-10-13 10:13:59,416 DEBUG [org.jboss.deployment.JARDeployer] looking for nested deployments in : file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar
      2004-10-13 10:13:59,416 DEBUG [org.jboss.management.j2ee.LocalJBossServerDomain] handleNotification: javax.management.Notification[source=jboss.system:service=JARDeployer,type=org.jboss.deployment.SubDeployer.init,sequenceNumber=3,timeStamp=1097655239416,message=null,userData=org.jboss.deployment.DeploymentInfo@32b5f4cb { url=file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar }
      deployer: org.jboss.deployment.JARDeployer@e80842
      status: null
      state: INIT_DEPLOYER
      watch: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar
      lastDeployed: 0
      lastModified: 0
      mbeans:
      ]
      2004-10-13 10:13:59,426 DEBUG [org.jboss.mx.loading.UnifiedClassLoader] Added url: file:/E:/jboss-3.2.5/server/default/tmp/deploy/tmp40870gfdtest.jar, to ucl: org.jboss.mx.loading.UnifiedClassLoader3@2d189c{ url=file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/ ,addedOrder=3}
      2004-10-13 10:13:59,426 DEBUG [org.jboss.deployment.MainDeployer] found 0 subpackages of file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar
      2004-10-13 10:13:59,426 DEBUG [org.jboss.deployment.MainDeployer] Watching new file: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar
      2004-10-13 10:13:59,426 DEBUG [org.jboss.deployment.MainDeployer] Watching new file: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/
      2004-10-13 10:13:59,426 DEBUG [org.jboss.deployment.MainDeployer] create step for deployment file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/
      2004-10-13 10:13:59,426 DEBUG [org.jboss.deployment.MainDeployer] create step for deployment file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar
      2004-10-13 10:13:59,426 DEBUG [org.jboss.management.j2ee.LocalJBossServerDomain] handleNotification: javax.management.Notification[source=jboss.system:service=JARDeployer,type=org.jboss.deployment.SubDeployer.create,sequenceNumber=4,timeStamp=1097655239426,message=null,userData=org.jboss.deployment.DeploymentInfo@32b5f4cb { url=file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar }
      deployer: org.jboss.deployment.JARDeployer@e80842
      status: null
      state: CREATE_DEPLOYER
      watch: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar
      lastDeployed: 1097655239426
      lastModified: 1097655239406
      mbeans:
      ]
      2004-10-13 10:13:59,426 DEBUG [org.jboss.deployment.MainDeployer] Done with create step of deploying gfdtest.jar
      2004-10-13 10:13:59,426 DEBUG [org.jboss.deployment.SARDeployer] Deploying SAR, create step: url file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/
      2004-10-13 10:13:59,426 DEBUG [org.jboss.deployment.SARDeployer] Registering service UCL=jmx.loading:UCL=2d189c
      2004-10-13 10:13:59,436 DEBUG [org.jboss.mx.modelmbean.ModelMBeanInvoker] No persistence-manager descriptor found, null persistence will be used
      2004-10-13 10:13:59,436 DEBUG [org.jboss.system.ServiceCreator] About to create bean: user:service=GFDServer with code: de.gebit.test.GFDServer
      2004-10-13 10:13:59,436 DEBUG [org.jboss.mx.modelmbean.ModelMBeanInvoker] No persistence-manager descriptor found, null persistence will be used
      2004-10-13 10:13:59,446 DEBUG [org.jboss.system.ServiceCreator] Created bean: user:service=GFDServer
      2004-10-13 10:13:59,446 DEBUG [org.jboss.system.ServiceController] Creating service user:service=GFDServer
      2004-10-13 10:13:59,446 DEBUG [de.gebit.test.GFDServer] Creating user:service=GFDServer
      2004-10-13 10:13:59,446 DEBUG [de.gebit.test.GFDServer] Created user:service=GFDServer
      2004-10-13 10:13:59,446 DEBUG [org.jboss.management.j2ee.LocalJBossServerDomain] handleNotification: javax.management.Notification[source=jboss.system:service=ServiceController,type= org.jboss.system.ServiceMBean.create,sequenceNumber=48,timeStamp=1097655239446,message=null,userData=user:service=GFDServer]
      2004-10-13 10:13:59,446 DEBUG [org.jboss.management.j2ee.factory.DefaultManagedObjectFactoryMap] Failed to find factory for event: javax.management.Notification[source=jboss.system:service=ServiceController,type= org.jboss.system.ServiceMBean.create,sequenceNumber=48,timeStamp=1097655239446,message=null,userData=user:service=GFDServer]
      2004-10-13 10:13:59,456 DEBUG [org.jboss.system.ServiceController] Creating dependent components for: user:service=GFDServer dependents are: []
      2004-10-13 10:13:59,456 DEBUG [org.jboss.management.j2ee.LocalJBossServerDomain] handleNotification: javax.management.Notification[source=jboss.system:service=ServiceDeployer,type=org.jboss.deployment.SubDeployer.create,sequenceNumber=6,timeStamp=1097655239456,message=null,userData=org.jboss.deployment.DeploymentInfo@cacca2cf { url=file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/ }
      deployer: org.jboss.deployment.SARDeployer@12bb7e0
      status: null
      state: CREATE_DEPLOYER
      watch: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/META-INF/jboss-service.xml
      lastDeployed: 1097655239426
      lastModified: 1097502074636
      mbeans:
      user:service=GFDServer state: Created
      ]
      2004-10-13 10:13:59,456 DEBUG [org.jboss.deployment.MainDeployer] Done with create step of deploying gfd.sar
      2004-10-13 10:13:59,456 DEBUG [org.jboss.deployment.MainDeployer] Begin deployment start file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/
      2004-10-13 10:13:59,456 DEBUG [org.jboss.deployment.MainDeployer] Begin deployment start file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar
      2004-10-13 10:13:59,456 DEBUG [org.jboss.management.j2ee.LocalJBossServerDomain] handleNotification: javax.management.Notification[source=jboss.system:service=JARDeployer,type=org.jboss.deployment.SubDeployer.start,sequenceNumber=5,timeStamp=1097655239456,message=null,userData=org.jboss.deployment.DeploymentInfo@32b5f4cb { url=file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar }
      deployer: org.jboss.deployment.JARDeployer@e80842
      status: Starting
      state: START_DEPLOYER
      watch: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar
      lastDeployed: 1097655239426
      lastModified: 1097655239406
      mbeans:
      ]
      2004-10-13 10:13:59,456 DEBUG [org.jboss.management.j2ee.factory.DefaultManagedObjectFactoryMap] Failed to find factory for event: javax.management.Notification[source=jboss.system:service=JARDeployer,type=org.jboss.deployment.SubDeployer.start,sequenceNumber=5,timeStamp=1097655239456,message=null,userData=org.jboss.deployment.DeploymentInfo@32b5f4cb { url=file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar }
      deployer: org.jboss.deployment.JARDeployer@e80842
      status: Starting
      state: START_DEPLOYER
      watch: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/gfdtest.jar
      lastDeployed: 1097655239426
      lastModified: 1097655239406
      mbeans:
      ]
      2004-10-13 10:13:59,456 DEBUG [org.jboss.deployment.MainDeployer] End deployment start on package: gfdtest.jar
      2004-10-13 10:13:59,456 DEBUG [org.jboss.deployment.SARDeployer] Deploying SAR, start step: url file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/
      2004-10-13 10:13:59,456 DEBUG [org.jboss.system.ServiceController] starting service user:service=GFDServer
      2004-10-13 10:13:59,456 DEBUG [de.gebit.test.GFDServer] Starting user:service=GFDServer
      2004-10-13 10:13:59,466 INFO [de.gebit.test.GFDServer] getRegistry: found registry
      2004-10-13 10:14:00,388 INFO [de.gebit.test.GFDServer] getRegistry: registry list not successful: Connection refused to host: localhost; nested exception is:
      java.net.ConnectException: Connection refused: connect
      2004-10-13 10:14:00,398 INFO [de.gebit.test.GFDServer] createRegistry: registry created
      2004-10-13 10:14:00,398 INFO [de.gebit.test.GFDServer] startService: registry fetched
      2004-10-13 10:14:00,398 INFO [de.gebit.test.GFDServer] startService: remote object bound
      2004-10-13 10:14:00,398 DEBUG [de.gebit.test.GFDServer] Started user:service=GFDServer
      2004-10-13 10:14:00,398 DEBUG [org.jboss.management.j2ee.LocalJBossServerDomain] handleNotification: javax.management.Notification[source=jboss.system:service=ServiceController,type= org.jboss.system.ServiceMBean.start,sequenceNumber=49,timeStamp=1097655240398,message=null,userData=user:service=GFDServer]
      2004-10-13 10:14:00,398 DEBUG [org.jboss.system.ServiceController] Starting dependent components for: user:service=GFDServer dependent components: []
      2004-10-13 10:14:00,398 DEBUG [org.jboss.management.j2ee.LocalJBossServerDomain] handleNotification: javax.management.Notification[source=jboss.system:service=ServiceDeployer,type=org.jboss.deployment.SubDeployer.start,sequenceNumber=7,timeStamp=1097655240398,message=null,userData=org.jboss.deployment.DeploymentInfo@cacca2cf { url=file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/ }
      deployer: org.jboss.deployment.SARDeployer@12bb7e0
      status: Starting
      state: START_DEPLOYER
      watch: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/META-INF/jboss-service.xml
      lastDeployed: 1097655239426
      lastModified: 1097502074636
      mbeans:
      user:service=GFDServer state: Started
      ]
      2004-10-13 10:14:00,408 DEBUG [org.jboss.management.j2ee.J2EEDeployedObject] File: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/, descriptor: META-INF/application.xml
      2004-10-13 10:14:00,428 DEBUG [org.jboss.mx.modelmbean.ModelMBeanInvoker] No persistence-manager descriptor found, null persistence will be used
      2004-10-13 10:14:00,428 DEBUG [org.jboss.management.j2ee.ServiceModule] postRegister(), parent: jboss.management.local:j2eeType=J2EEServer,name=Local
      2004-10-13 10:14:00,428 DEBUG [org.jboss.management.j2ee.ServiceModule] Created JSR-77 ServiceModule, name: gfd.sar
      2004-10-13 10:14:00,428 DEBUG [org.jboss.management.j2ee.factory.ServiceModuleFactory] Created ServiceModule: jboss.management.local:J2EEServer=Local,j2eeType=ServiceModule,name=gfd.sar
      2004-10-13 10:14:00,438 DEBUG [org.jboss.mx.modelmbean.ModelMBeanInvoker] No persistence-manager descriptor found, null persistence will be used
      2004-10-13 10:14:00,438 DEBUG [org.jboss.management.j2ee.MBean] postRegister(), parent: jboss.management.local:J2EEServer=Local,j2eeType=ServiceModule,name=gfd.sar
      2004-10-13 10:14:00,468 DEBUG [org.jboss.management.j2ee.factory.ServiceModuleFactory] Create MBean, name: user:service=GFDServer, SAR Module: jboss.management.local:J2EEServer=Local,j2eeType=ServiceModule,name=gfd.sar
      2004-10-13 10:14:00,468 DEBUG [org.jboss.deployment.MainDeployer] End deployment start on package: gfd.sar
      2004-10-13 10:14:00,468 DEBUG [org.jboss.deployment.MainDeployer] Deployed package: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/
      2004-10-13 10:14:00,468 DEBUG [org.jboss.deployment.scanner.URLDeploymentScanner] Watch URL for: file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/ -> file:/E:/jboss-3.2.5/server/default/deploy/gfd.sar/META-INF/jboss-service.xml


      Thanks a lot,
      Stephan